Skip to content
This repository has been archived by the owner on Nov 4, 2024. It is now read-only.

Commit

Permalink
Use ApiServerInitialisation for CouchDB auth extension (#229)
Browse files Browse the repository at this point in the history
* Use ApiServerInitialisation for couchdb auth extension

Signed-off-by: Eamonn Mansour <47121388+eamansour@users.noreply.github.com>

* Empty commit to kick off build

Signed-off-by: Eamonn Mansour <47121388+eamansour@users.noreply.github.com>

---------

Signed-off-by: Eamonn Mansour <47121388+eamansour@users.noreply.github.com>
  • Loading branch information
eamansour authored Jun 3, 2024
1 parent bf4d013 commit 80df180
Show file tree
Hide file tree
Showing 2 changed files with 7 additions and 7 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -19,7 +19,7 @@
import dev.galasa.extensions.common.impl.HttpRequestFactoryImpl;
import dev.galasa.extensions.common.api.HttpRequestFactory;
import dev.galasa.extensions.common.impl.LogFactoryImpl;
import dev.galasa.framework.spi.IFrameworkInitialisation;
import dev.galasa.framework.spi.IApiServerInitialisation;
import dev.galasa.framework.spi.SystemEnvironment;
import dev.galasa.framework.spi.auth.IAuthStoreRegistration;
import dev.galasa.framework.spi.utils.SystemTimeService;
Expand Down Expand Up @@ -53,18 +53,18 @@ public CouchdbAuthStoreRegistration(HttpClientFactory httpClientFactory, HttpReq
* This method checks that the auth store is a remote URL reference, and if true
* registers a new couchdb auth store as the only auth store.
*
* @param frameworkInitialisation Parameters this extension can use to to
* @param apiServerInitialisation Parameters this extension can use to to
* initialise itself.
* @throws AuthStoreException if there was a problem accessing the auth store.
*/
@Override
public void initialise(IFrameworkInitialisation frameworkInitialisation) throws AuthStoreException {
public void initialise(IApiServerInitialisation apiServerInitialisation) throws AuthStoreException {

URI authStoreUri = frameworkInitialisation.getAuthStoreUri();
URI authStoreUri = apiServerInitialisation.getAuthStoreUri();

if (isUriReferringToThisExtension(authStoreUri)) {
try {
frameworkInitialisation.registerAuthStore(
apiServerInitialisation.registerAuthStore(
new CouchdbAuthStore(
authStoreUri,
httpClientFactory,
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -11,13 +11,13 @@
import dev.galasa.framework.spi.ConfidentialTextException;
import dev.galasa.framework.spi.DynamicStatusStoreException;
import dev.galasa.framework.spi.EventsException;
import dev.galasa.framework.spi.IApiServerInitialisation;
import dev.galasa.framework.spi.ICertificateStoreService;
import dev.galasa.framework.spi.IConfidentialTextService;
import dev.galasa.framework.spi.IConfigurationPropertyStore;
import dev.galasa.framework.spi.IDynamicStatusStore;
import dev.galasa.framework.spi.IEventsService;
import dev.galasa.framework.spi.IFramework;
import dev.galasa.framework.spi.IFrameworkInitialisation;
import dev.galasa.framework.spi.IResultArchiveStoreService;
import dev.galasa.framework.spi.ResultArchiveStoreException;
import dev.galasa.framework.spi.auth.IAuthStore;
Expand All @@ -28,7 +28,7 @@
import java.net.URI;
import java.util.*;

public class MockFrameworkInitialisation implements IFrameworkInitialisation {
public class MockFrameworkInitialisation implements IApiServerInitialisation {

protected URI authStoreUri;
protected URI cpsBootstrapUri;
Expand Down

0 comments on commit 80df180

Please sign in to comment.