Versions Compared

Key

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

Table of Contents

Logging settings

WCS Core logging is handled by the log4j.properties config and a number of settings in flashphoner.properties:

Logging settings in flashphoner.properties

Setting

Default value

client_log_level

INFO

client_dump_level

0

enable_extended_logging

true

...

  • client_logs - logs recorded on the server side that correspond to the WCS server client session (client logs).
  • server_logs - general logs recorded on the server side.

Logging settings in log4j.properties

This is a standard config of the log4j format.

 

Settings description

Attribute

Value

Description

log4j.rootLogger

info, stdout, fAppender

Root logger.

info - INFO logging level. More detailed levels, for example, DEBUG and TRACE, and less detailed, for example, ERROR are available.

stdout, fAppender - set how and where logs are output.

log4j.logger.incoming.Publication

info, incoming_publication

RTMFP-SIP calls statistics logger for the traffic incoming from a SIP server.

info - logging level
incoming_publication - sets how and where logs are output.

log4j.logger.outgoing.Publication

info, outgoing_publication

RTMFP-SIP calls statistics logger for the traffic outgoing to a SIP server.

info - logging level
outgoing_publication - sets how and where logs are output.

log4j.logger.pushLogs.FlashphonerHandler

Not used

Not used

log4j.additivity.incoming.Publication

false

Do not add these logs to the general log, recording them as individual logs instead

log4j.additivity.outgoing.Publication

false

Do not add these logs to the general log, recording them as individual logs instead

log4j.logger.sipMessages

DEBUG

Put inbound and outgoing SIP messages to the log

log4j.appender.stdout

org.apache.log4j.ConsoleAppender

Output logs to stdout

log4j.appender.fAppender

org.apache.log4j.DailyRollingFileAppender

Output logs to fAppender

log4j.appender.incoming_publication

org.apache.log4j.DailyRollingFileAppender

Output RTMFP statistics to incoming_publication

log4j.appender.outgoing_publication

org.apache.log4j.DailyRollingFileAppender

Output RTMFP statistics to outgoing_publication

log4j.appender.clientLog

org.apache.log4j.DailyRollingFileAppender

Not used

Logging settings hot swapping

WCS automatically catches changes made to the log4j.properties file. This is convenient for debugging purposes and to receive additional logs without restarting the server. For instance, when you need to enable more detailed logs and change the output format of logs. However, for higher reliability during production, we recommend restarting the WCS server nevertheless.

Client logs

Client logs are logs on the server that are relevant to a web client session. Client logs are only recorded to client_logs if the enable_extended_logging=true setting is enabled. You can configure the logging detail level using the client_log_level setting that can assume the following values: ERROR, INFO, DEBUG, TRACE.

...

Code Block
languagebash
themeRDark
client_logs
---- 2018-05-16
-------- 84gij60a6u3ni7docsr1di1l5b-15-06-59
------------ flashphoner.log
------------ client-84gij60a6u3ni7docsr1di1l5b-2018.05.16.15.07.26-1526458046646.report
------------ MediaDump-85d65b00-639e-4a7e.31002-31004-31006-31008.pcap


flashphoner.log log

Client logs are recorded to client_logs by dates. For each date, a directory is created with the name formatted as YYYY-MM-DD, for instance, 2018-05-16.
When the web client establishes connection to the server, a folder for the current client session is created inside the date folder, for example, 84gij60a6u3ni7docsr1di1l5b-15-06-59, where 84gij60a6u3ni7docsr1di1l5b is a session identifier, 15 is hours, 06 is minutes, 59 is seconds. In the same directory the flashphoner.log file is recorded, which contains only those server events that are relevant to this specific client session. Hence, we see when the client connected to the server, and what logs were recorded for this client's session.

client-report log

This is an additional client log. The web client has a special WCS JavaScript API function 'pushLog'. This function sends to the WCS server logs recorded on the browser side. All logs received from the web client using pushLog are saved on the server. When the web client ends a session with the WCS server, the received logs are recorded to the client-84gij60a6u3ni7docsr1di1l5b-2018.05.16.15.07.26-1526458046646.report file, where 84gij60a6u3ni7docsr1di1l5b is a session identifier, 2018 is year, 05 is month, 26 is day, 15 is hours, 07 is minutes, 26 is seconds, 1526458046646 is milliseconds.

Media traffic dumps

If in the flashphoner.properties settings file a non-zero value is set for the client_dump_level setting, a dump session is additionally recorded for a client:

...

Traffic is recorded using tcpdump, if this utility is installed in the system.

Server logs

WCS Core records general server logs to logs/server_logs

...

Therefore, server logs offer general information about server operation. You can receive more detailed information in logs that are recorded individually for each client session.

CDR logs

Сall Detail Record is a SIP calls log.

...

Code Block
languagebash
themeRDark
3000;3001;f294f6116bf2cc4c725f20457ed76e5b@192.168.56.2;2014-11-21 15:01:37; 2014-11-21 15:01:41; 2014-11-21 15:02:45;64;ANSWERED

Field

Description

src

Caller

dst

Callee

cid

Call identifier

start

Call start (date and time).

answer

Date and time the call is answered by the subscriber or the SIP side.

end

Date and time the call ended.

billsec

Time in seconds between 'answer' and 'end'.

disposition

Call result: ANSWERED, NO_ANSWER, BUSY, FAILED.

MDR logs

Message Detail Record is a SIP messages log.

...

Code Block
languagebash
themeRDark
Fri Dec 26 15:26:16 NOVT 2014,null,A006,A005,RECEIVED

Field

Description

date

Date and time of the message

msgId

Message identifier. Is present only in message/cpim messages if isImdnRequired=true (see Web Call Server - Call Flow documentation, parameters of the passed messages in the sendMessage method are described there).

from

SIP from

to

SIP to

disposition

Message result: RECEIVED, SENT, FAILED.

RECEIVED - the message is received.

SENT - the message is sent.

FAILED - there were an error while sending the message.

You can also gather any message statistics and their statuses you need using WCS REST API. See Web Call Server - Call Flow documentation that describes all methods and data sets that WCS sends via REST when it processes messages.

SDR logs

Stream Detail Record is a stream publishing and playing session logs.

...

Code Block
languagebash
themeRDark
2015-11-11 08:36:13;Flash;stream-Bob;5c2d75c0-7d87-421d-aa93-2732c48d8eaa;00:00:48;UNPUBLISHED;;PUBLISH;3;

Field

Description

end

Date and time the session ended

mediaProvider

The media used in WCS JavaScript API: WebRTC, Flash

name

Name of the published / played stream

mediaSessionId

Media session identifier

duration

Duration of the session

disposition

Session result: UNPUBLISHED, STOPPED, FAILED

UNPUBLISHED - publishing of the stream was stopped

STOPPED - playing of the stream was stopped

FAILED - incorrect session end

info

If disposition==FAILED, this field contains the description of the reason

type

PUBLISH if publishing the stream

SUBSCRIBE if playing the stream

subscribers

The number of subscribers in case of publishing the stream; 0 if playing the stream

CONNDR logs

Connection Detail Record is a WebSocket sessions log.

...

Code Block
languagebash
themeRDark
2018-04-25 19:29:08;/5.44.168.45:52199/95.191.131.64:8443;DISCONNECTED;Normal disconnect;17;

Field

Description

end

Data and time the session ended

mediaSessionId

Media session identifier

disposition

Session result: DISCONNECTED, FAILED

DISCONNECTED - the session ended by client's initiative

FAILED - incorrect session end

info

Contains information about the session end

duration

Duration of the session