Package org.apache.openejb.server

Examples of org.apache.openejb.server.DiscoveryListener


        final CountDownLatch[] latches = {
                new CountDownLatch(PEERS + 1),
                new CountDownLatch(PEERS + 1)
        };

        final DiscoveryListener listener = new DiscoveryListener() {
            public void serviceAdded(URI service) {
                System.out.println("added = " + service);
                if (testService.equals(service)) {
                    latches[0].countDown();
                }
View Full Code Here


        if (log.isInfoEnabled()) {
            log.info(String.format("Removed Service{uri=%s}", uri));
        }

        if (discoveryListener != null) {
            final DiscoveryListener discoveryListener = this.discoveryListener;

            // Have the listener process the event async so that
            // he does not block this thread since we are doing time sensitive
            // processing of events.
            executor.execute(new Runnable() {
                public void run() {
                    if (discoveryListener != null) {
                        discoveryListener.serviceRemoved(uri);
                    }
                }
            });
        }
    }
View Full Code Here

        if (log.isInfoEnabled()) {
            log.info(String.format("Added Service{uri=%s}", uri));
        }

        if (discoveryListener != null) {
            final DiscoveryListener discoveryListener = this.discoveryListener;

            // Have the listener process the event async so that
            // he does not block this thread since we are doing time sensitive
            // processing of events.
            executor.execute(new Runnable() {
                public void run() {
                    if (discoveryListener != null) {
                        discoveryListener.serviceAdded(uri);
                    }
                }
            });
        }
    }
View Full Code Here

TOP

Related Classes of org.apache.openejb.server.DiscoveryListener

Copyright © 2018 www.massapicom. All rights reserved.
All source code are property of their respective owners. Java is a trademark of Sun Microsystems, Inc and owned by ORACLE Inc. Contact coftware#gmail.com.