Question
Acel Solutions Pvt Ltd
IN
Last activity: 31 May 2022 0:21 EDT
File listener issue in pega
Pega 8.2.8 in the file listener configuration...the empty file does not gets renamed as .err .
Also when I am using success criteria and based on the validation I am making it fail, the file gets vanished. it is not locatable either in completed folder or reprot folder of the filelistner.
***Edited by Moderator Marije to add possible FDBK ***
-
Reply
-
Syed Husain -
Share this page Facebook Twitter LinkedIn Email Copying... Copied!
Accepted Solution
Updated: 31 May 2022 0:21 EDT
Acel Solutions Pvt Ltd
IN
@KripalS3012 Thanks for showing interest and responding. I have moved away from FileListener and using Job schedular and Dataflow.
in the data flow post processing I am handling all the validations and logic and managing the files using Pega repository APIs.
that solves my business requirement.
This thread can be closed.
Updated: 18 May 2022 7:31 EDT
Pegasystems Inc.
GB
@KripalS3012 please can you confirm if this configuration worked in the past?
Can you confirm if the configuration is as per Best Practice documentation? Can you provide info about the source location and storage repository
As a quick sanity check could you restart the background nodes and file listeners as suggested here?
Can you tell us more about the configuration?
Do you have the File Listener configured with a Service File which parses records? Are you perhaps using prolog and epilog activities?
@KripalS3012 please can you confirm if this configuration worked in the past?
Can you confirm if the configuration is as per Best Practice documentation? Can you provide info about the source location and storage repository
As a quick sanity check could you restart the background nodes and file listeners as suggested here?
Can you tell us more about the configuration?
Do you have the File Listener configured with a Service File which parses records? Are you perhaps using prolog and epilog activities?
If so, there may be a gap in functionality that cannot be dealt with OOTB currently. If one of step in the activity is failing (puts a message on page), then the file listener does not treat it as an error and consequently does not move it to completed folder. Based on the code, only infrastructural errors (like exceptions ) are considered to be errors for file listener. There is no code to check for messages on page that fail the current item.
We have a field called SuccessCriteria (takes in when rule) where users can put in something like hasNoMessages when rule which will fail the item when there are messages on the page but success criteria is only called for parse segments activities not for prolog and epilog activities.
If there are errors (messages on page) while running epilog activity currently there is no way to fail it unless we throw an unchecked exception from the activity.
Can you confirm that you are including additional steps? If so you may need to write additional error handling logic in the prolog activity and move the file with appropriate extension.
You may want to log this with the support team. They will want to see documents which screenshots of
(1) File Listener Configuration (2) Service File Configuration (3) Log-Service-File instance xml
(4) Tracer
If you do log a support incident for this, could you please provide the INC id here?
Acel Solutions Pvt Ltd
IN
@MarijeSchillern it did not worked earlier also. we are using prolog processing. But I added activities in the parsing record and using validation. and doing page set messages. after that in the scusses criteria I am using !hasmessages(not has messages).
I restarted the listener but it does not work.
Acel Solutions Pvt Ltd
IN
@MarijeSchillern Thanks Marije. additionally as per my understanding we cannot write logic to act on the same file from 2 different process. e.g File listener will be trying to act on the file based on the configuration under clean up and error handling whereas the activity will also try to manage the file either by renaming and moving it. I am going with the concept that 2 different process will be able to act on 1 object.
Please correct me if my understanding is wrong.
Pegasystems Inc.
GB
@KripalS3012 we have an open Enhancement request : " Errors in file listener are limited" (FDBK-81374) Errors in file listener are meant for infrastructural issues, runtime exceptions and success criteria failure which works for the parse segment activity. It does not cater for scenarios where users are aggregating the records in the parse segment activity and the actual processing of the records is happening in the prolog activity. The request is to extend the functionality of 'Success Criteria' to prolog activity so that the file listener can identify processing errors and mark the file is an .err file.
I will need to find an SME for this area of functionality to comment on your outstanding question.
Pegasystems Inc.
US
Any attempt to explicitly move or rename the file while it is being operated on by the file listener is risky and not recommended. If the prolog activity is able to detect that the file is empty, and you want this to be handled as a processing error, you should induce a runtime exception to halt processing and cause the file to be renamed with the .err suffix. You can do this in a java step like this:
throw new PRRuntimeException("Received empty input file");
Accepted Solution
Updated: 31 May 2022 0:21 EDT
Acel Solutions Pvt Ltd
IN
@KripalS3012 Thanks for showing interest and responding. I have moved away from FileListener and using Job schedular and Dataflow.
in the data flow post processing I am handling all the validations and logic and managing the files using Pega repository APIs.
that solves my business requirement.
This thread can be closed.