Skip to content

Commit

Permalink
Intermediate commit
Browse files Browse the repository at this point in the history
  • Loading branch information
ajs6f committed Nov 21, 2013
1 parent 3937171 commit a8f930f
Show file tree
Hide file tree
Showing 41 changed files with 116 additions and 1,331 deletions.
@@ -1,6 +1,8 @@
<?xml version="1.0" encoding="UTF-8"?>
<beans xmlns="http://www.springframework.org/schema/beans" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
xmlns:context="http://www.springframework.org/schema/context"
xmlns:p="http://www.springframework.org/schema/p"
xmlns:c="http://www.springframework.org/schema/c"
xsi:schemaLocation="
http://www.springframework.org/schema/beans http://www.springframework.org/schema/beans/spring-beans-3.0.xsd
http://www.springframework.org/schema/context http://www.springframework.org/schema/context/spring-context-3.0.xsd">
Expand All @@ -12,18 +14,13 @@
<context:component-scan base-package="org.fcrepo.kernel.services" />

<bean name="modeshapeRepofactory" class="org.fcrepo.kernel.spring.ModeShapeRepositoryFactoryBean"
depends-on="authenticationProvider">
<property name="repositoryConfiguration" value="${fcrepo.modeshape.configuration:repository.json}" />
</bean>

<bean name="pep" class="org.mockito.Mockito" factory-method="mock">
<constructor-arg value="org.fcrepo.auth.FedoraPolicyEnforcementPoint" />
</bean>

<bean name="authenticationProvider" class="org.fcrepo.auth.ServletContainerAuthenticationProvider">
<property name="pep" ref="pep"/>
</bean>
depends-on="authenticationProvider" p:repositoryConfiguration="${fcrepo.modeshape.configuration:repository.json}"/>

<bean name="pep" class="org.mockito.Mockito" factory-method="mock" c:classToMock="org.fcrepo.auth.FedoraPolicyEnforcementPoint"/>

<bean name="authenticationProvider" class="org.fcrepo.auth.ServletContainerAuthenticationProvider"
p:pep-ref="pep"/>

<bean class="org.modeshape.jcr.JcrRepositoryFactory" />

</beans>
13 changes: 6 additions & 7 deletions fcrepo-auth-common/src/test/resources/spring-test/repo.xml
@@ -1,6 +1,7 @@
<?xml version="1.0" encoding="UTF-8"?>
<beans xmlns="http://www.springframework.org/schema/beans" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
xmlns:context="http://www.springframework.org/schema/context"
xmlns:p="http://www.springframework.org/schema/p"
xsi:schemaLocation="
http://www.springframework.org/schema/beans http://www.springframework.org/schema/beans/spring-beans-3.0.xsd
http://www.springframework.org/schema/context http://www.springframework.org/schema/context/spring-context-3.0.xsd">
Expand All @@ -12,15 +13,13 @@
<context:component-scan base-package="org.fcrepo.kernel.services" />

<bean name="modeshapeRepofactory" class="org.fcrepo.kernel.spring.ModeShapeRepositoryFactoryBean"
depends-on="authenticationProvider">
<property name="repositoryConfiguration" value="${fcrepo.modeshape.configuration:repository.json}" />
</bean>

depends-on="authenticationProvider" p:repositoryConfiguration="${fcrepo.modeshape.configuration:repository.json}"/>

<bean name="pep" class="org.fcrepo.auth.integration.PermitRootAndPathEndsWithPermitSuffixPEP"/>

<bean name="authenticationProvider" class="org.fcrepo.auth.ServletContainerAuthenticationProvider">
<property name="pep" ref="pep"/>
</bean>
<bean name="authenticationProvider" class="org.fcrepo.auth.ServletContainerAuthenticationProvider"
p:pep-ref="pep"/>


<bean class="org.modeshape.jcr.JcrRepositoryFactory" />

Expand Down
2 changes: 1 addition & 1 deletion fcrepo-auth-common/src/test/resources/spring-test/rest.xml
Expand Up @@ -10,5 +10,5 @@
<!-- Mints PIDs-->
<bean class="org.fcrepo.kernel.identifiers.UUIDPidMinter"/>

<context:component-scan base-package="org.fcrepo.http, org.fcrepo.kernel.services, org.fcrepo.serialization" />
<context:component-scan base-package="org.fcrepo.http, org.fcrepo.kernel.services, org.fcrepo.serialization" />
</beans>
Expand Up @@ -2,19 +2,20 @@
<beans xmlns="http://www.springframework.org/schema/beans"
xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
xmlns:context="http://www.springframework.org/schema/context"
xmlns:p="http://www.springframework.org/schema/p"
xsi:schemaLocation="http://www.springframework.org/schema/beans http://www.springframework.org/schema/beans/spring-beans-3.0.xsd
http://www.springframework.org/schema/context http://www.springframework.org/schema/context/spring-context-3.0.xsd">

<context:property-placeholder/>

<!-- show stack traces for easier debugging -->
<!-- <bean id="wildcardExceptionmapper" class="org.fcrepo.http.commons.exceptionhandlers.WildcardExceptionMapper" >
<!-- <bean id="wildcardExceptionmapper" class="org.fcrepo.http.commons.exceptionhandlers.WildcardExceptionMapper" >
<property name="showStackTrace" value="true" />
</bean> -->
<bean id="containerWrapper" class="org.fcrepo.http.commons.test.util.ContainerWrapper" init-method="start" destroy-method="stop" >
<property name="port" value="${test.port:8080}"/>
<property name="configLocation" value="classpath:web.xml" />
</bean>

<bean id="containerWrapper"
class="org.fcrepo.http.commons.test.util.ContainerWrapper"
init-method="start" destroy-method="stop" p:port="${test.port:8080}"
p:configLocation="classpath:web.xml"/>

</beans>
7 changes: 3 additions & 4 deletions fcrepo-auth-oauth/src/test/resources/spring-test/repo.xml
Expand Up @@ -2,6 +2,7 @@
<beans xmlns="http://www.springframework.org/schema/beans"
xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
xmlns:context="http://www.springframework.org/schema/context"
xmlns:p="http://www.springframework.org/schema/p"
xsi:schemaLocation="
http://www.springframework.org/schema/beans http://www.springframework.org/schema/beans/spring-beans-3.0.xsd
http://www.springframework.org/schema/context http://www.springframework.org/schema/context/spring-context-3.0.xsd">
Expand All @@ -11,11 +12,9 @@
<context:annotation-config/>

<bean name="modeshapeRepofactory"
class="org.fcrepo.kernel.spring.ModeShapeRepositoryFactoryBean">
<property name="repositoryConfiguration" value="${fcrepo.modeshape.configuration:config/rest-sessions/repository.json}"/>
</bean>
class="org.fcrepo.kernel.spring.ModeShapeRepositoryFactoryBean"
p:repositoryConfiguration="${fcrepo.modeshape.configuration:config/rest-sessions/repository.json}"/>

<bean class="org.modeshape.jcr.JcrRepositoryFactory"/>


</beans>
31 changes: 15 additions & 16 deletions fcrepo-auth-oauth/src/test/resources/spring-test/security.xml
Expand Up @@ -2,34 +2,33 @@
<beans xmlns="http://www.springframework.org/schema/beans"
xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
xmlns:context="http://www.springframework.org/schema/context"
xmlns:p="http://www.springframework.org/schema/p"
xmlns:u="http://www.springframework.org/schema/util"
xsi:schemaLocation="
http://www.springframework.org/schema/beans http://www.springframework.org/schema/beans/spring-beans-3.0.xsd
http://www.springframework.org/schema/context http://www.springframework.org/schema/context/spring-context-3.0.xsd">
http://www.springframework.org/schema/context http://www.springframework.org/schema/context/spring-context-3.0.xsd
http://www.springframework.org/schema/util http://www.springframework.org/schema/util/spring-util.xsd">

<!-- Context that supports the actual ModeShape JCR itself -->

<context:annotation-config/>

<bean name="oauthFilter" class="org.fcrepo.auth.oauth.filter.OAuthFilter">
<property name="realm" value="fedora"/>
<property name="provider">
<bean class="org.fcrepo.auth.oauth.DefaultOAuthResourceProvider">
<!-- mints JCR Sessions : needs to reappear here because it can't be autowired from the enclosed contexts-->
</bean>
</property>
<property name="parameterStyles">
<set
value-type="org.apache.oltu.oauth2.common.message.types.ParameterStyle">
<value>QUERY</value>
<value>HEADER</value>
</set>
</property>
<bean name="oauthFilter" class="org.fcrepo.auth.oauth.filter.OAuthFilter"
p:realm="fedora" p:provider-ref="defaultOAuthResourceProvider"
p:parameterStyles-ref="parameterStyles"/>

<bean id="defaultOAuthResourceProvider" class="org.fcrepo.auth.oauth.DefaultOAuthResourceProvider">
<!-- mints JCR Sessions : needs to reappear here because it can't be autowired from the enclosed contexts-->
</bean>

<u:set id="parameterStyles" value-type="org.apache.oltu.oauth2.common.message.types.ParameterStyle">
<value>QUERY</value>
<value>HEADER</value>
</u:set>

<bean name="wrapFilter"
class="org.fcrepo.auth.oauth.test.filter.AuthenticatedRequestWrappingFilter"/>


<bean name="authNFilter"
class="org.fcrepo.auth.oauth.filter.RestrictToAuthNFilter"/>

Expand Down
Expand Up @@ -2,14 +2,14 @@
<beans xmlns="http://www.springframework.org/schema/beans"
xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
xmlns:context="http://www.springframework.org/schema/context"
xmlns:p="http://www.springframework.org/schema/p"
xsi:schemaLocation="http://www.springframework.org/schema/beans http://www.springframework.org/schema/beans/spring-beans-3.0.xsd
http://www.springframework.org/schema/context http://www.springframework.org/schema/context/spring-context-3.0.xsd">

<context:property-placeholder/>

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

</beans>
Expand Up @@ -7,6 +7,7 @@
http://www.springframework.org/schema/task http://www.springframework.org/schema/task/spring-task-3.0.xsd">

<context:annotation-config />

<context:component-scan base-package="org.fcrepo.kernel.services" />

<task:scheduler id="taskScheduler" />
Expand Down

This file was deleted.

Expand Up @@ -3,6 +3,7 @@
xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
xmlns:context="http://www.springframework.org/schema/context"
xmlns:util="http://www.springframework.org/schema/util"
xmlns:p="http://www.springframework.org/schema/p"
xsi:schemaLocation="
http://www.springframework.org/schema/beans http://www.springframework.org/schema/beans/spring-beans-3.0.xsd
http://www.springframework.org/schema/context http://www.springframework.org/schema/context/spring-context-3.0.xsd
Expand All @@ -20,9 +21,8 @@
<bean class="org.fcrepo.kernel.identifiers.UUIDPidMinter"/>

<util:list id="dcgenerators" value-type="org.fcrepo.generator.dublincore.DCGenerator">
<bean class="org.fcrepo.generator.dublincore.WellKnownDatastreamGenerator">
<property name="wellKnownDsid" value="DC"/>
</bean>
<bean class="org.fcrepo.generator.dublincore.WellKnownDatastreamGenerator"
p:wellKnownDsid="DC"/>
<bean class="org.fcrepo.generator.dublincore.JcrPropertiesGenerator"/>
</util:list>

Expand Down
23 changes: 11 additions & 12 deletions fcrepo-generator-dc/src/test/resources/spring-test/repo.xml
@@ -1,23 +1,22 @@
<?xml version="1.0" encoding="UTF-8"?>
<beans xmlns="http://www.springframework.org/schema/beans"
xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
xmlns:context="http://www.springframework.org/schema/context"
xsi:schemaLocation="
xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
xmlns:context="http://www.springframework.org/schema/context"
xmlns:p="http://www.springframework.org/schema/p"
xsi:schemaLocation="
http://www.springframework.org/schema/beans http://www.springframework.org/schema/beans/spring-beans-3.0.xsd
http://www.springframework.org/schema/context http://www.springframework.org/schema/context/spring-context-3.0.xsd">

<!-- Context that supports the actual ModeShape JCR itself -->
<!-- Context that supports the actual ModeShape JCR itself -->

<context:annotation-config/>
<context:annotation-config/>

<context:property-placeholder/>
<context:property-placeholder/>

<bean name="modeshapeRepofactory"
class="org.fcrepo.kernel.spring.ModeShapeRepositoryFactoryBean">
<property name="repositoryConfiguration" value="${fcrepo.modeshape.configuration:/config/rest-sessions/repository.json}"/>
</bean>
<bean name="modeshapeRepofactory"
class="org.fcrepo.kernel.spring.ModeShapeRepositoryFactoryBean"
p:repositoryConfiguration="${fcrepo.modeshape.configuration:/config/rest-sessions/repository.json}"/>


<bean class="org.modeshape.jcr.JcrRepositoryFactory"/>
<bean class="org.modeshape.jcr.JcrRepositoryFactory"/>

</beans>
Expand Up @@ -2,19 +2,18 @@
<beans xmlns="http://www.springframework.org/schema/beans"
xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
xmlns:context="http://www.springframework.org/schema/context"
xmlns:p="http://www.springframework.org/schema/p"
xsi:schemaLocation="http://www.springframework.org/schema/beans http://www.springframework.org/schema/beans/spring-beans-3.0.xsd
http://www.springframework.org/schema/context http://www.springframework.org/schema/context/spring-context-3.0.xsd">

<context:property-placeholder/>

<!-- show stack traces for easier debugging -->
<bean id="wildcardExceptionmapper" class="org.fcrepo.http.commons.exceptionhandlers.WildcardExceptionMapper" >
<property name="showStackTrace" value="true" />
</bean>
<bean id="wildcardExceptionmapper" class="org.fcrepo.http.commons.exceptionhandlers.WildcardExceptionMapper"
p:showStackTrace="true"/>

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

</beans>
19 changes: 0 additions & 19 deletions fcrepo-http-api/src/main/resources/META-INF/spring/rest.xml

This file was deleted.

20 changes: 0 additions & 20 deletions fcrepo-http-api/src/main/resources/logback.xml

This file was deleted.

4 changes: 0 additions & 4 deletions fcrepo-http-api/src/main/resources/velocity.properties

This file was deleted.

13 changes: 0 additions & 13 deletions fcrepo-http-api/src/main/resources/views/common-breadcrumb.vsl

This file was deleted.

10 changes: 0 additions & 10 deletions fcrepo-http-api/src/main/resources/views/common-head.vsl

This file was deleted.

0 comments on commit a8f930f

Please sign in to comment.