IDEMPIERE-2756 Background threads losing context when user log out - fix validation / integrate fix from hengsin: Allow null context parameter for PO. Run pipodictionaryservice as system client ( ad_client_id=0 ).
This commit is contained in:
parent
c6bf87ef05
commit
6522a64289
|
@ -186,9 +186,7 @@ public abstract class PO
|
||||||
*/
|
*/
|
||||||
public PO (Properties ctx, int ID, String trxName, ResultSet rs)
|
public PO (Properties ctx, int ID, String trxName, ResultSet rs)
|
||||||
{
|
{
|
||||||
if (ctx == null)
|
p_ctx = ctx != null ? ctx : Env.getCtx();
|
||||||
throw new IllegalArgumentException ("No Context");
|
|
||||||
p_ctx = ctx;
|
|
||||||
m_trxName = trxName;
|
m_trxName = trxName;
|
||||||
|
|
||||||
p_info = initPO(ctx);
|
p_info = initPO(ctx);
|
||||||
|
|
|
@ -59,6 +59,9 @@ public class PipoDictionaryService implements IDictionaryService {
|
||||||
packIn = new PackIn();
|
packIn = new PackIn();
|
||||||
packIn.setPackageName(context.getBundle().getSymbolicName());
|
packIn.setPackageName(context.getBundle().getSymbolicName());
|
||||||
|
|
||||||
|
if (Env.getCtx().getProperty("#AD_Client_ID") == null) {
|
||||||
|
Env.getCtx().put("#AD_Client_ID", 0);
|
||||||
|
}
|
||||||
//get package version from file name suffix or bundle header
|
//get package version from file name suffix or bundle header
|
||||||
String packageVersion = null;
|
String packageVersion = null;
|
||||||
String fileName = packageFile.getName();
|
String fileName = packageFile.getName();
|
||||||
|
|
Loading…
Reference in New Issue