File tree 2 files changed +13
-3
lines changed
src/main/java/dev/openfeature/sdk
2 files changed +13
-3
lines changed Original file line number Diff line number Diff line change 16
16
*/
17
17
public abstract class EventProvider implements FeatureProvider {
18
18
19
+ /**
20
+ * {@inheritDoc}
21
+ */
22
+ @ Override
23
+ public abstract ProviderState getState ();
24
+
19
25
private TriConsumer <EventProvider , ProviderEvent , ProviderEventDetails > onEmit = null ;
20
26
21
27
/**
Original file line number Diff line number Diff line change @@ -31,7 +31,7 @@ default List<Hook> getProviderHooks() {
31
31
* if they have special initialization needed prior being called for flag
32
32
* evaluation.
33
33
* <p>
34
- * It is ok, if the method is expensive as it is executed in the background. All
34
+ * It is ok if the method is expensive as it is executed in the background. All
35
35
* runtime exceptions will be
36
36
* caught and logged.
37
37
* </p>
@@ -46,7 +46,7 @@ default void initialize(EvaluationContext evaluationContext) throws Exception {
46
46
* Providers can overwrite this method, if they have special shutdown actions
47
47
* needed.
48
48
* <p>
49
- * It is ok, if the method is expensive as it is executed in the background. All
49
+ * It is ok if the method is expensive as it is executed in the background. All
50
50
* runtime exceptions will be
51
51
* caught and logged.
52
52
* </p>
@@ -57,7 +57,11 @@ default void shutdown() {
57
57
58
58
/**
59
59
* Returns a representation of the current readiness of the provider.
60
- * Providers which do not implement this method are assumed to be ready immediately.
60
+ * If the provider needs to be initialized, it should return {@link ProviderState#NOT_READY}.
61
+ * If the provider is in an error state, it should return {@link ProviderState#ERROR}.
62
+ * If the provider is functioning normally, it should return {@link ProviderState#READY}.
63
+ *
64
+ * <p><i>Providers which do not implement this method are assumed to be ready immediately.</i></p>
61
65
*
62
66
* @return ProviderState
63
67
*/
You can’t perform that action at this time.
0 commit comments