Question
Adqura
IN
Last activity: 7 Aug 2023 10:35 EDT
Campaign with Volume Constraint fails in Pega 8.4.3
Dear All,
Please let me know what could be the root cause and resolution for the below Volume Constraint Issue.
Issue: Campaign will get failed Volume constraint is configured in the Campaign
Error Message in Program Run from the Campaign Dashboard:
Critical - Failure applying Constraint. Suspend and Update the campaign to resolve this issue. After updating, you can Restart or Skip this run.
Environment Details
Pega Platform Version: Pega 8.4.3
FW Details (if any): PegaMarketing_FW 8
Database: Postgres SQL
Log Message
Dear All,
Please let me know what could be the root cause and resolution for the below Volume Constraint Issue.
Issue: Campaign will get failed Volume constraint is configured in the Campaign
Error Message in Program Run from the Campaign Dashboard:
Critical - Failure applying Constraint. Suspend and Update the campaign to resolve this issue. After updating, you can Restart or Skip this run.
Environment Details
Pega Platform Version: Pega 8.4.3
FW Details (if any): PegaMarketing_FW 8
Database: Postgres SQL
Log Message
2020-11-24 00:20:21,672 [ PegaRULES-Batch-4] [ STANDARD] [ ] [hieBaseline:01.01.01] (.ProgressiveOptimizationEngine) ERROR - ProgressiveOptimizationEngine.applyConstraintToPartition() - Exception processing Volume Constraint com.pega.pegarules.pub.PRRuntimeException: Cannot list the database at com.pega.decision.dsm.batch.RDBBatchReader.<init>(RDBBatchReader.java:82) ~[prpublic.jar:?] at com.pegarules.generated.createSQLBasedIterator_080101_373222742713466010.createSQLBasedIterator08_01_01(createSQLBasedIterator_080101_373222742713466010.java:130) ~[?:?] at com.pegarules.generated.createSQLBasedIterator_080101_373222742713466010.invoke(createSQLBasedIterator_080101_373222742713466010.java:106) ~[?:?] at com.pega.pegarules.generation.internal.library.LibraryRuntime.resolveAndinvokeFunctionViaReflection(LibraryRuntime.java:232) ~[prprivate-generation.jar:?] at com.pega.pegarules.generation.internal.library.LibraryRuntime.invokeLibraryRuntime(LibraryRuntime.java:123) ~[prprivate-generation.jar:?] at com.pega.pegarules.session.internal.mgmt.Executable.invokeLibraryRuntime(Executable.java:9674) ~[prprivate-session.jar:?] at com.pega.pegarules.priv.generator.LibrarySupport.resolveAndInvokeFunctionViaReflection(LibrarySupport.java:260) ~[prpublic.jar:?] at com.pega.mkt.DataUtils.createSQLIterator(DataUtils.java:61) ~[pegamkt-08.04.01.jar:?] at com.pega.mkt.constraint.ProgressiveOptimizationEngine.applyConstraintToPartition(ProgressiveOptimizationEngine.java:122) ~[pegamkt-08.04.01.jar:?] at com.pega.mkt.constraint.ProgressiveOptimizationEngine.applyConstraint(ProgressiveOptimizationEngine.java:81) ~[pegamkt-08.04.01.jar:?] at com.pegarules.generated.ApplyProgressiveOptimization_080301__3951735868174170214.ApplyProgressiveOptimization08_03_01(ApplyProgressiveOptimization_080301__3951735868174170214.java:96) ~[?:?] at com.pegarules.generated.ApplyProgressiveOptimization_080301__3951735868174170214.invoke(ApplyProgressiveOptimization_080301__3951735868174170214.java:70) ~[?:?] at com.pega.pegarules.generation.internal.library.LibraryRuntime.resolveAndinvokeFunctionViaReflection(LibraryRuntime.java:232) ~[prprivate-generation.jar:?] at com.pega.pegarules.generation.internal.library.LibraryRuntime.invokeLibraryRuntime(LibraryRuntime.java:123) ~[prprivate-generation.jar:?] at com.pega.pegarules.generation.internal.library.LibraryFunctionUtilityImpl.resolveMethodCall(LibraryFunctionUtilityImpl.java:2932) ~[prprivate-generation.jar:?] at com.pega.pegarules.session.internal.mgmt.Executable.resolveMethodCall(Executable.java:11952) ~[prprivate-session.jar:?] at com.pegarules.generated.activity.ra_action_applyvolumeconstraint_74db442f4e442bf8ca766ed9e3813490.step8_circum0(ra_action_applyvolumeconstraint_74db442f4e442bf8ca766ed9e3813490.java:789) ~[?:?] at com.pegarules.generated.activity.ra_action_applyvolumeconstraint_74db442f4e442bf8ca766ed9e3813490.perform(ra_action_applyvolumeconstraint_74db442f4e442bf8ca766ed9e3813490.java:207) ~[?:?] at com.pega.pegarules.session.internal.mgmt.Executable.doActivity(Executable.java:2814) ~[prprivate-session.jar:?] at com.pegarules.generated.flow.ra_action_managevolumeconstraint_30eaca2b8db05eaafcc402297581c812.RunTaskActivity(ra_action_managevolumeconstraint_30eaca2b8db05eaafcc402297581c812.java:5222) ~[?:?] at com.pegarules.generated.flow.ra_action_managevolumeconstraint_30eaca2b8db05eaafcc402297581c812.Task_Utility1_circum0(ra_action_managevolumeconstraint_30eaca2b8db05eaafcc402297581c812.java:1156) ~[?:?] at com.pegarules.generated.flow.ra_action_managevolumeconstraint_30eaca2b8db05eaafcc402297581c812.perform(ra_action_managevolumeconstraint_30eaca2b8db05eaafcc402297581c812.java:633) ~[?:?] at com.pega.pegarules.session.internal.mgmt.Executable.doActivity(Executable.java:2814) ~[prprivate-session.jar:?] at com.pegarules.generated.flow.ra_action_executeprogramrun_459826b47a6b9323987a9593767fb91c.LaunchFlow(ra_action_executeprogramrun_459826b47a6b9323987a9593767fb91c.java:11285) ~[?:?] at com.pegarules.generated.flow.ra_action_executeprogramrun_459826b47a6b9323987a9593767fb91c.LaunchFlow(ra_action_executeprogramrun_459826b47a6b9323987a9593767fb91c.java:10923) ~[?:?] at com.pegarules.generated.flow.ra_action_executeprogramrun_459826b47a6b9323987a9593767fb91c.Task_SubProcess2_circum0(ra_action_executeprogramrun_459826b47a6b9323987a9593767fb91c.java:7417) ~[?:?] at com.pegarules.generated.flow.ra_action_executeprogramrun_459826b47a6b9323987a9593767fb91c.perform(ra_action_executeprogramrun_459826b47a6b9323987a9593767fb91c.java:737) ~[?:?] at com.pega.pegarules.session.internal.mgmt.Executable.doActivity(Executable.java:2814) ~[prprivate-session.jar:?] at com.pegarules.generated.flow.ra_action_managedataflowresilence_8d653d55326620fe1440db7217175850.RestartIssuingFlow(ra_action_managedataflowresilence_8d653d55326620fe1440db7217175850.java:5618) ~[?:?] at com.pegarules.generated.flow.ra_action_managedataflowresilence_8d653d55326620fe1440db7217175850.perform(ra_action_managedataflowresilence_8d653d55326620fe1440db7217175850.java:804) ~[?:?] at com.pega.pegarules.session.internal.mgmt.Executable.doActivity(Executable.java:2814) ~[prprivate-session.jar:?] at com.pegarules.generated.StartFlow_080401__6867397908777742199.StartFlow08_04_01(StartFlow_080401__6867397908777742199.java:165) ~[?:?] at com.pegarules.generated.StartFlow_080401__6867397908777742199.invoke(StartFlow_080401__6867397908777742199.java:74) ~[?:?] at com.pega.pegarules.generation.internal.library.LibraryRuntime.resolveAndinvokeFunctionViaReflection(LibraryRuntime.java:232) ~[prprivate-generation.jar:?] at com.pega.pegarules.generation.internal.library.LibraryRuntime.invokeLibraryRuntime(LibraryRuntime.java:123) ~[prprivate-generation.jar:?] at com.pega.pegarules.session.internal.mgmt.Executable.invokeLibraryRuntime(Executable.java:9674) ~[prprivate-session.jar:?] at com.pega.pegarules.priv.generator.LibrarySupport.resolveAndInvokeFunctionViaReflectionWithException(LibrarySupport.java:277) ~[prpublic.jar:?] at com.pegarules.generated.activity.ra_action_completeassignment_965414fb0790ab29aeb9f16139c0de89.step28_circum0(ra_action_completeassignment_965414fb0790ab29aeb9f16139c0de89.java:2823) ~[?:?] at com.pegarules.generated.activity.ra_action_completeassignment_965414fb0790ab29aeb9f16139c0de89.perform(ra_action_completeassignment_965414fb0790ab29aeb9f16139c0de89.java:592) ~[?:?] at com.pega.pegarules.session.internal.mgmt.Executable.doActivity(Executable.java:2814) ~[prprivate-session.jar:?] at com.pegarules.generated.callActivity_080101_2223927609556540475.callActivity08_01_01(callActivity_080101_2223927609556540475.java:134) ~[?:?] at com.pegarules.generated.callActivity_080101_2223927609556540475.invoke(callActivity_080101_2223927609556540475.java:81) ~[?:?] at com.pega.pegarules.generation.internal.library.LibraryRuntime.resolveAndinvokeFunctionViaReflection(LibraryRuntime.java:232) ~[prprivate-generation.jar:?] at com.pega.pegarules.generation.internal.library.LibraryRuntime.invokeLibraryRuntime(LibraryRuntime.java:123) ~[prprivate-generation.jar:?] at com.pega.pegarules.session.internal.mgmt.Executable.invokeLibraryRuntime(Executable.java:9674) ~[prprivate-session.jar:?] at com.pega.pegarules.priv.generator.LibrarySupport.resolveAndInvokeFunctionViaReflectionWithException(LibrarySupport.java:277) ~[prpublic.jar:?] at com.pegarules.generated.activity.ra_action_performflowaction_43a84b19d5cca918e2e2987f917a5996.step18_circum0(ra_action_performflowaction_43a84b19d5cca918e2e2987f917a5996.java:1727) ~[?:?] at com.pegarules.generated.activity.ra_action_performflowaction_43a84b19d5cca918e2e2987f917a5996.perform(ra_action_performflowaction_43a84b19d5cca918e2e2987f917a5996.java:372) ~[?:?] at com.pega.pegarules.session.internal.mgmt.Executable.doActivity(Executable.java:2814) ~[prprivate-session.jar:?] at com.pega.pegarules.session.internal.mgmt.Executable.invokeActivity(Executable.java:11393) ~[prprivate-session.jar:?] at com.pegarules.generated.activity.ra_action_resumeflow_bec2bd5e4bd9c39298c9f365023d50ee.step3_circum0(ra_action_resumeflow_bec2bd5e4bd9c39298c9f365023d50ee.java:439) ~[?:?] at com.pegarules.generated.activity.ra_action_resumeflow_bec2bd5e4bd9c39298c9f365023d50ee.perform(ra_action_resumeflow_bec2bd5e4bd9c39298c9f365023d50ee.java:110) ~[?:?] at com.pega.pegarules.session.internal.mgmt.Executable.doActivity(Executable.java:2814) ~[prprivate-session.jar:?] at com.pegarules.generated.callActivity_080101_2223927609556540475.callActivity08_01_01(callActivity_080101_2223927609556540475.java:134) ~[?:?] at com.pegarules.generated.callActivity_080101_2223927609556540475.invoke(callActivity_080101_2223927609556540475.java:81) ~[?:?] at com.pega.pegarules.generation.internal.library.LibraryRuntime.resolveAndinvokeFunctionViaReflection(LibraryRuntime.java:232) ~[prprivate-generation.jar:?] at com.pega.pegarules.generation.internal.library.LibraryRuntime.invokeLibraryRuntime(LibraryRuntime.java:123) ~[prprivate-generation.jar:?] at com.pega.pegarules.session.internal.mgmt.Executable.invokeLibraryRuntime(Executable.java:9674) ~[prprivate-session.jar:?] at com.pega.pegarules.priv.generator.LibrarySupport.resolveAndInvokeFunctionViaReflectionWithException(LibrarySupport.java:277) ~[prpublic.jar:?] at com.pegarules.generated.activity.ra_action_executesla_464350f6cf89e0b6dd36c2aed60a7659.step19_circum0(ra_action_executesla_464350f6cf89e0b6dd36c2aed60a7659.java:2133) ~[?:?] at com.pegarules.generated.activity.ra_action_executesla_464350f6cf89e0b6dd36c2aed60a7659.perform(ra_action_executesla_464350f6cf89e0b6dd36c2aed60a7659.java:441) ~[?:?] at com.pega.pegarules.session.internal.mgmt.Executable.doActivity(Executable.java:2814) ~[prprivate-session.jar:?] at com.pega.pegarules.session.internal.mgmt.Executable.invokeActivity(Executable.java:11393) ~[prprivate-session.jar:?] at com.pegarules.generated.activity.ra_action_processevent_7629eb033a352f0c9e7ba1095b657e01.step7_circum0(ra_action_processevent_7629eb033a352f0c9e7ba1095b657e01.java:706) ~[?:?] at com.pegarules.generated.activity.ra_action_processevent_7629eb033a352f0c9e7ba1095b657e01.perform(ra_action_processevent_7629eb033a352f0c9e7ba1095b657e01.java:205) ~[?:?] at com.pega.pegarules.session.internal.mgmt.Executable.doActivity(Executable.java:2814) ~[prprivate-session.jar:?] at com.pega.pegarules.session.internal.async.agent.QueueProcessor.runActivity(QueueProcessor.java:795) ~[prprivate-session.jar:?] at com.pega.pegarules.session.internal.async.agent.QueueProcessor.execute(QueueProcessor.java:620) ~[prprivate-session.jar:?] at com.pega.pegarules.session.internal.async.BatchRequestorTask.run(BatchRequestorTask.java:1158) ~[prprivate-session.jar:?] at com.pega.pegarules.session.internal.PRSessionProviderImpl.performTargetActionWithLock(PRSessionProviderImpl.java:1397) ~[prprivate-session.jar:?] at com.pega.pegarules.session.internal.PRSessionProviderImpl.doWithRequestorLocked(PRSessionProviderImpl.java:1140) ~[prprivate-session.jar:?] at com.pega.pegarules.session.internal.PRSessionProviderImpl.doWithRequestorLocked(PRSessionProviderImpl.java:1021) ~[prprivate-session.jar:?] at com.pega.pegarules.session.internal.async.BatchRequestorTask.run(BatchRequestorTask.java:818) ~[prprivate-session.jar:?] at java.util.concurrent.ThreadPoolExecutor.runWorker(ThreadPoolExecutor.java:1149) [?:1.8.0_171] at java.util.concurrent.ThreadPoolExecutor$Worker.run(ThreadPoolExecutor.java:624) [?:1.8.0_171] at java.lang.Thread.run(Thread.java:748) [?:1.8.0_171] Caused by: com.pega.pegarules.pub.database.DatabaseException: There was a problem getting a list: code: 0 SQLState: 42601 Message: ERROR: syntax error at or near "AND" Position: 29647 DatabaseException caused by prior exception: org.postgresql.util.PSQLException: ERROR: syntax error at or near "AND" Position: 29647 | SQL Code: 0 | SQL State: 42601 at com.pega.pegarules.data.internal.access.ExceptionInformation.createAppropriateExceptionDueToDBFailure(ExceptionInformation.java:385) ~[prprivate-data.jar:?] at com.pega.pegarules.data.internal.access.ExceptionInformation.createExceptionDueToDBFailure(ExceptionInformation.java:364) ~[prprivate-data.jar:?] at com.pega.pegarules.data.internal.access.Lister.convertSqlExceptionToDatabaseException(Lister.java:618) ~[prprivate-data.jar:?] at com.pega.pegarules.data.internal.access.Lister.listWithResultPackager(Lister.java:434) ~[prprivate-data.jar:?] at com.pega.pegarules.data.internal.access.Lister.list(Lister.java:190) ~[prprivate-data.jar:?] at com.pega.pegarules.data.internal.access.DatabaseImpl.list(DatabaseImpl.java:3010) ~[prprivate-data.jar:?] at com.pega.pegarules.data.internal.access.DatabaseImpl.list(DatabaseImpl.java:3001) ~[prprivate-data.jar:?] at com.pega.decision.dsm.batch.RDBBatchReader.<init>(RDBBatchReader.java:74) ~[prpublic.jar:?] ... 75 more Caused by: org.postgresql.util.PSQLException: ERROR: syntax error at or near "AND" Position: 29647 at org.postgresql.core.v3.QueryExecutorImpl.receiveErrorResponse(QueryExecutorImpl.java:2553) ~[postgresql-42.2.18.jar:42.2.18] at org.postgresql.core.v3.QueryExecutorImpl.processResults(QueryExecutorImpl.java:2285) ~[postgresql-42.2.18.jar:42.2.18] at org.postgresql.core.v3.QueryExecutorImpl.execute(QueryExecutorImpl.java:323) ~[postgresql-42.2.18.jar:42.2.18] at org.postgresql.jdbc.PgStatement.executeInternal(PgStatement.java:473) ~[postgresql-42.2.18.jar:42.2.18] at org.postgresql.jdbc.PgStatement.execute(PgStatement.java:393) ~[postgresql-42.2.18.jar:42.2.18] at org.postgresql.jdbc.PgPreparedStatement.executeWithFlags(PgPreparedStatement.java:164) ~[postgresql-42.2.18.jar:42.2.18] at org.postgresql.jdbc.PgPreparedStatement.execute(PgPreparedStatement.java:153) ~[postgresql-42.2.18.jar:42.2.18] at com.zaxxer.hikari.pool.ProxyPreparedStatement.execute(ProxyPreparedStatement.java:44) ~[HikariCP-java7-2.4.12.jar:?] at com.zaxxer.hikari.pool.HikariProxyPreparedStatement.execute(HikariProxyPreparedStatement.java) ~[HikariCP-java7-2.4.12.jar:?] at com.pega.pegarules.data.internal.store.DatabasePreparedStatementImpl.execute(DatabasePreparedStatementImpl.java:531) ~[prprivate-data.jar:?] at com.pega.pegarules.data.internal.access.Lister.listWithResultPackager(Lister.java:415) ~[prprivate-data.jar:?] at com.pega.pegarules.data.internal.access.Lister.list(Lister.java:190) ~[prprivate-data.jar:?] at com.pega.pegarules.data.internal.access.DatabaseImpl.list(DatabaseImpl.java:3010) ~[prprivate-data.jar:?] at com.pega.pegarules.data.internal.access.DatabaseImpl.list(DatabaseImpl.java:3001) ~[prprivate-data.jar:?] at com.pega.decision.dsm.batch.RDBBatchReader.<init>(RDBBatchReader.java:74) ~[prpublic.jar:?] ... 75 more