Skip to content

Commit e8daa92

Browse files
aepfliclaude
andcommitted
fix(flagd): use upstream SyncStreamQueueSource constructor
Update InProcessWasmResolver to use the single-parameter SyncStreamQueueSource constructor that matches upstream. 🤖 Generated with [Claude Code](https://claude.com/claude-code) Co-Authored-By: Claude Opus 4.5 <noreply@anthropic.com>
1 parent 3b6da5f commit e8daa92

1 file changed

Lines changed: 3 additions & 8 deletions

File tree

providers/flagd/src/main/java/dev/openfeature/contrib/providers/flagd/resolver/process/InProcessWasmResolver.java

Lines changed: 3 additions & 8 deletions
Original file line numberDiff line numberDiff line change
@@ -6,11 +6,8 @@
66
import static dev.openfeature.contrib.providers.flagd.resolver.process.FlagdWasmRuntime.getModule;
77

88
import com.dylibso.chicory.runtime.ExportFunction;
9-
import com.dylibso.chicory.runtime.HostFunction;
109
import com.dylibso.chicory.runtime.Instance;
1110
import com.dylibso.chicory.runtime.Memory;
12-
import com.dylibso.chicory.wasm.types.FunctionType;
13-
import com.dylibso.chicory.wasm.types.ValType;
1411
import com.fasterxml.jackson.core.JsonProcessingException;
1512
import com.fasterxml.jackson.databind.JavaType;
1613
import com.fasterxml.jackson.databind.ObjectMapper;
@@ -57,7 +54,6 @@ public class InProcessWasmResolver implements Resolver {
5754
}
5855

5956
private final Consumer<FlagdProviderEvent> onConnectionEvent;
60-
private final String scope;
6157
private final QueueSource connector;
6258
private Thread stateWatcher;
6359
private final ExportFunction validationMode;
@@ -78,8 +74,7 @@ public class InProcessWasmResolver implements Resolver {
7874
*/
7975
public InProcessWasmResolver(FlagdOptions options, Consumer<FlagdProviderEvent> onConnectionEvent) {
8076
this.onConnectionEvent = onConnectionEvent;
81-
this.connector = getConnector(options, onConnectionEvent);
82-
this.scope = options.getSelector();
77+
this.connector = getConnector(options);
8378

8479
var store = createStoreWithHostFunctions();
8580

@@ -210,14 +205,14 @@ public ProviderEvaluation<Value> objectEvaluation(String key, Value defaultValue
210205
.build();
211206
}
212207

213-
static QueueSource getConnector(final FlagdOptions options, Consumer<FlagdProviderEvent> onConnectionEvent) {
208+
static QueueSource getConnector(final FlagdOptions options) {
214209
if (options.getCustomConnector() != null) {
215210
return options.getCustomConnector();
216211
}
217212
return options.getOfflineFlagSourcePath() != null
218213
&& !options.getOfflineFlagSourcePath().isEmpty()
219214
? new FileQueueSource(options.getOfflineFlagSourcePath(), options.getOfflinePollIntervalMs())
220-
: new SyncStreamQueueSource(options, onConnectionEvent);
215+
: new SyncStreamQueueSource(options);
221216
}
222217

223218
private <T> ProviderEvaluation<T> resolve(Class<T> type, String key, EvaluationContext ctx) {

0 commit comments

Comments
 (0)