Java Code Examples for java.rmi.server.ObjID#DGC_ID
The following examples show how to use
java.rmi.server.ObjID#DGC_ID .
You can vote up the ones you like or vote down the ones you don't like,
and go to the original project or source file by following the links above each example. You may check out the related API usage on the sidebar.
Example 1
Source File: DGCImpl.java From jdk8u60 with GNU General Public License v2.0 | 5 votes |
public Void run() { ClassLoader savedCcl = Thread.currentThread().getContextClassLoader(); try { Thread.currentThread().setContextClassLoader( ClassLoader.getSystemClassLoader()); /* * Put remote collector object in table by hand to prevent * listen on port. (UnicastServerRef.exportObject would * cause transport to listen.) */ try { dgc = new DGCImpl(); ObjID dgcID = new ObjID(ObjID.DGC_ID); LiveRef ref = new LiveRef(dgcID, 0); UnicastServerRef disp = new UnicastServerRef(ref); Remote stub = Util.createProxy(DGCImpl.class, new UnicastRef(ref), true); disp.setSkeleton(dgc); Target target = new Target(dgc, disp, stub, dgcID, true); ObjectTable.putTarget(target); } catch (RemoteException e) { throw new Error( "exception initializing server-side DGC", e); } } finally { Thread.currentThread().setContextClassLoader(savedCcl); } return null; }
Example 2
Source File: DGCImpl.java From openjdk-8-source with GNU General Public License v2.0 | 5 votes |
public Void run() { ClassLoader savedCcl = Thread.currentThread().getContextClassLoader(); try { Thread.currentThread().setContextClassLoader( ClassLoader.getSystemClassLoader()); /* * Put remote collector object in table by hand to prevent * listen on port. (UnicastServerRef.exportObject would * cause transport to listen.) */ try { dgc = new DGCImpl(); ObjID dgcID = new ObjID(ObjID.DGC_ID); LiveRef ref = new LiveRef(dgcID, 0); UnicastServerRef disp = new UnicastServerRef(ref); Remote stub = Util.createProxy(DGCImpl.class, new UnicastRef(ref), true); disp.setSkeleton(dgc); Target target = new Target(dgc, disp, stub, dgcID, true); ObjectTable.putTarget(target); } catch (RemoteException e) { throw new Error( "exception initializing server-side DGC", e); } } finally { Thread.currentThread().setContextClassLoader(savedCcl); } return null; }
Example 3
Source File: DGCImpl.java From openjdk-8 with GNU General Public License v2.0 | 5 votes |
public Void run() { ClassLoader savedCcl = Thread.currentThread().getContextClassLoader(); try { Thread.currentThread().setContextClassLoader( ClassLoader.getSystemClassLoader()); /* * Put remote collector object in table by hand to prevent * listen on port. (UnicastServerRef.exportObject would * cause transport to listen.) */ try { dgc = new DGCImpl(); ObjID dgcID = new ObjID(ObjID.DGC_ID); LiveRef ref = new LiveRef(dgcID, 0); UnicastServerRef disp = new UnicastServerRef(ref); Remote stub = Util.createProxy(DGCImpl.class, new UnicastRef(ref), true); disp.setSkeleton(dgc); Target target = new Target(dgc, disp, stub, dgcID, true); ObjectTable.putTarget(target); } catch (RemoteException e) { throw new Error( "exception initializing server-side DGC", e); } } finally { Thread.currentThread().setContextClassLoader(savedCcl); } return null; }
Example 4
Source File: DGCImpl.java From jdk8u-jdk with GNU General Public License v2.0 | 5 votes |
public Void run() { ClassLoader savedCcl = Thread.currentThread().getContextClassLoader(); try { Thread.currentThread().setContextClassLoader( ClassLoader.getSystemClassLoader()); /* * Put remote collector object in table by hand to prevent * listen on port. (UnicastServerRef.exportObject would * cause transport to listen.) */ try { dgc = new DGCImpl(); ObjID dgcID = new ObjID(ObjID.DGC_ID); LiveRef ref = new LiveRef(dgcID, 0); UnicastServerRef disp = new UnicastServerRef(ref); Remote stub = Util.createProxy(DGCImpl.class, new UnicastRef(ref), true); disp.setSkeleton(dgc); Target target = new Target(dgc, disp, stub, dgcID, true); ObjectTable.putTarget(target); } catch (RemoteException e) { throw new Error( "exception initializing server-side DGC", e); } } finally { Thread.currentThread().setContextClassLoader(savedCcl); } return null; }
Example 5
Source File: DGCImpl.java From jdk8u-dev-jdk with GNU General Public License v2.0 | 5 votes |
public Void run() { ClassLoader savedCcl = Thread.currentThread().getContextClassLoader(); try { Thread.currentThread().setContextClassLoader( ClassLoader.getSystemClassLoader()); /* * Put remote collector object in table by hand to prevent * listen on port. (UnicastServerRef.exportObject would * cause transport to listen.) */ try { dgc = new DGCImpl(); ObjID dgcID = new ObjID(ObjID.DGC_ID); LiveRef ref = new LiveRef(dgcID, 0); UnicastServerRef disp = new UnicastServerRef(ref); Remote stub = Util.createProxy(DGCImpl.class, new UnicastRef(ref), true); disp.setSkeleton(dgc); Target target = new Target(dgc, disp, stub, dgcID, true); ObjectTable.putTarget(target); } catch (RemoteException e) { throw new Error( "exception initializing server-side DGC", e); } } finally { Thread.currentThread().setContextClassLoader(savedCcl); } return null; }
Example 6
Source File: DGCImpl.java From dragonwell8_jdk with GNU General Public License v2.0 | 4 votes |
public Void run() { ClassLoader savedCcl = Thread.currentThread().getContextClassLoader(); try { Thread.currentThread().setContextClassLoader( ClassLoader.getSystemClassLoader()); /* * Put remote collector object in table by hand to prevent * listen on port. (UnicastServerRef.exportObject would * cause transport to listen.) */ try { dgc = new DGCImpl(); ObjID dgcID = new ObjID(ObjID.DGC_ID); LiveRef ref = new LiveRef(dgcID, 0); UnicastServerRef disp = new UnicastServerRef(ref, DGCImpl::checkInput); Remote stub = Util.createProxy(DGCImpl.class, new UnicastRef(ref), true); disp.setSkeleton(dgc); Permissions perms = new Permissions(); perms.add(new SocketPermission("*", "accept,resolve")); ProtectionDomain[] pd = { new ProtectionDomain(null, perms) }; AccessControlContext acceptAcc = new AccessControlContext(pd); Target target = AccessController.doPrivileged( new PrivilegedAction<Target>() { public Target run() { return new Target(dgc, disp, stub, dgcID, true); } }, acceptAcc); ObjectTable.putTarget(target); } catch (RemoteException e) { throw new Error( "exception initializing server-side DGC", e); } } finally { Thread.currentThread().setContextClassLoader(savedCcl); } return null; }
Example 7
Source File: DGCImpl.java From TencentKona-8 with GNU General Public License v2.0 | 4 votes |
public Void run() { ClassLoader savedCcl = Thread.currentThread().getContextClassLoader(); try { Thread.currentThread().setContextClassLoader( ClassLoader.getSystemClassLoader()); /* * Put remote collector object in table by hand to prevent * listen on port. (UnicastServerRef.exportObject would * cause transport to listen.) */ try { dgc = new DGCImpl(); ObjID dgcID = new ObjID(ObjID.DGC_ID); LiveRef ref = new LiveRef(dgcID, 0); UnicastServerRef disp = new UnicastServerRef(ref, DGCImpl::checkInput); Remote stub = Util.createProxy(DGCImpl.class, new UnicastRef(ref), true); disp.setSkeleton(dgc); Permissions perms = new Permissions(); perms.add(new SocketPermission("*", "accept,resolve")); ProtectionDomain[] pd = { new ProtectionDomain(null, perms) }; AccessControlContext acceptAcc = new AccessControlContext(pd); Target target = AccessController.doPrivileged( new PrivilegedAction<Target>() { public Target run() { return new Target(dgc, disp, stub, dgcID, true); } }, acceptAcc); ObjectTable.putTarget(target); } catch (RemoteException e) { throw new Error( "exception initializing server-side DGC", e); } } finally { Thread.currentThread().setContextClassLoader(savedCcl); } return null; }
Example 8
Source File: DGCImpl.java From openjdk-jdk8u with GNU General Public License v2.0 | 4 votes |
public Void run() { ClassLoader savedCcl = Thread.currentThread().getContextClassLoader(); try { Thread.currentThread().setContextClassLoader( ClassLoader.getSystemClassLoader()); /* * Put remote collector object in table by hand to prevent * listen on port. (UnicastServerRef.exportObject would * cause transport to listen.) */ try { dgc = new DGCImpl(); ObjID dgcID = new ObjID(ObjID.DGC_ID); LiveRef ref = new LiveRef(dgcID, 0); UnicastServerRef disp = new UnicastServerRef(ref, DGCImpl::checkInput); Remote stub = Util.createProxy(DGCImpl.class, new UnicastRef(ref), true); disp.setSkeleton(dgc); Permissions perms = new Permissions(); perms.add(new SocketPermission("*", "accept,resolve")); ProtectionDomain[] pd = { new ProtectionDomain(null, perms) }; AccessControlContext acceptAcc = new AccessControlContext(pd); Target target = AccessController.doPrivileged( new PrivilegedAction<Target>() { public Target run() { return new Target(dgc, disp, stub, dgcID, true); } }, acceptAcc); ObjectTable.putTarget(target); } catch (RemoteException e) { throw new Error( "exception initializing server-side DGC", e); } } finally { Thread.currentThread().setContextClassLoader(savedCcl); } return null; }
Example 9
Source File: DGCImpl.java From openjdk-jdk8u-backup with GNU General Public License v2.0 | 4 votes |
public Void run() { ClassLoader savedCcl = Thread.currentThread().getContextClassLoader(); try { Thread.currentThread().setContextClassLoader( ClassLoader.getSystemClassLoader()); /* * Put remote collector object in table by hand to prevent * listen on port. (UnicastServerRef.exportObject would * cause transport to listen.) */ try { dgc = new DGCImpl(); ObjID dgcID = new ObjID(ObjID.DGC_ID); LiveRef ref = new LiveRef(dgcID, 0); UnicastServerRef disp = new UnicastServerRef(ref, DGCImpl::checkInput); Remote stub = Util.createProxy(DGCImpl.class, new UnicastRef(ref), true); disp.setSkeleton(dgc); Permissions perms = new Permissions(); perms.add(new SocketPermission("*", "accept,resolve")); ProtectionDomain[] pd = { new ProtectionDomain(null, perms) }; AccessControlContext acceptAcc = new AccessControlContext(pd); Target target = AccessController.doPrivileged( new PrivilegedAction<Target>() { public Target run() { return new Target(dgc, disp, stub, dgcID, true); } }, acceptAcc); ObjectTable.putTarget(target); } catch (RemoteException e) { throw new Error( "exception initializing server-side DGC", e); } } finally { Thread.currentThread().setContextClassLoader(savedCcl); } return null; }
Example 10
Source File: DGCImpl.java From openjdk-jdk9 with GNU General Public License v2.0 | 4 votes |
public Void run() { ClassLoader savedCcl = Thread.currentThread().getContextClassLoader(); try { Thread.currentThread().setContextClassLoader( ClassLoader.getSystemClassLoader()); /* * Put remote collector object in table by hand to prevent * listen on port. (UnicastServerRef.exportObject would * cause transport to listen.) */ try { dgc = new DGCImpl(); ObjID dgcID = new ObjID(ObjID.DGC_ID); LiveRef ref = new LiveRef(dgcID, 0); UnicastServerRef disp = new UnicastServerRef(ref, DGCImpl::checkInput); Remote stub = Util.createProxy(DGCImpl.class, new UnicastRef(ref), true); disp.setSkeleton(dgc); Permissions perms = new Permissions(); perms.add(new SocketPermission("*", "accept,resolve")); ProtectionDomain[] pd = { new ProtectionDomain(null, perms) }; AccessControlContext acceptAcc = new AccessControlContext(pd); Target target = AccessController.doPrivileged( new PrivilegedAction<Target>() { public Target run() { return new Target(dgc, disp, stub, dgcID, true); } }, acceptAcc); ObjectTable.putTarget(target); } catch (RemoteException e) { throw new Error( "exception initializing server-side DGC", e); } } finally { Thread.currentThread().setContextClassLoader(savedCcl); } return null; }
Example 11
Source File: DGCImpl.java From jdk8u-jdk with GNU General Public License v2.0 | 4 votes |
public Void run() { ClassLoader savedCcl = Thread.currentThread().getContextClassLoader(); try { Thread.currentThread().setContextClassLoader( ClassLoader.getSystemClassLoader()); /* * Put remote collector object in table by hand to prevent * listen on port. (UnicastServerRef.exportObject would * cause transport to listen.) */ try { dgc = new DGCImpl(); ObjID dgcID = new ObjID(ObjID.DGC_ID); LiveRef ref = new LiveRef(dgcID, 0); UnicastServerRef disp = new UnicastServerRef(ref, DGCImpl::checkInput); Remote stub = Util.createProxy(DGCImpl.class, new UnicastRef(ref), true); disp.setSkeleton(dgc); Permissions perms = new Permissions(); perms.add(new SocketPermission("*", "accept,resolve")); ProtectionDomain[] pd = { new ProtectionDomain(null, perms) }; AccessControlContext acceptAcc = new AccessControlContext(pd); Target target = AccessController.doPrivileged( new PrivilegedAction<Target>() { public Target run() { return new Target(dgc, disp, stub, dgcID, true); } }, acceptAcc); ObjectTable.putTarget(target); } catch (RemoteException e) { throw new Error( "exception initializing server-side DGC", e); } } finally { Thread.currentThread().setContextClassLoader(savedCcl); } return null; }
Example 12
Source File: DGCImpl.java From hottub with GNU General Public License v2.0 | 4 votes |
public Void run() { ClassLoader savedCcl = Thread.currentThread().getContextClassLoader(); try { Thread.currentThread().setContextClassLoader( ClassLoader.getSystemClassLoader()); /* * Put remote collector object in table by hand to prevent * listen on port. (UnicastServerRef.exportObject would * cause transport to listen.) */ try { dgc = new DGCImpl(); ObjID dgcID = new ObjID(ObjID.DGC_ID); LiveRef ref = new LiveRef(dgcID, 0); UnicastServerRef disp = new UnicastServerRef(ref); Remote stub = Util.createProxy(DGCImpl.class, new UnicastRef(ref), true); disp.setSkeleton(dgc); Permissions perms = new Permissions(); perms.add(new SocketPermission("*", "accept,resolve")); ProtectionDomain[] pd = { new ProtectionDomain(null, perms) }; AccessControlContext acceptAcc = new AccessControlContext(pd); Target target = AccessController.doPrivileged( new PrivilegedAction<Target>() { public Target run() { return new Target(dgc, disp, stub, dgcID, true); } }, acceptAcc); ObjectTable.putTarget(target); } catch (RemoteException e) { throw new Error( "exception initializing server-side DGC", e); } } finally { Thread.currentThread().setContextClassLoader(savedCcl); } return null; }
Example 13
Source File: DGCImpl.java From jdk8u_jdk with GNU General Public License v2.0 | 4 votes |
public Void run() { ClassLoader savedCcl = Thread.currentThread().getContextClassLoader(); try { Thread.currentThread().setContextClassLoader( ClassLoader.getSystemClassLoader()); /* * Put remote collector object in table by hand to prevent * listen on port. (UnicastServerRef.exportObject would * cause transport to listen.) */ try { dgc = new DGCImpl(); ObjID dgcID = new ObjID(ObjID.DGC_ID); LiveRef ref = new LiveRef(dgcID, 0); UnicastServerRef disp = new UnicastServerRef(ref, DGCImpl::checkInput); Remote stub = Util.createProxy(DGCImpl.class, new UnicastRef(ref), true); disp.setSkeleton(dgc); Permissions perms = new Permissions(); perms.add(new SocketPermission("*", "accept,resolve")); ProtectionDomain[] pd = { new ProtectionDomain(null, perms) }; AccessControlContext acceptAcc = new AccessControlContext(pd); Target target = AccessController.doPrivileged( new PrivilegedAction<Target>() { public Target run() { return new Target(dgc, disp, stub, dgcID, true); } }, acceptAcc); ObjectTable.putTarget(target); } catch (RemoteException e) { throw new Error( "exception initializing server-side DGC", e); } } finally { Thread.currentThread().setContextClassLoader(savedCcl); } return null; }