Skip to main content


         This documentation site is for previous versions. Visit our new documentation site for current releases.      
 

Using file listeners

Updated on April 6, 2022

Use a file listener with a file service to import and process files from another system or that have been created by application users. For example, you can import data that is used to create a work object.

The file listener monitors the file directory. When files that arrive in the directory match the pattern that the file listener is listening for, the listener moves the files into the work_<name of listener>/completed directory and calls the file service. The file service uses a parse rule to open and read the file, evaluate each input record, divide the record into fields, and then write the fields to the clipboard and a service activity processes the data.

After processing the files, the file listener moves the files to either the work_<name of listener>/completed or work_<name of listener> directory depending on whether the files were processed correctly, and how you configured the file listener:

  • If the initial processing is successful, the file moves to the work_<name of listener>/completed directory.
  • If the initial processing fails, and Recovery is enabled, the file listener repeats the processing the number of times specified in the Max recovery attempts field. The file moves to the Completed directory regardless of whether the retried processing is successful.
  • If the initial processing fails and Recovery is disabled, the file moves to the Work directory.

The file listener also creates a work_<name of listener>/reports directory to hold report files that contain the processing results, if the file listener is configured to generate reports. For more information, see Configuring file listener processing.

File listener restart after Service File rule changes

Any change to the Service File rule requires that you restart the listener from Admin Studio for the changes to take effect. For more information, see Restarting a listener.

The following topics describe how to use a file listener to import and process files from another system.

Have a question? Get answers now.

Visit the Support Center to ask questions, engage in discussions, share ideas, and help others.

Did you find this content helpful?

Want to help us improve this content?

We'd prefer it if you saw us at our best.

Pega.com is not optimized for Internet Explorer. For the optimal experience, please use:

Close Deprecation Notice
Contact us