Index: lams_common/src/java/org/lamsfoundation/lams/etherpad/service/EtherpadService.java =================================================================== diff -u -r459c29c159a6f5665479ed2490cf2d4a9db30d6e -rfc4e9fbf6df963c2ba59399e7a0be689e569f239 --- lams_common/src/java/org/lamsfoundation/lams/etherpad/service/EtherpadService.java (.../EtherpadService.java) (revision 459c29c159a6f5665479ed2490cf2d4a9db30d6e) +++ lams_common/src/java/org/lamsfoundation/lams/etherpad/service/EtherpadService.java (.../EtherpadService.java) (revision fc4e9fbf6df963c2ba59399e7a0be689e569f239) @@ -23,8 +23,6 @@ public class EtherpadService implements IEtherpadService { - private EPLiteClient client = null; - @SuppressWarnings("unchecked") @Override public Map createPad(String groupIdentifier, String content) throws EtherpadException { @@ -72,18 +70,15 @@ @Override public EPLiteClient getClient() throws EtherpadException { - if (client == null) { - // get the API key from the configuration and create EPLiteClient using it - String etherpadServerUrl = Configuration.get(ConfigurationKeys.ETHERPAD_SERVER_URL); - String etherpadApiKey = Configuration.get(ConfigurationKeys.ETHERPAD_API_KEY); - if (StringUtils.isBlank(etherpadServerUrl) || StringUtils.isBlank(etherpadApiKey)) { - throw new EtherpadException("Etherpad is not configured in sysadmin console"); - } - - // create EPLiteClient - client = new EPLiteClient(etherpadServerUrl, etherpadApiKey); + // get the API key from the configuration and create EPLiteClient using it + String etherpadServerUrl = Configuration.get(ConfigurationKeys.ETHERPAD_SERVER_URL); + String etherpadApiKey = Configuration.get(ConfigurationKeys.ETHERPAD_API_KEY); + if (StringUtils.isBlank(etherpadServerUrl) || StringUtils.isBlank(etherpadApiKey)) { + throw new EtherpadException("Etherpad is not configured in sysadmin console"); } - return client; + + // create EPLiteClient + return new EPLiteClient(etherpadServerUrl, etherpadApiKey); } /**