Examples of EndpointEvent


Examples of org.apache.servicemix.jbi.event.EndpointEvent

                MessageListener listener = new MessageListener() {
                    public void onMessage(Message message) {
                        try {
                            Object obj = ((ObjectMessage) message).getObject();
                            if (obj instanceof EndpointEvent) {
                                EndpointEvent event = (EndpointEvent) obj;
                                String container = ((InternalEndpoint) event.getEndpoint()).getComponentNameSpace().getContainerName();
                                if (!getBroker().getContainer().getName().equals(container)) {
                                    if (event.getEventType() == EndpointEvent.INTERNAL_ENDPOINT_REGISTERED) {
                                        onRemoteEndpointRegistered(event);
                                    } else if (event.getEventType() == EndpointEvent.INTERNAL_ENDPOINT_UNREGISTERED) {
                                        onRemoteEndpointUnregistered(event);
                                    }
                                }
                            }
                        } catch (Exception e) {
View Full Code Here

Examples of org.apache.servicemix.jbi.event.EndpointEvent

            ConsumerInfo info = (ConsumerInfo) obj;
            subscriberSet.add(info.getConsumerId().getConnectionId());
            ServiceEndpoint[] endpoints = broker.getContainer().getRegistry().getEndpointsForInterface(null);
            for (int i = 0; i < endpoints.length; i++) {
                if (endpoints[i] instanceof InternalEndpoint && ((InternalEndpoint) endpoints[i]).isLocal()) {
                    onInternalEndpointRegistered(new EndpointEvent(endpoints[i],
                            EndpointEvent.INTERNAL_ENDPOINT_REGISTERED), true);
                }
            }
        } else if (obj instanceof RemoveInfo) {
            ConsumerId id = (ConsumerId) ((RemoveInfo) obj).getObjectId();
View Full Code Here

Examples of org.osgi.service.remoteserviceadmin.EndpointEvent

          }
        // and EndpointEventListenerEvents
        } else if (eventObject instanceof EndpointEventListenerEvent) {
          final EndpointEventListenerEvent event = (EndpointEventListenerEvent) eventObject;
          final EndpointEventListener endpointEventListener = event.getEndpointEventListener();
          final EndpointEvent endpointEvent = event.getEndpointEvent();
          final String matchingFilter = event.getMatchingFilter();
          try {
            trace("endpointEventListener.discovered=" + getEndpointEventTypeAsString(endpointEvent.getType()) + " ", "fwk=" + getFrameworkUUID() + ", endpointEventListener=" //$NON-NLS-1$ //$NON-NLS-2$ //$NON-NLS-3$ //$NON-NLS-4$
                    + endpointEventListener
                    + ", endpointEvent=" //$NON-NLS-1$
                    + endpointEvent + ", matchingFilter=" //$NON-NLS-1$
                    + matchingFilter);
            endpointEventListener.endpointChanged(endpointEvent,
View Full Code Here

Examples of org.osgi.service.remoteserviceadmin.EndpointEvent

    if (eventQueue == null)
      return;
    synchronized (eventQueue) {
      eventQueue
          .dispatchEventAsynchronous(0, new EndpointEventListenerEvent(
              listener, new EndpointEvent(eventType, endpointDescription), matchingFilter));
    }
  }
View Full Code Here

Examples of org.osgi.service.remoteserviceadmin.EndpointEvent

      }
    }

    public void deliverRemoveEventForBundle(EndpointEventHolder eventHolder) {
      deliverSafe(
          new EndpointEvent(EndpointEvent.REMOVED,
              eventHolder.getEndpoint()), eventHolder.getFilter());
    }
View Full Code Here
TOP
Copyright © 2018 www.massapi.com. 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.