Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

App with MDBs doesn't restart cleanly after app monitor change, but enters a cycle of continuous recycling/restarting #27372

Open
scottkurz opened this issue Jan 16, 2024 · 1 comment
Labels
in:Application Services release bug This bug is present in a released version of Open Liberty

Comments

@scottkurz
Copy link
Member

scottkurz commented Jan 16, 2024

Describe the bug

Using a Liberty app with MDBs deployed as a "loose app" using liberty-maven-plugin, I make an update (e.g. compiling an updated app class). The default appMonitor config detects this change with its polling and restarts the app. However, instead we see a repeated sequence of app restarts.

Steps to Reproduce

  1. git clone --branch 27372-recreate [email protected]:scottkurz/cargotracker.git
  2. mvn -Popenliberty liberty:run # wait for startup to complete
  3. edit some Java file... eg src/main/java/org/eclipse/cargotracker/application/ApplicationEvents.java
  4. mvn compile

At this point you'll see the problem.

Expected behavior
The app should simply restart, i.e. stop then (re)start.

Diagnostic information:

product = Open Liberty 23.0.0.12 (wlp-1.0.84.cl231220231127-1901)
java.runtime = IBM Semeru Runtime Open Edition (17.0.3+7)
(see recreate above too)

Captured trace/messages.log

27372.logs.1.zip

Additional context

I believe there is a separate, related issue here though my guess is it is indeed separate.

The issue: OpenLiberty/ci.maven#1755 also describes an app that gets caught in a restart cycle.
However, looking at the trace in each, I found reason to suspect the core problem in the other issue may be the fact that the file system polling is used in app monitor rather than the 'mbean' trigger. I believe this is one of the key use cases for the 'mbean' trigger in the first place.

But I'm new to this code and have far from proven this. Will add more detail as I can.

@scottkurz scottkurz added release bug This bug is present in a released version of Open Liberty in:Application Services labels Jan 16, 2024
@scottkurz
Copy link
Member Author

Recreated the problem after manually compiling a single app .java file (rather than letting liberty-maven-plugin rebuild it). This proves to me that the default 'polled' behavior of applicationMonitor is not the cause of this problem. (Or maybe at least, more specifically, this proves that multiple updates within a short period of time, detected via polling, is not the cause of the problem.)

I still think the problem I've seen with this particular app is MDB related.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
in:Application Services release bug This bug is present in a released version of Open Liberty
Projects
None yet
Development

No branches or pull requests

1 participant