Skip to content
This repository has been archived by the owner on Jan 3, 2019. It is now read-only.

Commit

Permalink
Normalize configuration along the lines of other PRs in:
Browse files Browse the repository at this point in the history
  • Loading branch information
acoburn authored and Andrew Woods committed Jan 27, 2015
1 parent 9c48e4c commit b396ca1
Show file tree
Hide file tree
Showing 11 changed files with 40 additions and 48 deletions.
10 changes: 5 additions & 5 deletions README.md
Expand Up @@ -28,7 +28,7 @@ indexer-core.xml
<!-- sparql-update indexer -->
<bean id="sparqlUpdate" class="org.fcrepo.indexer.SparqlIndexer">
<!-- base URL for triplestore subjects, PID will be appended -->
<property name="prefix" value="http://localhost:${test.port:8080}/rest/objects/"/>
<property name="prefix" value="http://localhost:${fcrepo.test.port:8080}/rest/objects/"/>

<!-- fuseki (used by tests) -->
<property name="queryBase" value="http://localhost:3030/test/query"/>
Expand Down Expand Up @@ -83,7 +83,7 @@ indexer-core.xml

<!-- Message Driven POJO (MDP) that manages individual indexers -->
<bean id="indexerGroup" class="org.fcrepo.indexer.IndexerGroup">
<property name="repositoryURL" value="http://localhost:${test.port:8080}/rest/objects/" />
<property name="repositoryURL" value="http://localhost:${fcrepo.test.port:8080}/rest/objects/" />
<property name="indexers">
<set>
<ref bean="sparqlUpdate"/>
Expand Down Expand Up @@ -181,7 +181,7 @@ Solr can be installed embedded into a jetty server (recommended for test) or in
Use the following MAVEN_OPTS on build

``` sh
MAVEN_OPTS=-Xmx750M -XX:MaxPermSize=300M clean install
MAVEN_OPTS="-Xmx750M -XX:MaxPermSize=300M" mvn clean install
```

### Caveat: Blank Nodes
Expand All @@ -204,8 +204,8 @@ file that will later be set to these two system variables:
<activeByDefault>true</activeByDefault>
</activation>
<properties>
<fedora.repo.username>example</fedora.repo.username>
<fedora.repo.password>xxxxxxxx</fedora.repo.password>
<fcrepo.username>example</fcrepo.username>
<fcrepo.password>xxxxxxxx</fcrepo.password>
</properties>
</profile>
</profiles>
Expand Down
12 changes: 6 additions & 6 deletions fcrepo-message-consumer-core/pom.xml
Expand Up @@ -240,9 +240,9 @@
<!-- reserve ports for integration tests -->
<configuration>
<portNames>
<portName>test.port</portName>
<portName>test.mgt.port</portName>
<portName>test.fuseki.port</portName>
<portName>fcrepo.test.port</portName>
<portName>fuseki.test.mgt.port</portName>
<portName>fuseki.test.port</portName>
</portNames>
</configuration>
<executions>
Expand All @@ -263,9 +263,9 @@
<configuration>
<!-- export ports for integration tests to system.env-->
<systemPropertyVariables>
<test.port>${test.port}</test.port>
<test.mgt.port>${test.mgt.port}</test.mgt.port>
<test.fuseki.port>${test.fuseki.port}</test.fuseki.port>
<fcrepo.test.port>${fcrepo.test.port}</fcrepo.test.port>
<fuseki.test.mgt.port>${fuseki.test.mgt.port}</fuseki.test.mgt.port>
<fuseki.test.port>${fuseki.test.port}</fuseki.test.port>
</systemPropertyVariables>
</configuration>
</plugin>
Expand Down
Expand Up @@ -43,9 +43,9 @@ public class FusekiContainerWrapper extends ContainerWrapper {
final private Logger logger = getLogger(FusekiContainerWrapper.class);

private static final int FUSEKI_PORT = parseInt(getProperty(
"test.fuseki.port", "3030"));
"fuseki.test.port", "3030"));

private static final int MGT_PORT = parseInt(getProperty("test.mgt.port",
private static final int MGT_PORT = parseInt(getProperty("fuseki.test.mgt.port",
"3031"));

private static final String serverAddress = "http://localhost:" + MGT_PORT
Expand Down
Expand Up @@ -29,7 +29,7 @@
*/
public class SparqlIndexerITHelper {

private static String queryBase = "http://localhost:" + getProperty("test.fuseki.port", "3030") + "/test/query";
private static String queryBase = "http://localhost:" + getProperty("fuseki.test.port", "3030") + "/test/query";

/**
* No public constructor for utility class
Expand Down
Expand Up @@ -37,7 +37,7 @@ public abstract class IndexingIT {

private static final Logger LOGGER = getLogger(IndexingIT.class);

protected static final int SERVER_PORT = parseInt(getProperty("test.port",
protected static final int SERVER_PORT = parseInt(getProperty("fcrepo.test.port",
"8080"));

protected static final String serverAddress = "http://localhost:"
Expand Down
Expand Up @@ -12,9 +12,9 @@

<!-- fuseki -->
<property name="queryBase"
value="http://localhost:${test.fuseki.port:3030}/test/query"/>
value="http://localhost:${fuseki.test.port:3030}/test/query"/>
<property name="updateBase"
value="http://localhost:${test.fuseki.port:3030}/test/update"/>
value="http://localhost:${fuseki.test.port:3030}/test/update"/>
<property name="formUpdates">
<value type="java.lang.Boolean">false</value>
</property>
Expand Down
Expand Up @@ -8,7 +8,7 @@
<context:property-placeholder/>

<bean id="containerWrapper" class="org.fcrepo.indexer.FusekiContainerWrapper" init-method="start" destroy-method="stop" >
<property name="port" value="${test.port:8080}"/>
<property name="port" value="${fcrepo.test.port:8080}"/>
<property name="configLocation" value="classpath:web.xml" />
</bean>

Expand Down
42 changes: 17 additions & 25 deletions fcrepo-message-consumer-webapp/pom.xml
Expand Up @@ -13,8 +13,8 @@

<properties>
<!-- integration test properties -->
<test.context.path>/</test.context.path>
<fcrepo.test.context.path>/</fcrepo.test.context.path>

<!-- sonar -->
<sonar.artifact.path>${project.build.directory}${file.separator}${project.artifactId}-${project.version}.war</sonar.artifact.path>
</properties>
Expand Down Expand Up @@ -99,7 +99,7 @@
<scope>test</scope>
</dependency>
<!-- httpmime lib is required for standardalone Solr Server client
It is not included in Solr ver. 3.6.2,
It is not included in Solr ver. 3.6.2,
Solr 4.xx DO NOT need this since it is included.-->
<dependency>
<groupId>org.apache.httpcomponents</groupId>
Expand Down Expand Up @@ -128,11 +128,11 @@
<properties>
<property>
<name>fcrepo.username</name>
<value>${fedora.repo.username}</value>
<value>${fcrepo.username}</value>
</property>
<property>
<name>fcrepo.password</name>
<value>${fedora.repo.password}</value>
<value>${fcrepo.password}</value>
</property>
</properties>
</configuration>
Expand Down Expand Up @@ -179,9 +179,9 @@
<artifactId>maven-failsafe-plugin</artifactId>
<configuration>
<systemPropertyVariables>
<test.port>${test.port}</test.port>
<jms.port>${jms.port}</jms.port>
<test.context.path>${test.context.path}</test.context.path>
<fcrepo.test.port>${fcrepo.test.port}</fcrepo.test.port>
<fcrepo.jms.port>${fcrepo.jms.port}</fcrepo.jms.port>
<fcrepo.test.context.path>${fcrepo.test.context.path}</fcrepo.test.context.path>
</systemPropertyVariables>
</configuration>
</plugin>
Expand All @@ -190,11 +190,11 @@
<artifactId>build-helper-maven-plugin</artifactId>
<configuration>
<portNames>
<portName>test.port</portName>
<portName>jms.port</portName>
<portName>fcrepo.test.port</portName>
<portName>fcrepo.jms.port</portName>
<!-- reserves the stop port for jetty-maven-plugin -->
<portName>jetty.port.stop</portName>
<portName>stomp.port</portName>
<portName>fcrepo.stomp.port</portName>
</portNames>
</configuration>
</plugin>
Expand All @@ -206,7 +206,7 @@
<scanIntervalSeconds>2</scanIntervalSeconds>
<stopKey>STOP</stopKey>
<webApp>
<contextPath>${test.context.path}</contextPath>
<contextPath>${fcrepo.test.context.path}</contextPath>
<allowDuplicateFragmentNames>true</allowDuplicateFragmentNames>
</webApp>

Expand All @@ -223,28 +223,20 @@
<configuration>
<connectors>
<connector implementation="org.eclipse.jetty.server.nio.SelectChannelConnector">
<port>${test.port}</port>
<port>${fcrepo.test.port}</port>
<maxIdleTime>60000</maxIdleTime>
</connector>
</connectors>
<daemon>true</daemon>
<stopPort>${jetty.port.stop}</stopPort>
<systemProperties>
<systemProperty>
<name>jms.port</name>
<value>${jms.port}</value>
</systemProperty>
<systemProperty>
<name>stomp.port</name>
<value>${stomp.port}</value>
</systemProperty>
<systemProperty>
<name>fcrepo.port</name>
<value>${test.port}</value>
<name>fcrepo.jms.port</name>
<value>${fcrepo.jms.port}</value>
</systemProperty>
<systemProperty>
<name>fcrepo.context</name>
<value>/f4/</value>
<name>fcrepo.stomp.port</name>
<value>${fcrepo.stomp.port}</value>
</systemProperty>
</systemProperties>

Expand Down
Expand Up @@ -10,7 +10,7 @@

<bean id="connectionFactory" class="org.apache.activemq.ActiveMQConnectionFactory">
<!--The Reconnect query params allow the broker not to block on start-up-->
<property name="brokerURL" value="failover:(tcp://${jms.host:localhost}:${jms.port:61616})?startupMaxReconnectAttempts=1&amp;initialReconnectDelay=1"/>
<property name="brokerURL" value="failover:(tcp://${fcrepo.jms.host:localhost}:${fcrepo.jms.port:61616})?startupMaxReconnectAttempts=1&amp;initialReconnectDelay=1"/>
</bean>

<!-- ActiveMQ queue to listen for events -->
Expand Down
Expand Up @@ -42,14 +42,14 @@ public class FedoraIndexerIT {
* The server port of the application, set as system property by
* maven-failsafe-plugin.
*/
private static final String SERVER_PORT = System.getProperty("test.port");
private static final String SERVER_PORT = System.getProperty("fcrepo.test.port");

/**
* The context path of the application (including the leading "/"), set as
* system property by maven-failsafe-plugin.
*/
private static final String CONTEXT_PATH = System
.getProperty("test.context.path");
.getProperty("fcrepo.test.context.path");

private static final String HOSTNAME = "localhost";

Expand Down
Expand Up @@ -47,14 +47,14 @@ public class SanityCheckIT {
* The server port of the application, set as system property by
* maven-failsafe-plugin.
*/
private static final String SERVER_PORT = System.getProperty("test.port");
private static final String SERVER_PORT = System.getProperty("fcrepo.test.port");

/**
* The context path of the application (including the leading "/"), set as
* system property by maven-failsafe-plugin.
*/
private static final String CONTEXT_PATH = System
.getProperty("test.context.path");
.getProperty("fcrepo.test.context.path");

private static final String HOSTNAME = "localhost";

Expand Down

0 comments on commit b396ca1

Please sign in to comment.