Project

General

Profile

Actions

bug #9236

closed

stopping an instance breaks the centralized logging

Added by Andreas Kohlbecker over 3 years ago. Updated about 2 years ago.

Status:
Closed
Priority:
Highest
Category:
cdmserver
Target version:
Start date:
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 Kohlbecker

Actions
Actions #1

Updated by Andreas Kohlbecker over 3 years ago

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

Updated by Andreas Kohlbecker over 3 years 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 3 years ago

  • Description updated (diff)
Actions #4

Updated by Andreas Kohlbecker over 3 years 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 about 3 years ago

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

Updated by Andreas Müller about 3 years ago

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

Updated by Andreas Kohlbecker about 3 years ago

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

Updated by Andreas Müller almost 3 years ago

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

Updated by Andreas Kohlbecker over 2 years 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 over 2 years ago

  • Status changed from New to In Progress
Actions #11

Updated by Andreas Kohlbecker over 2 years ago

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

Updated by Andreas Kohlbecker over 2 years 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 over 2 years ago

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

This works as expected.

Actions #14

Updated by Andreas Müller about 2 years ago

  • Target version changed from Release 5.45 to Release 5.29
Actions

Also available in: Atom PDF