Adjusted method names in ConsumerLocator
This commit is contained in:
		@@ -41,7 +41,7 @@ class ConsumerLocator:
 | 
				
			|||||||
        """
 | 
					        """
 | 
				
			||||||
        removeList = []
 | 
					        removeList = []
 | 
				
			||||||
        for consumer in self.consumerList:
 | 
					        for consumer in self.consumerList:
 | 
				
			||||||
            if not communicator.isconsumeravailable(consumer["Host"]):
 | 
					            if not communicator.checkconsumer(consumer["Host"]):
 | 
				
			||||||
                consumer["State"] = False
 | 
					                consumer["State"] = False
 | 
				
			||||||
                if datetime.datetime.now() - consumer["LastOk"] > datetime.timedelta(hours=1):
 | 
					                if datetime.datetime.now() - consumer["LastOk"] > datetime.timedelta(hours=1):
 | 
				
			||||||
                    removeList.append(consumer)
 | 
					                    removeList.append(consumer)
 | 
				
			||||||
@@ -80,12 +80,12 @@ class ConsumerLocator:
 | 
				
			|||||||
        """
 | 
					        """
 | 
				
			||||||
        return self.currentConsumer["Host"]
 | 
					        return self.currentConsumer["Host"]
 | 
				
			||||||
 | 
					
 | 
				
			||||||
    def checkconsumer(self):
 | 
					    def checkcurrentconsumer(self):
 | 
				
			||||||
        """
 | 
					        """
 | 
				
			||||||
        Check the consumers health.
 | 
					        Check the consumers health.
 | 
				
			||||||
        :return: True if OK, False if fail
 | 
					        :return: True if OK, False if fail
 | 
				
			||||||
        """
 | 
					        """
 | 
				
			||||||
        if communicator.isconsumeravailable(self.currentConsumer["Host"]):
 | 
					        if communicator.checkconsumer(self.currentConsumer["Host"]):
 | 
				
			||||||
            return True
 | 
					            return True
 | 
				
			||||||
        else:
 | 
					        else:
 | 
				
			||||||
            return False
 | 
					            return False
 | 
				
			||||||
 
 | 
				
			|||||||
		Reference in New Issue
	
	Block a user