Skip to content

Commit 6aa5f37

Browse files
SyncServerImpl: suppress finalize warning.
1 parent cbbf9f2 commit 6aa5f37

File tree

1 file changed

+4
-0
lines changed

1 file changed

+4
-0
lines changed

objectbox-java/src/main/java/io/objectbox/sync/server/SyncServerImpl.java

Lines changed: 4 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -102,6 +102,10 @@ public void close() {
102102
}
103103
}
104104

105+
/**
106+
* Users of this class should explicitly call {@link #close()} instead to avoid expensive finalization.
107+
*/
108+
@SuppressWarnings("deprecation") // finalize()
105109
@Override
106110
protected void finalize() throws Throwable {
107111
close();

0 commit comments

Comments
 (0)