static <T extends ConfigBeanProxy> WriteableView getWriteableView(T s, ConfigBean sourceBean) throws TransactionFailure { WriteableView f = new WriteableView(s); try { if (sourceBean.getLock().tryLock(lockTimeOutInSeconds, TimeUnit.SECONDS)) { sourceBean.setWriteableView(f); return f; } } catch(InterruptedException e) { // ignore, will throw a TransactionFailure exception } throw new TransactionFailure("Config bean already locked " + sourceBean, null); }
static <T extends ConfigBeanProxy> WriteableView getWriteableView(T s, ConfigBean sourceBean) throws TransactionFailure { WriteableView f = new WriteableView(s); try { if (sourceBean.getLock().tryLock(lockTimeOutInSeconds, TimeUnit.SECONDS)) { sourceBean.setWriteableView(f); return f; } } catch(InterruptedException e) { // ignore, will throw a TransactionFailure exception } throw new TransactionFailure("Config bean already locked " + sourceBean, null); }
static <T extends ConfigBeanProxy> WriteableView getWriteableView(T s, ConfigBean sourceBean) throws TransactionFailure { WriteableView f = new WriteableView(s); try { if (sourceBean.getLock().tryLock(lockTimeOutInSeconds, TimeUnit.SECONDS)) { sourceBean.setWriteableView(f); return f; } } catch(InterruptedException e) { // ignore, will throw a TransactionFailure exception } throw new TransactionFailure("Config bean already locked " + sourceBean, null); }