Commit 18be3c45 authored by acoburn's avatar acoburn
Browse files

rename acrepo-jsonld-osgi to acrepo-services-jsonld

parent 0683a3c2
......@@ -12,7 +12,7 @@ Services
* `acrepo-idiomatic`: Id Mapping Service: This maps a public ID to a (internal and typically much longer) fedora URI
* `acrepo-idiomatic-pgsql`: Id Mapping Service Database: This exposes a Postgres datastore for use with the Id Mapping service
* `acrepo-image-service`: An image manipulation service
* `acrepo-jsonld-osgi`: This service creates expanded or compact JSON-LD representations of input documents
* `acrepo-services-jsonld`: This service creates expanded or compact JSON-LD representations of input documents
* `acrepo-jsonld-service`: This service exposes an HTTP endpoint for creating compact JSON-LD documents from a fedora repository using a pluggable context document
* `acrepo-mint-service`: This mints random (public) URIs for use with fedora resources
* `acrepo-services-validation`: An OSGi-based validation service
......@@ -37,7 +37,7 @@ command from its shell:
feature:install acrepo-idiomatic
feature:install acrepo-idiomatic-pgsql
feature:install acrepo-image-service
feature:install acrepo-jsonld-osgi
feature:install acrepo-services-jsonld
feature:install acrepo-jsonld-service
feature:install acrepo-mint-service
feature:install acrepo-services-validation
......
......@@ -47,7 +47,7 @@
<dependency>
<groupId>edu.amherst.acdc</groupId>
<artifactId>acrepo-jsonld-osgi</artifactId>
<artifactId>acrepo-services-jsonld</artifactId>
<version>${project.version}</version>
<scope>test</scope>
</dependency>
......
......@@ -69,7 +69,7 @@ public class AcrepoFitsIT extends AbstractOSGiIT {
.versionAsInProject().type("zip"))
.unpackDirectory(new File("target", "exam"))
.useDeployFolder(false),
logLevel(LogLevel.INFO),
logLevel(LogLevel.WARN),
keepRuntimeFolder(),
configureConsole().ignoreLocalConsole(),
features(maven().groupId("org.apache.karaf.features").artifactId("standard")
......
......@@ -80,7 +80,7 @@ public class AcrepoJsonLDIT extends AbstractOSGiIT {
.versionAsInProject().classifier("features").type("xml"), "scr"),
features(maven().groupId("edu.amherst.acdc").artifactId("acrepo-karaf")
.type("xml").classifier("features").versionAsInProject(),
"acrepo-jsonld-service", "acrepo-jsonld-osgi"),
"acrepo-jsonld-service", "acrepo-services-jsonld"),
mavenBundle().groupId("com.fasterxml.jackson.core").artifactId("jackson-core").versionAsInProject(),
mavenBundle().groupId("com.fasterxml.jackson.core").artifactId("jackson-databind").versionAsInProject(),
......@@ -101,7 +101,7 @@ public class AcrepoJsonLDIT extends AbstractOSGiIT {
assertTrue(featuresService.isInstalled(featuresService.getFeature("camel-core")));
assertTrue(featuresService.isInstalled(featuresService.getFeature("fcrepo-camel")));
assertTrue(featuresService.isInstalled(featuresService.getFeature("acrepo-jsonld-service")));
assertTrue(featuresService.isInstalled(featuresService.getFeature("acrepo-jsonld-osgi")));
assertTrue(featuresService.isInstalled(featuresService.getFeature("acrepo-services-jsonld")));
}
@Test
......@@ -114,7 +114,7 @@ public class AcrepoJsonLDIT extends AbstractOSGiIT {
final String baseUrl = "http://localhost:" + System.getProperty("fcrepo.port") + "/fcrepo/rest";
final String baseSvcUrl = "http://localhost:" + System.getProperty("karaf.jsonld.port") + "/jsonld";
assertTrue(options(baseSvcUrl).contains("owl:equivalentClass fedora:Resource"));
assertTrue(options(baseSvcUrl).contains("apix:bindsTo fedora:Resource"));
rangeClosed(1, 3).mapToObj(x -> post(baseUrl).replace(baseUrl, "")).forEach(id -> {
final ObjectMapper mapper = new ObjectMapper();
......
......@@ -79,8 +79,8 @@ public class AcrepoServicesIT extends AbstractOSGiIT {
features(maven().groupId("edu.amherst.acdc").artifactId("acrepo-karaf")
.type("xml").classifier("features").versionAsInProject(), "acrepo-idiomatic",
"acrepo-idiomatic-pgsql", "acrepo-mint-service", "acrepo-xml-metadata",
"acrepo-services-validation",
"acrepo-jsonld-service", "acrepo-jsonld-osgi", "acrepo-template-mustache",
"acrepo-services-validation", "acrepo-services-jsonld",
"acrepo-jsonld-service", "acrepo-template-mustache",
"acrepo-image-service", "acrepo-fits-rest"),
editConfigurationFilePut("etc/edu.amherst.acdc.jsonld.service.cfg", "rest.port", jsonldPort),
......@@ -105,7 +105,7 @@ public class AcrepoServicesIT extends AbstractOSGiIT {
assertTrue(featuresService.isInstalled(featuresService.getFeature("acrepo-services-validation")));
assertTrue(featuresService.isInstalled(featuresService.getFeature("acrepo-xml-metadata")));
assertTrue(featuresService.isInstalled(featuresService.getFeature("acrepo-jsonld-service")));
assertTrue(featuresService.isInstalled(featuresService.getFeature("acrepo-jsonld-osgi")));
assertTrue(featuresService.isInstalled(featuresService.getFeature("acrepo-services-jsonld")));
assertTrue(featuresService.isInstalled(featuresService.getFeature("acrepo-template-mustache")));
assertTrue(featuresService.isInstalled(featuresService.getFeature("acrepo-image-service")));
assertTrue(featuresService.isInstalled(featuresService.getFeature("acrepo-fits-rest")));
......
......@@ -75,7 +75,7 @@ public class AcrepoTemplateIT extends AbstractOSGiIT {
.versionAsInProject().classifier("features").type("xml"), "scr"),
features(maven().groupId("edu.amherst.acdc").artifactId("acrepo-karaf")
.type("xml").classifier("features").versionAsInProject(),
"acrepo-template-mustache", "acrepo-jsonld-osgi"),
"acrepo-template-mustache", "acrepo-services-jsonld"),
systemProperty("karaf.template.port").value(templateServicePort),
systemProperty("fcrepo.port").value(fcrepoPort),
......@@ -93,7 +93,7 @@ public class AcrepoTemplateIT extends AbstractOSGiIT {
assertTrue(featuresService.isInstalled(featuresService.getFeature("camel-core")));
assertTrue(featuresService.isInstalled(featuresService.getFeature("fcrepo-camel")));
assertTrue(featuresService.isInstalled(featuresService.getFeature("acrepo-template-mustache")));
assertTrue(featuresService.isInstalled(featuresService.getFeature("acrepo-jsonld-osgi")));
assertTrue(featuresService.isInstalled(featuresService.getFeature("acrepo-services-jsonld")));
}
@Test
......@@ -106,7 +106,7 @@ public class AcrepoTemplateIT extends AbstractOSGiIT {
final String baseUrl = "http://localhost:" + System.getProperty("fcrepo.port") + "/fcrepo/rest";
final String baseSvcUrl = "http://localhost:" + System.getProperty("karaf.template.port") + "/template";
assertTrue(options(baseSvcUrl).contains("owl:equivalentClass fedora:Resource"));
assertTrue(options(baseSvcUrl).contains("apix:bindsTo fedora:Resource"));
range(1, 2).mapToObj(x -> post(baseUrl)).forEach(url -> {
patch(url, "PREFIX dcterms: <http://purl.org/dc/terms/>\n" +
......
......@@ -37,7 +37,7 @@
</dependency>
<dependency>
<groupId>edu.amherst.acdc</groupId>
<artifactId>acrepo-jsonld-osgi</artifactId>
<artifactId>acrepo-services-jsonld</artifactId>
<version>${project.version}</version>
</dependency>
......
......@@ -7,7 +7,7 @@ rest.port=9102
rest.prefix=/jsonld
# JSON Context file
jsonld.context=https://acdc.amherst.edu/jsonld/context.json"
jsonld.context=https://acdc.amherst.edu/jsonld/models.json
# Repository Base URL
fcrepo.baseUrl=localhost:8080/fcrepo/rest
......
......@@ -19,7 +19,7 @@
</cm:default-properties>
</cm:property-placeholder>
<reference id="jsonldService" interface="edu.amherst.acdc.jsonld.JsonLdService" filter="(osgi.jndi.service.name=jsonld)" />
<reference id="jsonldService" interface="edu.amherst.acdc.services.jsonld.JsonLdService" filter="(osgi.jndi.service.name=jsonld)" />
<camelContext id="AcrepoJsonLdService" xmlns="http://camel.apache.org/schema/blueprint">
<package>edu.amherst.acdc.jsonld.service</package>
......
......@@ -18,8 +18,8 @@ package edu.amherst.acdc.jsonld.service;
import java.util.Dictionary;
import java.util.Map;
import edu.amherst.acdc.jsonld.JsonLdService;
import edu.amherst.acdc.jsonld.JsonLdServiceImpl;
import edu.amherst.acdc.services.jsonld.JsonLdService;
import edu.amherst.acdc.services.jsonld.JsonLdServiceImpl;
import org.apache.camel.test.blueprint.CamelBlueprintTestSupport;
import org.apache.camel.util.KeyValueHolder;
......
......@@ -41,7 +41,7 @@
<dependency>
<groupId>edu.amherst.acdc</groupId>
<artifactId>acrepo-jsonld-osgi</artifactId>
<artifactId>acrepo-services-jsonld</artifactId>
<scope>test</scope>
<version>${project.version}</version>
</dependency>
......@@ -67,15 +67,6 @@
<version>${project.version}</version>
</dependency>
<dependency>
<groupId>edu.amherst.acdc</groupId>
<artifactId>acrepo-karaf</artifactId>
<version>${project.version}</version>
<type>xml</type>
<classifier>features</classifier>
<scope>test</scope>
</dependency>
<!-- Testing & Camel Plugin -->
<dependency>
<groupId>junit</groupId>
......
......@@ -88,7 +88,7 @@
<configfile finalname="/etc/edu.amherst.acdc.xml.metadata.cfg">mvn:edu.amherst.acdc/acrepo-xml-metadata/${project.version}/cfg/configuration</configfile>
</feature>
<feature name="acrepo-jsonld-osgi" version="${project.version}" resolver="(orb)" start-level="50">
<feature name="acrepo-services-jsonld" version="${project.version}" resolver="(orb)" start-level="50">
<details>Installs the JSON-LD transformation OSGi service</details>
<feature version="${camel.version}">camel-jackson</feature>
......@@ -100,7 +100,7 @@
<bundle dependency="true">mvn:commons-io/commons-io/${commons-io.version}</bundle>
<bundle dependency="true">mvn:commons-codec/commons-codec/${commons-codec.version}</bundle>
<bundle>mvn:edu.amherst.acdc/acrepo-jsonld-osgi/${project.version}</bundle>
<bundle>mvn:edu.amherst.acdc/acrepo-services-jsonld/${project.version}</bundle>
</feature>
<feature name="acrepo-jsonld-service" version="${project.version}" resolver="(orb)" start-level="50">
......@@ -110,7 +110,7 @@
<feature version="${camel.version}">camel-blueprint</feature>
<feature version="${camel.version}">camel-jetty9</feature>
<feature version="${fcrepo-camel.version}">fcrepo-camel</feature>
<feature version="${project.version}">acrepo-jsonld-service</feature>
<feature version="${project.version}">acrepo-services-jsonld</feature>
<bundle>mvn:edu.amherst.acdc/acrepo-jsonld-service/${project.version}</bundle>
......@@ -127,7 +127,7 @@
<feature version="${camel.version}">camel-jackson</feature>
<feature version="${camel.version}">camel-http4</feature>
<feature version="${fcrepo-camel.version}">fcrepo-camel</feature>
<feature version="${project.version}">acrepo-jsonld-osgi</feature>
<feature version="${project.version}">acrepo-services-jsonld</feature>
<bundle>mvn:edu.amherst.acdc/acrepo-template-mustache/${project.version}</bundle>
......
......@@ -78,8 +78,8 @@ public class KarafIT {
final String version = cm.getProperty("project.version");
final String acrepoIdiomatic = getBundleUri("acrepo-idiomatic", version);
final String acrepoValidationSvc = getBundleUri("acrepo-services-validation", version);
final String acrepoJsonLd = getBundleUri("acrepo-jsonld-osgi", version);
final String acrepoJsonLdSvc = getBundleUri("acrepo-jsonld-service", version);
final String acrepoJsonLdSvc = getBundleUri("acrepo-services-jsonld", version);
final String acrepoJsonLd = getBundleUri("acrepo-jsonld-service", version);
final String acrepoMint = getBundleUri("acrepo-mint-service", version);
return new Option[] {
......
......@@ -19,7 +19,5 @@ Each of these projects can be deployed in an OSGi container. For example using
command from its shell:
feature:repo-add mvn:edu.amherst.acdc/acrepo-karaf/LATEST/xml/features
feature:install acrepo-jsonld-osgi
Or by copying any of the compiled bundles into `$KARAF_HOME/deploy`.
feature:install acrepo-services-jsonld
......@@ -26,14 +26,14 @@
<version>1.0.1-SNAPSHOT</version>
</parent>
<artifactId>acrepo-jsonld-osgi</artifactId>
<artifactId>acrepo-services-jsonld</artifactId>
<packaging>bundle</packaging>
<name>JSON-LD expansion and compaction service bundle</name>
<description>Repository JSON-LD transformation service.</description>
<properties>
<osgi.export.packages>edu.amherst.acdc.jsonld;version=${project.version}</osgi.export.packages>
<osgi.export.packages>edu.amherst.acdc.services.jsonld;version=${project.version}</osgi.export.packages>
</properties>
<dependencies>
......
......@@ -13,7 +13,7 @@
* See the License for the specific language governing permissions and
* limitations under the License.
*/
package edu.amherst.acdc.jsonld;
package edu.amherst.acdc.services.jsonld;
import java.io.InputStream;
......
......@@ -13,7 +13,7 @@
* See the License for the specific language governing permissions and
* limitations under the License.
*/
package edu.amherst.acdc.jsonld;
package edu.amherst.acdc.services.jsonld;
import static com.github.jsonldjava.utils.JsonUtils.fromInputStream;
import static com.github.jsonldjava.utils.JsonUtils.fromURL;
......
<?xml version="1.0" encoding="UTF-8"?>
<!--
Licensed to the Apache Software Foundation (ASF) under one or more
contributor license agreements. See the NOTICE file distributed with
this work for additional information regarding copyright ownership.
The ASF licenses this file to You under the Apache License, Version 2.0
(the "License"); you may not use this file except in compliance with
the License. You may obtain a copy of the License at
http://www.apache.org/licenses/LICENSE-2.0
Unless required by applicable law or agreed to in writing, software
distributed under the License is distributed on an "AS IS" BASIS,
WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
See the License for the specific language governing permissions and
limitations under the License.
-->
<blueprint xmlns="http://www.osgi.org/xmlns/blueprint/v1.0.0"
xmlns:cm="http://aries.apache.org/blueprint/xmlns/blueprint-cm/v1.1.0"
xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
......@@ -23,9 +7,9 @@
http://aries.apache.org/blueprint/xmlns/blueprint-cm/v1.1.0 http://aries.apache.org/schemas/blueprint-cm/blueprint-cm-1.1.0.xsd"
default-activation="lazy">
<bean id="jsonLdServiceBean" class="edu.amherst.acdc.jsonld.JsonLdServiceImpl"/>
<bean id="jsonLdServiceBean" class="edu.amherst.acdc.services.jsonld.JsonLdServiceImpl"/>
<service ref="jsonLdServiceBean" interface="edu.amherst.acdc.jsonld.JsonLdService">
<service ref="jsonLdServiceBean" interface="edu.amherst.acdc.services.jsonld.JsonLdService">
<service-properties>
<entry key="osgi.jndi.service.name" value="jsonld"/>
</service-properties>
......
......@@ -13,7 +13,7 @@
* See the License for the specific language governing permissions and
* limitations under the License.
*/
package edu.amherst.acdc.jsonld;
package edu.amherst.acdc.services.jsonld;
import static org.junit.Assert.assertEquals;
......
Markdown is supported
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment