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

Configuration updates #144

Merged
merged 3 commits into from
Dec 14, 2018
Merged
Show file tree
Hide file tree
Changes from all commits
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
32 changes: 18 additions & 14 deletions build.gradle
Original file line number Diff line number Diff line change
Expand Up @@ -378,13 +378,15 @@ task loadQueryOptions(type : com.marklogic.gradle.task.MarkLogicTask, dependsOn:
def client = newClient()
def manager = client.newServerConfigManager().newQueryOptionsManager()

def files = files(file("config/${fsConfig}/options").listFiles())
files.each { file ->
def optionsName = file.name.substring(0, file.name.lastIndexOf("."))
manager.writeOptions(
optionsName, new com.marklogic.client.io.FileHandle().with(file)
)
println "Loaded query options: ${optionsName}"
if (file("config/${fsConfig}/options").exists()) {
def files = files(file("config/${fsConfig}/options").listFiles())
files.each { file ->
def optionsName = file.name.substring(0, file.name.lastIndexOf("."))
manager.writeOptions(
optionsName, new com.marklogic.client.io.FileHandle().with(file)
)
println "Loaded query options: ${optionsName}"
}
}

println "Query options loaded"
Expand All @@ -396,13 +398,15 @@ task loadQueryTransforms(type : com.marklogic.gradle.task.MarkLogicTask, depends
def client = newClient()
def manager = client.newServerConfigManager().newTransformExtensionsManager()

def files = files(file("config/${fsConfig}/transforms").listFiles())
files.each { file ->
def transformName = file.name.substring(0, file.name.lastIndexOf("."))
manager.writeXQueryTransform(
transformName, new com.marklogic.client.io.FileHandle().with(file)
)
println "Loaded transform: ${transformName}"
if (file("config/${fsConfig}/transforms").exists()) {
def files = files(file("config/${fsConfig}/transforms").listFiles())
files.each { file ->
def transformName = file.name.substring(0, file.name.lastIndexOf("."))
manager.writeXQueryTransform(
transformName, new com.marklogic.client.io.FileHandle().with(file)
)
println "Loaded transform: ${transformName}"
}
}

println "Query transforms loaded"
Expand Down
101 changes: 0 additions & 101 deletions src/example/ml-config/databases/content-database.json
Original file line number Diff line number Diff line change
Expand Up @@ -74,20 +74,6 @@
"point-format": "long-lat-point",
"range-value-positions": false,
"invalid-values": "reject"
},
{
"path-expression" : "//location/item/Point",
"coordinate-system": "wgs84",
"point-format": "point",
"range-value-positions": false,
"invalid-values": "reject"
},
{
"path-expression" : "//location/item/coords",
"coordinate-system": "wgs84",
"point-format": "point",
"range-value-positions": false,
"invalid-values": "reject"
}
],
"geospatial-region-path-index": [
Expand All @@ -98,92 +84,5 @@
"geohash-precision": 2,
"invalid-values": "reject"
}
],
"geospatial-element-child-index" : [
{
"parent-namespace-uri" : "http://www.opengis.net/gml/3.2",
"parent-localname" : "Point",
"namespace-uri" : "http://www.opengis.net/gml/3.2",
"localname" : "pos",
"coordinate-system" : "wgs84",
"point-format" : "point",
"range-value-positions" : false,
"invalid-values" : "reject"
},
{
"parent-namespace-uri" : "http://www.opengis.net/kml/2.2",
"parent-localname" : "Point",
"namespace-uri" : "http://www.opengis.net/kml/2.2",
"localname" : "coordinates",
"coordinate-system" : "wgs84",
"point-format" : "long-lat-point",
"range-value-positions" : false,
"invalid-values" : "reject"
},
{
"parent-namespace-uri" : "http://www.marklogic.com/element-child",
"parent-localname" : "point",
"namespace-uri" : "",
"localname" : "coords",
"coordinate-system" : "wgs84",
"point-format" : "point",
"range-value-positions" : false,
"invalid-values" : "reject"
}
],
"geospatial-element-index" : [
{
"namespace-uri" : "http://www.georss.org/georss",
"localname" : "point",
"coordinate-system" : "wgs84",
"point-format" : "point",
"range-value-positions" : false,
"invalid-values" : "reject"
},
{
"namespace-uri" : "http://www.marklogic.com/element",
"localname" : "coords",
"coordinate-system" : "wgs84",
"point-format" : "point",
"range-value-positions" : false,
"invalid-values" : "reject"
}
],
"geospatial-element-attribute-pair-index" : [
{
"parent-namespace-uri" : "",
"parent-localname" : "Dot",
"latitude-namespace-uri" : "",
"latitude-localname" : "Latitude",
"longitude-namespace-uri" : "",
"longitude-localname" : "Longitude",
"coordinate-system" : "wgs84",
"range-value-positions" : false,
"invalid-values" : "reject"
},
{
"parent-namespace-uri" : "http://www.marklogic.com/element-attribute",
"parent-localname" : "point",
"latitude-namespace-uri" : "",
"latitude-localname" : "latitude",
"longitude-namespace-uri" : "",
"longitude-localname" : "longitude",
"coordinate-system" : "wgs84",
"range-value-positions" : false,
"invalid-values" : "reject"
}
],
"geospatial-element-pair-index" : [
{
"parent-namespace-uri" : "",
"parent-localname" : "point",
"latitude-namespace-uri" : "",
"latitude-localname" : "latitude",
"longitude-namespace-uri" : "",
"longitude-localname" : "longitude",
"coordinate-system" : "wgs84",
"range-value-positions" : false,
"invalid-values" : "reject"
}
]
}
3 changes: 2 additions & 1 deletion src/koop/package.json
Original file line number Diff line number Diff line change
Expand Up @@ -11,7 +11,8 @@
"config": "^1.25.1",
"winston": "^2.4.1",
"express": "^4.15.3",
"koop": "^3.5.4",
"koop": "3.10.1",
"featureserver": "2.16.2",
"marklogic": "^2.0.2"
},
"author": "MarkLogic",
Expand Down