Versions Compared

Key

  • This line was added.
  • This line was removed.
  • Formatting was changed.

...

To apply any configuration changes, backend server must be restarted.

Metrics storage DB connection setup

Influx BD connection setup

The following parameter in wcsoam.properties file should be set to allow to store metrics to Influx DB

Code Block
themeRDark
influxdb_enabled=true

...

Code Block
themeRDark
influxdb_database=wcs_oam
influxdb_user=root
influxdb_password=root

It is recommended to connect to By default, WCS OAM connects to Influx DB via UDP if WCS server is under high load, and incoming metrics traffic is big:

Code Block
themeRDark
influxdb_udp=true
influxdb_udp_port=8089

...

In this case, metric values can be lost. To escape loss, metric values can be passed using HTTP POST query as follows

Code Block
languagejs
themeRDark
POST /write?u=root&p=root&db=wcs_oam&rp=default&precision=n&consistency=one HTTP/1.1

3-5062030c-9def-49c2-a89e-639d664ab806 AUDIO_CODEC=102i,AUDIO_LOST=3795015i,AUDIO_RATE=137776i,AUDIO_SYNC=123432141899i,seq=26558i 1562263828767000000

Metrics writing can be switched to HTTP with the following parameter

Code Block
themeRDark
influxdb_udp=false

Anyway, metric values are read from Influx DB using HTTP GET query as follows

Code Block
languagejs
themeRDark
GET /query?u=root&p=root&db=wcs_oam&q=SELECT+*+FROM+%221-89dc5510-a198-11e9-a049-030fe6b5675c%22+order+by+time+desc+limit+10+offset+0 HTTP/1.1

Timescale DB connection setup

The following parameter in wcsoam.properties file should be set to allow to store metrics to Timescale DB

Code Block
themeRDark
metric_store=timescale

DB URL and access parameters should be set for connection setup

Code Block
themeRDark
timescale.url=jdbc:postgresql://127.0.0.1:5432/wcsstat
timescale.username=wcsoam
timescale.password=wcsoam

Connection tuning

Metric values batch size to write to DB can be set with the following parameter

Code Block
themeRDark
timescale_batch_size=1000

In this case metrics will be written to DB in batches of 1000 values.

Stream history and data acquisition settings DB connection setup

History storage support is enabled with the following parameter

...

By default, queue size is 3000 records.

SQL queries logging

If necessary, SQL queries logging can be enabled for debug purposes using the following parameters in wcsoam.properties file

Code Block
themeRDark
logging.level.org.hibernate.SQL=debug
logging.level.org.hibernate.type.descriptor.sql=trace

Note that metrics store to TimescaleDB will also be logged in this case.

WCS interaction setup

By default, backend server listens to WCS server connections for metrics acquisition on TCP port 7777. This port can be changed with the following parameter

...

Connection authentication key should be set with the following parameter

Code Block
themeRDark
secretsecurity_key=123456789

By default, authentication key is set to 123.

...

Backend server allows client connections using HTTPS and Secure Websocket. SSL is configi=ured configured with the following parameters

Code Block
themeRDark
server.ssl.key-store-type=JKS
server.ssl.key-store=file:/usr/local/FlashphonerWebCallServerOAM/conf/wss.jks
server.ssl.key-store-password=password
server.ssl.key-alias=selfsigned

Where:

  • server.ssl.key-store-type - SSL certificate storage type, ; only JKS only is supported
  • server.ssl.key-store - SSL certificate storage location
  • server.ssl.key-store-password - SSL certificate storage password
  • server.ssl.key-alias - domain name

...