if (allConsumersSeen_) return; if (seenConsumers_.add(consumer)) { if (consumer.equals(myOrgName_)) selfConsumer = 1; System.out.println("####### Seeing new consumer: "+consumer+" at supplier: "+ myOrganization_.getClusterPG().getMessageAddress().toString()); if (customerAlarm_ != null) {  customerAlarm_.cancel(); customerAlarm_ = null; } int consumerCount = getConsumerCount(); if (seenConsumers_.size() >= consumerCount){ if (extraCustomerDelay_ > 0L) { customerAlarm_ = wakeAfterRealTime(extraCustomerDelay_); } allConsumersSeen_ = true; System.out.println("####### All " + seenConsumers_.size() + " of " + consumerCount + " consumers seen at supplier: " + myOrganization_.getClusterPG().getMessageAddress().toString()); } else { System.out.println("####### Only " + seenConsumers_.size() + " of " + consumerCount + " consumers seen at supplier: " + myOrganization_.getClusterPG().getMessageAddress().toString()); customerAlarm_ = wakeAfterRealTime(NEW_CUSTOMER_WAIT); } } else {   }
if (allConsumersSeen_) return; if (seenConsumers_.add(consumer)) { if (consumer.equals(myOrgName_)) selfConsumer = 1; if (logger.isDebugEnabled()) { logger.debug("####### Seeing new consumer: " + consumer + " at supplier: "); } if (customerAlarm_ != null) {  customerAlarm_.cancel(); customerAlarm_ = null; } int consumerCount = getConsumerCount(); if (seenConsumers_.size() >= consumerCount) { if (extraCustomerDelay_ > 0L) { customerAlarm_ = wakeAfterRealTime(extraCustomerDelay_); } allConsumersSeen_ = true; if (logger.isDebugEnabled()) { logger.debug("####### All " + seenConsumers_.size() + " of " + consumerCount + " consumers seen at supplier: "); } } else { if (logger.isDebugEnabled()) { logger.debug("####### Only " + seenConsumers_.size() + " of " + consumerCount + " consumers seen at supplier: "); } customerAlarm_ = wakeAfterRealTime(NEW_CUSTOMER_WAIT); } } else {
    public void recordCustomer(String consumer) {        if (allConsumersSeen_) return;	if (seenConsumers_.add(consumer)) {            if (consumer.equals(myOrgName_)) selfConsumer = 1;	    System.out.println("####### Seeing new consumer: "+consumer+" at supplier: "+			       myOrganization_.getClusterPG().getMessageAddress().toString());            if (customerAlarm_ != null) {                /* Cancel current alarm */                customerAlarm_.cancel();                customerAlarm_ = null;            }            int consumerCount = getConsumerCount();            if (seenConsumers_.size() >= consumerCount){                if (extraCustomerDelay_ > 0L) {                    customerAlarm_ = wakeAfterRealTime(extraCustomerDelay_);                }                allConsumersSeen_ = true;                System.out.println("####### All " + seenConsumers_.size()                                   + " of " + consumerCount                                   + " consumers seen at supplier: "                                   + myOrganization_.getClusterPG().getMessageAddress().toString());            } else {                System.out.println("####### Only " + seenConsumers_.size()                                   + " of " + consumerCount                                   + " consumers seen at supplier: "                                   + myOrganization_.getClusterPG().getMessageAddress().toString());                customerAlarm_ = wakeAfterRealTime(NEW_CUSTOMER_WAIT);            }	} else {//  	    System.out.println("####### Seeing old consumer: "+consumer+" at supplier: "+//  			       myOrganization_.getClusterPG().getMessageAddress().toString());	}    }