Project

General

Profile

Actions

bug #9236

closed

stopping an instance breaks the centralized logging

Added by Andreas Kohlbecker over 1 year ago. Updated 5 days ago.

Status:
Closed
Priority:
Highest
Category:
cdmserver
Target version:
Start date:
10/01/2020
Due date:
% Done:

50%

Estimated time:
Severity:
critical
Found in Version:

Description

since switching to centralized logging through logback MDC (#7085) the logging gets broken when an cdm-webapp instance in the cdm-server is being stopped. Also (some) web services are broken afterwards.

To reproduce:

  • stop an instance in the cdm-server management console
  • ==> the last entry in the log file is e.e.cdm.server.instance.CdmInstance - lifeCycleStopping and no more logs are received.

IMPORTANT This has also observed on the production sever in a situation when some cdm instances have showed strange behavior. So this issue is critical and it is highly recommended not to stop an instance on the production server as long as this issue is not solved.


Related issues

Related to Edit - bug #7085: cdmserver logfiles getting too big, use RollingFileAppender ClosedAndreas Kohlbecker11/23/2017

Actions
Actions #1

Updated by Andreas Kohlbecker over 1 year ago

  • Related to bug #7085: cdmserver logfiles getting too big, use RollingFileAppender added
Actions #2

Updated by Andreas Kohlbecker over 1 year ago

  • Description updated (diff)

Further test showed that some service endpoints in fact are broken in the situation described above.

Actions #3

Updated by Andreas Kohlbecker over 1 year ago

  • Description updated (diff)
Actions #4

Updated by Andreas Kohlbecker over 1 year ago

  • Subject changed from stopping an intance breaks the centralized logging to stopping an instance breaks the centralized logging
Actions #5

Updated by Andreas Kohlbecker 12 months ago

  • Target version changed from Release 5.19 to Release 5.21
Actions #6

Updated by Andreas Müller 11 months ago

  • Target version changed from Release 5.21 to Release 5.22
Actions #7

Updated by Andreas Kohlbecker 9 months ago

  • Target version changed from Release 5.22 to Release 5.25
Actions #8

Updated by Andreas Müller 6 months ago

  • Target version changed from Release 5.25 to Release 5.29
Actions #9

Updated by Andreas Kohlbecker 6 days ago

The problem is caused by the LoggerContext being shutdown by the LogbackServletContextListener in LogbackServletContextListener.contextDestroyed(ServletContextEvent sce).
This effectively stops the shared logging context of all web-app instances.

The proposed solution is to

  • unregister the LogbackServletContextListener, or
  • to register a alternative ContextListener that checks the number of cdm-remote instances that are still running. The LoggerContext only is shut down when no more instances are available.
Actions #10

Updated by Andreas Müller 6 days ago

  • Status changed from New to In Progress
Actions #11

Updated by Andreas Kohlbecker 6 days ago

  • Status changed from In Progress to Resolved
  • % Done changed from 0 to 50
Actions #12

Updated by Andreas Kohlbecker 6 days ago

  • Assignee changed from Andreas Kohlbecker to Katja Luther

solved by excluding the LogbackServletContainerInitializer from the configuration.

Please review

Actions #13

Updated by Katja Luther 5 days ago

  • Status changed from Resolved to Closed
  • Assignee changed from Katja Luther to Andreas Kohlbecker

This works as expected.

Actions

Also available in: Atom PDF