Package EDU.oswego.cs.dl.util.concurrent

Examples of EDU.oswego.cs.dl.util.concurrent.SynchronizedLong


      tr = sp.getTxRepository();
      maxDeliveryAttempts = sp.getDefaultMaxDeliveryAttempts();
     
      deliveries = new ConcurrentHashMap();
     
      deliveryIdSequence = new SynchronizedLong(0);
   }
View Full Code Here


                              new DeliveryRecord(del, -1, dlqToUse,
                                                 expiryQueueToUse, dest.getRedeliveryDelay()));
            }
         }
        
         this.deliveryIdSequence = new SynchronizedLong(maxDeliveryId + 1);
      }
      catch (Throwable t)
      {
         throw ExceptionUtil.handleJMSInvocation(t, this + " recoverDeliveries");
      }
View Full Code Here

   /**
    * CTOR
    */
   public NotificationListener()
   {
      notificationCount = new SynchronizedLong(0);
      dynamicSubscriptions = true;
      notificationListener = null;
   }
View Full Code Here

   /**
    * CTOR
    */
   public ActiveAlarmTable()
   {
      notificationCount = new SynchronizedLong(0);
      almtab.setServerId(Alarm.DEFAULT_SERVER_ID);
      almtab.setMaxSize(1000);
   }
View Full Code Here

    * CTOR
    */
   public AlarmTable(MBeanImplAccess mbeanImpl)
   {
      this.mbeanImpl = mbeanImpl;
      this.alarmIdCount = new SynchronizedLong(0);
      this.alarmMap = new LinkedHashMap();
      this.statefulMap = new HashMap();
   }
View Full Code Here

   /**
    * CTOR
    */
   public NotificationListener()
   {
      notificationCount = new SynchronizedLong(0);
      dynamicSubscriptions = true;
      notificationListener = null;
      log.setLogLevel(DynamicLogger.LOG_LEVEL_INFO);
   }
View Full Code Here

   /**
    * CTOR
    */
   public ActiveAlarmTable()
   {
      notificationCount = new SynchronizedLong(0);
      almtab.setServerId(Alarm.DEFAULT_SERVER_ID);
      almtab.setMaxSize(1000);
   }
View Full Code Here

    */
   public ScriptingListener()
   {
      queue = new LinkedList();
     
      notificationsReceived = new SynchronizedLong(0);
      notificationsProcessed = new SynchronizedLong(0);
      totalProcessingTime = new SynchronizedLong(0);
   }
View Full Code Here

        }
    }

    private void addService(String name) {
        long timestamp = System.currentTimeMillis();
        SynchronizedLong activeTime = (SynchronizedLong) keepAliveMap.get(name);
        if (activeTime == null) {
            activeTime = new SynchronizedLong(0);
            keepAliveMap.put(name, activeTime);
        }
        activeTime.set(timestamp);
    }
View Full Code Here

    private void checkNodesAlive() throws JMSException {
        long timestamp = System.currentTimeMillis();
        long timeout = timestamp - timeoutExpiration;
        for (Iterator i = keepAliveMap.entrySet().iterator();i.hasNext();) {
            Map.Entry entry = (Map.Entry) i.next();
            SynchronizedLong activeTime = (SynchronizedLong) entry.getValue();
            if (activeTime.get() < timeout) {
                String name = entry.getKey().toString();
                removeService(name);
                log.warn(serviceName + " Expiring node: " + name);
            }
        }
View Full Code Here

TOP

Related Classes of EDU.oswego.cs.dl.util.concurrent.SynchronizedLong

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.