Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Support zilla.yaml config reader and writer #323

Merged
merged 6 commits into from
Aug 3, 2023
Merged
Show file tree
Hide file tree
Changes from 1 commit
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
Prev Previous commit
Next Next commit
Remove unused fields
  • Loading branch information
jfallows committed Aug 2, 2023
commit 755bc325baa47dd81dae32d64c78661170206e18
Original file line number Diff line number Diff line change
Expand Up @@ -47,7 +47,6 @@ public final class GrpcOptionsConfigAdapter implements OptionsConfigAdapterSpi,
{
private static final String SERVICES_NAME = "services";
private Function<String, String> readURL;
private ConfigAdapterContext context;

@Override
public Kind kind()
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -24,12 +24,9 @@

public class KindAdapter implements JsonbAdapter<KindConfig, JsonString>
{
private final ConfigAdapterContext context;

public KindAdapter(
ConfigAdapterContext context)
{
this.context = context;
}

@Override
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -36,12 +36,9 @@ public class NamspaceRefAdapter implements JsonbAdapter<NamespaceRef, JsonObject

private static final Map<String, String> LINKS_DEFAULT = emptyMap();

private final ConfigAdapterContext context;

public NamspaceRefAdapter(
ConfigAdapterContext context)
{
this.context = context;
}

@Override
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -43,15 +43,14 @@ public class RouteAdapter implements JsonbAdapter<RouteConfig, JsonObject>
private static final String WITH_NAME = "with";
private static final String GUARDED_NAME = "guarded";

private int index;
private final ConditionAdapter condition;
private final WithAdapter with;
private ConfigAdapterContext context;

private int index;

public RouteAdapter(
ConfigAdapterContext context)
{
this.context = context;
condition = new ConditionAdapter();
with = new WithAdapter();
}
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -22,8 +22,6 @@
import jakarta.json.JsonArrayBuilder;
import jakarta.json.JsonObject;
import jakarta.json.JsonObjectBuilder;
import jakarta.json.JsonString;
import jakarta.json.JsonValue;
import jakarta.json.bind.adapter.JsonbAdapter;

import io.aklivity.zilla.runtime.engine.config.MetricRefConfig;
Expand Down Expand Up @@ -62,10 +60,4 @@ public TelemetryRefConfig adaptFromJson(
: List.of();
return new TelemetryRefConfig(metricRefs);
}

private static String asJsonString(
JsonValue value)
{
return ((JsonString) value).getString();
}
}