All Downloads are FREE. Search and download functionalities are using the official Maven repository.

nyla.solutions.global.patterns.loadbalancer.LoadBalanceRegistry Maven / Gradle / Ivy

Go to download

Nyla Solutions Global Java API provides support for basic application utilities (application configuration, data encryption, debugger and text processing).

The newest version!
package nyla.solutions.global.patterns.loadbalancer;

import java.util.Collection;

/**
 * Implement round robin/other balancing for call distributions and routing.
 * 
 * Used by the COMMAS Partition data service implementation
 * @author Gregory Green
 *
 * @param 
 * @param 
 */
public interface LoadBalanceRegistry
{
	/**
	 * Lookup item registered with key or return new register previously registered based on balancing
	 * @param key
	 * @return
	 */
	V lookup(K key);
	
	void register(K key, V associated );
	
	void register(V associated );
	
	/**
	 * 
	 * @return all registered locations
	 */
	Collection listRegistered();
	
	/**
	 * Remote all keys and registration for the association
	 * @param associated
	 */
	void unregister(V associated);
	
	/**
	 * 
	 * @return next available location
	 */
	V next();
}




© 2015 - 2024 Weber Informatics LLC | Privacy Policy