/** * Builder method to set the URL. * * @param url * the URL to set * @return this configuration instance */ public final TerracottaClientConfiguration url(String url) { setUrl(url); return this; }
/** * Builder method to set the URL for a host and a port. * * @param host * the host where to get the Terracotta configuration from * @param port * the port on that host * @return this configuration instance */ public final TerracottaClientConfiguration url(String host, String port) { if (host.contains(":")) { host = "[" + host + "]"; } setUrl(host + ":" + port); return this; }
/** * Builder method to set the URL. * * @param url * the URL to set * @return this configuration instance */ public final TerracottaClientConfiguration url(String url) { setUrl(url); return this; }
/** * Builder method to set the URL. * * @param url * the URL to set * @return this configuration instance */ public final TerracottaClientConfiguration url(String url) { setUrl(url); return this; }
/** * Builder method to set the URL. * * @param url * the URL to set * @return this configuration instance */ public final TerracottaClientConfiguration url(String url) { setUrl(url); return this; }
/** * Builder method to set the URL for a host and a port. * * @param host * the host where to get the Terracotta configuration from * @param port * the port on that host * @return this configuration instance */ public final TerracottaClientConfiguration url(String host, String port) { setUrl(host + ":" + port); return this; }
/** * Builder method to set the URL for a host and a port. * * @param host * the host where to get the Terracotta configuration from * @param port * the port on that host * @return this configuration instance */ public final TerracottaClientConfiguration url(String host, String port) { setUrl(host + ":" + port); return this; }
/** * Builder method to set the URL for a host and a port. * * @param host * the host where to get the Terracotta configuration from * @param port * the port on that host * @return this configuration instance */ public final TerracottaClientConfiguration url(String host, String port) { if (host.contains(":")) { host = "[" + host + "]"; } setUrl(host + ":" + port); return this; }
public void afterPropertiesSet() throws IOException, CacheException { logger.info("Initializing EHCache CacheManager"); this.configuration = ConfigurationFactory.parseConfiguration(this.configLocation.getInputStream()); if (this.diskStorePath != null) { logger.info("diskStorePath=" + this.diskStorePath); DiskStoreConfiguration dsConfig = new DiskStoreConfiguration(); dsConfig.setPath(this.diskStorePath); logger.info("diskStorePath (translated)=" + dsConfig.getPath()); configuration.addDiskStore(dsConfig); } if (this.terracottaUrl != null) { logger.info("terracottaUrl=" + this.terracottaUrl); TerracottaClientConfiguration tcConfig = new TerracottaClientConfiguration(); tcConfig.setUrl(this.terracottaUrl); configuration.addTerracottaConfig(tcConfig); } }
terracottaConfig.setUrl(serverUrlsString); terracottaConfig.setRejoin(true); configuration.addTerracottaConfig(terracottaConfig);