setCriteria Ends in java.lang.nullpointerexception for Groovy Script (Doc ID 2127414.1)

Last updated on JUNE 27, 2017

Applies to:

Oracle Agile PLM Framework - Version 9.3.5.0 to 9.3.5.0 [Release 9.3]
Information in this document applies to any platform.

Symptoms

When attempting to run script PX including setCriteria the following error occurs.

Error
java.lang.NullPointerException

Steps
The issue can be reproduced at will with the following steps:

  1. Login to admin in Java Client
  2. Admin > System Settings > Event Management > Event Handlers

    Handler Type : Script PX
    Name : Test - Bad Changes 2
    Enabled : Yes
    Script :
      

  3. Validate Script --> OK
  4. Admin > System Settings > Event Management > Events

    Event Type : Extend Tools Menu
    Name : Test - Bad Changes 2
    Enabled : Yes

  5. Event Subscriber

    Name : Test - Bad Changes 2
    Enabled : Yes
    Event : Test - Bad Changes 2
    Event Handler : Test - Bad Changes 2
    Trigger : Post
    Execution Mode : Synchronous
    Order : 0
    Error Handling Rule : Continue

  6. Click Enabled Triggering Events
  7. Process Extensions > Test - Bad Changes 2

    Process Extension Result
    java.lang.NullPointerException

  8. Application Server log : stdout.log shows the following:

    <2016-03-15 11:25:43,169> <EventMgr:ERROR> <108>--invokeEventHandlers-- Error occurred when running Handler:Test - Bad Changes 2 - Event: Test - Bad Changes 2 - Subscriber: Test - Bad Changes 2 -- ignore it as requested

 

Cause

Sign In with your My Oracle Support account

Don't have a My Oracle Support account? Click to get started

My Oracle Support provides customers with access to over a
Million Knowledge Articles and hundreds of Community platforms