You are viewing a plain text version of this content. The canonical link for it is here.
Posted to issues@bookkeeper.apache.org by GitBox <gi...@apache.org> on 2022/05/21 12:25:48 UTC

[GitHub] [bookkeeper] wenbingshen opened a new pull request, #3285: validate diskUsageThreshold and diskUsageLwmThreshold

wenbingshen opened a new pull request, #3285:
URL: https://github.com/apache/bookkeeper/pull/3285

   ### Motivation
   
   When `diskUsageThreshold < diskUsageLwmThreshold`, the bookie can be started normally. When the disk usage reaches `diskUsageThreshold` , bookie will automatically switch to `ReadOnly` mode. The `LedgerDirsMonitor` then switches the bookie back to  `read-write` mode since the disk usage is less than `diskUsageLwmThreshold`, the bookie will switch state back and forth frequently.
   
   ### Changes
   When creating `LedgerDirsMonitor`, we need to validate `diskUsageThreshold` and `diskUsageLwmThreshold` first.
   


-- 
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

To unsubscribe, e-mail: issues-unsubscribe@bookkeeper.apache.org

For queries about this service, please contact Infrastructure at:
users@infra.apache.org


[GitHub] [bookkeeper] wenbingshen commented on pull request #3285: validate diskUsageThreshold and diskUsageLwmThreshold

Posted by GitBox <gi...@apache.org>.
wenbingshen commented on PR #3285:
URL: https://github.com/apache/bookkeeper/pull/3285#issuecomment-1192154184

   rerun failure checks


-- 
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

To unsubscribe, e-mail: issues-unsubscribe@bookkeeper.apache.org

For queries about this service, please contact Infrastructure at:
users@infra.apache.org


[GitHub] [bookkeeper] wenbingshen commented on pull request #3285: validate diskUsageThreshold and diskUsageLwmThreshold

Posted by GitBox <gi...@apache.org>.
wenbingshen commented on PR #3285:
URL: https://github.com/apache/bookkeeper/pull/3285#issuecomment-1184338863

   Merge master to trigger CI test flaky test again.


-- 
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

To unsubscribe, e-mail: issues-unsubscribe@bookkeeper.apache.org

For queries about this service, please contact Infrastructure at:
users@infra.apache.org


[GitHub] [bookkeeper] wenbingshen commented on pull request #3285: validate diskUsageThreshold and diskUsageLwmThreshold

Posted by GitBox <gi...@apache.org>.
wenbingshen commented on PR #3285:
URL: https://github.com/apache/bookkeeper/pull/3285#issuecomment-1133637675

   rerun failure checks


-- 
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

To unsubscribe, e-mail: issues-unsubscribe@bookkeeper.apache.org

For queries about this service, please contact Infrastructure at:
users@infra.apache.org


[GitHub] [bookkeeper] wenbingshen commented on pull request #3285: validate diskUsageThreshold and diskUsageLwmThreshold

Posted by GitBox <gi...@apache.org>.
wenbingshen commented on PR #3285:
URL: https://github.com/apache/bookkeeper/pull/3285#issuecomment-1186884061

   rerun failure checks


-- 
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

To unsubscribe, e-mail: issues-unsubscribe@bookkeeper.apache.org

For queries about this service, please contact Infrastructure at:
users@infra.apache.org


[GitHub] [bookkeeper] wenbingshen commented on pull request #3285: validate diskUsageThreshold and diskUsageLwmThreshold

Posted by GitBox <gi...@apache.org>.
wenbingshen commented on PR #3285:
URL: https://github.com/apache/bookkeeper/pull/3285#issuecomment-1192316572

   rerun failure checks


-- 
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

To unsubscribe, e-mail: issues-unsubscribe@bookkeeper.apache.org

For queries about this service, please contact Infrastructure at:
users@infra.apache.org


[GitHub] [bookkeeper] wenbingshen commented on pull request #3285: validate diskUsageThreshold and diskUsageLwmThreshold

Posted by GitBox <gi...@apache.org>.
wenbingshen commented on PR #3285:
URL: https://github.com/apache/bookkeeper/pull/3285#issuecomment-1170806792

   @dlg99 @eolivelli @zymap @Shoothzj Can you help take a look at this pr? Thanks.


-- 
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

To unsubscribe, e-mail: issues-unsubscribe@bookkeeper.apache.org

For queries about this service, please contact Infrastructure at:
users@infra.apache.org


[GitHub] [bookkeeper] hangc0276 merged pull request #3285: validate diskUsageThreshold and diskUsageLwmThreshold

Posted by GitBox <gi...@apache.org>.
hangc0276 merged PR #3285:
URL: https://github.com/apache/bookkeeper/pull/3285


-- 
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

To unsubscribe, e-mail: issues-unsubscribe@bookkeeper.apache.org

For queries about this service, please contact Infrastructure at:
users@infra.apache.org


[GitHub] [bookkeeper] wenbingshen commented on pull request #3285: validate diskUsageThreshold and diskUsageLwmThreshold

Posted by GitBox <gi...@apache.org>.
wenbingshen commented on PR #3285:
URL: https://github.com/apache/bookkeeper/pull/3285#issuecomment-1186940935

   rerun failure checks


-- 
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

To unsubscribe, e-mail: issues-unsubscribe@bookkeeper.apache.org

For queries about this service, please contact Infrastructure at:
users@infra.apache.org


[GitHub] [bookkeeper] wenbingshen commented on pull request #3285: validate diskUsageThreshold and diskUsageLwmThreshold

Posted by GitBox <gi...@apache.org>.
wenbingshen commented on PR #3285:
URL: https://github.com/apache/bookkeeper/pull/3285#issuecomment-1186975411

   rerun failure checks


-- 
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

To unsubscribe, e-mail: issues-unsubscribe@bookkeeper.apache.org

For queries about this service, please contact Infrastructure at:
users@infra.apache.org


[GitHub] [bookkeeper] wenbingshen commented on pull request #3285: validate diskUsageThreshold and diskUsageLwmThreshold

Posted by GitBox <gi...@apache.org>.
wenbingshen commented on PR #3285:
URL: https://github.com/apache/bookkeeper/pull/3285#issuecomment-1187129748

   rerun failure checks


-- 
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

To unsubscribe, e-mail: issues-unsubscribe@bookkeeper.apache.org

For queries about this service, please contact Infrastructure at:
users@infra.apache.org


[GitHub] [bookkeeper] wenbingshen commented on a diff in pull request #3285: validate diskUsageThreshold and diskUsageLwmThreshold

Posted by GitBox <gi...@apache.org>.
wenbingshen commented on code in PR #3285:
URL: https://github.com/apache/bookkeeper/pull/3285#discussion_r927307398


##########
bookkeeper-server/src/main/java/org/apache/bookkeeper/bookie/LedgerDirsMonitor.java:
##########
@@ -229,5 +231,18 @@ private void checkDirs(final LedgerDirsManager ldm)
         }
         ldm.getWritableLedgerDirs();
     }
+
+    @VisibleForTesting
+    void setDiskSpaceThreshold(float diskSpaceThreshold, float diskUsageLwmThreshold) {

Review Comment:
   Make sense to me. I have addressed your comments. PTAL. 



-- 
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

To unsubscribe, e-mail: issues-unsubscribe@bookkeeper.apache.org

For queries about this service, please contact Infrastructure at:
users@infra.apache.org


[GitHub] [bookkeeper] wenbingshen commented on pull request #3285: validate diskUsageThreshold and diskUsageLwmThreshold

Posted by GitBox <gi...@apache.org>.
wenbingshen commented on PR #3285:
URL: https://github.com/apache/bookkeeper/pull/3285#issuecomment-1133821293

   rerun failure checks


-- 
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

To unsubscribe, e-mail: issues-unsubscribe@bookkeeper.apache.org

For queries about this service, please contact Infrastructure at:
users@infra.apache.org


[GitHub] [bookkeeper] wenbingshen commented on pull request #3285: validate diskUsageThreshold and diskUsageLwmThreshold

Posted by GitBox <gi...@apache.org>.
wenbingshen commented on PR #3285:
URL: https://github.com/apache/bookkeeper/pull/3285#issuecomment-1186999235

   rerun failure checks


-- 
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

To unsubscribe, e-mail: issues-unsubscribe@bookkeeper.apache.org

For queries about this service, please contact Infrastructure at:
users@infra.apache.org


[GitHub] [bookkeeper] wenbingshen commented on pull request #3285: validate diskUsageThreshold and diskUsageLwmThreshold

Posted by GitBox <gi...@apache.org>.
wenbingshen commented on PR #3285:
URL: https://github.com/apache/bookkeeper/pull/3285#issuecomment-1186844559

   rerun failure checks


-- 
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

To unsubscribe, e-mail: issues-unsubscribe@bookkeeper.apache.org

For queries about this service, please contact Infrastructure at:
users@infra.apache.org


[GitHub] [bookkeeper] wenbingshen commented on pull request #3285: validate diskUsageThreshold and diskUsageLwmThreshold

Posted by GitBox <gi...@apache.org>.
wenbingshen commented on PR #3285:
URL: https://github.com/apache/bookkeeper/pull/3285#issuecomment-1188482954

   rerun failure checks


-- 
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

To unsubscribe, e-mail: issues-unsubscribe@bookkeeper.apache.org

For queries about this service, please contact Infrastructure at:
users@infra.apache.org


[GitHub] [bookkeeper] wenbingshen commented on pull request #3285: validate diskUsageThreshold and diskUsageLwmThreshold

Posted by GitBox <gi...@apache.org>.
wenbingshen commented on PR #3285:
URL: https://github.com/apache/bookkeeper/pull/3285#issuecomment-1179156175

   PTAL @zymap Thanks.


-- 
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

To unsubscribe, e-mail: issues-unsubscribe@bookkeeper.apache.org

For queries about this service, please contact Infrastructure at:
users@infra.apache.org


[GitHub] [bookkeeper] wenbingshen commented on pull request #3285: validate diskUsageThreshold and diskUsageLwmThreshold

Posted by GitBox <gi...@apache.org>.
wenbingshen commented on PR #3285:
URL: https://github.com/apache/bookkeeper/pull/3285#issuecomment-1188545610

   rerun failure checks


-- 
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

To unsubscribe, e-mail: issues-unsubscribe@bookkeeper.apache.org

For queries about this service, please contact Infrastructure at:
users@infra.apache.org


[GitHub] [bookkeeper] wenbingshen commented on pull request #3285: validate diskUsageThreshold and diskUsageLwmThreshold

Posted by GitBox <gi...@apache.org>.
wenbingshen commented on PR #3285:
URL: https://github.com/apache/bookkeeper/pull/3285#issuecomment-1188508164

   rerun failure checks


-- 
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

To unsubscribe, e-mail: issues-unsubscribe@bookkeeper.apache.org

For queries about this service, please contact Infrastructure at:
users@infra.apache.org


[GitHub] [bookkeeper] wenbingshen commented on pull request #3285: validate diskUsageThreshold and diskUsageLwmThreshold

Posted by GitBox <gi...@apache.org>.
wenbingshen commented on PR #3285:
URL: https://github.com/apache/bookkeeper/pull/3285#issuecomment-1192263025

   rerun failure checks


-- 
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

To unsubscribe, e-mail: issues-unsubscribe@bookkeeper.apache.org

For queries about this service, please contact Infrastructure at:
users@infra.apache.org


[GitHub] [bookkeeper] wenbingshen commented on pull request #3285: validate diskUsageThreshold and diskUsageLwmThreshold

Posted by GitBox <gi...@apache.org>.
wenbingshen commented on PR #3285:
URL: https://github.com/apache/bookkeeper/pull/3285#issuecomment-1187350239

   rerun failure checks


-- 
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

To unsubscribe, e-mail: issues-unsubscribe@bookkeeper.apache.org

For queries about this service, please contact Infrastructure at:
users@infra.apache.org


[GitHub] [bookkeeper] Shoothzj commented on a diff in pull request #3285: validate diskUsageThreshold and diskUsageLwmThreshold

Posted by GitBox <gi...@apache.org>.
Shoothzj commented on code in PR #3285:
URL: https://github.com/apache/bookkeeper/pull/3285#discussion_r927283344


##########
bookkeeper-server/src/main/java/org/apache/bookkeeper/bookie/LedgerDirsMonitor.java:
##########
@@ -229,5 +231,18 @@ private void checkDirs(final LedgerDirsManager ldm)
         }
         ldm.getWritableLedgerDirs();
     }
+
+    @VisibleForTesting
+    void setDiskSpaceThreshold(float diskSpaceThreshold, float diskUsageLwmThreshold) {

Review Comment:
   do we really need this method? can we instantiate a LedgerDirsMonitor to run tests?



-- 
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

To unsubscribe, e-mail: issues-unsubscribe@bookkeeper.apache.org

For queries about this service, please contact Infrastructure at:
users@infra.apache.org


[GitHub] [bookkeeper] wenbingshen commented on pull request #3285: validate diskUsageThreshold and diskUsageLwmThreshold

Posted by GitBox <gi...@apache.org>.
wenbingshen commented on PR #3285:
URL: https://github.com/apache/bookkeeper/pull/3285#issuecomment-1192373957

   rerun failure checks


-- 
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

To unsubscribe, e-mail: issues-unsubscribe@bookkeeper.apache.org

For queries about this service, please contact Infrastructure at:
users@infra.apache.org


[GitHub] [bookkeeper] hangc0276 commented on pull request #3285: validate diskUsageThreshold and diskUsageLwmThreshold

Posted by GitBox <gi...@apache.org>.
hangc0276 commented on PR #3285:
URL: https://github.com/apache/bookkeeper/pull/3285#issuecomment-1184053416

   rerun failure checks


-- 
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

To unsubscribe, e-mail: issues-unsubscribe@bookkeeper.apache.org

For queries about this service, please contact Infrastructure at:
users@infra.apache.org


[GitHub] [bookkeeper] wenbingshen commented on pull request #3285: validate diskUsageThreshold and diskUsageLwmThreshold

Posted by GitBox <gi...@apache.org>.
wenbingshen commented on PR #3285:
URL: https://github.com/apache/bookkeeper/pull/3285#issuecomment-1184440970

   @hangc0276 There are two frequent flaky tests: #3206 #2665.
   
   Another flaky test seems to be related to the timeout of the bookie service shutdown, which has nothing to do with this PR, we can analyze and solve this flaky test in another PR.
   
   ```java
   Flakes: 
   Warning:  org.apache.bookkeeper.bookie.StateManagerTest.testReadOnlyBookieTransitions
   Error:    Run 1: StateManagerTest.testReadOnlyBookieTransitions:173->Object.wait:-2 ยป TestTimedOut
   ```


-- 
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

To unsubscribe, e-mail: issues-unsubscribe@bookkeeper.apache.org

For queries about this service, please contact Infrastructure at:
users@infra.apache.org