gedi-geode-extensions-core/src/main/java/gedi/solutions/geode/client/GemFireJmxClient.java
public static synchronized Pool getPoolForLocator(JMX jmx)
	{
		String locatorsPoolName = jmx.getHost()+"["+jmx.getPort()+"]";
		
		Pool pool = PoolManager.find(locatorsPoolName);
				
		if(pool != null)
					return pool;
				
				
				PoolFactory poolFactory = PoolManager.createFactory();
				
				try
				{
					int port = getLocatorPort(jmx);
					
					poolFactory= poolFactory.addLocator(jmx.getHost(), port);
					
					return poolFactory.create(locatorsPoolName);
				}
				catch (Exception e)
				{
					throw new RuntimeException("Unable to create pool for locator:"+jmx.getHost()+" error:"+e.getMessage(),e);
				}
				
			}
public static synchronized Pool getPoolForLocator(JMX jmx)
	{
		String locatorsPoolName = jmx.getHost()+"["+jmx.getPort()+"]";
		
		Pool pool = PoolManager.find(locatorsPoolName);
				
		if(pool != null)
					return pool;
				
				
				PoolFactory poolFactory = PoolManager.createFactory();
				
				try
				{
					int port = getLocatorPort(jmx);
					
					poolFactory= poolFactory.addLocator(jmx.getHost(), port);
					
					return poolFactory.create(locatorsPoolName);
				}
				catch (Exception e)
				{
					throw new RuntimeException("Unable to create pool for locator:"+jmx.getHost()+" error:"+e.getMessage(),e);
				}
				
			}
This methods create a pool for connecting to a locator
@param jmx the JMX connection
@return the pool instance