package org.gcube.spatial.data.sdi.engine.impl; import java.util.Arrays; import javax.inject.Singleton; import org.gcube.spatial.data.sdi.engine.SDIManager; import org.gcube.spatial.data.sdi.model.ScopeConfiguration; import org.gcube.spatial.data.sdi.model.credentials.AccessType; import org.gcube.spatial.data.sdi.model.credentials.Credentials; import org.gcube.spatial.data.sdi.model.service.GeoNetworkConfiguration; import org.gcube.spatial.data.sdi.model.service.GeoServerClusterConfiguration; import org.gcube.spatial.data.sdi.model.service.GeoServerConfiguration; import org.gcube.spatial.data.sdi.model.service.ThreddsConfiguration; import org.gcube.spatial.data.sdi.model.service.Version; @Singleton public class SDIManagerImpl implements SDIManager { @Override public ScopeConfiguration getContextConfiguration() { GeoNetworkConfiguration gn=new GeoNetworkConfiguration(new Version(2,2,2), "http://geonetwork.d4science.org/geonetwork", Arrays.asList(new Credentials("GNuser","pwd",AccessType.ADMIN)), "vre_group", "vre_shared", "global public access"); ThreddsConfiguration thredds=new ThreddsConfiguration(new Version(2,2,2), "http://thredds.d4sciecne.org/thredds", Arrays.asList(new Credentials("THuser","pwd",AccessType.ADMIN))); GeoServerConfiguration gs1=new GeoServerConfiguration(new Version(2,10,1), "http://geoserver1.d4science.org/geoserver", Arrays.asList(new Credentials("GS1user","pwd",AccessType.ADMIN)), "context_confidential_ws", "context_only_ws", "context_ws", "public_access_ws"); GeoServerConfiguration gs2=new GeoServerConfiguration(new Version(2,6,1), "http://geoserver2.d4science.org/geoserver", Arrays.asList(new Credentials("GS1user","pwd",AccessType.ADMIN)), "context_confidential_ws", "context_only_ws", "context_ws", "public_access_ws"); ScopeConfiguration toReturn=new ScopeConfiguration("/some/context", gn, new GeoServerClusterConfiguration(Arrays.asList(gs1,gs2)), thredds); return toReturn; } }