You are viewing a plain text version of this content. The canonical link for it is here.
Posted to commits@river.apache.org by gt...@apache.org on 2015/12/06 09:24:02 UTC

svn commit: r1718151 [2/3] - in /river/jtsk/branches/2.2: ./ qa/quarantined-src/ qa/quarantined-src/com/ qa/quarantined-src/com/sun/ qa/quarantined-src/com/sun/jini/ qa/quarantined-src/com/sun/jini/test/ qa/quarantined-src/com/sun/jini/test/impl/ qa/qu...

Modified: river/jtsk/branches/2.2/qa/src/com/sun/jini/test/impl/start/SerializedServiceDescriptors.java
URL: http://svn.apache.org/viewvc/river/jtsk/branches/2.2/qa/src/com/sun/jini/test/impl/start/SerializedServiceDescriptors.java?rev=1718151&r1=1718150&r2=1718151&view=diff
==============================================================================
--- river/jtsk/branches/2.2/qa/src/com/sun/jini/test/impl/start/SerializedServiceDescriptors.java (original)
+++ river/jtsk/branches/2.2/qa/src/com/sun/jini/test/impl/start/SerializedServiceDescriptors.java Sun Dec  6 08:23:59 2015
@@ -21,8 +21,6 @@ import com.sun.jini.qa.harness.TestExcep
 import com.sun.jini.start.LifeCycle;
 import com.sun.jini.start.NonActivatableServiceDescriptor;
 import com.sun.jini.start.ServiceDescriptor;
-import com.sun.jini.start.SharedActivatableServiceDescriptor;
-import com.sun.jini.start.SharedActivationGroupDescriptor;
 
 import java.io.FileInputStream;
 import java.io.FileOutputStream;
@@ -74,52 +72,12 @@ public class SerializedServiceDescriptor
         String[] sharedvm_props = new String[] {// server properties
 		    "com.sun.jini.start.activatewrapper.debug", "init",
 	        };
-        SharedActivationGroupDescriptor sharedvm =
-            new SharedActivationGroupDescriptor(
-	        "/view/resendes/vob/jive/policy/policy.sharedvm",
-	        "/view/resendes/vob/jive/lib/bogus_sharedvm.jar",
-	        sharedVmLog,
-    	        "/bin/java", //server command
-	        new String[] {// server options
-		    "-ea", 
-		},
-	        sharedvm_props);
-
-        SharedActivatableServiceDescriptor sasd = 
-            new SharedActivatableServiceDescriptor(
-	        "http://resendes:8080/mercury-dl.jar",
-	        "http://resendes:8086/policy.mercury",
-	        "http://resendes:8080/mercury.jar",
-	        "com.sun.jini.mercury.MailboxBogusImpl",
-	        sharedVmLog,
-	        new String[] { 
-		    "http://resendes:8089/mercury_service_act.config" 
-		},
-	        true);
-
-        SharedActivatableServiceDescriptor sasdWithExtras = 
-            new SharedActivatableServiceDescriptor(
-	        "http://resendes:8080/mercury-dl.jar",
-	        "http://resendes:8086/policy.mercury",
-	        "http://resendes:8080/mercury.jar",
-	        "com.sun.jini.mercury.MailboxBogusImpl",
-	        sharedVmLog,
-	        new String[] { 
-		    "http://resendes:8089/mercury_service_act.config" 
-		},
-                pp,
-                pp,
-	        true,
-                "localhost",
-                1234);
                 
         ServiceDescriptor[] serviceDescriptors = 
 	    new ServiceDescriptor[] {
 		// sasdWithExtras & nasdWithExtras not written because 
                 // default/recovered preparer and lifecycle objects won't match.
                 nasdWithoutExtras, 
-		sharedvm, 
-		sasd
 	    };
 
         // Serialize service descriptors to a file
@@ -127,17 +85,11 @@ public class SerializedServiceDescriptor
 	ObjectOutput oos = new ObjectOutputStream(f);    
 	oos.writeObject(nasdWithExtras);    
        	oos.writeObject(nasdWithoutExtras);    
-	oos.writeObject(sharedvm);    
-	oos.writeObject(sasd);    
-	oos.writeObject(sasdWithExtras);    
         oos.writeObject(serviceDescriptors);    
 	oos.flush(); 
 	oos.close();
         logger.log(Level.INFO, "Wrote: " + nasdWithExtras);
         logger.log(Level.INFO, "Wrote: " + nasdWithoutExtras);        
-        logger.log(Level.INFO, "Wrote: " + sharedvm);
-        logger.log(Level.INFO, "Wrote: " + sasd);
-        logger.log(Level.INFO, "Wrote: " + sasdWithExtras);
         logger.log(Level.INFO, "Wrote: " + Arrays.asList(serviceDescriptors));
 
         // Deserialize objects from a file.    
@@ -149,24 +101,12 @@ public class SerializedServiceDescriptor
         nasdWithExtras_r.setServicePreparer(pp);
 	NonActivatableServiceDescriptor nasdWithoutExtras_r = 
 	    (NonActivatableServiceDescriptor)ois.readObject();        
-	SharedActivationGroupDescriptor sharedvm_r = 
-	    (SharedActivationGroupDescriptor)ois.readObject();
-	SharedActivatableServiceDescriptor sasd_r =
-	    (SharedActivatableServiceDescriptor)ois.readObject();
-	SharedActivatableServiceDescriptor sasdWithExtras_r =
-	    (SharedActivatableServiceDescriptor)ois.readObject();
-	//sasdWithExtras_r.setLifeCycle(lc);
-        sasdWithExtras_r.setServicePreparer(pp);
-        sasdWithExtras_r.setInnerProxyPreparer(pp);
 	ServiceDescriptor[] recovered = 
             (ServiceDescriptor[])ois.readObject(); 
 	ois.close();
 	
         logger.log(Level.INFO, "Read: " + nasdWithExtras_r);
         logger.log(Level.INFO, "Read: " + nasdWithoutExtras_r);
-        logger.log(Level.INFO, "Read: " + sharedvm_r);
-        logger.log(Level.INFO, "Read: " + sasd_r);
-        logger.log(Level.INFO, "Read: " + sasdWithExtras_r);
         logger.log(Level.INFO, "Read: " + Arrays.asList(recovered));
 
 	if (!verifyNonActivatableServiceDescriptors(nasdWithExtras, nasdWithExtras_r)) {
@@ -177,18 +117,6 @@ public class SerializedServiceDescriptor
 	    throw new TestException(
 	        "Written and recovered NonActivatableServiceDescriptors don't match");
 	}
-        if (!verifySharedActivationGroupDescriptors(sharedvm, sharedvm_r)) {
-	    throw new TestException(
-	        "Written and recovered SharedActivationGroupDescriptors don't match");
-	}
-	if (!verifySharedActivatableServiceDescriptors(sasd, sasd_r)) {
-	    throw new TestException(
-	        "Written and recovered SharedActivatableServiceDescriptors don't match");
-	}
-	if (!verifySharedActivatableServiceDescriptors(sasdWithExtras, sasdWithExtras_r)) {
-	    throw new TestException(
-	        "Written and recovered SharedActivatableServiceDescriptors don't match");
-	}
 	if (!verifyServiceDescriptors(serviceDescriptors, recovered)) {
 	    throw new TestException(
 	        "Written and recovered ServiceDescriptor[] don't match");
@@ -235,59 +163,6 @@ public class SerializedServiceDescriptor
 	    throw new TestException("Unexpected exception: " + e);
 	}
 
-	//Do some negative tests - Ensure bad descriptor doesn't match
-        SharedActivatableServiceDescriptor bogus_sasd = 
-            new SharedActivatableServiceDescriptor(
-	        sasd.getExportCodebase(),
-	        sasd.getPolicy(),
-	        sasd.getImportCodebase(),
-	        sasd.getImplClassName(),
-	        sasd.getSharedGroupLog() + "_bogus",
-	        sasd.getServerConfigArgs(),
-	        sasd.getRestart());
-	if (verifySharedActivatableServiceDescriptors(bogus_sasd, sasd)) {
-	    throw new TestException("Bogus SASD passed verification");
-	}
-	
-	//Do some negative tests - Ensure setLifeCycle can't be called after creation
-	try {
-	    sasd.create(EmptyConfiguration.INSTANCE); //Original descriptor
-	} catch (Exception e) {
-            logger.log(Level.INFO, "exception creating SASD ... ignoring", e);
-	}
-	try {
-	    sasd.setLifeCycle(lc); 
-	} catch (IllegalStateException ie) {
-            logger.log(Level.INFO, "Expected exception setting SASD LifeCycle ... ignoring", ie);
-	} catch (Exception e) {
-	    e.printStackTrace();
-	    throw new TestException("Unexpected exception: " + e);
-	}
-	try {
-	    sasd_r.create(EmptyConfiguration.INSTANCE); //Recovered descriptor
-	} catch (Exception e) {
-            logger.log(Level.INFO, "exception creating recovered SASD ... ignoring", e);
-	}
-	try {
-	    sasd_r.setLifeCycle(lc); 
-	} catch (IllegalStateException ie) {
-            logger.log(Level.INFO, "Expected exception setting recovered SASD LifeCycle ... ignoring", ie);
-	} catch (Exception e) {
-	    e.printStackTrace();
-	    throw new TestException("Unexpected exception: " + e);
-	}
-		
-        SharedActivationGroupDescriptor bogus_sharedvm =
-            new SharedActivationGroupDescriptor(
-	        sharedvm.getPolicy(),
-	        sharedvm.getClasspath(),
-	        sharedvm.getLog() + "_bogus",
-	        sharedvm.getServerCommand(),
-	        sharedvm.getServerOptions(),
-	        sharedvm_props);
-	if (verifySharedActivationGroupDescriptors(bogus_sharedvm, sharedvm)) {
-	    throw new TestException("Bogus SAGD passed verification");
-	}
 		
     }
     
@@ -300,15 +175,7 @@ public class SerializedServiceDescriptor
             return false;
 	}
 	for (int i=0; i < wrote.length; i++) {
-	    if (wrote[i] instanceof SharedActivatableServiceDescriptor) {
-	        SharedActivatableServiceDescriptor sasdw = 
-		    (SharedActivatableServiceDescriptor)wrote[i];
-	        SharedActivatableServiceDescriptor sasdr = 
-		    (SharedActivatableServiceDescriptor)read[i];
-		if (!verifySharedActivatableServiceDescriptors(sasdw, sasdr)) {
-		    return false;
-		}
-	    } else if (wrote[i] instanceof NonActivatableServiceDescriptor) {
+            if (wrote[i] instanceof NonActivatableServiceDescriptor) {
 	        NonActivatableServiceDescriptor nasdw = 
 		    (NonActivatableServiceDescriptor)wrote[i];
 	        NonActivatableServiceDescriptor nasdr = 
@@ -316,14 +183,6 @@ public class SerializedServiceDescriptor
 		if (!verifyNonActivatableServiceDescriptors(nasdw, nasdr)) {
 		    return false;
 		}
-	    } else if (wrote[i] instanceof SharedActivationGroupDescriptor) {
-	        SharedActivationGroupDescriptor sagdw = 
-		    (SharedActivationGroupDescriptor)wrote[i];
-	        SharedActivationGroupDescriptor sagdr = 
-		    (SharedActivationGroupDescriptor)read[i];
-		if (!verifySharedActivationGroupDescriptors(sagdw, sagdr)) {
-		    return false;
-		}
 	    } else {
                 logger.log(Level.INFO, "ServiceDescriptor " + wrote[i]
 		    + " not handled");
@@ -333,24 +192,6 @@ public class SerializedServiceDescriptor
 	return true;
     }
     
-    private static boolean verifySharedActivatableServiceDescriptors(
-        SharedActivatableServiceDescriptor wrote, SharedActivatableServiceDescriptor read) 
-    {
-        if (verifyNonActivatableServiceDescriptors(wrote, read) &&
-	    wrote.getSharedGroupLog().equals(read.getSharedGroupLog()) &&
-	    (wrote.getRestart() == read.getRestart()) &&
-	    wrote.getActivationSystemHost().equals(read.getActivationSystemHost()) &&
-	    (wrote.getActivationSystemPort() == read.getActivationSystemPort()))
-	{
-            logger.log(Level.FINE, "Written SASD [" + wrote + "] does match "
-	        + "recovered SASD [" + read + "]");	    
-	    return true;
-	}
-        logger.log(Level.INFO, "Written SASD [" + wrote + "] DOESN'T match "
-	    + "recovered SASD [" + read + "]");
-	return false;
-    }
-    
     private static boolean verifyNonActivatableServiceDescriptors(
         NonActivatableServiceDescriptor wrote, NonActivatableServiceDescriptor read) 
     {
@@ -373,24 +214,4 @@ public class SerializedServiceDescriptor
 	return false;
     }
     
-    private static boolean verifySharedActivationGroupDescriptors(
-        SharedActivationGroupDescriptor wrote, SharedActivationGroupDescriptor read) 
-    {
-        if (wrote.getPolicy().equals(read.getPolicy()) &&
-	    wrote.getClasspath().equals(read.getClasspath()) &&
-	    wrote.getLog().equals(read.getLog()) &&
-	    wrote.getServerCommand().equals(read.getServerCommand()) &&
-	    Arrays.equals(wrote.getServerOptions(), read.getServerOptions()) &&
-	    wrote.getServerProperties().equals(read.getServerProperties()) &&
-	    wrote.getActivationSystemHost().equals(read.getActivationSystemHost()) &&
-	    (wrote.getActivationSystemPort() == read.getActivationSystemPort()))
-	{
-            logger.log(Level.FINE, "Written SAGD [" + wrote + "] does match "
-	        + "recovered SAGD [" + read + "]");	    
-	    return true;
-	}
-        logger.log(Level.INFO, "Written SAGD [" + wrote + "] DOESN'T match "
-	    + "recovered SAGD [" + read + "]");
-	return false;
-    }
 }

Modified: river/jtsk/branches/2.2/qa/src/com/sun/jini/test/impl/start/ServiceDescriptorProxyPreparationTest.java
URL: http://svn.apache.org/viewvc/river/jtsk/branches/2.2/qa/src/com/sun/jini/test/impl/start/ServiceDescriptorProxyPreparationTest.java?rev=1718151&r1=1718150&r2=1718151&view=diff
==============================================================================
--- river/jtsk/branches/2.2/qa/src/com/sun/jini/test/impl/start/ServiceDescriptorProxyPreparationTest.java (original)
+++ river/jtsk/branches/2.2/qa/src/com/sun/jini/test/impl/start/ServiceDescriptorProxyPreparationTest.java Sun Dec  6 08:23:59 2015
@@ -42,16 +42,11 @@ import java.util.List;
 import java.util.Enumeration;
 
 import com.sun.jini.qa.harness.TestException;
-import com.sun.jini.qa.harness.SharedGroupAdmin;
-import com.sun.jini.start.ActivateWrapper;
-import com.sun.jini.start.ActivateWrapper.ActivateDesc;
 import com.sun.jini.start.ClassLoaderUtil;
 import com.sun.jini.start.ServiceStarter;
 import com.sun.jini.start.NonActivatableServiceDescriptor;
 //import com.sun.jini.start.NonActivatableServiceDescriptor.Created;
-import com.sun.jini.start.SharedActivatableServiceDescriptor;
 //import com.sun.jini.start.SharedActivatableServiceDescriptor.Created;
-import com.sun.jini.start.SharedGroup;
 import net.jini.config.EmptyConfiguration;
 import net.jini.event.EventMailbox;
 import net.jini.security.BasicProxyPreparer;
@@ -76,11 +71,6 @@ public class ServiceDescriptorProxyPrepa
 	new BasicProxyPreparer();
 
     public void run() throws Exception {
-        SharedGroup sg = null;
-        sg = (SharedGroup)manager.startService("sharedGroup");
-	SharedGroupAdmin sga = null;
-	sga = (SharedGroupAdmin)manager.getAdmin(sg);
-
         String codebase = 
             getConfig().genIntegrityCodebase(
                 getConfig().getStringConfigVal(
@@ -89,9 +79,6 @@ public class ServiceDescriptorProxyPrepa
         String policy = getConfig().getStringConfigVal(
             "net.jini.event.EventMailbox.policyfile", null);
         logger.log(Level.INFO, "policy = " + policy);
-        String act_impl = getConfig().getStringConfigVal(
-            "net.jini.event.EventMailbox.activatable.impl", null);
-        logger.log(Level.INFO, "activatable impl = " + act_impl);
         String trans_impl = getConfig().getStringConfigVal(
             "net.jini.event.EventMailbox.transient.impl", null);
         logger.log(Level.INFO, "transient impl = " + trans_impl);
@@ -99,7 +86,7 @@ public class ServiceDescriptorProxyPrepa
             "net.jini.event.EventMailbox.classpath", null);
         logger.log(Level.INFO, "classpath = " + classpath);
         if (codebase == null || policy == null ||
-            act_impl == null || trans_impl == null ||
+            trans_impl == null ||
             classpath == null) {
             throw new TestException(
                 "Service codebase, classpath, "
@@ -109,109 +96,11 @@ public class ServiceDescriptorProxyPrepa
         String config = null;
 	config = 
 	    ServiceStarterCreateBadTransientServiceTest.getServiceConfigFile().toString();
-	
-
-	SharedActivatableServiceDescriptor antiMercuryInnerProxy =
-            new SharedActivatableServiceDescriptor(
-		codebase,
-                policy,
-                classpath,
-                act_impl,
-                sga.getSharedGroupLog().toString(),
-                new String[] { config },
-		antiMercuryProxyPreparer,
-		noOpProxyPreparer,
-		true);
-        try {
-            SharedActivatableServiceDescriptor.Created created = 
-                (SharedActivatableServiceDescriptor.Created)antiMercuryInnerProxy.create(
-		    EmptyConfiguration.INSTANCE);
-	    throw new TestException(
-	        "Created proxy: " + created.proxy 
-		+ " with a bad inner proxy descriptor: " 
-		+ antiMercuryInnerProxy);
-        } catch (Exception e) {
-	    logger.log(Level.INFO, 
-		"Caught failure -- with a bad inner proxy descriptor: " 
-	        + e);
-            e.printStackTrace();
-	    if (!antiMercuryException.equals(e)) {
-	        throw new TestException("Caught unexpected exception");
-	    } else {
-	        logger.log(Level.INFO, 
-		    "Expected failure caught.");
-	    }
-        } 
 
 	config = 
 	    ServiceStarterCreateBadTransientServiceTest.getServiceConfigFile().toString();
-	SharedActivatableServiceDescriptor antiMercuryOuterProxy =
-            new SharedActivatableServiceDescriptor(
-		codebase,
-                policy,
-                classpath,
-                act_impl,
-                sga.getSharedGroupLog().toString(),
-                new String[] { config },
-		noOpProxyPreparer,
-                antiMercuryProxyPreparer,
-		true);
-        try {
-            SharedActivatableServiceDescriptor.Created created = 
-                (SharedActivatableServiceDescriptor.Created)antiMercuryOuterProxy.create(
-		    EmptyConfiguration.INSTANCE);
-	    throw new TestException(
-	        "Created proxy: " + created.proxy 
-		+ " with a bad outer proxy descriptor: " 
-		+ antiMercuryOuterProxy);
-        } catch (Exception e) {
-	    logger.log(Level.INFO, 
-		"Caught failure -- with a bad outer proxy descriptor: " 
-	        + e);
-            e.printStackTrace();
-	    if (!antiMercuryException.equals(e)) {
-	        throw new TestException("Caught unexpected exception");
-	    } else {
-	        logger.log(Level.INFO, 
-		    "Expected failure caught.");
-	    }
-        } 
 
-	config = 
-	    ServiceStarterCreateBadTransientServiceTest.getServiceConfigFile().toString();
-	SharedActivatableServiceDescriptor antiMercuryInnerOuterProxy =
-            new SharedActivatableServiceDescriptor(
-		codebase,
-                policy,
-                classpath,
-                act_impl,
-                sga.getSharedGroupLog().toString(),
-                new String[] { config },
-		antiMercuryProxyPreparer,
-                antiMercuryProxyPreparer,
-		true);
-        try {
-            SharedActivatableServiceDescriptor.Created created = 
-                (SharedActivatableServiceDescriptor.Created)antiMercuryInnerOuterProxy.create(
-		    EmptyConfiguration.INSTANCE);
-	    throw new TestException(
-	        "Created proxy: " + created.proxy 
-		+ " with a bad inner-outer proxy descriptor: " 
-		+ antiMercuryInnerOuterProxy);
-        } catch (Exception e) {
-	    logger.log(Level.INFO, 
-		"Caught failure -- with a bad inner-outer proxy descriptor: " 
-	        + e);
-            e.printStackTrace();
-	    if (!antiMercuryException.equals(e)) {
-	        throw new TestException("Caught unexpected exception");
-	    } else {
-	        logger.log(Level.INFO, 
-		    "Expected failure caught.");
-	    }
-        } 
-
-	config = 
+        config = 
 	    ServiceStarterCreateBadTransientServiceTest.getServiceConfigFile().toString();
 	NonActivatableServiceDescriptor antiNonActMercuryProxy =
             new NonActivatableServiceDescriptor(

Modified: river/jtsk/branches/2.2/qa/src/com/sun/jini/test/impl/start/StartAllServicesTest.java
URL: http://svn.apache.org/viewvc/river/jtsk/branches/2.2/qa/src/com/sun/jini/test/impl/start/StartAllServicesTest.java?rev=1718151&r1=1718150&r2=1718151&view=diff
==============================================================================
--- river/jtsk/branches/2.2/qa/src/com/sun/jini/test/impl/start/StartAllServicesTest.java (original)
+++ river/jtsk/branches/2.2/qa/src/com/sun/jini/test/impl/start/StartAllServicesTest.java Sun Dec  6 08:23:59 2015
@@ -26,7 +26,6 @@ import java.rmi.activation.ActivationGro
 import java.util.Arrays;
 
 import com.sun.jini.start.*;
-import com.sun.jini.start.ActivateWrapper.*;
 import com.sun.jini.qa.harness.TestException;
 
 /**

Modified: river/jtsk/branches/2.2/qa/src/com/sun/jini/test/impl/start/StarterBase.java
URL: http://svn.apache.org/viewvc/river/jtsk/branches/2.2/qa/src/com/sun/jini/test/impl/start/StarterBase.java?rev=1718151&r1=1718150&r2=1718151&view=diff
==============================================================================
--- river/jtsk/branches/2.2/qa/src/com/sun/jini/test/impl/start/StarterBase.java (original)
+++ river/jtsk/branches/2.2/qa/src/com/sun/jini/test/impl/start/StarterBase.java Sun Dec  6 08:23:59 2015
@@ -39,11 +39,6 @@ public abstract class StarterBase extend
 	l.setLevel(Level.ALL);
 	handler = new MyHandler();
 	l.addHandler(handler);
-        if (getConfig().getBooleanConfigVal("com.sun.jini.qa.harness.shared",
-                                       true))
-        {
-            manager.startService("sharedGroup");
-        }
     }
 
     static class MyHandler extends Handler {

Modified: river/jtsk/branches/2.2/qa/src/com/sun/jini/test/impl/start/TestUtil.java
URL: http://svn.apache.org/viewvc/river/jtsk/branches/2.2/qa/src/com/sun/jini/test/impl/start/TestUtil.java?rev=1718151&r1=1718150&r2=1718151&view=diff
==============================================================================
--- river/jtsk/branches/2.2/qa/src/com/sun/jini/test/impl/start/TestUtil.java (original)
+++ river/jtsk/branches/2.2/qa/src/com/sun/jini/test/impl/start/TestUtil.java Sun Dec  6 08:23:59 2015
@@ -20,37 +20,13 @@ package com.sun.jini.test.impl.start;
 import com.sun.jini.qa.harness.QAConfig;
 
 import com.sun.jini.start.ServiceStarter;
-import com.sun.jini.start.SharedGroup;
 
 import java.io.*;
 import java.rmi.*;
-import java.rmi.activation.*;
-
 
 public class TestUtil {
 
     /**
-     * Restores the <code>SharedCreated</code> object from a well known file
-     * under the provided <code>log</code> path.
-     */
-
-    static ActivationGroupID loadSharedCreate(String log)
-        throws Exception
-    {
-
-        ActivationGroupID gid = null;
-        File dir = new File(log);
-        try {
-            gid = (ActivationGroupID)restoreGroupCookie(dir);
-        } catch (Exception e) {
-            e.printStackTrace();
-	    throw e;
-        }
-
-        return gid;
-    }
-
-    /**
      * Utility method that restores the object stored in a well known file
      * under the provided <code>dir</code> path.
      */

Modified: river/jtsk/branches/2.2/qa/src/com/sun/jini/test/impl/start/start.properties
URL: http://svn.apache.org/viewvc/river/jtsk/branches/2.2/qa/src/com/sun/jini/test/impl/start/start.properties?rev=1718151&r1=1718150&r2=1718151&view=diff
==============================================================================
--- river/jtsk/branches/2.2/qa/src/com/sun/jini/test/impl/start/start.properties (original)
+++ river/jtsk/branches/2.2/qa/src/com/sun/jini/test/impl/start/start.properties Sun Dec  6 08:23:59 2015
@@ -2,56 +2,7 @@ qatest.discoveryTries=5
 qatest.lookupAdminClass=com.sun.jini.qa.admin.LookupServiceAdmin
 qatest.serviceAdminClass=com.sun.jini.qa.admin.ServiceAdmin
 
-test.sharedVM=true
-
-com.sun.jini.start.SharedGroup.type=activatable
-com.sun.jini.start.SharedGroup.impl=com.sun.jini.start.SharedGroupImpl
-com.sun.jini.start.SharedGroup.component=com.sun.jini.start
-com.sun.jini.start.SharedGroup.classpath=${com.sun.jini.jsk.home}$/lib$/group.jar
-com.sun.jini.start.SharedGroup.codebase=http://${HOST}:${com.sun.jini.jsk.port}/group-dl.jar
-com.sun.jini.start.SharedGroup.policyfile=<url:harness/policy/policy.all>
-com.sun.jini.start.SharedGroup.log=SharedGroup_log
-com.sun.jini.start.SharedGroup.serviceConfiguration=<url:harness/configs/<config>/sharedgroup/sharedgroup.config>
-com.sun.jini.start.SharedGroup.starterConfiguration=<url:harness/configs/<config>/sharedgroup/sharedgroup.config>
-
-
-com.sun.jini.test.impl.start.Probe.type=activatable
-com.sun.jini.test.impl.start.Probe.impl=com.sun.jini.test.impl.start.ProbeImpl
-com.sun.jini.test.impl.start.Probe.classpath=<file:lib/qa1-start-probe.jar>
-com.sun.jini.test.impl.start.Probe.codebase=http://${HOST}:${com.sun.jini.test.port}/qa1-start-probe-dl.jar
-com.sun.jini.test.impl.start.Probe.policyfile=<url:harness/policy/policy.all>
-com.sun.jini.test.impl.start.Probe.log=none
-com.sun.jini.test.impl.start.Probe.serviceConfiguration=-
-com.sun.jini.test.impl.start.Probe.starterConfiguration=<url:harness/configs/<config>/sharedgroup/sharedgroup.config>
-
-com.sun.jini.test.impl.start.UnsharedProbe.type=activatable
-com.sun.jini.test.impl.start.UnsharedProbe.impl=com.sun.jini.test.impl.start.UnsharedProbeImpl
-com.sun.jini.test.impl.start.UnsharedProbe.classpath=<file:lib/qa1-start-probe.jar>
-com.sun.jini.test.impl.start.UnsharedProbe.codebase=http://${HOST}:${com.sun.jini.test.port}/qa1-start-probe-dl.jar
-com.sun.jini.test.impl.start.UnsharedProbe.policyfile=<url:harness/policy/policy.all>
-com.sun.jini.test.impl.start.UnsharedProbe.log=none
-com.sun.jini.test.impl.start.UnsharedProbe.serviceConfiguration=-
-com.sun.jini.test.impl.start.UnsharedProbe.starterConfiguration=<url:harness/configs/<config>/sharedgroup/sharedgroup.config>
-
-com.sun.jini.test.impl.start.NoStubProbe.type=activatable
-com.sun.jini.test.impl.start.NoStubProbe.impl=com.sun.jini.test.impl.start.NoStubProbeImpl
-com.sun.jini.test.impl.start.NoStubProbe.classpath=<file:lib/qa1-start-probe.jar>
-com.sun.jini.test.impl.start.NoStubProbe.codebase=http://${HOST}:${com.sun.jini.test.port}/qa1-start-probe-dl.jar
-com.sun.jini.test.impl.start.NoStubProbe.policyfile=<url:harness/policy/policy.all>
-com.sun.jini.test.impl.start.NoStubProbe.log=none
-com.sun.jini.test.impl.start.NoStubProbe.serviceConfiguration=-
-com.sun.jini.test.impl.start.NoStubProbe.starterConfiguration=<url:harness/configs/<config>/sharedgroup/sharedgroup.config>
-
-com.sun.jini.test.impl.start.BadServiceProxyAccessorImpl.type=activatable
-com.sun.jini.test.impl.start.BadServiceProxyAccessorImpl.impl=com.sun.jini.test.impl.start.BadServiceProxyAccessorImpl
-com.sun.jini.test.impl.start.BadServiceProxyAccessorImpl.classpath=<file:lib/qa1-start-probe.jar>
-com.sun.jini.test.impl.start.BadServiceProxyAccessorImpl.codebase=http://${HOST}:${com.sun.jini.test.port}/qa1-start-probe-dl.jar
-com.sun.jini.test.impl.start.BadServiceProxyAccessorImpl.policyfile=<url:harness/policy/policy.all>
-com.sun.jini.test.impl.start.BadServiceProxyAccessorImpl.log=none
-com.sun.jini.test.impl.start.BadServiceProxyAccessorImpl.serviceConfiguration=-
-com.sun.jini.test.impl.start.BadServiceProxyAccessorImpl.starterConfiguration=<url:harness/configs/<config>/sharedgroup/sharedgroup.config>
-
-com.sun.jini.qa.harness.verifier=${com.sun.jini.qa.harness.verifier} com.sun.jini.qa.harness.SharedVMVerifier
+test.sharedVM=false
 
 # the following replace with an include in the test description file
 #com.sun.jini.test.impl.start.MemberGroupsProblem.prop=com.sun.jini.test.share.simReg1_0

Modified: river/jtsk/branches/2.2/qa/src/com/sun/jini/test/services/lookupsimulator/LookupSimulatorImpl.java
URL: http://svn.apache.org/viewvc/river/jtsk/branches/2.2/qa/src/com/sun/jini/test/services/lookupsimulator/LookupSimulatorImpl.java?rev=1718151&r1=1718150&r2=1718151&view=diff
==============================================================================
--- river/jtsk/branches/2.2/qa/src/com/sun/jini/test/services/lookupsimulator/LookupSimulatorImpl.java (original)
+++ river/jtsk/branches/2.2/qa/src/com/sun/jini/test/services/lookupsimulator/LookupSimulatorImpl.java Sun Dec  6 08:23:59 2015
@@ -73,7 +73,6 @@ import javax.security.auth.Subject;
 import javax.security.auth.login.LoginContext;
 import javax.security.auth.login.LoginException;
 
-import net.jini.activation.ActivationExporter;
 import net.jini.security.BasicProxyPreparer;
 import net.jini.security.ProxyPreparer;
 import net.jini.security.TrustVerifier;
@@ -345,36 +344,11 @@ public class LookupSimulatorImpl impleme
                                                    ConfigurationException,
 						   ActivationException
     {
-	if (activationID != null) {
-	    activationSystem = ActivationGroup.getSystem();
-	    // if not the none configuration, prepare proxies
-	    if (!noneConfiguration) {
-		ProxyPreparer activationIdPreparer =
-		    (ProxyPreparer) Config.getNonNullEntry(config,
-						       "lookupSimulator",
-						       "activationIdPreparer",
-						       ProxyPreparer.class);
-	
-		ProxyPreparer activationSystemPreparer = (ProxyPreparer)
-		    Config.getNonNullEntry(config, 
-				       "lookupSimulator",
-				       "activationSystemPreparer",
-				       ProxyPreparer.class);
-
-		activationID = (ActivationID)
-		    activationIdPreparer.prepareProxy(activationID);
-		activationSystem = (ActivationSystem)
-		    activationSystemPreparer.prepareProxy(activationSystem);
-	    }
-	}
+
 	if (noneConfiguration) {
 	    serverExporter =
 		new BasicJeriExporter(TcpServerEndpoint.getInstance(0),
 				      new BasicILFactory());
-	    if (activationID != null) {
-		serverExporter = new ActivationExporter(activationID,
-							serverExporter);
-	    }
 	} else {
 	    serverExporter = 
 		(Exporter) Config.getNonNullEntry(config,

Modified: river/jtsk/branches/2.2/qa/src/com/sun/jini/test/share/TestBase.java
URL: http://svn.apache.org/viewvc/river/jtsk/branches/2.2/qa/src/com/sun/jini/test/share/TestBase.java?rev=1718151&r1=1718150&r2=1718151&view=diff
==============================================================================
--- river/jtsk/branches/2.2/qa/src/com/sun/jini/test/share/TestBase.java (original)
+++ river/jtsk/branches/2.2/qa/src/com/sun/jini/test/share/TestBase.java Sun Dec  6 08:23:59 2015
@@ -46,7 +46,6 @@ import com.sun.jini.outrigger.AdminItera
 import com.sun.jini.admin.DestroyAdmin;
 
 import com.sun.jini.qa.harness.Admin;
-import com.sun.jini.qa.harness.ActivatableServiceStarterAdmin;
 
 // com.sun.jini.qa
 import com.sun.jini.qa.harness.QATest;

Modified: river/jtsk/branches/2.2/qa/src/com/sun/jini/test/spec/lookupservice/QATestRegistrar.java
URL: http://svn.apache.org/viewvc/river/jtsk/branches/2.2/qa/src/com/sun/jini/test/spec/lookupservice/QATestRegistrar.java?rev=1718151&r1=1718150&r2=1718151&view=diff
==============================================================================
--- river/jtsk/branches/2.2/qa/src/com/sun/jini/test/spec/lookupservice/QATestRegistrar.java (original)
+++ river/jtsk/branches/2.2/qa/src/com/sun/jini/test/spec/lookupservice/QATestRegistrar.java Sun Dec  6 08:23:59 2015
@@ -43,7 +43,6 @@ import java.util.HashMap;
 import java.util.logging.Level;
 import com.sun.jini.qa.harness.QAConfig;
 import com.sun.jini.qa.harness.QATest;
-import com.sun.jini.qa.harness.ActivatableServiceStarterAdmin;
 
 import net.jini.config.Configuration;
 import net.jini.config.ConfigurationException;

Modified: river/jtsk/branches/2.2/src/com/sun/jini/fiddler/FiddlerImpl.java
URL: http://svn.apache.org/viewvc/river/jtsk/branches/2.2/src/com/sun/jini/fiddler/FiddlerImpl.java?rev=1718151&r1=1718150&r2=1718151&view=diff
==============================================================================
--- river/jtsk/branches/2.2/src/com/sun/jini/fiddler/FiddlerImpl.java (original)
+++ river/jtsk/branches/2.2/src/com/sun/jini/fiddler/FiddlerImpl.java Sun Dec  6 08:23:59 2015
@@ -41,8 +41,6 @@ import com.sun.jini.thread.ReadersWriter
 import com.sun.jini.thread.ReadyState;
 import com.sun.jini.thread.TaskManager;
 
-import net.jini.activation.ActivationExporter;
-import net.jini.activation.ActivationGroup;
 import net.jini.config.Configuration;
 import net.jini.config.ConfigurationProvider;
 import net.jini.config.ConfigurationException;
@@ -105,9 +103,6 @@ import java.io.ObjectOutputStream;
 import java.io.OutputStream;
 import java.io.Serializable;
 
-import java.rmi.activation.ActivationException;
-import java.rmi.activation.ActivationID;
-import java.rmi.activation.ActivationSystem;
 import java.rmi.MarshalledObject;
 import java.rmi.NoSuchObjectException;
 import java.rmi.RemoteException;
@@ -222,12 +217,6 @@ class FiddlerImpl implements ServerProxy
      *  with any lookup service.
      */
     private ServiceID serviceID = null;
-    /** The activation id of the current instance of the lookup discovery
-     *  service, if it happens to be and activatable instance
-     */
-    private ActivationID activationID;
-    /* Holds the prepared proxy to the ActivationSystem */
-    private ActivationSystem activationSystem;
     /** The unique identifier generated (or recovered) when an instance of
      *  this service is constructed. This ID is typically used to determine
      *  equality between the proxies of any two instances of this service.
@@ -370,63 +359,6 @@ class FiddlerImpl implements ServerProxy
     private final ReadyState readyState = new ReadyState();
 
     /* ************************* BEGIN Constructors ************************ */
-    /**
-     * Constructs a new instance of FiddlerImpl. This version of the
-     * constructor is used to create an activatable instance of the lookup
-     * discovery service that logs its state information to persistent storage.
-     * <p>
-     * A constructor having this signature is required for the class to be
-     * activatable. This constructor is automatically called by the 
-     * activation group when the lookup discovery service is activated.
-     * 
-     * @param activationID the activation ID generated by the activation
-     *                     system and assigned to the instance of the server
-     *                     being activated
-     * @param data         state data (represented as a 
-     *                     <code>MarshalledObject</code>) which is needed to
-     *                     re-activate this server
-     *
-     * @throws IOException            this exception can occur when there is
-     *                                a problem recovering data from disk,
-     *                                exporting the server that's being
-     *                                activated, or when unmarshalling the
-     *                                given <code>data</code> parameter.
-     * @throws ConfigurationException this exception can occur when a
-     *                                problem occurs while retrieving an item
-     *                                from the <code>Configuration</code>
-     *                                generated from the contents of the
-     *                                given <code>data</code> parameter
-     * @throws ActivationException    this exception can occur when a problem
-     *                                occurs while activating the service
-     * @throws LoginException         this exception occurs when authentication
-     *                                fails while performing a JAAS login for
-     *                                this service
-     * @throws ClassNotFoundException this exception can occur while 
-     *                                unmarshalling the given <code>data</code>
-     *                                parameter; when a class needed in the
-     *                                unmarshalling process cannot be found.
-     * @throws ClassCastException     this exception can occur while
-     *                                unmarshalling the given <code>data</code>
-     *                                parameter; when the contents of that
-     *                                parameter is not a <code>String</code>
-     *                                array.
-     */
-    FiddlerImpl(ActivationID activationID,
-                MarshalledObject data) throws IOException,
-                                              ActivationException,
-                                              ConfigurationException,
-                                              LoginException,
-                                              ClassNotFoundException
-    {
-        this.activationID = activationID;
-        try {
-            activationSystem = ActivationGroup.getSystem();
-            init( (String[])data.get(), true );//true ==> persistent
-        } catch(Throwable e) {
-            cleanupInitFailure();
-            handleActivatableInitThrowable(e);
-        }
-    }//end activatable constructor
 
     /**
      * Constructs a new instance of FiddlerImpl. This version of the
@@ -2399,18 +2331,6 @@ class FiddlerImpl implements ServerProxy
              * that the object corresponding to the given activation ID can
              * no longer be activated through that ID.
              */
-	    if (activationID != null) {
-		try {
-                    activationSystem.unregisterObject(activationID);
-		} catch (RemoteException e) {
-                    problemLogger.log(Level.WARNING, "aborting shutdown - "
-                                     +"could not unregister activation ID", e);
-		    return;//give up until we can at least unregister
-		} catch (ActivationException e) {
-                    problemLogger.log(Levels.HANDLED, "shutdown problem - "
-                                     +"could not unregister activation ID", e);
-                }
-	    }
             readyState.shutdown();
             /* Unexport the object. This removes the object from the RMI
              * runtime so that the object can no longer accept incoming RMI
@@ -2447,17 +2367,9 @@ class FiddlerImpl implements ServerProxy
 		if(log != null) snapshotThread.join();
 	    } catch (InterruptedException e) { }
 	    if(log != null) log.deletePersistentStore();
-	    if (activationID != null) {
-                /* Inform the activation system that the object corresponding
-                 * to the given activation ID is no longer active.
-                 */
-		try {
-		    ActivationGroup.inactive(activationID, serverExporter);
-		} catch (RemoteException e) {
-		} catch (ActivationException e) { }
-            } else {//not activatable, tell starter it's ok to release for gc
-                if(lifeCycle != null)  lifeCycle.unregister(FiddlerImpl.this);
-            }//endif(activationID != null)
+            // tell starter it's ok to release for gc
+            if(lifeCycle != null)  lifeCycle.unregister(FiddlerImpl.this);
+            
             /* If applicable, logout of the JAAS login session */
             if(loginContext != null) {
                 try {
@@ -5322,27 +5234,6 @@ class FiddlerImpl implements ServerProxy
                                                          ilFactory,
                                                          false,
                                                          true);
-        /* For the activatable server */
-        if(activationID != null) {
-            ProxyPreparer aidPreparer =
-              (ProxyPreparer)Config.getNonNullEntry(config,
-                                                    COMPONENT_NAME,
-                                                    "activationIdPreparer",
-                                                    ProxyPreparer.class,
-                                                    new BasicProxyPreparer());
-            ProxyPreparer aSysPreparer = 
-              (ProxyPreparer)Config.getNonNullEntry(config,
-                                                    COMPONENT_NAME,
-                                                    "activationSystemPreparer",
-                                                    ProxyPreparer.class,
-                                                    new BasicProxyPreparer());
-            activationID = (ActivationID)aidPreparer.prepareProxy
-                                                               (activationID);
-            activationSystem = (ActivationSystem)aSysPreparer.prepareProxy
-                                                            (activationSystem);
-            defaultExporter = new ActivationExporter(activationID,
-                                                     defaultExporter);
-        }//endif(activationID != null)
 
         /* Get the exporter that will be used to export this service */
         try {
@@ -5350,8 +5241,7 @@ class FiddlerImpl implements ServerProxy
                                                               COMPONENT_NAME,
                                                               "serverExporter",
                                                               Exporter.class,
-                                                              defaultExporter,
-                                                              activationID);
+                                                              defaultExporter);
         } catch(ConfigurationException e) {// exception, use default
             throw new ExportException("Configuration exception while "
                                       +"retrieving service's exporter",
@@ -5450,15 +5340,12 @@ class FiddlerImpl implements ServerProxy
      */
     private void handleActivatableInitThrowable(Throwable t) 
                                             throws IOException,
-                                                   ActivationException,
                                                    ConfigurationException,
                                                    LoginException,
                                                    ClassNotFoundException
     {
         handleInitThrowable(t);
-        if (t instanceof ActivationException) {
-            throw (ActivationException)t;
-        } else if (t instanceof LoginException) {
+        if (t instanceof LoginException) {
             throw (ClassNotFoundException)t;
         } else {
             throw new AssertionError(t);

Modified: river/jtsk/branches/2.2/src/com/sun/jini/mahalo/TxnManagerImpl.java
URL: http://svn.apache.org/viewvc/river/jtsk/branches/2.2/src/com/sun/jini/mahalo/TxnManagerImpl.java?rev=1718151&r1=1718150&r2=1718151&view=diff
==============================================================================
--- river/jtsk/branches/2.2/src/com/sun/jini/mahalo/TxnManagerImpl.java (original)
+++ river/jtsk/branches/2.2/src/com/sun/jini/mahalo/TxnManagerImpl.java Sun Dec  6 08:23:59 2015
@@ -44,11 +44,6 @@ import java.io.File;
 import java.io.IOException;
 import java.rmi.MarshalledObject;
 import java.rmi.RemoteException;
-import java.rmi.activation.Activatable;
-import java.rmi.activation.ActivationException;
-import java.rmi.activation.ActivationGroup;
-import java.rmi.activation.ActivationID;
-import java.rmi.activation.ActivationSystem;
 import java.security.PrivilegedActionException;
 import java.security.PrivilegedExceptionAction;
 import java.security.SecureRandom;
@@ -65,7 +60,6 @@ import javax.security.auth.Subject;
 import javax.security.auth.login.LoginContext;
 import javax.security.auth.login.LoginException;
 
-import net.jini.activation.ActivationExporter;
 import net.jini.config.Configuration;
 import net.jini.config.ConfigurationProvider;
 import net.jini.core.constraint.RemoteMethodControl;
@@ -188,17 +182,6 @@ class TxnManagerImpl /*extends RemoteSer
      */
     private String persistenceDirectory = null;
 
-    /**
-     * @serial
-     */
-    private ActivationID activationID;
-    
-    /** Whether the activation ID has been prepared */
-    private boolean activationPrepared;
-
-    /** The activation system, prepared */
-    private ActivationSystem activationSystem;
-
     /** Proxy preparer for listeners */
     private ProxyPreparer participantPreparer;
 
@@ -299,34 +282,6 @@ class TxnManagerImpl /*extends RemoteSer
 		TxnManagerImpl.class.getName(), "TxnManagerImpl");
 	}
     }
-    /**
-     * Constructs an activatable transaction manager.
-     *
-     * @param activationID activation ID passed in by the activation daemon.
-     *
-     * @param data state data needed to re-activate a transaction manager.
-     */
-    TxnManagerImpl(ActivationID activationID, MarshalledObject data)
-	throws Exception
-    {
-        if (operationsLogger.isLoggable(Level.FINER)) {
-            operationsLogger.entering(
-		TxnManagerImpl.class.getName(), "TxnManagerImpl",
-	        new Object[] {activationID, data} );
-	}
-	this.activationID = activationID;
-        try {
-            // Initialize state
-            init((String[])data.get());
-        } catch (Throwable e) {
-            cleanup();
-	    initFailed(e); 
-        }
-        if (operationsLogger.isLoggable(Level.FINER)) {
-            operationsLogger.exiting(
-		TxnManagerImpl.class.getName(), "TxnManagerImpl");
-	}
-    }
     
     /** Initialization common to both activatable and transient instances. */
     private void init(String[] configArgs)
@@ -394,61 +349,17 @@ class TxnManagerImpl /*extends RemoteSer
             operationsLogger.entering(
 		TxnManagerImpl.class.getName(), "doInit", config);
 	}
-        // Get activatable settings, if activated
-        if (activationID != null) {
-            ProxyPreparer activationSystemPreparer =
-                (ProxyPreparer) Config.getNonNullEntry(config,
-                    TxnManager.MAHALO, "activationSystemPreparer",
-                    ProxyPreparer.class, new BasicProxyPreparer());
-            if(initLogger.isLoggable(Level.CONFIG)) {
-		initLogger.log(Level.CONFIG, "activationSystemPreparer: {0}", 
-	            activationSystemPreparer);		
-	    }
-            activationSystem =
-                (ActivationSystem) activationSystemPreparer.prepareProxy(
-                    ActivationGroup.getSystem());
-            if(initLogger.isLoggable(Level.CONFIG)) {
-		initLogger.log(Level.CONFIG, "Prepared activation system is: {0}",
-                    activationSystem);
-            }
-            ProxyPreparer activationIdPreparer =
-                (ProxyPreparer) Config.getNonNullEntry(config,
-                    TxnManager.MAHALO, "activationIdPreparer",
-                    ProxyPreparer.class, new BasicProxyPreparer());
-            if(initLogger.isLoggable(Level.CONFIG)) {
-		initLogger.log(Level.CONFIG, "activationIdPreparer: {0}", 
-	            activationIdPreparer);		
-            }
-	    activationID = (ActivationID) activationIdPreparer.prepareProxy(
-                activationID);
-            if(initLogger.isLoggable(Level.CONFIG)) {
-		initLogger.log(Level.CONFIG, "Prepared activationID is: {0}",
-                    activationID);
-            }
-	    activationPrepared = true;
-            exporter = (Exporter)Config.getNonNullEntry(config,
-	        TxnManager.MAHALO, "serverExporter", Exporter.class,
-                new ActivationExporter(
-		    activationID,
-                    new BasicJeriExporter(
-			TcpServerEndpoint.getInstance(0), 
-			new BasicILFactory(), false, true)),
-		    activationID);
-            if(initLogger.isLoggable(Level.CONFIG)) {
-		initLogger.log(Level.CONFIG, 
-	            "Activatable service exporter is: {0}", exporter);
-	    }
-        } else {
-            exporter = (Exporter) Config.getNonNullEntry(config,
-                TxnManager.MAHALO, "serverExporter", Exporter.class,
-                new BasicJeriExporter( 
-		    TcpServerEndpoint.getInstance(0), 
-		    new BasicILFactory(), false, true));
-            if(initLogger.isLoggable(Level.CONFIG)) {
-		initLogger.log(Level.CONFIG, 
-	            "Non-activatable service exporter is: {0}", exporter);
-            }
-	}
+
+        exporter = (Exporter) Config.getNonNullEntry(config,
+            TxnManager.MAHALO, "serverExporter", Exporter.class,
+            new BasicJeriExporter( 
+                TcpServerEndpoint.getInstance(0), 
+                new BasicILFactory(), false, true));
+        if(initLogger.isLoggable(Level.CONFIG)) {
+            initLogger.log(Level.CONFIG, 
+                "Non-activatable service exporter is: {0}", exporter);
+        }
+	
 	
 	ProxyPreparer recoveredParticipantPreparer = 
 	    (ProxyPreparer)Config.getNonNullEntry(config,
@@ -1430,38 +1341,6 @@ class TxnManagerImpl /*extends RemoteSer
 
             Exception failed = null;
 
-/**TODO 
-  * - move this block into the destroy() method and let the 
-  *   remote ex pass through
-  */
-            if (activationPrepared) {	    
-	        try {
-                    if(destroyLogger.isLoggable(Level.FINEST)) {
-	                destroyLogger.log(Level.FINEST,
-			    "Unregistering object.");
-                    }
-		    if (activationID != null)
-                        activationSystem.unregisterObject(activationID);
-   		} catch (RemoteException e) {
-   		    /* give up until we can at least unregister */
-                    if(destroyLogger.isLoggable(Level.WARNING)) {
-	                destroyLogger.log(Level.WARNING,
-			    "Trouble unregistering object -- aborting.", e);
-                    }
-   		    return;
-   		} catch (ActivationException e) {
-                    /*
-                     * Activation system is shutting down or this
-                     * object has already been unregistered --
-                     * ignore in either case.
-                     */
-                    if(destroyLogger.isLoggable(Levels.HANDLED)) {
-	                destroyLogger.log(Levels.HANDLED,
-			    "Trouble unregistering object -- ignoring.", e);
-                    }
-   		}
-	    }
-
             // Attempt to unexport this object -- nicely first
             if(destroyLogger.isLoggable(Level.FINEST)) {
 	        destroyLogger.log(Level.FINEST,
@@ -1585,25 +1464,6 @@ class TxnManagerImpl /*extends RemoteSer
     	        }
 	    }
 	    
-            if(activationID != null) {
-	        if(destroyLogger.isLoggable(Level.FINEST)) {
-	            destroyLogger.log(Level.FINEST,"Calling Activatable.inactive.");
-                }
-	        try {
-                    Activatable.inactive(activationID);
-                } catch (RemoteException e) { // ignore
-                    if(destroyLogger.isLoggable(Levels.HANDLED)) {
-	                destroyLogger.log(Levels.HANDLED, 
-		            "Problem inactivating service", e);
-		    }
-                } catch (ActivationException e) { // ignore
-                    if(destroyLogger.isLoggable(Levels.HANDLED)) {
-	                destroyLogger.log(Levels.HANDLED, 
-		            "Problem inactivating service", e);
-		    }
-                }
-            }
-
 	    if (lifeCycle != null) {
 	        if(destroyLogger.isLoggable(Level.FINEST)) {
 	            destroyLogger.log(Level.FINEST,

Modified: river/jtsk/branches/2.2/src/com/sun/jini/mercury/MailboxImpl.java
URL: http://svn.apache.org/viewvc/river/jtsk/branches/2.2/src/com/sun/jini/mercury/MailboxImpl.java?rev=1718151&r1=1718150&r2=1718151&view=diff
==============================================================================
--- river/jtsk/branches/2.2/src/com/sun/jini/mercury/MailboxImpl.java (original)
+++ river/jtsk/branches/2.2/src/com/sun/jini/mercury/MailboxImpl.java Sun Dec  6 08:23:59 2015
@@ -44,7 +44,6 @@ import com.sun.jini.thread.ReadyState;
 import com.sun.jini.thread.RetryTask;
 import com.sun.jini.thread.TaskManager;
 import com.sun.jini.thread.WakeupManager;
-import net.jini.activation.ActivationExporter;
 import net.jini.config.Configuration;
 import net.jini.config.ConfigurationProvider;
 import net.jini.config.ConfigurationException;
@@ -70,12 +69,6 @@ import java.io.ObjectInputStream;
 import java.io.ObjectOutputStream;
 import java.io.OutputStream;
 import java.io.Serializable;
-import java.rmi.activation.Activatable;
-import java.rmi.activation.ActivationException;
-import java.rmi.activation.ActivationGroup;
-import java.rmi.activation.ActivationGroupID;
-import java.rmi.activation.ActivationID;
-import java.rmi.activation.ActivationSystem;
 import java.rmi.MarshalledObject;
 import java.rmi.NoSuchObjectException;
 import java.rmi.RemoteException;
@@ -343,15 +336,6 @@ class MailboxImpl implements MailboxBack
    /** ServiceID returned from the lookup registration process */
     private Uuid serviceID = null;
 
-    /** Our activation ID */
-    private ActivationID activationID = null;
-
-    /** Whether the activation ID has been prepared */
-    private boolean activationPrepared;
-
-    /** The activation system, prepared */
-    private ActivationSystem activationSystem;
-    
     /** <code>EventLogIterator</code> generator */
     private final EventLogFactory eventLogFactory = new EventLogFactory();
 
@@ -504,37 +488,6 @@ class MailboxImpl implements MailboxBack
         return mailboxAdminProxy;
     }
 
-    /**
-     * Activation constructor
-     *
-     * @param activationID activation ID passed in by the activation daemon.
-     * @param data state data needed to re-activate a Mercury server
-     */
-    MailboxImpl(ActivationID activationID, MarshalledObject data) 
-	throws Exception
-    {
-        if (operationsLogger.isLoggable(Level.FINER)) {
-	    operationsLogger.entering(mailboxSourceClass, 
-	        "MailboxImpl", 
-		new Object[] {activationID, data});
-	}
-	this.activationID = activationID;
-	try {
-	    // Initialize state
-	    init((String[])data.get());
-	} catch (Throwable e) {
-	    cleanup();
-	    initFailed(e);
-	}	  
-        if (operationsLogger.isLoggable(Level.FINER)) {
-	    operationsLogger.exiting(mailboxSourceClass, 
-	        "MailboxImpl");
-	}
-    }
-    
-    /////////////////////////
-    // Non-Activation Methods
-    /////////////////////////
     /** 
      * Constructor for creating transient (i.e. non-activatable) service 
      * instances. 
@@ -637,62 +590,17 @@ class MailboxImpl implements MailboxBack
 	}
 //TODO - defer "big" default object to catch block around getNonNullEntry()
     
-        // Get activation specific configuration items, if activated
-	if (activationID != null) {
-            ProxyPreparer activationSystemPreparer =
-                (ProxyPreparer) Config.getNonNullEntry(config,
-	            MERCURY, "activationSystemPreparer", 
-		    ProxyPreparer.class, new BasicProxyPreparer());
-            if (initLogger.isLoggable(Level.CONFIG)) {
-                initLogger.log(Level.CONFIG, "activationSystemPreparer: {0}", 
-	        activationSystemPreparer);
-	    }		
-            activationSystem =
-                (ActivationSystem) activationSystemPreparer.prepareProxy(
-                    ActivationGroup.getSystem());
-            if (initLogger.isLoggable(Level.FINEST)) {
-                initLogger.log(Level.FINEST, "Prepared activation system is: {0}", 
-	        activationSystem);
-	    }		
-            ProxyPreparer activationIdPreparer = 
-	        (ProxyPreparer)  Config.getNonNullEntry(config,
-	            MERCURY, "activationIdPreparer", 
-		    ProxyPreparer.class, new BasicProxyPreparer());
-            if (initLogger.isLoggable(Level.CONFIG)) {
-                initLogger.log(Level.CONFIG, "activationIdPreparer: {0}", 
-	        activationIdPreparer);
-	    }		
-            activationID = (ActivationID) activationIdPreparer.prepareProxy(
-                activationID);
-            if (initLogger.isLoggable(Level.FINEST)) {
-                initLogger.log(Level.FINEST, "Prepared activationID is: {0}", 
-	        activationID);
-	    }		
-            activationPrepared = true;
+        //Get non-activatable configuration items
+        exporter = (Exporter) Config.getNonNullEntry(config,
+            MERCURY, "serverExporter", Exporter.class, 
+            new BasicJeriExporter(
+                TcpServerEndpoint.getInstance(0), 
+                new BasicILFactory(), false, true));
+        if (initLogger.isLoggable(Level.CONFIG)) {
+            initLogger.log(Level.CONFIG, 
+            "Non-activatable service exporter is: {0}", exporter);		
+        }
 	
-            exporter = (Exporter)Config.getNonNullEntry(config,
-	        MERCURY, "serverExporter", Exporter.class,
-		new ActivationExporter(
-		    activationID, 
-		    new BasicJeriExporter(
-		        TcpServerEndpoint.getInstance(0), 
-			new BasicILFactory(), false, true)),
-		activationID);
-            if (initLogger.isLoggable(Level.CONFIG)) {
-                initLogger.log(Level.CONFIG, "Activatable service exporter is: {0}", 
-	        exporter);
-	    }		
-	} else { //Get non-activatable configuration items
-            exporter = (Exporter) Config.getNonNullEntry(config,
-                MERCURY, "serverExporter", Exporter.class, 
-		new BasicJeriExporter(
-		    TcpServerEndpoint.getInstance(0), 
-		    new BasicILFactory(), false, true));
-            if (initLogger.isLoggable(Level.CONFIG)) {
-                initLogger.log(Level.CONFIG, 
-		"Non-activatable service exporter is: {0}", exporter);		
-	    }
-	}
 
         listenerPreparer = (ProxyPreparer) Config.getNonNullEntry(
 	    config, MERCURY, "listenerPreparer", ProxyPreparer.class,
@@ -3248,35 +3156,6 @@ class MailboxImpl implements MailboxBack
 	            }
                     return;
                 }
-/**TODO 
-  * - move this block into the destroy() method and let the 
-  *   remote ex pass through
-  */
-   	        /* must unregister before unexport */
-   	        if (activationPrepared) {
-   		    try {
-   		        activationSystem.unregisterObject(activationID);
-   		    } catch (RemoteException e) {
-   		        if (adminLogger.isLoggable(Level.WARNING)) {
-                            adminLogger.log(Level.WARNING, 
-                                "aborting shutdown - could not unregister"
-                                + " activation ID", e);
-                        }
-                        /* give up until we can at least unregister */
-   		        return;
-   		    } catch (ActivationException e) {
-                        /*
-                         * Activation system is shutting down or this
-                         * object has already been unregistered --
-                         * ignore in either case.
-                         */
-   		        if (adminLogger.isLoggable(Levels.HANDLED)) {
-                            adminLogger.log(Levels.HANDLED, 
-                                "problem shutting down - could not unregister"
-                                + " activation ID", e);
-                        }
-   		    }
-   	        }
                 
                 long now = System.currentTimeMillis();
                 long endTime = now + maxUnexportDelay;
@@ -3461,15 +3340,7 @@ class MailboxImpl implements MailboxBack
    	        // directory, so it has to be last.
      	        if (log != null) log.deletePersistentStore();
    
-   	        if (activationID != null) {
-   		    /* inactive will set current group ID to null */
-   		    ActivationGroupID gid = ActivationGroup.currentGroupID();
-   		    try {
-   		        Activatable.inactive(activationID);
-   		    } catch (RemoteException e) { // ignore
-   		    } catch (ActivationException e) { // ignore
-   		    }
-   	        } else if (lifeCycle != null) {
+                if (lifeCycle != null) {
 		    lifeCycle.unregister(MailboxImpl.this);
 		}
 

Modified: river/jtsk/branches/2.2/src/com/sun/jini/outrigger/OutriggerServerImpl.java
URL: http://svn.apache.org/viewvc/river/jtsk/branches/2.2/src/com/sun/jini/outrigger/OutriggerServerImpl.java?rev=1718151&r1=1718150&r2=1718151&view=diff
==============================================================================
--- river/jtsk/branches/2.2/src/com/sun/jini/outrigger/OutriggerServerImpl.java (original)
+++ river/jtsk/branches/2.2/src/com/sun/jini/outrigger/OutriggerServerImpl.java Sun Dec  6 08:23:59 2015
@@ -31,7 +31,6 @@ import com.sun.jini.start.LifeCycle;
 
 import net.jini.id.Uuid;
 import net.jini.id.UuidFactory;
-import net.jini.activation.ActivationGroup;
 
 import net.jini.config.Configuration;
 import net.jini.config.ConfigurationProvider;
@@ -47,8 +46,6 @@ import net.jini.security.TrustVerifier;
 import net.jini.security.ProxyPreparer;
 import net.jini.security.proxytrust.ServerProxyTrust;
 
-import net.jini.activation.ActivationExporter;
-
 import net.jini.core.discovery.LookupLocator;
 import net.jini.core.lookup.ServiceID;
 import net.jini.core.entry.Entry;
@@ -73,9 +70,6 @@ import java.rmi.MarshalledObject;
 import java.rmi.NoSuchObjectException;
 import java.rmi.RemoteException;
 import java.rmi.UnmarshalException;
-import java.rmi.activation.ActivationID;
-import java.rmi.activation.ActivationSystem;
-import java.rmi.activation.ActivationException;
 import java.security.SecureRandom;
 import java.security.PrivilegedExceptionAction;
 import java.security.PrivilegedActionException;
@@ -412,16 +406,6 @@ public class OutriggerServerImpl
      */
     private static final SecureRandom idGen = new SecureRandom();
 
-    /** Our activation ID, <code>null</code> if we are not activatable */
-    private ActivationID activationID;
-
-    /** 
-     * A prepared reference to the activation system, <code>null</code> if
-     * we are not activatable.
-     */
-    private ActivationSystem activationSystem;
-
-      
     /**
      * Store - The reference to the persistent store, if any.
      */
@@ -507,14 +491,12 @@ public class OutriggerServerImpl
      *         in the configuration is non-null and throws 
      *         an exception when login is attempted.  
      */
-    OutriggerServerImpl(ActivationID activationID, LifeCycle lifeCycle,
+    OutriggerServerImpl(LifeCycle lifeCycle,
 			String[] configArgs, final boolean persistent,
 			OutriggerServerWrapper wrapper) 
-	throws IOException, ConfigurationException, LoginException,
-	       ActivationException
+	throws IOException, ConfigurationException, LoginException
     {	
 	this.lifeCycle = lifeCycle;
-	this.activationID = activationID;
 	this.serverGate = wrapper;
 
 	try {
@@ -581,35 +563,14 @@ public class OutriggerServerImpl
      * @throws ConfigurationException if the <code>Configuration</code> is 
      * malformed.  */
     private void init(Configuration config, boolean persistent) 
-    	throws IOException, ConfigurationException, ActivationException
+    	throws IOException, ConfigurationException
     {
 	txnMonitor = new TxnMonitor(this, config);
 
-	/* Get the activation related preparers we need */
-
 	// Default do nothing preparer
 	final ProxyPreparer defaultPreparer = 
 	    new net.jini.security.BasicProxyPreparer();
 
-	if (activationID != null) {
-	    final ProxyPreparer aidPreparer = 
-		(ProxyPreparer)Config.getNonNullEntry(config,
-		    COMPONENT_NAME, "activationIdPreparer",
-		    ProxyPreparer.class, defaultPreparer);
-                
-	    final ProxyPreparer aSysPreparer =
-		(ProxyPreparer)Config.getNonNullEntry(config,
-		     COMPONENT_NAME, "activationSystemPreparer",
-		     ProxyPreparer.class, defaultPreparer);
-
-	    activationID = 
-		(ActivationID)aidPreparer.prepareProxy(activationID);
-	    activationSystem =
-		(ActivationSystem)aSysPreparer.prepareProxy(
-		    ActivationGroup.getSystem());
-	}
-
-
 	// The preparers that all outrigger's need
 	transactionManagerPreparer = 
 	    (ProxyPreparer)Config.getNonNullEntry(config, 
@@ -631,16 +592,11 @@ public class OutriggerServerImpl
 	final Exporter basicExporter = 
 	    new BasicJeriExporter(TcpServerEndpoint.getInstance(0),
 				  new BasicILFactory(), false, true);
-	if (activationID == null) {
-	    exporter = (Exporter)Config.getNonNullEntry(config,
-		COMPONENT_NAME,	"serverExporter", Exporter.class,
-		basicExporter);
-	} else {
-	    exporter = (Exporter)Config.getNonNullEntry(config, 
-		COMPONENT_NAME,	"serverExporter", Exporter.class,
-		new ActivationExporter(activationID, basicExporter),
-		activationID);
-	}
+
+	exporter = (Exporter)Config.getNonNullEntry(config, 
+            COMPONENT_NAME,"serverExporter", Exporter.class,
+            basicExporter);
+	
 
 	ourRemoteRef = (OutriggerServer)exporter.export(serverGate);
 
@@ -707,7 +663,7 @@ public class OutriggerServerImpl
 	    //
 	    log.bootOp(System.currentTimeMillis(), getSessionId());
 	    recoverTxns();
-	} else if (activationID != null || persistent) {
+	} else if (persistent) {
 	    /* else we don't have a store, if we need one complain
 	     * will be logged by constructor
 	     */
@@ -2794,18 +2750,6 @@ public class OutriggerServerImpl
 		logDestroyProblem("destroying JoinManager", t);
 	    }	
 
-	    // Want to unregister before unexporting so a call can't
-	    // sneak in and re-activate us
-	    if (activationID != null) {  // In an activation group
-		try {
-		    //shared VM -- just unregister this object
-		    logDestroyPhase("unregistering object");
-		    activationSystem.unregisterObject(activationID);
-		} catch (Exception t) {
-		    logDestroyProblem("unregistering server", t);
-		}
-	    }
-	
 	    // Attempt to unexport this object -- nicely first
 	    logDestroyPhase("unexporting force = false");
 	    long now = System.currentTimeMillis();
@@ -2921,17 +2865,6 @@ public class OutriggerServerImpl
 		}
 	    }
 
-            if (activationID != null) {         
-		logDestroyPhase("calling ActivationGroup.inactive");
-                try {
-                    ActivationGroup.inactive(activationID, exporter);
-                } catch (RemoteException e) {
-		    logDestroyProblem("calling ActivationGroup.inactive", e);
-                } catch (ActivationException e) {
-		    logDestroyProblem("calling ActivationGroup.inactive", e);
-                }	
-	    }
-
 	    if (lifeCycle != null) {
 		// runtime has a ref to the serverGate, not this
 		logDestroyPhase("calling lifeCycle.unregister");

Modified: river/jtsk/branches/2.2/src/com/sun/jini/outrigger/OutriggerServerWrapper.java
URL: http://svn.apache.org/viewvc/river/jtsk/branches/2.2/src/com/sun/jini/outrigger/OutriggerServerWrapper.java?rev=1718151&r1=1718150&r2=1718151&view=diff
==============================================================================
--- river/jtsk/branches/2.2/src/com/sun/jini/outrigger/OutriggerServerWrapper.java (original)
+++ river/jtsk/branches/2.2/src/com/sun/jini/outrigger/OutriggerServerWrapper.java Sun Dec  6 08:23:59 2015
@@ -19,11 +19,8 @@ package com.sun.jini.outrigger;
 
 import java.util.Map;
 import java.io.IOException;
-import java.rmi.Remote;
 import java.rmi.MarshalledObject;
 import java.rmi.RemoteException;
-import java.rmi.activation.ActivationID;
-import java.rmi.activation.ActivationException;
 import javax.security.auth.login.LoginException;
 
 import net.jini.core.discovery.LookupLocator;
@@ -34,7 +31,6 @@ import net.jini.core.transaction.Transac
 import net.jini.core.transaction.TransactionException;
 import net.jini.core.transaction.UnknownTransactionException;
 import net.jini.core.transaction.server.TransactionManager;
-import net.jini.core.lease.Lease;
 import net.jini.core.lease.LeaseDeniedException;
 import net.jini.core.lease.UnknownLeaseException;
 import net.jini.export.ProxyAccessor;
@@ -73,7 +69,7 @@ class OutriggerServerWrapper
 
     /** 
      * If non-null cause incoming calls to immediately throw this
-     * exception. Takes presidents over <code>holdCalls</code>. This
+     * exception. Takes precedence over <code>holdCalls</code>. This
      * field is only set to an <code>Error</code>,
      * <code>RemoteException</code>, or <code>RuntimeException</code>
      * and thus can be thrown by an of <code>OutriggerServer</code>'s
@@ -105,42 +101,9 @@ class OutriggerServerWrapper
 			   boolean persistent) 
 	throws IOException, ConfigurationException, LoginException
     {
-	try {
-	    delegate = new OutriggerServerImpl(null, lifeCycle, configArgs,
+	
+	delegate = new OutriggerServerImpl(lifeCycle, configArgs,
 					       persistent, this);
-	} catch (ActivationException e) {
-	    throw new AssertionError(e);
-	}
-    }
-
-    /**
-     * Create an <code>OutriggerServerWrapper</code> that
-     * will delegate to an <code>OutriggerServerImpl</code>
-     * created with the specified argument and wrapped by <code>this</code>.
-     * @param activationID of the server, must not be <code>null</code>.
-     * @param configArgs set of strings to be used to obtain a
-     *                   <code>Configuration</code>.
-     * @throws IOException if there is problem recovering data
-     *         from disk, exporting the server, or unpacking 
-     *         <code>data</code>.
-     * @throws ConfigurationException if the <code>Configuration</code> is 
-     *         malformed.
-     * @throws ActivationException if activatable and there
-     *         is a problem getting a reference to the activation system.
-     * @throws LoginException if the <code>loginContext</code> specified
-     *         in the configuration is non-null and throws 
-     *         an exception when login is attempted.
-     * @throws NullPointerException if <code>activationID</code>
-     *         is <code>null</code>.
-     */
-    OutriggerServerWrapper(ActivationID activationID, String[] configArgs) 
-	throws IOException, ConfigurationException, LoginException,
-	       ActivationException
-    {
-	if (activationID == null)
-	    throw new NullPointerException("activationID must be non-null");
-	delegate = new OutriggerServerImpl(activationID, null, configArgs,
-					   true, this);
     }
 
     /**

Modified: river/jtsk/branches/2.2/src/com/sun/jini/outrigger/PersistentOutriggerImpl.java
URL: http://svn.apache.org/viewvc/river/jtsk/branches/2.2/src/com/sun/jini/outrigger/PersistentOutriggerImpl.java?rev=1718151&r1=1718150&r2=1718151&view=diff
==============================================================================
--- river/jtsk/branches/2.2/src/com/sun/jini/outrigger/PersistentOutriggerImpl.java (original)
+++ river/jtsk/branches/2.2/src/com/sun/jini/outrigger/PersistentOutriggerImpl.java Sun Dec  6 08:23:59 2015
@@ -20,8 +20,6 @@ package com.sun.jini.outrigger;
 import java.io.IOException;
 import java.rmi.Remote;
 import java.rmi.MarshalledObject;
-import java.rmi.activation.ActivationID;
-import java.rmi.activation.ActivationException;
 import javax.security.auth.login.LoginException;
 import net.jini.config.ConfigurationException;
 import com.sun.jini.start.LifeCycle;
@@ -35,37 +33,6 @@ import com.sun.jini.start.LifeCycle;
  */
 class PersistentOutriggerImpl extends OutriggerServerWrapper {
     /**
-     * Create a new incarnation of an activatable
-     * <code>OutriggerServerImpl</code> server.
-     * @param activationID of the server, may be <code>null</code>.
-     * @param data an array of <code>String</code>s (packaged in
-     *        a marshalled object) that will be used 
-     *        to obtain a <code>Configuration</code>.
-     * @throws IOException if there is problem recovering data
-     *         from disk, exporting the server, or unpacking
-     *         <code>data</code>.
-     * @throws ClassCastException if the value of <code>data.get()</code>
-     *         is not an array of <code>String</code>s.
-     * @throws ConfigurationException if the <code>Configuration</code> is 
-     *         malformed.  
-     * @throws ActivationException if activatable and there
-     *         is a problem getting a reference to the activation system.
-     * @throws LoginException if the <code>loginContext</code> specified
-     *         in the configuration is non-null and throws 
-     *         an exception when login is attempted.
-     * @throws ClassNotFoundException if the classes of the objects
-     *         encapsulated inside <code>data</code> can not be found.
-     */
-    PersistentOutriggerImpl(ActivationID activationID, 
-			    MarshalledObject data) 
-	throws IOException, ConfigurationException, LoginException,
-	       ActivationException, ClassNotFoundException
-    {
-	super(activationID, (String[])data.get());
-	allowCalls();
-    }
-
-    /**
      * Create a new non-activatable, persistent space.
      * The space will be implemented by a new
      * <code>OutriggerServerImpl()</code> server instance.

Modified: river/jtsk/branches/2.2/src/com/sun/jini/reggie/PersistentRegistrarImpl.java
URL: http://svn.apache.org/viewvc/river/jtsk/branches/2.2/src/com/sun/jini/reggie/PersistentRegistrarImpl.java?rev=1718151&r1=1718150&r2=1718151&view=diff
==============================================================================
--- river/jtsk/branches/2.2/src/com/sun/jini/reggie/PersistentRegistrarImpl.java (original)
+++ river/jtsk/branches/2.2/src/com/sun/jini/reggie/PersistentRegistrarImpl.java Sun Dec  6 08:23:59 2015
@@ -20,10 +20,9 @@ package com.sun.jini.reggie;
 
 import com.sun.jini.start.LifeCycle;
 import java.rmi.MarshalledObject;
-import java.rmi.activation.ActivationID;
 
 /**
- * Class for starting activatable and non-activatable persistent lookup
+ * Class for starting persistent lookup
  * services.
  *
  * @author Sun Microsystems, Inc.
@@ -31,24 +30,14 @@ import java.rmi.activation.ActivationID;
 public class PersistentRegistrarImpl extends RegistrarImpl {
 
     /**
-     * Constructs a non-activatable PersistentRegistrarImpl based on a
+     * Constructs a PersistentRegistrarImpl based on a
      * configuration obtained using the provided arguments.  If lifeCycle is
      * non-null, then its unregister method is invoked during service shutdown.
      */
     protected PersistentRegistrarImpl(String[] configArgs, LifeCycle lifeCycle)
 	throws Exception
     {
-	super(configArgs, null, true, lifeCycle);
+	super(configArgs, true, lifeCycle);
     }
 
-    /**
-     * Constructs an activatable PersistentRegistrarImpl assigned
-     * the given activation ID, based on a configuration obtained using
-     * the provided marshalled string array.
-     */
-    PersistentRegistrarImpl(ActivationID activationID, MarshalledObject data)
-	throws Exception
-    {
-	super((String[]) data.get(), activationID, true, null);
-    }
 }

Modified: river/jtsk/branches/2.2/src/com/sun/jini/reggie/RegistrarImpl.java
URL: http://svn.apache.org/viewvc/river/jtsk/branches/2.2/src/com/sun/jini/reggie/RegistrarImpl.java?rev=1718151&r1=1718150&r2=1718151&view=diff
==============================================================================
--- river/jtsk/branches/2.2/src/com/sun/jini/reggie/RegistrarImpl.java (original)
+++ river/jtsk/branches/2.2/src/com/sun/jini/reggie/RegistrarImpl.java Sun Dec  6 08:23:59 2015
@@ -63,9 +63,6 @@ import java.nio.ByteBuffer;
 import java.rmi.MarshalledObject;
 import java.rmi.NoSuchObjectException;
 import java.rmi.RemoteException;
-import java.rmi.activation.ActivationException;
-import java.rmi.activation.ActivationID;
-import java.rmi.activation.ActivationSystem;
 import java.util.ArrayList;
 import java.util.Arrays;
 import java.util.Collections;
@@ -86,8 +83,6 @@ import javax.net.SocketFactory;
 import javax.security.auth.Subject;
 import javax.security.auth.login.LoginContext;
 import javax.security.auth.login.LoginException;
-import net.jini.activation.ActivationExporter;
-import net.jini.activation.ActivationGroup;
 import net.jini.config.Configuration;
 import net.jini.config.ConfigurationException;
 import net.jini.config.ConfigurationProvider;
@@ -179,10 +174,6 @@ class RegistrarImpl implements Registrar
     private Registrar myRef;
     /** Our service ID */
     private ServiceID myServiceID;
-    /** Our activation id, or null if not activatable */
-    private ActivationID activationID;
-    /** Associated activation system, or null if not activatable */
-    private ActivationSystem activationSystem;
     /** Our LookupLocator */
     private volatile LookupLocator myLocator;
     /** Our login context, for logging out */
@@ -377,14 +368,11 @@ class RegistrarImpl implements Registrar
 
     /**
      * Constructs RegistrarImpl based on a configuration obtained using the
-     * provided string arguments.  If activationID is non-null, the created
-     * RegistrarImpl runs as activatable; if persistent is true, it
-     * persists/recovers its state to/from disk.  A RegistrarImpl instance
-     * cannot be constructed as both activatable and non-persistent.  If
+     * provided string arguments.  If persistent is true, it
+     * persists/recovers its state to/from disk.  If
      * lifeCycle is non-null, its unregister method is invoked during shutdown.
      */
     RegistrarImpl(String[] configArgs,
-		  final ActivationID activationID,
 		  final boolean persistent,
 		  final LifeCycle lifeCycle)
 	throws Exception
@@ -393,7 +381,7 @@ class RegistrarImpl implements Registrar
 	    final Configuration config = ConfigurationProvider.getInstance(
 		configArgs, getClass().getClassLoader());
 
-            loginAndRun(config,activationID,persistent,lifeCycle);
+            loginAndRun(config,persistent,lifeCycle);
 	} catch (Throwable t) {
 	    logger.log(Level.SEVERE, "Reggie initialization failed", t);
 	    if (t instanceof Exception) {
@@ -406,20 +394,17 @@ class RegistrarImpl implements Registrar
 
     /**
      * Constructs RegistrarImpl based on the
-     * Configuration argument.  If activationID is non-null, the created
-     * RegistrarImpl runs as activatable; if persistent is true, it
-     * persists/recovers its state to/from disk.  A RegistrarImpl instance
-     * cannot be constructed as both activatable and non-persistent.  If
+     * Configuration argument.  If persistent is true, it
+     * persists/recovers its state to/from disk.  If
      * lifeCycle is non-null, its unregister method is invoked during shutdown.
      */
     RegistrarImpl(final Configuration config,
-		  final ActivationID activationID,
 		  final boolean persistent,
 		  final LifeCycle lifeCycle)
 	throws Exception
     {
 	try {
-            loginAndRun(config,activationID,persistent,lifeCycle);
+            loginAndRun(config,persistent,lifeCycle);
 	} catch (Throwable t) {
 	    logger.log(Level.SEVERE, "Reggie initialization failed", t);
 	    if (t instanceof Exception) {
@@ -431,21 +416,17 @@ class RegistrarImpl implements Registrar
     }
 
     private void loginAndRun( final Configuration config,
-                        final ActivationID activationID,
                         final boolean persistent,
                         final LifeCycle lifeCycle)
 	throws Throwable
     {
-	if (activationID != null && !persistent) {
-	    throw new IllegalArgumentException();
-	}
 
         loginContext = (LoginContext) config.getEntry(
            COMPONENT, "loginContext", LoginContext.class, null);
 
         PrivilegedExceptionAction init = new PrivilegedExceptionAction() {
             public Object run() throws Exception {
-                init(config, activationID, persistent, lifeCycle);
+                init(config, persistent, lifeCycle);
                 return null;
             }
         };
@@ -2232,8 +2213,7 @@ class RegistrarImpl implements Registrar
 
     /**
      * Termination thread code.  We do this in a separate thread to
-     * avoid deadlock, because ActivationGroup.inactive will block until
-     * in-progress RMI calls are finished.
+     * avoid deadlock.
      */
     private class DestroyThread extends InterruptedStatusThread {
 
@@ -2294,13 +2274,6 @@ class RegistrarImpl implements Registrar
 		log.deletePersistentStore();
 		logger.finer("deleted persistence directory");
 	    }
-	    if (activationID != null) {
-		try {
-		    ActivationGroup.inactive(activationID, serverExporter);
-		} catch (Exception e) {
-		    logger.log(Level.INFO, "exception going inactive", e);
-		}
-	    }
 	    if (lifeCycle != null) {
 		lifeCycle.unregister(RegistrarImpl.this);
 	    }
@@ -3496,19 +3469,6 @@ class RegistrarImpl implements Registrar
 	try {
 	    ready.check();
 	    logger.info("starting Reggie shutdown");
-	    /* unregister with activation system if activatable */
-	    if (activationID != null) {
-		try {
-		    activationSystem.unregisterObject(activationID);
-		} catch (ActivationException e) {
-		    logger.log(Levels.HANDLED,
-			       "exception unregistering activation ID", e);
-		} catch (RemoteException e) {
-		    logger.log(Level.WARNING,
-			       "aborting Reggie shutdown", e);
-		    throw e;
-		}
-	    }
 	    ready.shutdown();	    
 	    new DestroyThread().start();
 	} finally {
@@ -4427,10 +4387,9 @@ class RegistrarImpl implements Registrar
 
     /** Post-login (if login configured) initialization. */
     private void init(Configuration config,
-		      ActivationID activationID,
 		      boolean persistent,
 		      LifeCycle lifeCycle)
-	throws IOException, ConfigurationException, ActivationException
+	throws IOException, ConfigurationException
     {
 	this.lifeCycle = lifeCycle;
 
@@ -4471,42 +4430,12 @@ class RegistrarImpl implements Registrar
 	    log = null;
 	}
 
-	/* activation-specific initialization */
-	if (activationID != null) {
-	    ProxyPreparer activationIdPreparer = (ProxyPreparer)
-		Config.getNonNullEntry(
-		    config, COMPONENT, "activationIdPreparer",
-		    ProxyPreparer.class, new BasicProxyPreparer());
-	    ProxyPreparer activationSystemPreparer = (ProxyPreparer)
-		Config.getNonNullEntry(
-		    config, COMPONENT, "activationSystemPreparer",
-		    ProxyPreparer.class, new BasicProxyPreparer());
-
-	    this.activationID = (ActivationID)
-		activationIdPreparer.prepareProxy(activationID);
-	    activationSystem = (ActivationSystem)
-		activationSystemPreparer.prepareProxy(
-		    ActivationGroup.getSystem());
-
-	    serverExporter = (Exporter) Config.getNonNullEntry(
-		config, COMPONENT, "serverExporter", Exporter.class,
-		new ActivationExporter(
-		    this.activationID,
-		    new BasicJeriExporter(
-			TcpServerEndpoint.getInstance(0),
-			new BasicILFactory())),
-		this.activationID);
-	} else {
-	    this.activationID = null;
-	    activationSystem = null;
-
-	    serverExporter = (Exporter) Config.getNonNullEntry(
-		config, COMPONENT, "serverExporter", Exporter.class,
-		new BasicJeriExporter(
-		    TcpServerEndpoint.getInstance(0),
-		    new BasicILFactory()));
-	}
-
+        serverExporter = (Exporter) Config.getNonNullEntry(
+            config, COMPONENT, "serverExporter", Exporter.class,
+            new BasicJeriExporter(
+                TcpServerEndpoint.getInstance(0),
+                new BasicILFactory()));
+	
 	/* fetch "initial*" config entries, if first time starting up */
 	if (!recoveredSnapshot) {
 	    Entry[] initialLookupAttributes = (Entry[]) config.getEntry(

Modified: river/jtsk/branches/2.2/src/com/sun/jini/reggie/TransientRegistrarImpl.java
URL: http://svn.apache.org/viewvc/river/jtsk/branches/2.2/src/com/sun/jini/reggie/TransientRegistrarImpl.java?rev=1718151&r1=1718150&r2=1718151&view=diff
==============================================================================
--- river/jtsk/branches/2.2/src/com/sun/jini/reggie/TransientRegistrarImpl.java (original)
+++ river/jtsk/branches/2.2/src/com/sun/jini/reggie/TransientRegistrarImpl.java Sun Dec  6 08:23:59 2015
@@ -36,7 +36,7 @@ public class TransientRegistrarImpl exte
     protected TransientRegistrarImpl(String[] configArgs, LifeCycle lifeCycle)
 	throws Exception
     {
-	super(configArgs, null, false, lifeCycle);
+	super(configArgs, false, lifeCycle);
     }
 
     /**
@@ -51,7 +51,7 @@ public class TransientRegistrarImpl exte
     protected TransientRegistrarImpl(Configuration config, LifeCycle lifeCycle)
 	throws Exception
     {
-	super(config, null, false, lifeCycle);
+	super(config, false, lifeCycle);
     }
     
 }

Added: river/jtsk/branches/2.2/src/com/sun/jini/start/ExportClassLoader.java
URL: http://svn.apache.org/viewvc/river/jtsk/branches/2.2/src/com/sun/jini/start/ExportClassLoader.java?rev=1718151&view=auto
==============================================================================
--- river/jtsk/branches/2.2/src/com/sun/jini/start/ExportClassLoader.java (added)
+++ river/jtsk/branches/2.2/src/com/sun/jini/start/ExportClassLoader.java Sun Dec  6 08:23:59 2015
@@ -0,0 +1,101 @@
+/*
+ * Licensed to the Apache Software Foundation (ASF) under one
+ * or more contributor license agreements.  See the NOTICE file
+ * distributed with this work for additional information
+ * regarding copyright ownership. The ASF licenses this file
+ * to you 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.
+ */
+package com.sun.jini.start;
+
+import java.net.URL;
+import java.util.Arrays;
+import net.jini.id.Uuid;
+import net.jini.id.UuidFactory;
+import net.jini.loader.pref.PreferredClassLoader;
+
+/**
+ * A simple subclass of <code>PreferredClassLoader</code> that overrides
+ * <code>getURLs</code> to return the <code>URL</code>s of the provided export
+ * codebase. <code>getURLs</code> is called by the RMI subsystem in order to
+ * annotate objects leaving the virtual machine.
+ */
+/*
+ * Implementation note. Subclasses of this class that override
+ * getClassAnnotation might need to override getURLs because getURLs
+ * uses a "cached" version of the export annotation.
+ */
+public class ExportClassLoader extends PreferredClassLoader {
+
+    /**
+     * Cached value of the provided export codebase <code>URL</code>s
+     */
+    private final URL[] exportURLs;
+    /**
+     * Id field used to make toString() unique
+     */
+    private final Uuid id = UuidFactory.generate();
+
+    /**
+     * Trivial constructor that calls
+     * <pre>
+     * super(importURLs, parent, urlsToPath(exportURLs), false);
+     * </pre> and assigns <code>exportURLs</code> to an internal field.
+     */
+    public ExportClassLoader(URL[] importURLs, URL[] exportURLs, ClassLoader parent) {
+        super(importURLs, parent, urlsToPath(exportURLs), false);
+        // Not safe to call getClassAnnotation() w/i cons if subclassed,
+        // so need to redo "super" logic here.
+        if (exportURLs == null) {
+            this.exportURLs = importURLs;
+        } else {
+            this.exportURLs = exportURLs;
+        }
+    }
+
+    //Javadoc inherited from super type
+    public URL[] getURLs() {
+        return (URL[]) exportURLs.clone();
+    }
+
+    // Javadoc inherited from supertype
+    public String toString() {
+        URL[] urls = super.getURLs();
+        return this.getClass().getName() + "[importURLs=" + (urls == null ? null : Arrays.asList(urls)) + "," + "exportURLs=" + (exportURLs == null ? null : Arrays.asList(exportURLs)) + "," + "parent=" + getParent() + "," + "id=" + id + "]";
+    }
+
+    /**
+     * Utility method that converts a <code>URL[]</code> into a corresponding,
+     * space-separated string with the same array elements.
+     *
+     * Note that if the array has zero elements, the return value is null, not
+     * the empty string.
+     */
+    private static String urlsToPath(URL[] urls) {
+//TODO - check if spaces in file paths are properly escaped (i.e.% chars)	
+        if (urls == null) {
+            return null;
+        } else if (urls.length == 0) {
+            return "";
+        } else if (urls.length == 1) {
+            return urls[0].toExternalForm();
+        } else {
+            StringBuffer path = new StringBuffer(urls[0].toExternalForm());
+            for (int i = 1; i < urls.length; i++) {
+                path.append(' ');
+                path.append(urls[i].toExternalForm());
+            }
+            return path.toString();
+        }
+    }
+
+}