Oracle Waveset 8.1.1 Resources Reference

getUser Action

The getUser action retrieves a map of existing user attributes from the customer’s database. If the getUser action is not defined, the adapter cannot perform any user actions.

Context

The actionContext map contains the following entries:

Key  

Value Type  

Value Description  

conn

java.sql.Connection 

JDBC connection to the customer’s database 

adapter

com.wavset.adapter.ScriptedJdbcResourceAdapter 

Adapter instance 

action

java.lang.String 

The getUser string

id

java.lang.String 

The user account ID to fetch 

attrsToGet

java.util.List 

List of strings identifying which user attributes to fetch. This list is derived from the right-hand side of the schema map. 

result

java.util.Map 

  • If the user does not currently exist in the database, the script should leave this map empty.

  • If the user does exist, see the following description of the expected map.

errors

java.util.List 

Initially this value is an empty list. 

The script may add java.lang.String objects to this list if any errors are found during processing.

trace

com.waveset.adapter.Trace 

Object used to trace execution. 

Scripts can use the methods of this class to make themselves “debuggable” in a customer environment. 

The adapter expects the result map to be populated with the following entries:

Key  

Value Type  

Value Description  

attrMap

java.util.Map 

If the script is capable of directly retrieving the user attributes, then the script can set this entry with a map of the user attributes. The attribute names are defined in the Resource User Attribute column of the resource’s schema map. 

isDisabled

java.lang.Boolean or java.lang.String 

If set by the script to a Boolean.TRUE or a true string, then the user is considered disabled.

Error Handling

Any throw from within the script is considered a failure.

If the script encounters any errors, it may add appropriate strings to the errors key. The presence of any items in the errors List is considered a fetch failure.