Question

Element in ReporterStackImpl is not at the top

[Pega7.3.1]

Hi everyone,

We're facing very strange error in one of our environments.

Whenever I try to save/create any Application rule, I get the error in logs:

"com.pega.pegarules.pub.generator.UnresolvedAssemblyError: ** Error occurred trying to parse the expression and augmenting the code: java.lang.IllegalStateException: Trying to pop a database reporting element from com.pega.pegarules.monitor.internal.database.ReporterStackImpl@6f048e01 that is not at the top of the stack".

We were trying to

1. Simple server restart.

2. Turn off the persistance mode on Tomcat and restart it (I thought that maybe the ReporterStackImpl is corrupted and during restart it is being serialized/deserialized so we need to clean it up, but it didn't work).

3. Revalidate and Save.

4. Obj-Open --> Obj-Save one of the application rule.

Nothing helped.

The problem is only exist with Application Rules, others are working as expected (save/create).

Any thoughts, ideas or even links to java docs for com.pega.pegarules.monitor.internal.database package will be appreciated.

Correct Answer
December 12, 2019 - 3:59am

ok, the sledgehammer approach helped - truncate all the cache tables:

TRUNCATE TABLE PR_SYS_APP_HIERARCHY_FLAT;

TRUNCATE TABLE PR_SYS_APP_RULESET_INDEX;

TRUNCATE TABLE PR_SYS_CLASS_ANCESTORS;

TRUNCATE TABLE PR_ASSEMBLEDCLASSES;

TRUNCATE TABLE PR4_RULE_SYSGEN;

TRUNCATE TABLE PR_SYS_APPCACHE_ENTRY;

TRUNCATE TABLE PR_SYS_APPCACHE_DEP;

TRUNCATE TABLE PR_SYS_APPCACHE_SHORTCUT;

TRUNCATE TABLE PR_SYS_CACHE_DEP;

TRUNCATE TABLE PR_SYS_CACHE_ENTRY;

TRUNCATE TABLE PR_SYS_CACHE_IMPL;

TRUNCATE TABLE PR_SYS_CACHE_DEP;

Comments

Keep up to date on this post and subscribe to comments

December 9, 2019 - 9:20am

Hello, 

Can you trace it and share the XML output? Is it on all environments or just in Development?

December 9, 2019 - 9:50am
Response to MarcLasserre_GCS

@MarcLasserre_GCS,

There's nothing interesting in the tracer - it just fails on Rule- Save activity, step 21 (Obj-Save method). See in the attachment

So it's purely Pega internal issue. The instance of java class ReporterStackImpl is seems to be corrupted, but I don't know how to clean it up.

December 10, 2019 - 3:57am

moving on top

December 12, 2019 - 3:59am

ok, the sledgehammer approach helped - truncate all the cache tables:

TRUNCATE TABLE PR_SYS_APP_HIERARCHY_FLAT;

TRUNCATE TABLE PR_SYS_APP_RULESET_INDEX;

TRUNCATE TABLE PR_SYS_CLASS_ANCESTORS;

TRUNCATE TABLE PR_ASSEMBLEDCLASSES;

TRUNCATE TABLE PR4_RULE_SYSGEN;

TRUNCATE TABLE PR_SYS_APPCACHE_ENTRY;

TRUNCATE TABLE PR_SYS_APPCACHE_DEP;

TRUNCATE TABLE PR_SYS_APPCACHE_SHORTCUT;

TRUNCATE TABLE PR_SYS_CACHE_DEP;

TRUNCATE TABLE PR_SYS_CACHE_ENTRY;

TRUNCATE TABLE PR_SYS_CACHE_IMPL;

TRUNCATE TABLE PR_SYS_CACHE_DEP;