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

F/574 #599

Open
wants to merge 27 commits into
base: master
Choose a base branch
from
Open

F/574 #599

Show file tree
Hide file tree
Changes from 24 commits
Commits
Show all changes
27 commits
Select commit Hold shift + click to select a range
fda76e4
initial work
mhogeweg Dec 5, 2024
e925451
resolved issue 572, started issue 574
mhogeweg Dec 6, 2024
b46a326
project geometries
mhogeweg Dec 9, 2024
5bb890d
geometry projection includes gsdb:geometry_wkt field
mhogeweg Dec 24, 2024
95d540a
/items and /search completed also
mhogeweg Dec 24, 2024
a625ebc
output projected collection and collections
mhogeweg Dec 27, 2024
f675124
work in progress
mhogeweg Jan 2, 2025
288260b
PATCH with projection implemented
mhogeweg Jan 6, 2025
d020ef6
finishing patching and item geometry projection
mhogeweg Jan 10, 2025
97337d1
validate unique value
mhogeweg Jan 14, 2025
c88ff77
refactoring and setup for intersect rule
mhogeweg Jan 14, 2025
ea67588
intersect implemented
mhogeweg Jan 17, 2025
0cb6f0e
Fixed Stac Collection Validation (Was broken due to some formatting
as0050629 Jan 17, 2025
da670c8
fix for adding collection
mhogeweg Jan 17, 2025
3315ced
Merge branch 'f/574' of https://github.com/Esri/geoportal-server-cata…
mhogeweg Jan 17, 2025
e8387d6
adding stac configuration items
mhogeweg Jan 17, 2025
15d6512
fix find by property value
mhogeweg Jan 18, 2025
1a16039
sync
mhogeweg Feb 5, 2025
745da45
consolidate
mhogeweg Feb 5, 2025
bd0dba2
switching to serverless
mhogeweg Feb 5, 2025
8ea6935
update gitignore
mhogeweg Feb 5, 2025
eb6d63a
Merge branch 'master' into f/574
mhogeweg Feb 6, 2025
d2ffe42
Fixed compilation issue
as0050629 Feb 10, 2025
b302d4b
Commented aws serverless options in default app-context,
as0050629 Feb 10, 2025
ed5ea3d
Fixed bug in add item(use sendPut)
as0050629 Feb 10, 2025
0cd8bea
updates for multilinestring support
mhogeweg Feb 13, 2025
4f76f3a
partial 573 and 603
mhogeweg Feb 16, 2025
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
4 changes: 4 additions & 0 deletions .gitignore
Original file line number Diff line number Diff line change
Expand Up @@ -146,3 +146,7 @@ geoportal/nb-configuration.xml
.vscode/settings.json
geoportal/.factorypath
geoportal/.vscode/settings.json
/components/CswClient/Pro/CswClient/obj
.vs/slnx.sqlite
.vs/VSWorkspaceState.json
/components/CswClient/Pro/CswClient/.vs
Original file line number Diff line number Diff line change
Expand Up @@ -224,7 +224,7 @@ public void interrogate() throws UnrecognizedTypeException, Exception {
XsltTemplate xsltTemplate = XsltTemplates.getCompiledTemplate(toKnownXslt);
String result = xsltTemplate.transform(getXml());
this.setXml(result);
if (hasXml()) this.updateDom();;
if (hasXml()) this.updateDom();
this.interrogate();

//evaluator.interrogate(this);
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -16,6 +16,8 @@
import com.esri.geoportal.base.security.Group;
import com.esri.geoportal.lib.elastic.ElasticContext;
import com.esri.geoportal.lib.harvester.HarvesterContext;
import com.esri.geoportal.service.stac.GeometryServiceClient;
import com.esri.geoportal.service.stac.StacContext;

import org.springframework.beans.BeansException;
import org.springframework.context.ApplicationContext;
Expand Down Expand Up @@ -55,16 +57,22 @@ public static GeoportalContext getInstance() {
private String defaultApprovalStatus;
private ElasticContext elasticContext;
private HarvesterContext harvesterContext;
private StacContext stacContext;
private GeometryServiceClient geometryServiceClient;
private boolean supportsApprovalStatus = false;
private boolean supportsGroupBasedAccess = false;
private String version = "2.7.2";
private String version = "2.7.2.1";
private boolean parseGml;
private boolean supportsCollections = false;
// HashMap stores userName and List of User Groups in ArcGISAuthentication
private HashMap<String,ArrayList<Group>> userGroupMap = new HashMap<String,ArrayList<Group>>();
private HashMap<String,ArrayList<Group>> userGroupMap = new HashMap<>();
private int numStacFeaturesAddItem = 100;
private boolean validateStacFields = false;

private String canStacAutogenerateId = "false";
private String canStacGeomTransform = "false";
private String geometryService = "";
private String geomWKTField = "";
private String geomCRSField = "";

public HashMap<String, ArrayList<Group>> getUserGroupMap() {
return userGroupMap;
Expand All @@ -77,7 +85,8 @@ public void setUserGroupMap(HashMap<String, ArrayList<Group>> userGroupMap) {
/** Constructor */
public GeoportalContext() {}

/** The Spring application context. */
/** The Spring application context.
* @return */
public ApplicationContext getApplicationContext() {
return applicationContext;
}
Expand All @@ -104,29 +113,35 @@ public void setApplicationContext(ApplicationContext springApplicationContext) t
}
}

/** Default access level. */
/** Default access level.
* @return */
public String getDefaultAccessLevel() {
return defaultAccessLevel;
}
/** Default access level . */
/** Default access level .
* @param defaultAccessLevel */
public void setDefaultAccessLevel(String defaultAccessLevel) {
this.defaultAccessLevel = defaultAccessLevel;
}

/** Default approval status. */
/** Default approval status.
* @return */
public String getDefaultApprovalStatus() {
return defaultApprovalStatus;
}
/** Default approval status. */
/** Default approval status.
* @param defaultApprovalStatus */
public void setDefaultApprovalStatus(String defaultApprovalStatus) {
this.defaultApprovalStatus = defaultApprovalStatus;
}

/** The Elasticsearch context. */
/** The Elasticsearch context.
* @return the elasticContext */
public ElasticContext getElasticContext() {
return elasticContext;
}
/** The Elasticsearch context. */
/** The Elasticsearch context.
* @param elasticContext */
public void setElasticContext(ElasticContext elasticContext) {
this.elasticContext = elasticContext;
}
Expand All @@ -145,11 +160,30 @@ public HarvesterContext getHarvesterContext() {
public void setHarvesterContext(HarvesterContext harvesterContext) {
this.harvesterContext = harvesterContext;
}

/**
* Gets STAC context.
* @return STAC context
*/
public StacContext getStacContext() {
return stacContext;
}
/**
* Sets STAC context.
* @param stacContext context
*/
public void setStacContext(StacContext stacContext) {
this.stacContext = stacContext;
}

public GeometryServiceClient getGeometryServiceClient() {
return this.geometryServiceClient;
}

/** Support for document approval status. */
public boolean getSupportsApprovalStatus() {
return supportsApprovalStatus;
}
}
/** Support for document approval status. */
public void setSupportsApprovalStatus(boolean supportsApprovalStatus) {
this.supportsApprovalStatus = supportsApprovalStatus;
Expand All @@ -176,10 +210,12 @@ public void setVersion(String version) {
public boolean getSupportsCollections() {
return supportsCollections;
}

/** Support for collections. */
public void setSupportsCollections(boolean supportsCollections) {
this.supportsCollections = supportsCollections;
}

//Number of Stac features allowed in POST request
public int getNumStacFeaturesAddItem() {
return numStacFeaturesAddItem;
Expand All @@ -188,6 +224,7 @@ public int getNumStacFeaturesAddItem() {
public void setNumStacFeaturesAddItem(int numStacFeaturesAddItem) {
this.numStacFeaturesAddItem = numStacFeaturesAddItem;
}

//Validate Stac fields in Stac Feature in POST request
public boolean isValidateStacFields() {
return this.validateStacFields;
Expand All @@ -196,6 +233,53 @@ public boolean isValidateStacFields() {
public void setValidateStacFields(boolean validateStacFields) {
this.validateStacFields = validateStacFields;
}

// Support for autogenerating item id
public boolean isCanStacAutogenerateId() {
return "true".equals(this.canStacAutogenerateId);
}
public void setCanStacAutogenerateId(String canStacAutogenerateId) {
this.canStacAutogenerateId = canStacAutogenerateId;
}

// Support for transforming the CRS of STAC geometries
public String isCanStacGeomTransform() {
return this.canStacGeomTransform;
}
public void setCanStacGeomTransform(String canStacGeomTransform) {
this.canStacGeomTransform = canStacGeomTransform;
}

// The ArcGIS Geometry service used to reproject STAC geometries
public String getGeometryService() {
return this.geometryService;
}
public void setGeometryService(String geometryService) {
this.geometryService = geometryService;
this.geometryServiceClient = new GeometryServiceClient(geometryService);

}


// If this is set, the field in the STAC item properties holds
// a dictionary of WKT geometries to be reprojected as well
public String getGeomWKTField() {
return this.geomWKTField;
}
public void setGeomWKTField(String geomWKTField) {
this.geomWKTField = geomWKTField;
}


// If this is set, the field in the STAC item properties holds
// CRS of its geometries
public String getGeomCRSField() {
return this.geomCRSField;
}
public void setGeomCRSField(String geomCRSField) {
this.geomCRSField = geomCRSField;
}


/** Methods =============================================================== */

Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -166,56 +166,68 @@ public void setProxyBufferSize(Integer proxyBufferSize) {
public boolean getAllowFileId() {
return allowFileId;
}
/** Allow internal metadata file idenitfiers to be used as the Elasticsearch _id .*/
/** Allow internal metadata file identifiers to be used as the Elasticsearch _id
* @param allowFileId.*/
public void setAllowFileId(boolean allowFileId) {
this.allowFileId = allowFileId;
}

/** Auto-create the metadata index if required. */
/** Auto-create the metadata index if required.
* @return */
public boolean getAutoCreateIndex() {
return autoCreateIndex;
}
/** Auto-create the metadata index if required. */
/** Auto-create the metadata index if required.
* @param autoCreateIndex */
public void setAutoCreateIndex(boolean autoCreateIndex) {
this.autoCreateIndex = autoCreateIndex;
}

/** The cluster name. */
/** The cluster name.
* @return */
public String getClusterName() {
return clusterName;
}
/** The cluster name. */
/** The cluster name.
* @param clusterName */
public void setClusterName(String clusterName) {
this.clusterName = clusterName;
}

/** The HTTP port (default=9200) */
/** The HTTP port (default=9200)
* @return */
public int getHttpPort() {
return httpPort;
}
/** The HTTP port (default=9200) */
/** The HTTP port (default=9200)
* @param httpPort */
public void setHttpPort(int httpPort) {
this.httpPort = httpPort;
}

/** The metadata index name (default=metadata). */
/** The metadata index name (default=metadata).
* @return */
public String getIndexName() {
return this.indexName;
}
/** The metadata index name (default=metadata). */
/** The metadata index name (default=metadata).
* @param indexName */
public void setIndexName(String indexName) {
this.indexName = indexName;
}
/** The collections index name (default=collections). */
/** The collections index name (default=collections).
* @return */
public String getCollectionIndexName() {
return collectionIndexName;
}
/** The collections index name (default=collections). */
/** The collections index name (default=collections).
* @param collectionIndexName */
public void setCollectionIndexName(String collectionIndexName) {
this.collectionIndexName = collectionIndexName;
}

/** Treat the index name as an alias. */
/** Treat the index name as an alias.
* @return */
public boolean getIndexNameIsAlias() {
return indexNameIsAlias;
}
Expand All @@ -228,40 +240,48 @@ public boolean getAutoCreateCollectionIndex() {
public void setAutoCreateCollectionIndex(boolean autoCreateCollectionIndex) {
this.autoCreateCollectionIndex = autoCreateCollectionIndex;
}

/** Treat the index name as an alias. */

/** Treat the index name as an alias.
* @param indexNameIsAlias */
public void setIndexNameIsAlias(boolean indexNameIsAlias) {
this.indexNameIsAlias = indexNameIsAlias;
}

/** Version 6+ */
/** Version 6+
* @return */
public boolean getIs6Plus() {
return is6Plus;
}
/** Version 6+ */
/** Version 6+
* @param is6Plus */
public void setIs6Plus(boolean is6Plus) {
this.is6Plus = is6Plus;
}

/** Version 7+ */
/** Version 7+
* @return */
public boolean getIs7Plus() {
return is7Plus;
}
/** Version 7+ */
/** Version 7+
* @param is7Plus */
public void setIs7Plus(boolean is7Plus) {
this.is7Plus = is7Plus;
}

/** The index name holding metadata items. */
/** The index name holding metadata items.
* @return */
public String getItemIndexName() {
return this.indexName;
}

/** The item index type (default=item). */
/** The item index type (default=item).
* @return */
public String getItemIndexType() {
return this.itemIndexType;
}
/** The item index type (default=item). */
/** The item index type (default=item).
* @param itemIndexType */
public void setItemIndexType(String itemIndexType) {
this.itemIndexType = itemIndexType;
}
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -90,7 +90,7 @@ public class FieldNames {
public static String FIELD_SYS_META = "sys_meta";


/*------------------------Stac------------------------*/
/*----------------------- STAC -----------------------*/
/** FIELD_STAC_CREATED = "created" */
public static String FIELD_STAC_CREATED = "created";

Expand All @@ -106,5 +106,4 @@ public class FieldNames {
public static String FIELD_BBOX = "bbox";
public static String FIELD_ASSETS = "assets";
public static String FIELD_THUMBNAIL = "thumbnail";

}
Loading