piserver.yml configuration file
This page outlines the settings available in the IPLM Server configuration file /etc/mdx/piserver.yml
.
For log rotation, see IPLM Server logging.
Common section
Setting | Default | Description |
---|---|---|
maxQueuedRequests |
1024 |
The maximum number of requests to queue before blocking the acceptors |
idleThreadTimeout |
1 minute |
The amount of time a worker thread can be idle before being stopped |
shutdownGracePeriod |
30 seconds |
The maximum time to wait for the server to cleanly shutdown before forcibly terminating it |
gzip sub section
Setting | Default | Description |
---|---|---|
enabled |
true |
If true: - requests with 'gzip' in the 'Accept-Encoding' header will have their response entities compressed - requests with 'gzip' in the 'Content-Encoding' header will have their request entities decompressed |
minimumEntitySize |
256 bytes |
Response entities under this size are not compressed |
bufferSize |
8 KiB |
The size of the buffer to use when compressing |
Application section
Setting | Default | Description |
---|---|---|
minThreads |
8 |
The minimum number of threads to keep alive in the thread pool |
maxThreads |
1024 |
The maximum number of threads the thread pool is allowed to grow |
ApplicationConnectors section
Setting | Default | Description |
---|---|---|
bindHost |
HOST |
The hostname to bind to |
idleTimeout
|
30 seconds | The maximum idle time for a connection. If the client does not send any data to the server after this period of time, the server will close its socket on its end of the connection, possibly causing a broken pipe error on the client if the client later writes to its socket. |
port |
8080 |
The TCP/IP port on which to listen for incoming connections |
acceptorThreads |
100 |
The number of worker threads dedicated to accepting connections. Can make this bigger if its ok to have queries in the wait queue, as per SLA. |
selectorThreads |
100 |
The number of worker threads dedicated to sending and receiving data. Should be tuned using traditional web-server tuning methods (make sure there is no wait queue overflow with all cores busy, increase wait queue until it breaks the SLA, then add hardware) |
Neo4j credentials section
Setting | Default | Description |
---|---|---|
databaseName |
None |
Specify a database name to minimize performance overhead. If no database is provided, the database driver has to send an extra request to the server to figure out what the default database is. |
httpClient section
Setting | Default | Description |
---|---|---|
maxconnections |
1024 | The maximum number of concurrent open connections. |
maxConnectionsPerRoute |
1024 | The maximum number of concurrent open connections per route. |
timeout |
500 ms |
The maximum idle time for a connection, once established. Recommended value: 10 minutes |
connectionTimeout |
500 ms |
The maximum time to wait for a connection to open. Recommended value: 2 seconds |
connectionRequestTimeout |
500 ms |
The maximum time to wait for a connection to be returned from the connection pool. Recommended value: 2 seconds |
timeToLive |
1 hour | The maximum time a pooled connection can stay idle (not leased to any thread) before it is shut down. |
keepAlive |
0 ms | The maximum time a connection will be kept alive before it is reconnected. If set to 0, connections will be immediately closed after every request/response. |
validateAfterInactivityPeriod |
0 ms | The maximum time before a persistent connection is checked to remain active. If set to 0, no inactivity check will be performed. |
retries |
0 | The number of times to retry failed requests. |
userAgent |
AGENT | The 'User-Agent' header to send with requests. |
gzipEnabled |
true | If true: adds an 'Accept-Encoding: gzip' header to all requests enables automatic gzip decoding of responses |
gzipEnabledForRequests |
true | If true: adds a 'Content-Encoding: gzip' header to all requests enables automatic gzip encoding of requests |
chunkedEncodingEnabled |
true | Enables the use of chunked encoding for requests |
Security section
Setting | Default | Description |
---|---|---|
accessTokenExpirationTime |
0 |
Time an access token can be idle before it is invalidated. If set to 0, access tokens never expire. You must change the Perforce IPLM
accessTokenExpirationTime attribute from the default setting to a setting that meets the requirements of the installing organization. The default may not be in compliance with some industry standards or best practices. |
geofencing |
false |
As a server administrator, you can globally enable or disable the enforcement of geofencing at run time. Set to true if you want geofencing enabled. When enabled, allowed/restricted geographic locations (geos) will be included when considering user permissions. |
logUsername |
false |
The logging option controls if user names are included in logging output or not. Default is false, which means that the user names will be obscured from log events. Where possible, a user ID will be displayed instead. Otherwise, “…” will be shown in place of the user name. |
passwordValidationPattern |
none |
Set the password policy via a regular expression. Define the minimum length of the password and the minimum number of types of characters (special, upper and lower case letters, numbers). The pattern must be included within single quotes as shown in the example. Double quotes can be used but any backslashes need an additional backslash added (\\d instead of \d). Patterns are interpreted by Example: passwordValidationPattern: '^(?=.*[\d])(?=.*[!@#$%^&*])[\w!@#$%^&*]{12,32}$' |
passwordValidationDescription |
none |
Enter a description that describes the password policy to the user. Example: passwordValidationDescription: Must contain upper and lower case, digits and special characters, between 12 and 32 characters long. |
External security subsection
Setting | Default | Description |
---|---|---|
script |
SCRIPT |
External authentication script |
scriptTimeout |
10 seconds | External authentication script timeout |
External synchronization subsection
Setting | Default | Description |
---|---|---|
script |
SCRIPT |
External synchronization script |
scriptTimeout |
10 seconds | External synchronization script timeout |
Redis section
Setting | Default | Description |
---|---|---|
hosts |
"demo2:6379" |
Redis hosts. |
sentinelMaster |
MASTER |
Redis Sentinel master. |
timeout |
2 seconds |
Redis timeout. |
Prometheus metrics section
Setting | Default | Description |
---|---|---|
enabled |
false |
Whether or not to enable the Prometheus exporter server |
port |
2002 |
Port of the Prometheus exporter server |
IPLM Server logging levels
The logging output becomes more verbose with each option.
-
WARN logs warning messages.
-
INFO logs info messages.
-
DEBUG logs messages helpful for debugging.
piserver.yml example
# -------------------------------------------------- # Pi Server configuration # -------------------------------------------------- # -------------------------------------------------- # IMPORTANT: # This file was migrated from a legacy configuration file # This notice should be removed when this file is modified manually # -------------------------------------------------- # -------------------------------------------------- # Server # -------------------------------------------------- server: # -------------------------------------------------- # Common # -------------------------------------------------- # The maximum number of requests to queue before blocking the acceptors maxQueuedRequests: 1024 # The amount of time a worker thread can be idle before being stopped idleThreadTimeout: 1 minute # The maximum time to wait for the server to cleanly shutdown before forcibly terminating it shutdownGracePeriod: 30 seconds gzip: # If true: # - requests with 'gzip' in the 'Accept-Encoding' header will have their response entities compressed # - requests with 'gzip' in the 'Content-Encoding' header will have their request entities decompressed enabled: true # Response entities under this size are not compressed minimumEntitySize: 256 bytes # The size of the buffer to use when compressing bufferSize: 8 KiB # -------------------------------------------------- # Application # -------------------------------------------------- # The minimum number of threads to keep alive in the thread pool minThreads: 8 # The maximum number of threads the thread pool is allowed to grow maxThreads: 1024 applicationConnectors: - type: http # The hostname to bind to #bindHost: HOST # The TCP/IP port on which to listen for incoming connections port: 8080 # The number of worker threads dedicated to accepting connections #acceptorThreads: N # The number of worker threads dedicated to sending and receiving data #selectorThreads: N # The size of the TCP/IP accept queue for the listening socket #acceptQueueSize: N # The size of the header field cache #headerCacheSize: 512 bytes # The size of the buffer into which response content is aggregated before being sent to the client #outputBufferSize: 32 KiB # The maximum size of a request header #maxRequestHeaderSize: 8 KiB # The maximum size of a response header #maxResponseHeaderSize: 8 KiB # The size of the per-connection input buffer #inputBufferSize: 8 KiB # The maximum idle time for a connection #idleTimeout: 30 seconds # The minimum size of the buffer pool #minBufferPoolSize: 64 bytes # The maximum size of the buffer pool #maxBufferPoolSize: 64 KiB # The increment by which the buffer pool should be increased #bufferPoolIncrement: 1 KiB # Whether or not SO_REUSEADDR is enabled on the listening socket #reuseAddress: true # Whether or not to add the 'Server' header to each response #useServerHeader: false # Whether or not to add the 'Date' header to each response #useDateHeader: true # -------------------------------------------------- # Admin # -------------------------------------------------- adminMinThreads: 1 adminMaxThreads: 64 adminConnectors: - type: http port: 8081 # -------------------------------------------------- # Neo4j # -------------------------------------------------- neo4j: # URI of the Neo4j server/proxy uri: "http://localhost:7474/pi" # Neo4j credentials #username: USERNAME #password: PASSWORD httpClient: # The maximum number of concurrent open connections #maxConnections: 1024 # The maximum number of concurrent open connections per route #maxConnectionsPerRoute: 1024 # The maximum idle time for a connection, once established #timeout: 500 ms # The maximum time to wait for a connection to open #connectionTimeout: 500 ms # The maximum time to wait for a connection to be returned from the connection pool #connectionRequestTimeout: 500 ms # The maximum time a pooled connection can stay idle (not leased to any thread) before it is shut down #timeToLive: 1 hour # The maximum time a connection will be kept alive before it is reconnected # If set to 0, connections will be immediately closed after every request/response #keepAlive: 0 ms # The maximum time before a persistent connection is checked to remain active # If set to 0, no inactivity check will be performed #validateAfterInactivityPeriod: 0 ms # The number of times to retry failed requests #retries: 0 # The 'User-Agent' header to send with requests #userAgent: AGENT # If true: # - adds an 'Accept-Encoding: gzip' header to all requests # - enables automatic gzip decoding of responses #gzipEnabled: true # If true: # - adds a 'Content-Encoding: gzip' header to all requests # - enables automatic gzip encoding of requests #gzipEnabledForRequests: true # Enables the use of chunked encoding for requests #chunkedEncodingEnabled: true # -------------------------------------------------- # Security # -------------------------------------------------- security: # Time an access token can be idle before it is invalidated # If set to 0, access tokens never expire accessTokenExpirationTime: 0 seconds externalSecurity: # External authentication script #script: SCRIPT # External authentication script timeout scriptTimeout: 10 seconds externalSync: # External synchronization script #script: SCRIPT # External synchronization script timeout scriptTimeout: 30 seconds # -------------------------------------------------- # Redis (events) # -------------------------------------------------- redis: # Redis hosts hosts: "demo2:6379" # Redis Sentinel master #sentinelMaster: MASTER # Redis timeout timeout: 2 seconds # -------------------------------------------------- # Prometheus metrics # -------------------------------------------------- prometheus: # Whether or not to enable the Prometheus exporter server enabled: true # Port of the Prometheus exporter server port: 2002 # -------------------------------------------------- # Access log # -------------------------------------------------- accessLogFile: "/var/log/mdx-piserver/piserver-access.log" # -------------------------------------------------- # Logging # -------------------------------------------------- logging: level: INFO appenders: - type: file currentLogFilename: /var/log/mdx-piserver/piserver.log archive: true archivedLogFilenamePattern: /var/log/mdx-piserver/piserver-%d.log archivedFileCount: 5
Related information