Skip to content

coltonfischer/ps-chrome-logger

master
Switch branches/tags
Code

Latest commit

 

Git stats

Files

Permalink
Failed to load latest commit information.
Type
Name
Latest commit message
Commit time
 
 
 
 

PS-Chrome-Logger

A utility to allow PeopleSoft developers to write log statements to the Chrome browser console from PeopleCode.

Dependencies

  • You must be on PeopleTools 8.55 or later.

  • [Optional] Install the PS-Jsonify utility to enable logging of PeopleCode object types such as Arrays, App Classes, Records, and Rowsets with one line of code.

Installing

  • Download and import the PeopleSoft project into App Designer.

  • Install the Chrome Logger extension for Google Chrome.

  • Click the extension icon to enable logging for the current tab's domain (It will light up blue).

Toggle Chrome Logger

Usage

You can to write log statements from PeopleCode like this:

(CreateObject("L:O")).G("Hello from the server");

The log output will show in the Chrome browser console like this:

Log String Output

If you have the PS-Jsonify utility installed then you can output PeopleCode object types. Here is an example statement logging the Landing Page Rowset from the PT_LANDINGPAGE Component PeopleCode:

Local  Rowset  &rsLandingPages = GetLevel0()(1).GetRowset(Scroll.PTNUI_LP_PAGE);

(CreateObject("L:O")).G(&rsLandingPages);

The log output will show in the Chrome browser console like this:

Log Rowset Output

If you do not use the PS-Jsonify utility then above example would output "Rowset".

Limitations

  • This utility only supports the output of log statements to the Chrome browser console in PeopleCode contexts where the %Response object is available. You can extend the logging facade class to use different logging strategies in contexts where the %Response object is unavailable. An example might include writing to a file when in an Integration Broker or Process Scheduler context.

  • This utility communicates log data via HTTP response headers. The Chrome browser has a limit of 250kb across all headers for a single request so this poses a limit on the amount of data you can log.

Additional Details

Blog Post: Server Side Logs in the Browser Console

About

Chrome Logger for PeopleSoft

Resources

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published