Skip to content

Commit 89f4faf

Browse files
authored
fix: fix skip logging on exporter closing (#2892)
Change-Id: I6fbe6935d51dfb67aaba5500ca391abc5fec9401 Thank you for opening a Pull Request! Before submitting your PR, there are a few things you can do to make sure it goes smoothly: - [ ] Make sure to open an issue as a [bug/issue](https://togithub.com/googleapis/java-bigtable/issues/new/choose) before writing your code! That way we can discuss the change, evaluate designs, and agree on the general idea - [ ] Ensure the tests and linter pass - [ ] Code coverage does not decrease (if any source code was changed) - [ ] Appropriate docs were updated (if necessary) - [ ] Rollback plan is reviewed and LGTMed - [ ] All new data plane features have a completed end to end testing plan Fixes #<issue_number_goes_here> ☕️ If you write sample code, please follow the [samples format]( https://togithub.com/GoogleCloudPlatform/java-docs-samples/blob/main/SAMPLE_FORMAT.md).
1 parent 261ed95 commit 89f4faf

1 file changed

Lines changed: 1 addition & 1 deletion

File tree

google-cloud-bigtable/src/main/java/com/google/cloud/bigtable/data/v2/internal/csm/exporter/BigtableCloudMonitoringExporter.java

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -195,7 +195,7 @@ public void onFailure(Throwable throwable) {
195195
RuntimeException asyncWrapper = new RuntimeException("export failed", throwable);
196196
asyncWrapper.setStackTrace(stackTrace);
197197

198-
if (state.get() != State.Closing || state.get() != State.Closed) {
198+
if (state.get() != State.Closing && state.get() != State.Closed) {
199199
// ignore the export warning when client is shutting down
200200
LOGGER.log(Level.WARNING, msg, asyncWrapper);
201201
}

0 commit comments

Comments
 (0)