Overview
- Introduced in
v0.9.6, we're currently on v0.10.7
- Validators are disabled by default
- Scytale's code interprets configured validator failures as something to either
- log a info/warning message and continue with the request or
- log an error and return a
400
- Only cd has validator enabled machines (i.e. scytale)
Available validators:
- always_invalid
- doesn't validate anything about the message and always returns an error
- always_valid
- doesn't validate anything about the message and always returns nil
- utf8
- validates that it contains UTF-8 strings
- msg_type
- validates the message's Type
- source
- validates the message's Source
- destination
- validates the message's Destination
- simple_res_req
- validates the message's Type is of SimpleRequestResponseMessageType
- simple_event
- validates the message's Type is of SimpleEventMessageType
- spans
- validates the message's Spans
- `An array of arrays of timing values as a list in the format: "parent" (string), "name" (string), "start time" (int), "duration" (int), "status" (int)
Integration Details
Integration Details
WRP validators are configured with the following (regardless of the application code) yaml:
# wrpValidators defines the wrp validators used to validate incoming wrp messages.
# (Optional)
# Available validator types: always_invalid, always_valid, utf8, msg_type, source, destination, simple_res_req, simple_event, spans
# Available validator levels: info, warning, error
# Validators can be disabled with `disable: true`, it is false by default
wrpValidators:
- type: utf8
level: warning
disable: true
- type: source
level: error
Key points:
- no validator is included by default
- a level is assigned to a given validator (default value is
unknown and it's consider invalid): info, warning, error
- during a validation failure, the application code determines how the validator level is interpret
Currently, only cd has validator enabled scytales . This is the validator config:
wrpValidators:
- type: utf8
level: error
- type: msg_type
level: error
- type: destination
level: warning
- type: source
level: warning
utf8 and msg_type validation errors are logged as errors and scytale returns a 400
destination and source validation errors are logged as warnings (scytale continues with the request)
Pending Questions
- For
destination do want to allow destinations without dns: identifiers to go through?
- Which validators should scytale use?
- For the selected validators, what level should be used?
Overview
v0.9.6, we're currently onv0.10.7400Available validators:
Integration Details
Integration Details
WRP validators are configured with the following (regardless of the application code) yaml:
Key points:
unknownand it's consider invalid): info, warning, errorCurrently, only
cdhas validator enabled scytales . This is the validator config:utf8andmsg_typevalidation errors are logged as errors and scytale returns a400destinationandsourcevalidation errors are logged as warnings (scytale continues with the request)Pending Questions
destinationdo want to allow destinations without dns: identifiers to go through?