Class: Logging

@proceed/machine.Logging

Class for initializing and getting a logger

Classes

Logger
RotationUtils

Methods

clearProcessLogs(processID)

Sets the currentLogs variable in the logging_meta_data for a given process to 0

Parameters:
Name Type Description
processID string

the process for which the operation is to be performed

Source:

clearProcessTables(processID)

Sets the tables variable in the logging_meta_data for a given process to 0

Parameters:
Name Type Description
processID string

the process for which the operation is to be performed

Source:

(async) clearStandardLogs()

Sets the standardLogs variable in the logging_meta_data to 0 and move monitoring to monitoring_old

Source:

decreaseProcessTables(processID, number)

Descreases the tables counter in the logging_meta_data by a given number

Parameters:
Name Type Description
processID string

the process for which the operation is to be performed

number number

the number by which the tables counter is to be decreased

Source:

deleteLoggingTable(name)

Deletes a logging table with a specific name

Parameters:
Name Type Description
name string

The name of the table that is to be deleted.

Source:
Requires:
  • module:{module:@proceed/system.Data}

(async) getInstanceLogs(processId, instanceId, limit)

Parameters:
Name Type Description
processId string

The ID of the process

instanceId string

the ID of the specific instance of the process for which the logs are to be returned

limit number

how many logs we want to get

Source:

getLogger(confObject)

Factory method creating a logger

Parameters:
Name Type Description
confObject object

An object containing all configuration parameters for the logger

Source:
Returns:

a logger

(async) getProcessLogTables(processID, limit)

Returns all process logs across all tables

Parameters:
Name Type Description
processID string

The ID of the process for which the logs are to be returned

limit number

how many logs we want to get

Source:

(async) getStandardLogTables(limit) → {object}

Returns the last [limit] standard logs

Parameters:
Name Type Default Description
limit number 100

how many logs we want to get

Source:
Returns:

standard logs

Type
object

init()

Initializes all things necessary for the Logging

  • Provides the data module to the rotation utils
  • Creates the config data file if it doesn't exist
  • starts the log rotation
Source: