Skip to main content

Logging and auditing

OpenCDMP backend services use a uniform logging infrastructure built on Logback (SLF4J). Every service produces two separate log streams: a troubleshooting log for operational diagnostics and an audit log for recording user activity. This page explains how each stream works, how to configure them, and what events the audit system captures.


Log files

Each backend service writes to two rolling log files:

FilePurposeDefault path
logging.logOperational diagnostics — DEBUG/WARN/ERROR output from the application and its dependencies/logs/logging.log
auditing.logUser activity trail — one line per audited API call, fixed at INFO level/logs/auditing.log

Both files roll by date and size. Each rolled file is named with a timestamp and index (e.g., logging.2025-11-01.0.log). Up to 15 rolled files are retained per appender; files larger than 100 MB roll immediately.


Log entry format

Troubleshooting log

%date{ISO8601} [%thread] %-5level %logger{36} [%X{req.id}] - %message%n

Example line:

2025-11-01T14:23:01.456+0200 [http-nio-8080-exec-3] WARN o.o.service.PlanService [a1b2c3d4] - Plan not found: id=f8e7...

Fields:

FieldDescription
%date{ISO8601}Timestamp in ISO 8601 format
[%thread]Thread name that handled the request
%-5levelLog level, left-padded to 5 characters (DEBUG, INFO, WARN, ERROR)
%logger{36}Logger class name, truncated to 36 characters
[%X{req.id}]Request correlation ID from MDC — use this to trace a single request across all log lines
%messageLog message

Audit log

%date{ISO8601} - %X{req.id} - %message%n

Each audit entry is a single line containing a timestamp, request ID, and a JSON payload under the d key. Example (formatted for readability):

2026-04-15 16:15:59,048 - da05effb-f63d-4555-8ff6-3042eb2cdb15 - {
"d": {
"Plan_Lookup": 5001,
"usr": {
"usr.subject": "8a0d0e1f-2723-4ac2-8056-8f395f8789c7",
"usr.name": "dmproot dmproot"
},
"id": "71f92236-07a4-4c4d-ad0c-7104c87628ce",
"invoker": {
"req.requestURI": "/api/plan/71f92236-07a4-4c4d-ad0c-7104c87628ce",
"req.remoteAddr": "0:0:0:0:0:0:0:1",
"req.remoteUser": "dmproot dmproot",
"req.method": "GET",
"req.requestURL": "http://localhost:8081/api/plan/71f92236-07a4-4c4d-ad0c-7104c87628ce",
"req.scheme": "http",
"req.userAgent": "Mozilla/5.0 ..."
},
"fields": {
"empty": false,
"fields": ["id", "blueprint.definition.sections.id"]
},
"ts": "2026-04-15T13:15:59.047159200Z"
}
}

Fields:

FieldDescription
TimestampLocal server time in yyyy-MM-dd HH:mm:ss,SSS format
Request IDUUID correlating this entry with logging.log lines from the same request
dEnvelope object containing all audit context
d.<EventName>The audit event name as the key, its numeric ID as the value (e.g., "Plan_Lookup": 5001)
d.usr.usr.subjectKeycloak subject UUID of the authenticated user (null for anonymous requests)
d.usr.usr.nameDisplay name of the authenticated user
d.invokerHTTP request metadata: URI, method, remote address, user agent
d.fieldsField projection requested by the client (the f= query parameters)
d.tsUTC timestamp of the audit event in ISO 8601 format
Additional keysEvent-specific context — e.g., id for single-entity lookups, lookup for query parameters, model for persist payloads

The request ID appears in both files, making it straightforward to correlate an audit entry with any troubleshooting lines produced by the same API call.

Anonymous API calls (no authenticated user) omit the usr block. The d.invoker block is always present.


Configuration

Logback is configured in web/src/main/resources/logging/logback.xml within each service. Two properties are injected from the Spring environment at startup:

PropertyDefaultDescription
LOGGING_PATH/logsDirectory where logging.log and auditing.log are written
LOGGING_DEFAULT_LOG_LEVELWARNLog level applied to the framework loggers and the root logger for troubleshooting output

Set these as environment variables or Spring Boot application properties to change the output path or increase verbosity (e.g., LOGGING_DEFAULT_LOG_LEVEL=DEBUG during development).

Configured loggers

LoggerLevel sourceAppender
org.springframework.webLOGGING_DEFAULT_LOG_LEVELlogging.log
org.hibernateLOGGING_DEFAULT_LOG_LEVELlogging.log
gr.citeLOGGING_DEFAULT_LOG_LEVELlogging.log
org.springframework.data.elasticsearch.client.WIRELOGGING_DEFAULT_LOG_LEVELlogging.log
auditINFO (fixed)auditing.log
rootINFOlogging.log

The audit logger is always at INFO and is not affected by LOGGING_DEFAULT_LOG_LEVEL.


Troubleshooting log levels

Application code uses the LoggerService wrapper (from gr.cite.tools.logging) around a standard SLF4J logger. The following levels are used:

LevelWhen used
DEBUGEntry into a service method or controller action — includes entity type, ID, and requested field set. Useful during development; suppressed in production by the default WARN threshold.
WARNUnexpected but recoverable conditions. Emitted by the root logger and framework loggers when LOGGING_DEFAULT_LOG_LEVEL=WARN.
ERRORUnhandled exceptions and critical failures.

Structured log entries are produced using MapLogEntry to attach key-value context:

// Simple string message
logger.debug("querying {}", Plan.class.getSimpleName());

// Structured entry with key-value pairs
logger.debug(new MapLogEntry("retrieving " + Plan.class.getSimpleName())
.And("id", id)
.And("fields", fieldSet));

Audit trail

How it works

The AuditService (from gr.cite.tools.auditing) is injected into every REST controller. At the end of each endpoint method — after the main operation succeeds — the controller calls auditService.track(...) with an event identifier and the relevant context parameters. The audit service writes one line to the audit logger, which routes to auditing.log.

Audit calls are placed at the end of successful controller methods only. They are not triggered on authorization failures or exceptions, so the audit log reflects completed, authorized operations.

Call patterns

Single parameter:

this.auditService.track(AuditableAction.Plan_Delete, "id", id);

Multiple parameters:

this.auditService.track(AuditableAction.Plan_Lookup, Map.ofEntries(
new AbstractMap.SimpleEntry<String, Object>("id", id),
new AbstractMap.SimpleEntry<String, Object>("fields", fieldSet)
));

Audit event reference

All audit events are defined in AuditableAction.java in the main API service. Each event has a numeric ID and a string name. The name appears in auditing.log.

Plans (5000–5022)

Event IDEvent nameTrigger
5000Plan_QueryList/search Plans
5001Plan_LookupRetrieve a single Plan by ID
5002Plan_PersistCreate or update a Plan
5003Plan_DeleteDelete a Plan
5004Plan_CloneClone a Plan
5005Plan_PersistNewVersionCreate a new version of a Plan
5006Plan_Assign_UsersAssign users to a Plan
5007Plan_RemoveUserRemove a user from a Plan
5008Plan_Invite_UsersSend invitations to collaborate on a Plan
5009Plan_Invite_AcceptAccept a Plan collaboration invitation
5010Plan_PublicQueryQuery publicly visible Plans
5011Plan_ExportExport a Plan to a file format
5012Plan_PublicLookupRetrieve a single public Plan by ID
5013Plan_FinalizeFinalize a Plan
5014Plan_Undo_FinalizeUndo finalization of a Plan
5015Plan_ValidateValidate a Plan
5016Plan_GetXmlExport a Plan as XML
5017Plan_ImportImport a Plan from XML
5017Plan_GetPublicXmlExport a public Plan as XML
5018Plan_ExportPublicExport a public Plan to a file format
5019Plan_PublicCloneClone a public Plan
5020Plan_SetStatusChange a Plan's workflow status
5021Plan_Creation_From_RequestCreate a Plan from a Plan update request
5022Plan_GetActiveUsersList active users of a Plan

Descriptions (6000–6015)

Event IDEvent nameTrigger
6000Description_QueryList/search Descriptions
6001Description_LookupRetrieve a single Description by ID
6002Description_PersistCreate or update a Description
6003Description_DeleteDelete a Description
6004Description_PublicQueryQuery publicly visible Descriptions
6005Description_PublicLookupRetrieve a single public Description by ID
6006Description_PersistStatusChange a Description's workflow status
6007Description_UploadFieldFilesUpload files attached to Description fields
6008Description_GetFieldFileDownload a file attached to a Description field
6009Description_ValidateValidate a Description
6010Description_GetDescriptionSectionPermissionsRetrieve section-level permissions for a Description
6011Description_UpdateDescriptionTemplateUpdate the template linked to a Description
6012Description_GetXmlExport a Description as XML
6013Description_GetPublicXmlExport a public Description as XML
6014Description_PersistMultipleCreate or update multiple Descriptions
6015Description_CloneClone a Description

Blueprints (3000–3011)

Event IDEvent nameTrigger
3000PlanBlueprint_QueryList/search Plan Blueprints
3001PlanBlueprint_LookupRetrieve a single Blueprint by ID
3002PlanBlueprint_PersistCreate or update a Blueprint
3003PlanBlueprint_DeleteDelete a Blueprint
3004PlanBlueprint_CloneClone a Blueprint
3005PlanBlueprint_PersistNewVersionCreate a new version of a Blueprint
3006PlanBlueprint_GetXmlExport a Blueprint as XML
3007PlanBlueprint_ImportImport a Blueprint from XML
3008PlanBlueprintType_QueryList Blueprint types
3009PlanBlueprintType_LookupRetrieve a single Blueprint type
3010PlanBlueprintType_PersistCreate or update a Blueprint type
3011PlanBlueprintType_DeleteDelete a Blueprint type

Description templates (8000–8007)

Event IDEvent nameTrigger
8000DescriptionTemplate_QueryList/search Description Templates
8001DescriptionTemplate_LookupRetrieve a single Template by ID
8002DescriptionTemplate_PersistCreate or update a Template
8003DescriptionTemplate_DeleteDelete a Template
8004DescriptionTemplate_CloneClone a Template
8005DescriptionTemplate_PersistNewVersionCreate a new version of a Template
8006DescriptionTemplate_GetXmlExport a Template as XML
8007DescriptionTemplate_ImportImport a Template from XML

Description template types (1000–1003)

Event IDEvent nameTrigger
1000DescriptionTemplateType_QueryList Description Template types
1001DescriptionTemplateType_LookupRetrieve a single Template type
1002DescriptionTemplateType_PersistCreate or update a Template type
1003DescriptionTemplateType_DeleteDelete a Template type

Users (11000–11017)

Event IDEvent nameTrigger
11000User_QueryList/search users
11001User_LookupRetrieve a single user by ID
11002User_PersistCreate or update a user
11003User_DeleteDelete a user
11004User_LookupByEmailLook up a user by email address
11005User_ExportCsvExport user list as CSV
11006User_PersistRolesUpdate a user's roles
11007User_LanguageMineRetrieve the current user's language preference
11008User_TimezoneMineRetrieve the current user's timezone preference
11009User_CultureMineRetrieve the current user's culture preference
11010User_MergeRequestRequest to merge two user accounts
11011User_MergeConfirmConfirm a user account merge
11012User_RemoveCredentialRequestRequest to remove a user credential
11013User_RemoveCredentialConfirmConfirm removal of a user credential
11014User_PlanAssociatedQueryQuery Plans associated with a user
11015User_AllowMergeAccountAllow another account to merge into this user
11016User_InviteToTenantInvite a user to a tenant
11017User_InviteToTenantConfirmConfirm a tenant invitation

Tenants (12000–12003)

Event IDEvent nameTrigger
12000Tenant_QueryList/search tenants
12001Tenant_LookupRetrieve a single tenant by ID
12002Tenant_PersistCreate or update a tenant
12003Tenant_DeleteDelete a tenant

Tenant configuration (270000–270005)

Event IDEvent nameTrigger
270000TenantConfiguration_QueryList tenant configuration entries
270001TenantConfiguration_LookupRetrieve a single tenant configuration entry
270002TenantConfiguration_PersistCreate or update a tenant configuration entry
270003TenantConfiguration_DeleteDelete a tenant configuration entry
270004TenantConfiguration_LookupByTypeRetrieve tenant configuration by type
270005TenantConfiguration_LookupBActiveTypeRetrieve active tenant configuration by type

References (7000–7005)

Event IDEvent nameTrigger
7000Reference_QueryList/search References
7001Reference_LookupRetrieve a single Reference by ID
7002Reference_PersistCreate or update a Reference
7003Reference_DeleteDelete a Reference
7004Reference_SearchSearch References
7005Reference_TestTest a Reference type configuration

Reference types (10000–10003)

Event IDEvent nameTrigger
10000ReferenceType_QueryList/search Reference types
10001ReferenceType_LookupRetrieve a single Reference type
10002ReferenceType_PersistCreate or update a Reference type
10003ReferenceType_DeleteDelete a Reference type

Prefilling sources (260000–260005)

Event IDEvent nameTrigger
260000PrefillingSource_QueryList/search prefilling sources
260001PrefillingSource_LookupRetrieve a single prefilling source
260002PrefillingSource_PersistCreate or update a prefilling source
260003PrefillingSource_DeleteDelete a prefilling source
260004PrefillingSource_GenerateGenerate a Description from a prefilling source
260005PrefillingSource_TestTest a prefilling source configuration

Statuses and workflows

Event IDEvent nameTrigger
300000PlanStatus_QueryList Plan statuses
300001PlanStatus_LookupRetrieve a single Plan status
300002PlanStatus_PersistCreate or update a Plan status
300003PlanStatus_DeleteDelete a Plan status
400000DescriptionStatus_QueryList Description statuses
400001DescriptionStatus_LookupRetrieve a single Description status
400002DescriptionStatus_PersistCreate or update a Description status
400003DescriptionStatus_DeleteDelete a Description status
500000PlanWorkflow_QueryList Plan workflows
500001PlanWorkflow_LookupRetrieve a single Plan workflow
500002PlanWorkflow_PersistCreate or update a Plan workflow
500003PlanWorkflow_DeleteDelete a Plan workflow
600000DescriptionWorkflow_QueryList Description workflows
600001DescriptionWorkflow_LookupRetrieve a single Description workflow
600002DescriptionWorkflow_PersistCreate or update a Description workflow
600003DescriptionWorkflow_DeleteDelete a Description workflow

Entity DOIs (2000–2003)

Event IDEvent nameTrigger
2000EntityDoi_QueryList DOI associations
2001EntityDoi_LookupRetrieve a single DOI association
2002EntityDoi_PersistCreate or update a DOI association
2003EntityDoi_DeleteDelete a DOI association

Storage files (14000–14002)

Event IDEvent nameTrigger
14000StorageFile_DownloadDownload a stored file
14001StorageFile_UploadUpload a stored file
14002StorageFile_QueryList stored files

Tags (19000–19003)

Event IDEvent nameTrigger
19000Tag_QueryList/search tags
19001Tag_LookupRetrieve a single tag
19002Tag_PersistCreate or update a tag
19003Tag_DeleteDelete a tag

Languages (13000–13003)

Event IDEvent nameTrigger
13000Language_QueryList available languages
13001Language_LookupRetrieve a single language
13002Language_PersistCreate or update a language
13003Language_DeleteDelete a language

Supportive material (9000–9003)

Event IDEvent nameTrigger
9000SupportiveMaterial_QueryList supportive material entries
9001SupportiveMaterial_LookupRetrieve a single supportive material entry
9002SupportiveMaterial_PersistCreate or update a supportive material entry
9003SupportiveMaterial_DeleteDelete a supportive material entry

User settings (4000–4003)

Event IDEvent nameTrigger
4000User_Settings_QueryList user settings entries
4001User_Settings_LookupRetrieve a single user settings entry
4002User_Settings_PersistCreate or update a user settings entry
4003User_Settings_DeleteDelete a user settings entry

Locks (17000–17009)

Event IDEvent nameTrigger
17000Lock_QueryList entity locks
17001Lock_LookupRetrieve a single lock
17002Lock_PersistAcquire a lock
17003Lock_DeleteRelease a lock
17004Lock_IsLockedCheck whether an entity is locked
17005Lock_UnLockedConfirm an entity is not locked
17006Lock_TouchedExtend a lock's TTL
17007Lock_LockedConfirm an entity is locked
17008Lock_UnLockedMultipleRelease multiple locks at once
17009Lock_CheckLockCheck lock status

Usage limits (290000–290003)

Event IDEvent nameTrigger
290000UsageLimit_QueryList usage limit rules
290001UsageLimit_LookupRetrieve a single usage limit rule
290002UsageLimit_PersistCreate or update a usage limit rule
290003UsageLimit_DeleteDelete a usage limit rule

Plan update requests (700000–700005)

Event IDEvent nameTrigger
700000PlanUpdateRequest_QueryList Plan update requests
700001PlanUpdateRequest_LookupRetrieve a single Plan update request
700002PlanUpdateRequest_PersistCreate or update a Plan update request
700003PlanUpdateRequest_DeleteDelete a Plan update request
700004PlanUpdateRequest_PreprocessingPreprocess a Plan update request
700005PlanUpdateRequest_BuildPlanBuild a Plan from an update request

Dashboard (15000–15002)

Event IDEvent nameTrigger
15000Dashboard_MyRecentActivityItemsRetrieve the current user's recent activity
15001Dashboard_MyDashboardStatisticsRetrieve the current user's dashboard statistics
15002Dashboard_PublicDashboardStatisticsRetrieve public dashboard statistics

Principal (240000–240001)

Event IDEvent nameTrigger
240000Principal_LookupRetrieve the authenticated principal's details
240001Principal_MyTenantsRetrieve the current user's tenant memberships

Deposit integration (18000–18005)

Event IDEvent nameTrigger
18000Deposit_GetAvailableRepositoriesList configured deposit repositories
18001Deposit_GetAccessTokenObtain a deposit repository access token
18002Deposit_DepositSubmit a Plan to a deposit repository
18003Deposit_GetLogoRetrieve a deposit repository logo
18004Deposit_GetRepositoryRetrieve a deposit repository configuration
18005Deposit_GetAuthMethodsList authentication methods for a deposit repository

File transformers and evaluators (20000–20001)

Event IDEvent nameTrigger
20000FileTransformer_GetAvailableConfigurationsList configured file transformer services
20001Evaluator_GetAvailableConfigurationsList configured evaluator services

Annotations and notifications (16000, 280000)

Event IDEvent nameTrigger
16000Notification_PersistCreate a notification
280000Annotation_Created_NotifySend notification for a new annotation
280001MaDMP_TouchedmaDMP synchronization event triggered

Semantics (250000)

Event IDEvent nameTrigger
250000GetSemanticsRetrieve the list of available semantics

Contact support (210000–210001)

Event IDEvent nameTrigger
210000ContactSupport_SentSubmit a contact support request (authenticated)
210001ContactSupport_PublicSentSubmit a contact support request (anonymous)

Maintenance (220000, 230000–230030)

These events are emitted by the maintenance controller when administrative background tasks are triggered manually.

Event IDEvent nameTrigger
220000Maintenance_GenerateElasticRebuild Elasticsearch indexes
230000Maintenance_ClearElasticClear Elasticsearch indexes
230001Maintenance_SendUserTouchEventsResend user accounting touch events
230002Maintenance_SendTenantTouchEventsResend tenant accounting touch events
230003Maintenance_SendPlanTouchEventsResend Plan accounting touch events
230004Maintenance_SendDescriptionTouchEventsResend Description accounting touch events
230005Maintenance_SendPlanAccountingEntriesEventsResend Plan accounting entries
230006Maintenance_SendBlueprintAccountingEntriesEventsResend Blueprint accounting entries
230007Maintenance_SendDescriptionAccountingEntriesEventsResend Description accounting entries
230008Maintenance_SendDescriptionTemplateAccountingEntriesEventsResend Template accounting entries
230009Maintenance_SendDescriptionTemplateTypeAccountingEntriesEventsResend Template type accounting entries
230010Maintenance_SendPrefillingSourceAccountingEntriesEventsResend prefilling source accounting entries
230011Maintenance_SendReferenceTypeAccountingEntriesEventsResend Reference type accounting entries
230012Maintenance_SendUserAccountingEntriesEventsResend user accounting entries
230013Maintenance_SendIndicatorCreateEntryEventsResend indicator creation entries
230014Maintenance_SendIndicatorResetEntryEventsResend indicator reset entries
230015Maintenance_SendIndicatorAccessEntryEventsResend indicator access entries
230016Maintenance_SendIndicatorPointPlanEntryEventsResend Plan indicator point entries
230017Maintenance_SendIndicatorPointDescriptionEntryEventsResend Description indicator point entries
230018Maintenance_SendIndicatorPointReferenceEntryEventsResend Reference indicator point entries
230019Maintenance_SendIndicatorPointUserEntryEventsResend user indicator point entries
230020Maintenance_SendIndicatorPointPlanBlueprintEntryEventsResend Blueprint indicator point entries
230021Maintenance_SendIndicatorPointDescriptionTemplateEntryEventsResend Template indicator point entries
230022Maintenance_SendPlanStatusAccountingEntriesEventsResend Plan status accounting entries
230023Maintenance_SendDescriptionStatusAccountingEntriesEventsResend Description status accounting entries
230024Maintenance_SendEvaluationPlanAccountingEntriesEventsResend Plan evaluation accounting entries
230025Maintenance_SendEvaluationDescriptionAccountingEntriesEventsResend Description evaluation accounting entries
230026Maintenance_SendIndicatorPointTenantEntryEventsResend tenant indicator point entries
230027Maintenance_SetPlanBlueprintCanEditDescriptionTemplatesSet Blueprint flag for template editing
230028Maintenance_SendReferenceEntriesEventsResend Reference accounting entries
230029Maintenance_SendLanguageEntriesEventsResend language accounting entries
230030Maintenance_SendBlueprintTypeAccountingEntriesEventsResend Blueprint type accounting entries

See also