diff --git a/org.adempiere.base/src/org/compiere/acct/DocManager.java b/org.adempiere.base/src/org/compiere/acct/DocManager.java index 3b2d00a234..3696376460 100644 --- a/org.adempiere.base/src/org/compiere/acct/DocManager.java +++ b/org.adempiere.base/src/org/compiere/acct/DocManager.java @@ -66,7 +66,7 @@ public class DocManager { return documentsTableName; } - private static void fillDocumentsTableArrays() { + private synchronized static void fillDocumentsTableArrays() { if (documentsTableID == null) { String sql = "SELECT t.AD_Table_ID, t.TableName " + "FROM AD_Table t, AD_Column c " + diff --git a/org.adempiere.base/src/org/compiere/db/CConnection.java b/org.adempiere.base/src/org/compiere/db/CConnection.java index 8a452470c9..58594c7d11 100644 --- a/org.adempiere.base/src/org/compiere/db/CConnection.java +++ b/org.adempiere.base/src/org/compiere/db/CConnection.java @@ -48,7 +48,7 @@ public class CConnection implements Serializable, Cloneable */ private static final long serialVersionUID = -7893119456331485444L; /** Connection */ - private static CConnection s_cc = null; + private volatile static CConnection s_cc = null; /** Logger */ private static CLogger log = CLogger.getCLogger (CConnection.class); @@ -86,7 +86,7 @@ public class CConnection implements Serializable, Cloneable * @param apps_host optional apps host for new connections * @return Connection Descriptor */ - public static CConnection get (String apps_host) + public synchronized static CConnection get (String apps_host) { if (s_cc == null) { @@ -1418,7 +1418,7 @@ public class CConnection implements Serializable, Cloneable * Get Last Exception of Apps Server Connection attempt * @return Exception or null */ - public Exception getAppsServerException () + public synchronized Exception getAppsServerException () { return m_appsException; } // getAppsServerException diff --git a/org.adempiere.base/src/org/compiere/dbPort/Convert.java b/org.adempiere.base/src/org/compiere/dbPort/Convert.java index 494449eb49..f669498599 100644 --- a/org.adempiere.base/src/org/compiere/dbPort/Convert.java +++ b/org.adempiere.base/src/org/compiere/dbPort/Convert.java @@ -432,7 +432,7 @@ public abstract class Convert */ public abstract boolean isOracle(); - public static void logMigrationScript(String oraStatement, String pgStatement) { + public synchronized static void logMigrationScript(String oraStatement, String pgStatement) { // Check AdempiereSys // check property Log migration script boolean logMigrationScript = false; diff --git a/org.adempiere.base/src/org/compiere/model/MEXPProcessor.java b/org.adempiere.base/src/org/compiere/model/MEXPProcessor.java index b2d69b69c2..c300207d61 100644 --- a/org.adempiere.base/src/org/compiere/model/MEXPProcessor.java +++ b/org.adempiere.base/src/org/compiere/model/MEXPProcessor.java @@ -51,7 +51,7 @@ public class MEXPProcessor extends X_EXP_Processor { /** Static Logger */ private static CLogger s_log = CLogger.getCLogger (MEXPProcessor.class); - private static MEXPProcessor processor= null; + private volatile static MEXPProcessor processor= null; private X_EXP_ProcessorParameter[] parameters = null; public static MEXPProcessor get(Properties ctx, int EXP_Processor_ID, String trxName) diff --git a/org.adempiere.base/src/org/compiere/model/MLocator.java b/org.adempiere.base/src/org/compiere/model/MLocator.java index 67c3d306a3..2ece305a49 100644 --- a/org.adempiere.base/src/org/compiere/model/MLocator.java +++ b/org.adempiere.base/src/org/compiere/model/MLocator.java @@ -186,7 +186,7 @@ public class MLocator extends X_M_Locator } // get /** Cache */ - private static CCache s_cache; + private volatile static CCache s_cache; /** Logger */ private static CLogger s_log = CLogger.getCLogger (MLocator.class); diff --git a/org.adempiere.base/src/org/compiere/model/MRequestType.java b/org.adempiere.base/src/org/compiere/model/MRequestType.java index e447537429..1e8363092e 100644 --- a/org.adempiere.base/src/org/compiere/model/MRequestType.java +++ b/org.adempiere.base/src/org/compiere/model/MRequestType.java @@ -196,7 +196,7 @@ public class MRequestType extends X_R_RequestType * Get Total No of requests of type * @return no */ - public int getTotalNo() + public synchronized int getTotalNo() { updateStatistics(); return m_totalNo; @@ -206,7 +206,7 @@ public class MRequestType extends X_R_RequestType * Get Open No of requests of type * @return no */ - public int getOpenNo() + public synchronized int getOpenNo() { updateStatistics(); return m_openNo; @@ -216,7 +216,7 @@ public class MRequestType extends X_R_RequestType * Get Closed in last 30 days of type * @return no */ - public int getClosed30No() + public synchronized int getClosed30No() { updateStatistics(); return m_closed30No; @@ -226,7 +226,7 @@ public class MRequestType extends X_R_RequestType * Get New in the last 30 days of type * @return no */ - public int getNew30No() + public synchronized int getNew30No() { updateStatistics(); return m_new30No; diff --git a/org.adempiere.base/src/org/compiere/model/MSystem.java b/org.adempiere.base/src/org/compiere/model/MSystem.java index fed85f1340..a983d7d81e 100644 --- a/org.adempiere.base/src/org/compiere/model/MSystem.java +++ b/org.adempiere.base/src/org/compiere/model/MSystem.java @@ -62,7 +62,7 @@ public class MSystem extends X_AD_System * @param ctx context * @return System */ - public static MSystem get (Properties ctx) + public synchronized static MSystem get (Properties ctx) { if (s_system != null) return s_system; diff --git a/org.adempiere.base/src/org/compiere/model/MUserDefWin.java b/org.adempiere.base/src/org/compiere/model/MUserDefWin.java index bd52bbfbb9..511b2eb0cf 100644 --- a/org.adempiere.base/src/org/compiere/model/MUserDefWin.java +++ b/org.adempiere.base/src/org/compiere/model/MUserDefWin.java @@ -35,7 +35,7 @@ public class MUserDefWin extends X_AD_UserDef_Win */ private static final long serialVersionUID = -5775251886672840324L; - private static List m_fullList = null; + private volatile static List m_fullList = null; /** * Standard constructor. diff --git a/org.adempiere.base/src/org/compiere/model/TranslationTable.java b/org.adempiere.base/src/org/compiere/model/TranslationTable.java index f6528a3feb..17ecde661c 100644 --- a/org.adempiere.base/src/org/compiere/model/TranslationTable.java +++ b/org.adempiere.base/src/org/compiere/model/TranslationTable.java @@ -65,7 +65,7 @@ public class TranslationTable * @param requery requery * @return number of active Translations */ - public static int getActiveLanguages (boolean requery) + public synchronized static int getActiveLanguages (boolean requery) { if (s_activeLanguages != null && !requery) return s_activeLanguages.intValue(); diff --git a/org.adempiere.base/src/org/compiere/print/ArchiveEngine.java b/org.adempiere.base/src/org/compiere/print/ArchiveEngine.java index 6594b201f9..db23742186 100644 --- a/org.adempiere.base/src/org/compiere/print/ArchiveEngine.java +++ b/org.adempiere.base/src/org/compiere/print/ArchiveEngine.java @@ -195,7 +195,7 @@ public class ArchiveEngine /** Logger */ private static CLogger log = CLogger.getCLogger(ArchiveEngine.class); /** Singleton */ - private static ArchiveEngine s_engine = null; + private volatile static ArchiveEngine s_engine = null; /************************************************************************** diff --git a/org.adempiere.base/src/org/compiere/print/util/SwapFile.java b/org.adempiere.base/src/org/compiere/print/util/SwapFile.java index 51c0764980..89f8f8438b 100644 --- a/org.adempiere.base/src/org/compiere/print/util/SwapFile.java +++ b/org.adempiere.base/src/org/compiere/print/util/SwapFile.java @@ -171,7 +171,7 @@ public class SwapFile freeBlocks(segment.getOffsets()); } - private void verifyOpen() { + private synchronized void verifyOpen() { if (randomAccessFile == null) { throw new RuntimeException("Swap file not open for read write access"); } diff --git a/org.adempiere.base/src/org/compiere/util/CCachedRowSet.java b/org.adempiere.base/src/org/compiere/util/CCachedRowSet.java index 13aa1a1168..16a889b3a5 100644 --- a/org.adempiere.base/src/org/compiere/util/CCachedRowSet.java +++ b/org.adempiere.base/src/org/compiere/util/CCachedRowSet.java @@ -52,7 +52,7 @@ public class CCachedRowSet extends CachedRowSetImpl implements CachedRowSet * @return Cached Row Set * @throws SQLException */ - public static CCachedRowSet get() throws SQLException + public synchronized static CCachedRowSet get() throws SQLException { CCachedRowSet crs = null; // only first time call diff --git a/org.adempiere.base/src/org/compiere/util/CLogger.java b/org.adempiere.base/src/org/compiere/util/CLogger.java index 072a064293..653746224e 100644 --- a/org.adempiere.base/src/org/compiere/util/CLogger.java +++ b/org.adempiere.base/src/org/compiere/util/CLogger.java @@ -116,7 +116,7 @@ public class CLogger extends Logger implements Serializable } // get /** Default Logger */ - private static CLogger s_logger = null; + private volatile static CLogger s_logger = null; /************************************************************************** diff --git a/org.adempiere.base/src/org/compiere/util/DB.java b/org.adempiere.base/src/org/compiere/util/DB.java index 28e5092a70..69282464a4 100644 --- a/org.adempiere.base/src/org/compiere/util/DB.java +++ b/org.adempiere.base/src/org/compiere/util/DB.java @@ -255,7 +255,7 @@ public final class DB * Set connection * @param cc connection */ - public static void setDBTarget (CConnection cc) + public synchronized static void setDBTarget (CConnection cc) { if (cc == null) throw new IllegalArgumentException("Connection is NULL"); diff --git a/org.adempiere.base/src/org/compiere/util/Ini.java b/org.adempiere.base/src/org/compiere/util/Ini.java index b39307c61e..9f121f7e69 100644 --- a/org.adempiere.base/src/org/compiere/util/Ini.java +++ b/org.adempiere.base/src/org/compiere/util/Ini.java @@ -224,7 +224,7 @@ public final class Ini implements Serializable }; /** Container for Properties */ - private static Properties s_prop = new Properties(); + private volatile static Properties s_prop = new Properties(); private static String s_propertyFileName = null; diff --git a/org.adempiere.base/src/org/compiere/util/SecureEngine.java b/org.adempiere.base/src/org/compiere/util/SecureEngine.java index 796a532060..ef9be7313c 100644 --- a/org.adempiere.base/src/org/compiere/util/SecureEngine.java +++ b/org.adempiere.base/src/org/compiere/util/SecureEngine.java @@ -217,7 +217,7 @@ public class SecureEngine /** Test String */ private static final String TEST = "This is a 0123456789 .,; -= Test!"; /** Secure Engine */ - private static SecureEngine s_engine = null; + private volatile static SecureEngine s_engine = null; /** The real Engine */ private SecureInterface implementation = null; diff --git a/org.adempiere.base/src/org/compiere/util/WebInfo.java b/org.adempiere.base/src/org/compiere/util/WebInfo.java index 07521402e8..d32b3ba5b0 100644 --- a/org.adempiere.base/src/org/compiere/util/WebInfo.java +++ b/org.adempiere.base/src/org/compiere/util/WebInfo.java @@ -64,7 +64,7 @@ public class WebInfo } // getGeneral /** General Info */ - private static WebInfo m_general = null; + private volatile static WebInfo m_general = null; /** * Constructor diff --git a/org.adempiere.base/src/org/compiere/util/WebUser.java b/org.adempiere.base/src/org/compiere/util/WebUser.java index 92db947e16..5f8fea21ca 100644 --- a/org.adempiere.base/src/org/compiere/util/WebUser.java +++ b/org.adempiere.base/src/org/compiere/util/WebUser.java @@ -107,7 +107,7 @@ public class WebUser } // get /** Short term Cache for immediate re-query/post (hit rate 20%) */ - private static WebUser s_cache = null; + private volatile static WebUser s_cache = null; /*************************************************************************/ diff --git a/org.adempiere.base/src/org/compiere/wf/DocWorkflowManager.java b/org.adempiere.base/src/org/compiere/wf/DocWorkflowManager.java index 5c4772a472..c5d91ac441 100644 --- a/org.adempiere.base/src/org/compiere/wf/DocWorkflowManager.java +++ b/org.adempiere.base/src/org/compiere/wf/DocWorkflowManager.java @@ -55,7 +55,7 @@ public class DocWorkflowManager implements DocWorkflowMgr } /** Document Workflow Manager */ - private static DocWorkflowManager s_mgr = null; + private volatile static DocWorkflowManager s_mgr = null; /** Logger */ private static CLogger log = CLogger.getCLogger(DocWorkflowManager.class); diff --git a/org.adempiere.eclipse.equinox.http.servlet/src/org/eclipse/equinox/http/servlet/internal/HttpServiceImpl.java b/org.adempiere.eclipse.equinox.http.servlet/src/org/eclipse/equinox/http/servlet/internal/HttpServiceImpl.java index 0d99739af1..8589e2986b 100644 --- a/org.adempiere.eclipse.equinox.http.servlet/src/org/eclipse/equinox/http/servlet/internal/HttpServiceImpl.java +++ b/org.adempiere.eclipse.equinox.http.servlet/src/org/eclipse/equinox/http/servlet/internal/HttpServiceImpl.java @@ -50,7 +50,7 @@ public class HttpServiceImpl implements HttpService, ExtendedHttpService { shutdown = true; } - private void checkShutdown() { + private synchronized void checkShutdown() { if (shutdown) throw new IllegalStateException("Service instance is already shutdown"); //$NON-NLS-1$ } diff --git a/org.adempiere.eclipse.equinox.http.servlet/src/org/eclipse/equinox/http/servlet/internal/ProxyServlet.java b/org.adempiere.eclipse.equinox.http.servlet/src/org/eclipse/equinox/http/servlet/internal/ProxyServlet.java index a9c051c653..f9d1854f9c 100644 --- a/org.adempiere.eclipse.equinox.http.servlet/src/org/eclipse/equinox/http/servlet/internal/ProxyServlet.java +++ b/org.adempiere.eclipse.equinox.http.servlet/src/org/eclipse/equinox/http/servlet/internal/ProxyServlet.java @@ -42,7 +42,7 @@ public class ProxyServlet extends HttpServlet implements Filter { Activator.addProxyServlet(this); } - public void destroy() { + public synchronized void destroy() { Activator.removeProxyServlet(this); proxyContext.destroy(); proxyContext = null; @@ -56,7 +56,7 @@ public class ProxyServlet extends HttpServlet implements Filter { process(req, resp, null); } - protected void process(HttpServletRequest req, HttpServletResponse resp, FilterChain filterChain) throws ServletException, IOException { + protected synchronized void process(HttpServletRequest req, HttpServletResponse resp, FilterChain filterChain) throws ServletException, IOException { proxyContext.initializeServletPath(req, filterChain); String alias = HttpServletRequestAdaptor.getDispatchPathInfo(req, filterChain); if (alias == null) diff --git a/org.adempiere.eclipse.equinox.servletbridge/src/org/eclipse/equinox/servletbridge/BridgeServlet.java b/org.adempiere.eclipse.equinox.servletbridge/src/org/eclipse/equinox/servletbridge/BridgeServlet.java index 177b467a4c..f66b1dcc74 100644 --- a/org.adempiere.eclipse.equinox.servletbridge/src/org/eclipse/equinox/servletbridge/BridgeServlet.java +++ b/org.adempiere.eclipse.equinox.servletbridge/src/org/eclipse/equinox/servletbridge/BridgeServlet.java @@ -35,7 +35,7 @@ public class BridgeServlet extends HttpServlet { private static HttpServlet servletDelegateInstance; private HttpServlet delegate; // true if current HttpServlet is an HTTP Filter and false otherwise. - private boolean delegateIsFilter; + private static boolean delegateIsFilter; private int delegateReferenceCount; /** @@ -175,7 +175,7 @@ public class BridgeServlet extends HttpServlet { try { // cache the flag if HttpServlet servlet delegate is an HTTP Filter. - instance.delegateIsFilter = (servletDelegate instanceof Filter); + BridgeServlet.delegateIsFilter = (servletDelegate instanceof Filter); // initialize the servlet delegate. servletDelegate.init(instance.getServletConfig()); } catch (ServletException e) { @@ -207,7 +207,7 @@ public class BridgeServlet extends HttpServlet { HttpServlet oldProxy = instance.delegate; instance.delegate = null; - instance.delegateIsFilter = false; + BridgeServlet.delegateIsFilter = false; while (instance.delegateReferenceCount != 0) { try { instance.wait(); diff --git a/org.adempiere.server/src/main/server/org/compiere/server/AdempiereServerGroup.java b/org.adempiere.server/src/main/server/org/compiere/server/AdempiereServerGroup.java index dad61e56e0..17393879c5 100644 --- a/org.adempiere.server/src/main/server/org/compiere/server/AdempiereServerGroup.java +++ b/org.adempiere.server/src/main/server/org/compiere/server/AdempiereServerGroup.java @@ -38,7 +38,7 @@ public class AdempiereServerGroup extends ThreadGroup } // get /** Group */ - private static AdempiereServerGroup s_group = null; + private volatile static AdempiereServerGroup s_group = null; /** * AdempiereServerGroup diff --git a/org.adempiere.server/src/main/servlet/org/compiere/web/AdempiereMonitor.java b/org.adempiere.server/src/main/servlet/org/compiere/web/AdempiereMonitor.java index ed7a7eb72e..36f006d63a 100644 --- a/org.adempiere.server/src/main/servlet/org/compiere/web/AdempiereMonitor.java +++ b/org.adempiere.server/src/main/servlet/org/compiere/web/AdempiereMonitor.java @@ -94,11 +94,11 @@ public class AdempiereMonitor extends HttpServlet /** Logger */ private static CLogger log = CLogger.getCLogger(AdempiereMonitor.class); /** The Server */ - private AdempiereServerMgr m_serverMgr = null; + private static AdempiereServerMgr m_serverMgr = null; /** Message */ - private p m_message = null; + private static p m_message = null; - private ArrayList m_dirAccessList = null; + private volatile static ArrayList m_dirAccessList = null; /** * Get diff --git a/org.adempiere.ui.swing/src/org/compiere/grid/ed/VAccountDialog.java b/org.adempiere.ui.swing/src/org/compiere/grid/ed/VAccountDialog.java index 6e5d986a3e..199af65e93 100644 --- a/org.adempiere.ui.swing/src/org/compiere/grid/ed/VAccountDialog.java +++ b/org.adempiere.ui.swing/src/org/compiere/grid/ed/VAccountDialog.java @@ -146,7 +146,7 @@ public final class VAccountDialog extends CDialog protected boolean m_changed = false; /** Accounting Schema */ - private static MAcctSchema s_AcctSchema = null; + private volatile static MAcctSchema s_AcctSchema = null; /** MWindow for AccountCombination */ private GridWindow m_mWindow = null; /** MTab for AccountCombination */ diff --git a/org.adempiere.ui.zk/WEB-INF/src/fi/jawsy/jawwa/zk/atmosphere/AtmosphereServerPush.java b/org.adempiere.ui.zk/WEB-INF/src/fi/jawsy/jawwa/zk/atmosphere/AtmosphereServerPush.java index a9c8ef6dda..f45929b215 100644 --- a/org.adempiere.ui.zk/WEB-INF/src/fi/jawsy/jawwa/zk/atmosphere/AtmosphereServerPush.java +++ b/org.adempiere.ui.zk/WEB-INF/src/fi/jawsy/jawwa/zk/atmosphere/AtmosphereServerPush.java @@ -90,7 +90,7 @@ public class AtmosphereServerPush implements ServerPush { synchronized (info) { info.nActive = 1; //granted - info.notify(); + info.notifyAll(); } try { @@ -145,7 +145,7 @@ public class AtmosphereServerPush implements ServerPush { _active = null; synchronized (_mutex) { - _mutex.notify(); + _mutex.notifyAll(); } } } diff --git a/org.adempiere.ui.zk/WEB-INF/src/org/adempiere/webui/window/WAccountDialog.java b/org.adempiere.ui.zk/WEB-INF/src/org/adempiere/webui/window/WAccountDialog.java index b922167979..b7dcca971a 100644 --- a/org.adempiere.ui.zk/WEB-INF/src/org/adempiere/webui/window/WAccountDialog.java +++ b/org.adempiere.ui.zk/WEB-INF/src/org/adempiere/webui/window/WAccountDialog.java @@ -123,7 +123,7 @@ public final class WAccountDialog extends Window protected boolean m_changed = false; /** Accounting Schema */ - private static MAcctSchema s_AcctSchema = null; + private volatile static MAcctSchema s_AcctSchema = null; /** MWindow for AccountCombination */ private GridWindow m_mWindow = null; /** MTab for AccountCombination */ diff --git a/org.adempiere.webstore.servlet/src/org/compiere/wstore/StoreFilter.java b/org.adempiere.webstore.servlet/src/org/compiere/wstore/StoreFilter.java index 33735ecf04..e18696dc1a 100644 --- a/org.adempiere.webstore.servlet/src/org/compiere/wstore/StoreFilter.java +++ b/org.adempiere.webstore.servlet/src/org/compiere/wstore/StoreFilter.java @@ -43,7 +43,7 @@ import org.compiere.util.WebEnv; public class StoreFilter implements javax.servlet.Filter { /** Logging */ - private static CLogger log = null; + private volatile static CLogger log = null; /** * Init diff --git a/org.compiere.db.oracle.provider/src/org/compiere/db/DB_Oracle.java b/org.compiere.db.oracle.provider/src/org/compiere/db/DB_Oracle.java index e65680e6ef..8ae60f5dc3 100644 --- a/org.compiere.db.oracle.provider/src/org/compiere/db/DB_Oracle.java +++ b/org.compiere.db.oracle.provider/src/org/compiere/db/DB_Oracle.java @@ -164,7 +164,7 @@ public class DB_Oracle implements AdempiereDatabase * @return Driver * @throws SQLException */ - public Driver getDriver() throws SQLException + public synchronized Driver getDriver() throws SQLException { if (s_driver == null) { diff --git a/org.idempiere.fitnesse.fixture/src/org/idempiere/fitnesse/fixture/AssertRecord.java b/org.idempiere.fitnesse.fixture/src/org/idempiere/fitnesse/fixture/AssertRecord.java index d6dce28088..4cf37ea271 100644 --- a/org.idempiere.fitnesse.fixture/src/org/idempiere/fitnesse/fixture/AssertRecord.java +++ b/org.idempiere.fitnesse.fixture/src/org/idempiere/fitnesse/fixture/AssertRecord.java @@ -45,7 +45,7 @@ import fitnesse.fixtures.TableFixture; * @author Carlos Ruiz - globalqss */ public class AssertRecord extends TableFixture { - private static Instance adempiereInstance = null; + private volatile static Instance adempiereInstance = null; @Override protected void doStaticTable(int rows) { diff --git a/org.idempiere.fitnesse.fixture/src/org/idempiere/fitnesse/fixture/AssertVariable.java b/org.idempiere.fitnesse.fixture/src/org/idempiere/fitnesse/fixture/AssertVariable.java index 47e739b981..7a20125665 100644 --- a/org.idempiere.fitnesse.fixture/src/org/idempiere/fitnesse/fixture/AssertVariable.java +++ b/org.idempiere.fitnesse.fixture/src/org/idempiere/fitnesse/fixture/AssertVariable.java @@ -36,7 +36,7 @@ import fitnesse.fixtures.TableFixture; * @author Carlos Ruiz - globalqss */ public class AssertVariable extends TableFixture { - private static Instance adempiereInstance = null; + private volatile static Instance adempiereInstance = null; @Override protected void doStaticTable(int rows) { diff --git a/org.idempiere.fitnesse.fixture/src/org/idempiere/fitnesse/fixture/CreateRecord.java b/org.idempiere.fitnesse.fixture/src/org/idempiere/fitnesse/fixture/CreateRecord.java index d4f4c470cd..2f6268d58a 100644 --- a/org.idempiere.fitnesse.fixture/src/org/idempiere/fitnesse/fixture/CreateRecord.java +++ b/org.idempiere.fitnesse.fixture/src/org/idempiere/fitnesse/fixture/CreateRecord.java @@ -44,7 +44,7 @@ import fitnesse.fixtures.TableFixture; * @author Carlos Ruiz - globalqss */ public class CreateRecord extends TableFixture { - private static Instance adempiereInstance = null; + private volatile static Instance adempiereInstance = null; @Override protected void doStaticTable(int rows) { diff --git a/org.idempiere.fitnesse.fixture/src/org/idempiere/fitnesse/fixture/Login.java b/org.idempiere.fitnesse.fixture/src/org/idempiere/fitnesse/fixture/Login.java index ed39c9d727..0d8561108f 100644 --- a/org.idempiere.fitnesse.fixture/src/org/idempiere/fitnesse/fixture/Login.java +++ b/org.idempiere.fitnesse.fixture/src/org/idempiere/fitnesse/fixture/Login.java @@ -39,7 +39,7 @@ import fitnesse.fixtures.TableFixture; */ public class Login extends TableFixture { private static final String LANGUAGE_EN_US = "en_US"; - private static Instance adempiereInstance = null; + private volatile static Instance adempiereInstance = null; private String m_user; private String m_password; private String m_language; diff --git a/org.idempiere.fitnesse.fixture/src/org/idempiere/fitnesse/fixture/ReadRecord.java b/org.idempiere.fitnesse.fixture/src/org/idempiere/fitnesse/fixture/ReadRecord.java index 28f1eac69e..7f5dd615ce 100644 --- a/org.idempiere.fitnesse.fixture/src/org/idempiere/fitnesse/fixture/ReadRecord.java +++ b/org.idempiere.fitnesse.fixture/src/org/idempiere/fitnesse/fixture/ReadRecord.java @@ -45,7 +45,7 @@ import fitnesse.fixtures.TableFixture; * @author Carlos Ruiz - globalqss */ public class ReadRecord extends TableFixture { - private static Instance adempiereInstance = null; + private volatile static Instance adempiereInstance = null; @Override protected void doStaticTable(int rows) { diff --git a/org.idempiere.fitnesse.fixture/src/org/idempiere/fitnesse/fixture/RunProcess.java b/org.idempiere.fitnesse.fixture/src/org/idempiere/fitnesse/fixture/RunProcess.java index a4e34fe805..90b582f69a 100644 --- a/org.idempiere.fitnesse.fixture/src/org/idempiere/fitnesse/fixture/RunProcess.java +++ b/org.idempiere.fitnesse.fixture/src/org/idempiere/fitnesse/fixture/RunProcess.java @@ -58,7 +58,7 @@ import fitnesse.fixtures.TableFixture; * @author Carlos Ruiz - globalqss */ public class RunProcess extends TableFixture { - private static Instance adempiereInstance = null; + private volatile static Instance adempiereInstance = null; private static CLogger log = CLogger.getCLogger(RunProcess.class); diff --git a/org.idempiere.fitnesse.fixture/src/org/idempiere/fitnesse/fixture/SetDocAction.java b/org.idempiere.fitnesse.fixture/src/org/idempiere/fitnesse/fixture/SetDocAction.java index 117f975ff7..97422214e0 100644 --- a/org.idempiere.fitnesse.fixture/src/org/idempiere/fitnesse/fixture/SetDocAction.java +++ b/org.idempiere.fitnesse.fixture/src/org/idempiere/fitnesse/fixture/SetDocAction.java @@ -43,7 +43,7 @@ import fitnesse.fixtures.TableFixture; * @author Carlos Ruiz - globalqss */ public class SetDocAction extends TableFixture { - private static Instance adempiereInstance = null; + private volatile static Instance adempiereInstance = null; @Override protected void doStaticTable(int rows) { diff --git a/org.idempiere.fitnesse.fixture/src/org/idempiere/fitnesse/fixture/SetVariable.java b/org.idempiere.fitnesse.fixture/src/org/idempiere/fitnesse/fixture/SetVariable.java index a1c6a9d532..c5b65dcce6 100644 --- a/org.idempiere.fitnesse.fixture/src/org/idempiere/fitnesse/fixture/SetVariable.java +++ b/org.idempiere.fitnesse.fixture/src/org/idempiere/fitnesse/fixture/SetVariable.java @@ -38,7 +38,7 @@ import fitnesse.fixtures.TableFixture; * @author Carlos Ruiz - globalqss */ public class SetVariable extends TableFixture { - private static Instance adempiereInstance = null; + private volatile static Instance adempiereInstance = null; @Override protected void doStaticTable(int rows) { diff --git a/org.idempiere.fitnesse.fixture/src/org/idempiere/fitnesse/fixture/Static_iDempiereInstance.java b/org.idempiere.fitnesse.fixture/src/org/idempiere/fitnesse/fixture/Static_iDempiereInstance.java index 506624e70e..8d10ee3480 100644 --- a/org.idempiere.fitnesse.fixture/src/org/idempiere/fitnesse/fixture/Static_iDempiereInstance.java +++ b/org.idempiere.fitnesse.fixture/src/org/idempiere/fitnesse/fixture/Static_iDempiereInstance.java @@ -32,7 +32,7 @@ package org.idempiere.fitnesse.fixture; * @author Carlos Ruiz - globalqss */ public class Static_iDempiereInstance { - private static Instance adempiereInstance; + private volatile static Instance adempiereInstance; public static Instance getInstance() { if (adempiereInstance == null) { diff --git a/org.idempiere.hazelcast.service/src/org/idempiere/hazelcast/service/Activator.java b/org.idempiere.hazelcast.service/src/org/idempiere/hazelcast/service/Activator.java index 9a57f5a743..853fd80b18 100644 --- a/org.idempiere.hazelcast.service/src/org/idempiere/hazelcast/service/Activator.java +++ b/org.idempiere.hazelcast.service/src/org/idempiere/hazelcast/service/Activator.java @@ -39,7 +39,7 @@ public class Activator implements BundleActivator { return context; } - private static HazelcastInstance hazelcastInstance; + private volatile static HazelcastInstance hazelcastInstance; private static AtomicReference> futureRef = new AtomicReference>(); /*