The adapters.properties file is a configuration file used within PAS for OpenEdge to control the JSON processing behavior of the REST adapter within a web application.

This file is located at <instance-dir>/webapps/<webapp-name>/WEB-INF/adapters/rest/adapters.properties. It is primarily used to set operational limits for the underlying Jackson JSON parser. The settings defined in this file ensure that JSON parsing and generation for the REST adapter comply with organizational performance and security requirements.

adapter.properties

The adapter.properties file provides detailed descriptions of the properties that you can define in the PAS for OpenEdge. It consists of the following properties:
  • maxTokenLength=1000
    • Definition—This property defines the maximum length, measured in characters or bytes depending on the input source, for numeric values in JSON. The default is 1000, and negative values are not allowed.
    • Context—Used to prevent excessively large numeric tokens in incoming JSON payloads, which could lead to parsing errors or memory issues. Helps enforce data integrity and protect against malformed or malicious input.
  • maxStringLength=20000000
    • Definition—This property defines the maximum string length, measured in characters or bytes depending on the input context. The default is 20000000. Note that this limit is not exact and failures may occur if buffer extensions exceed it. It is not recommended to set this value lower than maxNumberLength, and negative values are not allowed.
    • Context—Controls the size of string values in JSON input. Useful for managing memory usage and preventing buffer overflows. Should be set with consideration to maxNumberLength to maintain consistency.
  • maxNestingDepth=1000
    • Definition—This property defines the maximum nesting depth for JSON objects and arrays, referring to the count of unclosed { and [ brackets. Negative values are not permitted.
    • Context—Prevents overly complex or deeply nested JSON structures that could cause stack overflows or degrade performance during parsing.
  • maxPropertyNameLength=50000
    • Definition—This property specifies the maximum allowed length, measured in characters or bytes, for property names (object keys) in JSON data. The default is 50000. Enforcement may not be exact and failures can occur slightly above this threshold. Negative values are not allowed.
    • Context—Ensures that object keys in JSON are of a manageable size, which helps maintain readability, performance, and compatibility with downstream systems.
  • maxDocumentLength=-1
    • Definition—This property sets the maximum total length of the entire JSON document, measured in input units such as bytes or characters. If a positive number is specified, it becomes the limit; a value of 0 or a negative number allows unlimited length.
    • Context—Useful for bounding the size of incoming JSON payloads to avoid excessive memory consumption or denial-of-service risks.
  • maxOutputNestingDepth=1000
    • Definition—This property defines the maximum allowed nesting depth for server-generated JSON output, limiting the depth of objects and arrays created during serialization.
    • Context—Helps control the complexity of JSON responses generated by the server, ensuring they remain readable and compatible with clients that may have nesting limits.