Deprecate waitKey and expose client
This commit is contained in:
parent
f7a971ad8e
commit
e0a9e3bda5
@ -1,5 +1,6 @@
|
||||
package eu.mikroskeem.utils.etcdconnector;
|
||||
|
||||
import mousio.etcd4j.EtcdClient;
|
||||
import org.jetbrains.annotations.NotNull;
|
||||
import org.jetbrains.annotations.Nullable;
|
||||
|
||||
@ -73,8 +74,18 @@ public interface EtcdConnector {
|
||||
/**
|
||||
* Waits for key change
|
||||
*
|
||||
* Deprecated: it is broken, literally
|
||||
*
|
||||
* @param path Key path
|
||||
* @param callback Callback to run
|
||||
*/
|
||||
@Deprecated
|
||||
void waitKey(@NotNull String path, @NotNull Function<Object,Void> callback);
|
||||
|
||||
/**
|
||||
* Get client instance
|
||||
*
|
||||
* @return Etcd client instance
|
||||
*/
|
||||
EtcdClient getClient();
|
||||
}
|
||||
|
@ -166,4 +166,8 @@ abstract class EtcdConnectorBase implements EtcdConnector {
|
||||
e.printStackTrace();
|
||||
}
|
||||
}
|
||||
|
||||
public EtcdClient getClient() {
|
||||
return etcdClient;
|
||||
}
|
||||
}
|
||||
|
Loading…
Reference in New Issue
Block a user