Examples of Detection


Examples of org.jboss.remoting.detection.Detection

         String bindName = "";
         NamingEnumeration enumeration = context.listBindings(bindName);
         while(enumeration.hasMore())
         {
            Binding binding = (Binding) enumeration.next();
            Detection regMsg = (Detection) binding.getObject();
            // No need to detect myself here
            if(isRemoteDetection(regMsg))
            {
               log.debug("Detected id: " + regMsg.getIdentity().getInstanceId() + ", message: " + regMsg);

               if(cleanDetect)
               {
                  if(log.isTraceEnabled())
                  {
                     log.trace("Doing clean detection.");
                  }
                  // Need to actually detect if servers registered in JNDI server
                  // are actually there (since could die before unregistering)
                  ClassLoader cl = JNDIDetector.this.getClass().getClassLoader();
                  if(!checkInvokerServer(regMsg, cl))
                  {
                     unregisterDetection(regMsg.getIdentity().getInstanceId());
                  }
               }
               else
               {
                  // Let parent handle detection
View Full Code Here

Examples of org.jboss.remoting.detection.Detection

   private boolean verifyLocalDetectionMsg(Detection regMsg) throws NamingException
   {
      boolean verified = false;

      InvokerLocator[] locators = InvokerRegistry.getRegisteredServerLocators();
      Detection msg = createDetection();
      String sId = id.getInstanceId();
      InvokerLocator[] invokers = regMsg.getLocators();

      // first do sanity check to make sure even local detection msg (just in case)
      if(sId.equals(regMsg.getIdentity().getInstanceId()))
View Full Code Here

Examples of org.jboss.remoting.detection.Detection

    */
   protected void heartbeat()
   {
      if(socket != null)
      {
         Detection msg = createDetection();
         if (msg == null)
            return;
        
         try
         {
View Full Code Here

Examples of org.jboss.remoting.detection.Detection

      return verified;
   }

   private void addLocalDetectionMsg() throws NamingException
   {
      Detection msg = createDetection();
      String sId = id.getInstanceId();
      registerDetectionMsg(sId, msg);
   }
View Full Code Here

Examples of org.jboss.remoting.detection.Detection

            ByteArrayInputStream byteInput = new ByteArrayInputStream(buf);
            ObjectInputStream objectInput = new ObjectInputStream(byteInput);
            Object obj = objectInput.readObject();
            if(obj instanceof Detection)
            {
               Detection msg = (Detection)obj;
               if(log.isTraceEnabled())
               {
                  log.trace("received detection: " + msg);
               }
View Full Code Here

Examples of org.jboss.remoting.detection.Detection

         String bindName = "";
         NamingEnumeration enumeration = context.listBindings(bindName);
         while(enumeration.hasMore())
         {
            Binding binding = (Binding) enumeration.next();
            Detection regMsg = (Detection) binding.getObject();
            // No need to detect myself here
            if(isRemoteDetection(regMsg))
            {
               log.debug("Detected id: " + regMsg.getIdentity().getInstanceId() + ", message: " + regMsg);

               if(cleanDetect)
               {
                  if(log.isTraceEnabled())
                  {
                     log.trace("Doing clean detection.");
                  }
                  // Need to actually detect if servers registered in JNDI server
                  // are actually there (since could die before unregistering)
                  ClassLoader cl = JNDIDetector.this.getClass().getClassLoader();
                  if(!checkInvokerServer(regMsg, cl))
                  {
                     unregisterDetection(regMsg.getIdentity().getInstanceId());
                  }
                  else
                  {
                     // Now, let parent handle detection
                     detect(regMsg);
View Full Code Here

Examples of org.jboss.remoting.detection.Detection

   private boolean verifyLocalDetectionMsg(Detection regMsg) throws NamingException
   {
      boolean verified = false;

      InvokerLocator[] locators = InvokerRegistry.getRegisteredServerLocators();
      Detection msg = createDetection();
      String sId = id.getInstanceId();
      InvokerLocator[] invokers = regMsg.getLocators();

      // first do sanity check to make sure even local detection msg (just in case)
      if(sId.equals(regMsg.getIdentity().getInstanceId()))
View Full Code Here

Examples of org.jboss.remoting.detection.Detection

      return verified;
   }

   private void addLocalDetectionMsg() throws NamingException
   {
      Detection msg = createDetection();
      String sId = id.getInstanceId();
      registerDetectionMsg(sId, msg);
   }
View Full Code Here

Examples of org.jboss.remoting.detection.Detection

    */
   protected void heartbeat()
   {
      if(socket != null)
      {
         Detection msg = createDetection();
         try
         {
            if(log.isTraceEnabled())
            {
               log.trace("sending heartbeat: " + msg);
View Full Code Here

Examples of org.jboss.remoting.detection.Detection

            ByteArrayInputStream byteInput = new ByteArrayInputStream(buf);
            ObjectInputStream objectInput = new ObjectInputStream(byteInput);
            Object obj = objectInput.readObject();
            if(obj instanceof Detection)
            {
               Detection msg = (Detection)obj;
               if(log.isTraceEnabled())
               {
                  log.trace("received detection: " + msg);
               }
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.