Flux - Logging/Metrics

Flux - Logging/Metrics

Flux provides rich, structured logging to track every aspect of data synchronization — including timing, throughput, retries, file operations, and queue performance. This observability is delivered via two key log streams:

  • metricinfo.log: Captures metrics about operations (timing, size, IO).

  • metricevent.log: Captures lifecycle events (start, end, file state changes).

All logs follow a structured JSON format with embedded context to support downstream indexing, alerting, and visualization.

Log Overview

Log Name

Description

Path

Collected To

Configuration Source

Log Name

Description

Path

Collected To

Configuration Source

metricevent.log

Informative lifecycle events (start, end, failure, etc.)

log/metricevent.log

Shared configuration (per node)

log4jXpolog.properties

metricinfo.log

Detailed operational metrics

log/metricinfo.log

Shared configuration (per node)

log4jXpolog.properties

 

Standard Context Fields

Included in all events and metrics:

Field

Description

Field

Description

scope

Logical name of operation (xplg.flux.data-sync)

appTags

App tags associated with the task (if any)

task.id

Unique task ID from configuration

task.name

Task name from configuration

job.id

Runtime job instance ID

job.name

Human-readable job name

nodes.source.id

Source agent ID (account ID)

nodes.source.name

Source agent name (account name)

 

File-related events may include:

  • directory

  • filename

  • file.length

 

metricinfo Fields

Each metric provides structured insight into performance, behavior, and system usage.

Name

Metric Key

Extra Context

Unit

Relevant To

Description

Name

Metric Key

Extra Context

Unit

Relevant To

Description

Time of data sync

process.time

milliseconds

Target/Agent

Total time to complete a sync task - Full duration of the data sync task, measured from start to finish. This is the primary indicator of job duration and is essential for performance monitoring.

Time waiting in queue

process.wait.time

milliseconds

Target/Agent

Delay due to queue limitations - Time a sync task spent waiting in queue before execution. High values suggest delays or system backpressure.

Bytes received from network

system.network.bytes.read

sessionId

bytes

Target

Total bytes read from the remote connection

Read latency from network

system.network.read.cpu.time

sessionId

milliseconds

Target

Time spent waiting for a network packet

Bytes sent over network

system.network.bytes.write

sessionId

bytes

Target

Total bytes sent per request

Write latency to network

system.network.write.cpu.time

sessionId

milliseconds

Target

Time spent writing a packet to the network

File block received (write)

system.io.bytes.write

start_pos, end_pos

bytes

Target

Amount of data written to the repository per block - Summing this value gives the exact volume of data successfully transferred and stored.

File block read (source)

system.io.bytes.read

start_pos, end_pos

bytes

Agent

Amount read per file block

File read time (IO)

system.io.read.cpu.time

start_pos, end_pos, data_length

milliseconds

Agent

Time to read data block from disk

File write time (IO)

system.io.write.cpu.time

start_pos, end_pos, data_length

milliseconds

Target

Time to write data block to disk

Queue waiting time

system.queue.cpu.waitingtime

sessionId

milliseconds

Agent

Time task waited on an internal queue

Example: metricinfo Log Record

[2025-06-01 09:50:00,074] {"metric":"process.time","startTimeUnixNano":1750067400026000000,"timeUnixNano":1750067400074000000,"value":48,"attributes":{"scope":"xplg.flux.data-sync","task.id":"1749729871595","task.name":"data sync: manual test task","nodes.source.name":"agent1","nodes.source.id":"","job.name":"data sync: test task","job.id":"1749729871595_test_datasync-agent_1750067400026","appTags":""}}

 

metricevent Fields

Name

Log Event

Extra Context

Description

Name

Log Event

Extra Context

Description

Data Sync Start

event.data-sync.start

Emitted at the start of a data sync task

Data Sync End

event.data-sync.end

Emitted at the completion of a data sync task

File Sync

event.data-sync.file

File Context

Indicates the outcome of a file: NEW, NOT_CHANGE, UPDATE, DELETE, FAIL, CHECKSUM, COMPLETED

File Sync State Change

event.data-sync.file.state

File Context

Indicates the outcome of a file: NEW, NOT_CHANGE, UPDATE, DELETE, FAIL, CHECKSUM, COMPLETED

Example: metricevent Log Record

[2025-06-01 09:51:00,072] {"event":"event.data-sync.end","eventName":"Events","timeUnixNano":1750067460072000000,"attributes":{"scope":"xplg.flux.data-sync","task.id":"1749729871595","task.name":"data sync: test task","nodes.source.name":"agent1","nodes.source.id":"","job.name":"data sync: test task test_datasync-agent","job.id":"1749729871595_test_datasync-agent_1750067460022","appTags":""}}