[
https://issues.apache.org/jira/browse/ARTEMIS-5675?focusedWorklogId=984018&page=com.atlassian.jira.plugin.system.issuetabpanels:worklog-tabpanel#worklog-984018
]
ASF GitHub Bot logged work on ARTEMIS-5675:
-------------------------------------------
Author: ASF GitHub Bot
Created on: 22/Sep/25 16:56
Start Date: 22/Sep/25 16:56
Worklog Time Spent: 10m
Work Description: clebertsuconic commented on code in PR #5934:
URL: https://github.com/apache/activemq-artemis/pull/5934#discussion_r2369426973
##########
artemis-journal/src/main/java/org/apache/activemq/artemis/core/journal/impl/JournalImpl.java:
##########
@@ -2858,16 +2858,19 @@ public synchronized void start() {
}
@Override
- public synchronized void stop() throws Exception {
+ public synchronized void stop() {
if (state == JournalState.STOPPED) {
return;
}
- flush();
+ try {
+ flush();
+ } catch (Exception e) {
+ logger.warn(e.getMessage(), e);
Review Comment:
fixed though
##########
artemis-journal/src/main/java/org/apache/activemq/artemis/core/journal/impl/JournalImpl.java:
##########
@@ -2880,8 +2883,12 @@ public synchronized void stop() throws Exception {
fileFactory.deactivateBuffer();
- if (currentFile != null && currentFile.getFile().isOpen()) {
- currentFile.getFile().close(true, true);
+ try {
+ if (currentFile != null && currentFile.getFile().isOpen()) {
+ currentFile.getFile().close(true, true);
+ }
+ } catch (Exception e) {
+ logger.warn(e.getMessage(), e);
Review Comment:
fixed
Issue Time Tracking
-------------------
Worklog Id: (was: 984018)
Time Spent: 50m (was: 40m)
> Server's JVM won't halt when storage is disconnected
> ----------------------------------------------------
>
> Key: ARTEMIS-5675
> URL: https://issues.apache.org/jira/browse/ARTEMIS-5675
> Project: ActiveMQ Artemis
> Issue Type: Bug
> Affects Versions: 2.42.0
> Reporter: Clebert Suconic
> Assignee: Clebert Suconic
> Priority: Major
> Labels: pull-request-available
> Fix For: 2.43.0
>
> Time Spent: 50m
> Remaining Estimate: 0h
>
> I tested this by inserting an USB stick, mounting the journal to the folder
> and disconnecting it.
> At the critical exception, the server will shutdown, however the file.close
> from the journal will throw an exception and not allow some of the thread
> dumps to close.
> I have fixed this, by manually testing it. I have no idea on how I could
> write an automated test for this. (I could of course throw mock tests, but
> they will not be reliable as I have no idea what errors could happen, I know
> the current ones but not future issues, so a mock test is not effective IMO).
--
This message was sent by Atlassian Jira
(v8.20.10#820010)
---------------------------------------------------------------------
To unsubscribe, e-mail: [email protected]
For additional commands, e-mail: [email protected]
For further information, visit: https://activemq.apache.org/contact