This commit is contained in:
Zoltan Haindrich 2024-05-16 13:23:45 +00:00
parent cabf2a31c3
commit fc9a6c7740
2 changed files with 7 additions and 4 deletions

View File

@ -129,11 +129,14 @@ import java.io.IOException;
import java.util.List;
import java.util.Properties;
class BrokerBasedTestConnection implements QueryComponentSupplier
/**
* A wrapper class to expose a {@link QueryComponentSupplier} as a Broker service.
*/
public class ExposedAsBrokerQueryComponentSupplierWrapper implements QueryComponentSupplier
{
private QueryComponentSupplier delegate;
public BrokerBasedTestConnection(QueryComponentSupplier delegate)
public ExposedAsBrokerQueryComponentSupplierWrapper(QueryComponentSupplier delegate)
{
this.delegate = delegate;
}
@ -180,7 +183,7 @@ class BrokerBasedTestConnection implements QueryComponentSupplier
installForServerModules(builder);
overrideModules.addAll(BrokerBasedTestConnection.brokerModules());
overrideModules.addAll(ExposedAsBrokerQueryComponentSupplierWrapper.brokerModules());
overrideModules.add(new DiscovertModule());
}

View File

@ -83,7 +83,7 @@ public class Launcher
ConfigurationInstance ci = CONFIG_STORE.getConfigurationInstance(
config,
x -> new BrokerBasedTestConnection(x)
x -> new ExposedAsBrokerQueryComponentSupplierWrapper(x)
);
return ci;
}