Java 类org.apache.catalina.tribes.io.ReplicationStream 实例源码

项目:tomcat7    文件:DeltaSession.java   
/**
 * Applies a diff to an existing object.
 * @param diff byte[]
 * @param offset int
 * @param length int
 * @throws IOException
 */
@Override
public void applyDiff(byte[] diff, int offset, int length) throws IOException, ClassNotFoundException {
    try {
        lock();
        ReplicationStream stream = ( (ClusterManager) getManager()).getReplicationStream(diff, offset, length);
        ClassLoader contextLoader = Thread.currentThread().getContextClassLoader();
        try {
            ClassLoader[] loaders = getClassLoaders();
            if (loaders != null && loaders.length > 0)
                Thread.currentThread().setContextClassLoader(loaders[0]);
            getDeltaRequest().readExternal(stream);
            getDeltaRequest().execute(this, ((ClusterManager)getManager()).isNotifyListenersOnReplication());
            stream.close();
        } finally {
            Thread.currentThread().setContextClassLoader(contextLoader);
        }
    }finally {
        unlock();
    }
}
项目:apache-tomcat-7.0.73-with-comment    文件:DeltaSession.java   
/**
 * Applies a diff to an existing object.
 * @param diff byte[]
 * @param offset int
 * @param length int
 * @throws IOException
 */
@Override
public void applyDiff(byte[] diff, int offset, int length) throws IOException, ClassNotFoundException {
    try {
        lock();
        ReplicationStream stream = ( (ClusterManager) getManager()).getReplicationStream(diff, offset, length);
        ClassLoader contextLoader = Thread.currentThread().getContextClassLoader();
        try {
            ClassLoader[] loaders = getClassLoaders();
            if (loaders != null && loaders.length > 0)
                Thread.currentThread().setContextClassLoader(loaders[0]);
            getDeltaRequest().readExternal(stream);
            getDeltaRequest().execute(this, ((ClusterManager)getManager()).isNotifyListenersOnReplication());
            stream.close();
        } finally {
            Thread.currentThread().setContextClassLoader(contextLoader);
        }
    }finally {
        unlock();
    }
}
项目:lazycat    文件:DeltaSession.java   
/**
 * Applies a diff to an existing object.
 * 
 * @param diff
 *            byte[]
 * @param offset
 *            int
 * @param length
 *            int
 * @throws IOException
 */
@Override
public void applyDiff(byte[] diff, int offset, int length) throws IOException, ClassNotFoundException {
    try {
        lock();
        ReplicationStream stream = ((ClusterManager) getManager()).getReplicationStream(diff, offset, length);
        ClassLoader contextLoader = Thread.currentThread().getContextClassLoader();
        try {
            ClassLoader[] loaders = getClassLoaders();
            if (loaders != null && loaders.length > 0)
                Thread.currentThread().setContextClassLoader(loaders[0]);
            getDeltaRequest().readExternal(stream);
            getDeltaRequest().execute(this, ((ClusterManager) getManager()).isNotifyListenersOnReplication());
            stream.close();
        } finally {
            Thread.currentThread().setContextClassLoader(contextLoader);
        }
    } finally {
        unlock();
    }
}
项目:class-guard    文件:DeltaSession.java   
/**
 * Applies a diff to an existing object.
 * @param diff byte[]
 * @param offset int
 * @param length int
 * @throws IOException
 */
@Override
public void applyDiff(byte[] diff, int offset, int length) throws IOException, ClassNotFoundException {
    try {
        lock();
        ReplicationStream stream = ( (ClusterManager) getManager()).getReplicationStream(diff, offset, length);
        ClassLoader contextLoader = Thread.currentThread().getContextClassLoader();
        try {
            ClassLoader[] loaders = getClassLoaders();
            if (loaders != null && loaders.length > 0)
                Thread.currentThread().setContextClassLoader(loaders[0]);
            getDeltaRequest().readExternal(stream);
            getDeltaRequest().execute(this, ((ClusterManager)getManager()).isNotifyListenersOnReplication());
        } finally {
            Thread.currentThread().setContextClassLoader(contextLoader);
        }
    }finally {
        unlock();
    }
}
项目:apache-tomcat-7.0.57    文件:DeltaSession.java   
/**
 * Applies a diff to an existing object.
 * @param diff byte[]
 * @param offset int
 * @param length int
 * @throws IOException
 */
@Override
public void applyDiff(byte[] diff, int offset, int length) throws IOException, ClassNotFoundException {
    try {
        lock();
        ReplicationStream stream = ( (ClusterManager) getManager()).getReplicationStream(diff, offset, length);
        ClassLoader contextLoader = Thread.currentThread().getContextClassLoader();
        try {
            ClassLoader[] loaders = getClassLoaders();
            if (loaders != null && loaders.length > 0)
                Thread.currentThread().setContextClassLoader(loaders[0]);
            getDeltaRequest().readExternal(stream);
            getDeltaRequest().execute(this, ((ClusterManager)getManager()).isNotifyListenersOnReplication());
        } finally {
            Thread.currentThread().setContextClassLoader(contextLoader);
        }
    }finally {
        unlock();
    }
}
项目:apache-tomcat-7.0.57    文件:DeltaSession.java   
/**
 * Applies a diff to an existing object.
 * @param diff byte[]
 * @param offset int
 * @param length int
 * @throws IOException
 */
@Override
public void applyDiff(byte[] diff, int offset, int length) throws IOException, ClassNotFoundException {
    try {
        lock();
        ReplicationStream stream = ( (ClusterManager) getManager()).getReplicationStream(diff, offset, length);
        ClassLoader contextLoader = Thread.currentThread().getContextClassLoader();
        try {
            ClassLoader[] loaders = getClassLoaders();
            if (loaders != null && loaders.length > 0)
                Thread.currentThread().setContextClassLoader(loaders[0]);
            getDeltaRequest().readExternal(stream);
            getDeltaRequest().execute(this, ((ClusterManager)getManager()).isNotifyListenersOnReplication());
        } finally {
            Thread.currentThread().setContextClassLoader(contextLoader);
        }
    }finally {
        unlock();
    }
}
项目:WBSAirback    文件:DeltaSession.java   
/**
 * Applies a diff to an existing object.
 * @param diff byte[]
 * @param offset int
 * @param length int
 * @throws IOException
 */
@Override
public void applyDiff(byte[] diff, int offset, int length) throws IOException, ClassNotFoundException {
    try {
        lock();
        ReplicationStream stream = ( (ClusterManager) getManager()).getReplicationStream(diff, offset, length);
        ClassLoader contextLoader = Thread.currentThread().getContextClassLoader();
        try {
            ClassLoader[] loaders = getClassLoaders();
            if (loaders != null && loaders.length > 0)
                Thread.currentThread().setContextClassLoader(loaders[0]);
            getDeltaRequest().readExternal(stream);
            getDeltaRequest().execute(this, ((ClusterManager)getManager()).isNotifyListenersOnReplication());
        } finally {
            Thread.currentThread().setContextClassLoader(contextLoader);
        }
    }finally {
        unlock();
    }
}
项目:tomcat7    文件:DeltaManager.java   
/**
 * Load sessionID
 * @throws IOException if an input/output error occurs
 */
protected String deserializeSessionId(byte[] data) throws IOException {
    ReplicationStream ois = getReplicationStream(data);
    String sessionId = ois.readUTF();
    ois.close();
    return sessionId;
}
项目:tomcat7    文件:DeltaManager.java   
/**
 * Load Deltarequest from external node
 * Load the Class at container classloader
 * @see DeltaRequest#readExternal(java.io.ObjectInput)
 * @param session
 * @param data message data
 * @return The request
 * @throws ClassNotFoundException
 * @throws IOException
 */
protected DeltaRequest deserializeDeltaRequest(DeltaSession session, byte[] data) throws ClassNotFoundException, IOException {
    try {
        session.lock();
        ReplicationStream ois = getReplicationStream(data);
        session.getDeltaRequest().readExternal(ois);
        ois.close();
        return session.getDeltaRequest();
    }finally {
        session.unlock();
    }
}
项目:apache-tomcat-7.0.73-with-comment    文件:DeltaManager.java   
/**
 * Load sessionID
 * @throws IOException if an input/output error occurs
 */
protected String deserializeSessionId(byte[] data) throws IOException {
    ReplicationStream ois = getReplicationStream(data);
    String sessionId = ois.readUTF();
    ois.close();
    return sessionId;
}
项目:apache-tomcat-7.0.73-with-comment    文件:DeltaManager.java   
/**
 * Load Deltarequest from external node
 * Load the Class at container classloader
 * @see DeltaRequest#readExternal(java.io.ObjectInput)
 * @param session
 * @param data message data
 * @return The request
 * @throws ClassNotFoundException
 * @throws IOException
 */
protected DeltaRequest deserializeDeltaRequest(DeltaSession session, byte[] data) throws ClassNotFoundException, IOException {
    try {
        session.lock();
        ReplicationStream ois = getReplicationStream(data);
        session.getDeltaRequest().readExternal(ois);
        ois.close();
        return session.getDeltaRequest();
    }finally {
        session.unlock();
    }
}
项目:lazycat    文件:DeltaManager.java   
/**
 * Load sessionID
 * 
 * @throws IOException
 *             if an input/output error occurs
 */
protected String deserializeSessionId(byte[] data) throws IOException {
    ReplicationStream ois = getReplicationStream(data);
    String sessionId = ois.readUTF();
    ois.close();
    return sessionId;
}
项目:lazycat    文件:DeltaManager.java   
/**
 * Load Deltarequest from external node Load the Class at container
 * classloader
 * 
 * @see DeltaRequest#readExternal(java.io.ObjectInput)
 * @param session
 * @param data
 *            message data
 * @return The request
 * @throws ClassNotFoundException
 * @throws IOException
 */
protected DeltaRequest deserializeDeltaRequest(DeltaSession session, byte[] data)
        throws ClassNotFoundException, IOException {
    try {
        session.lock();
        ReplicationStream ois = getReplicationStream(data);
        session.getDeltaRequest().readExternal(ois);
        ois.close();
        return session.getDeltaRequest();
    } finally {
        session.unlock();
    }
}
项目:class-guard    文件:DeltaManager.java   
/**
 * Load sessionID
 * @throws IOException if an input/output error occurs
 */
protected String deserializeSessionId(byte[] data) throws IOException {
    ReplicationStream ois = getReplicationStream(data);
    String sessionId = ois.readUTF();
    ois.close();
    return sessionId;
}
项目:class-guard    文件:DeltaManager.java   
/**
 * Load Deltarequest from external node
 * Load the Class at container classloader
 * @see DeltaRequest#readExternal(java.io.ObjectInput)
 * @param session
 * @param data message data
 * @return The request
 * @throws ClassNotFoundException
 * @throws IOException
 */
protected DeltaRequest deserializeDeltaRequest(DeltaSession session, byte[] data) throws ClassNotFoundException, IOException {
    try {
        session.lock();
        ReplicationStream ois = getReplicationStream(data);
        session.getDeltaRequest().readExternal(ois);
        ois.close();
        return session.getDeltaRequest();
    }finally {
        session.unlock();
    }
}
项目:apache-tomcat-7.0.57    文件:DeltaManager.java   
/**
 * Load sessionID
 * @throws IOException if an input/output error occurs
 */
protected String deserializeSessionId(byte[] data) throws IOException {
    ReplicationStream ois = getReplicationStream(data);
    String sessionId = ois.readUTF();
    ois.close();
    return sessionId;
}
项目:apache-tomcat-7.0.57    文件:DeltaManager.java   
/**
 * Load Deltarequest from external node
 * Load the Class at container classloader
 * @see DeltaRequest#readExternal(java.io.ObjectInput)
 * @param session
 * @param data message data
 * @return The request
 * @throws ClassNotFoundException
 * @throws IOException
 */
protected DeltaRequest deserializeDeltaRequest(DeltaSession session, byte[] data) throws ClassNotFoundException, IOException {
    try {
        session.lock();
        ReplicationStream ois = getReplicationStream(data);
        session.getDeltaRequest().readExternal(ois);
        ois.close();
        return session.getDeltaRequest();
    }finally {
        session.unlock();
    }
}
项目:apache-tomcat-7.0.57    文件:DeltaManager.java   
/**
 * Load sessionID
 * @throws IOException if an input/output error occurs
 */
protected String deserializeSessionId(byte[] data) throws IOException {
    ReplicationStream ois = getReplicationStream(data);
    String sessionId = ois.readUTF();
    ois.close();
    return sessionId;
}
项目:apache-tomcat-7.0.57    文件:DeltaManager.java   
/**
 * Load Deltarequest from external node
 * Load the Class at container classloader
 * @see DeltaRequest#readExternal(java.io.ObjectInput)
 * @param session
 * @param data message data
 * @return The request
 * @throws ClassNotFoundException
 * @throws IOException
 */
protected DeltaRequest deserializeDeltaRequest(DeltaSession session, byte[] data) throws ClassNotFoundException, IOException {
    try {
        session.lock();
        ReplicationStream ois = getReplicationStream(data);
        session.getDeltaRequest().readExternal(ois);
        ois.close();
        return session.getDeltaRequest();
    }finally {
        session.unlock();
    }
}
项目:WBSAirback    文件:DeltaManager.java   
/**
 * Load sessionID
 * @throws IOException if an input/output error occurs
 */
protected String deserializeSessionId(byte[] data) throws IOException {
    ReplicationStream ois = getReplicationStream(data);
    String sessionId = ois.readUTF();
    ois.close();
    return sessionId;
}
项目:WBSAirback    文件:DeltaManager.java   
/**
 * Load Deltarequest from external node
 * Load the Class at container classloader
 * @see DeltaRequest#readExternal(java.io.ObjectInput)
 * @param session
 * @param data message data
 * @return The request
 * @throws ClassNotFoundException
 * @throws IOException
 */
protected DeltaRequest deserializeDeltaRequest(DeltaSession session, byte[] data) throws ClassNotFoundException, IOException {
    try {
        session.lock();
        ReplicationStream ois = getReplicationStream(data);
        session.getDeltaRequest().readExternal(ois);
        ois.close();
        return session.getDeltaRequest();
    }finally {
        session.unlock();
    }
}
项目:tomcat7    文件:ClusterManagerBase.java   
@Override
public ReplicationStream getReplicationStream(byte[] data) throws IOException {
    return getReplicationStream(data,0,data.length);
}
项目:tomcat7    文件:ClusterManagerBase.java   
@Override
public ReplicationStream getReplicationStream(byte[] data, int offset, int length) throws IOException {
    ByteArrayInputStream fis = new ByteArrayInputStream(data, offset, length);
    return new ReplicationStream(fis, getClassLoaders());
}
项目:apache-tomcat-7.0.73-with-comment    文件:ClusterManagerBase.java   
@Override
public ReplicationStream getReplicationStream(byte[] data) throws IOException {
    return getReplicationStream(data,0,data.length);
}
项目:apache-tomcat-7.0.73-with-comment    文件:ClusterManagerBase.java   
@Override
public ReplicationStream getReplicationStream(byte[] data, int offset, int length) throws IOException {
    ByteArrayInputStream fis = new ByteArrayInputStream(data, offset, length);
    return new ReplicationStream(fis, getClassLoaders());
}
项目:lazycat    文件:ClusterManagerBase.java   
@Override
public ReplicationStream getReplicationStream(byte[] data) throws IOException {
    return getReplicationStream(data, 0, data.length);
}
项目:lazycat    文件:ClusterManagerBase.java   
@Override
public ReplicationStream getReplicationStream(byte[] data, int offset, int length) throws IOException {
    ByteArrayInputStream fis = new ByteArrayInputStream(data, offset, length);
    return new ReplicationStream(fis, getClassLoaders());
}
项目:class-guard    文件:ClusterManagerBase.java   
@Override
public ReplicationStream getReplicationStream(byte[] data, int offset, int length) throws IOException {
    ByteArrayInputStream fis = new ByteArrayInputStream(data, offset, length);
    return new ReplicationStream(fis, getClassLoaders());
}
项目:apache-tomcat-7.0.57    文件:ClusterManagerBase.java   
@Override
public ReplicationStream getReplicationStream(byte[] data, int offset, int length) throws IOException {
    ByteArrayInputStream fis = new ByteArrayInputStream(data, offset, length);
    return new ReplicationStream(fis, getClassLoaders());
}
项目:apache-tomcat-7.0.57    文件:ClusterManagerBase.java   
@Override
public ReplicationStream getReplicationStream(byte[] data, int offset, int length) throws IOException {
    ByteArrayInputStream fis = new ByteArrayInputStream(data, offset, length);
    return new ReplicationStream(fis, getClassLoaders());
}
项目:WBSAirback    文件:ClusterManagerBase.java   
@Override
public ReplicationStream getReplicationStream(byte[] data, int offset, int length) throws IOException {
    ByteArrayInputStream fis = new ByteArrayInputStream(data, offset, length);
    return new ReplicationStream(fis, getClassLoaders());
}
项目:tomcat7    文件:ClusterManager.java   
/**
 * Open stream and use correct ClassLoader (Container), switching thread
 * context class loader.
 *
 * @param data The data
 * @return The object input stream
 * @throws IOException An error occurred
 */
public ReplicationStream getReplicationStream(byte[] data) throws IOException;
项目:apache-tomcat-7.0.73-with-comment    文件:ClusterManager.java   
/**
 * Open stream and use correct ClassLoader (Container), switching thread
 * context class loader.
 *
 * @param data The data
 * @return The object input stream
 * @throws IOException An error occurred
 */
public ReplicationStream getReplicationStream(byte[] data) throws IOException;
项目:lazycat    文件:ClusterManager.java   
/**
 * Open stream and use correct ClassLoader (Container), switching thread
 * context class loader.
 *
 * @param data
 *            The data
 * @return The object input stream
 * @throws IOException
 *             An error occurred
 */
public ReplicationStream getReplicationStream(byte[] data) throws IOException;
项目:class-guard    文件:ClusterManagerBase.java   
/**
 * Open Stream and use correct ClassLoader (Container) Switch
 * ThreadClassLoader
 * 
 * @param data
 * @return The object input stream
 * @throws IOException
 */
@Override
public ReplicationStream getReplicationStream(byte[] data) throws IOException {
    return getReplicationStream(data,0,data.length);
}
项目:apache-tomcat-7.0.57    文件:ClusterManagerBase.java   
/**
 * Open Stream and use correct ClassLoader (Container) Switch
 * ThreadClassLoader
 * 
 * @param data
 * @return The object input stream
 * @throws IOException
 */
@Override
public ReplicationStream getReplicationStream(byte[] data) throws IOException {
    return getReplicationStream(data,0,data.length);
}
项目:apache-tomcat-7.0.57    文件:ClusterManagerBase.java   
/**
 * Open Stream and use correct ClassLoader (Container) Switch
 * ThreadClassLoader
 * 
 * @param data
 * @return The object input stream
 * @throws IOException
 */
@Override
public ReplicationStream getReplicationStream(byte[] data) throws IOException {
    return getReplicationStream(data,0,data.length);
}
项目:WBSAirback    文件:ClusterManagerBase.java   
/**
 * Open Stream and use correct ClassLoader (Container) Switch
 * ThreadClassLoader
 * 
 * @param data
 * @return The object input stream
 * @throws IOException
 */
@Override
public ReplicationStream getReplicationStream(byte[] data) throws IOException {
    return getReplicationStream(data,0,data.length);
}
项目:tomcat7    文件:ClusterManager.java   
public ReplicationStream getReplicationStream(byte[] data, int offset, int length) throws IOException;
项目:apache-tomcat-7.0.73-with-comment    文件:ClusterManager.java   
public ReplicationStream getReplicationStream(byte[] data, int offset, int length) throws IOException;