Added setting default access scopes in the config file & fixed #21.
Change-Id: Ic9cdf2c1aed100d6c0aa37f4d1195a3f6f2c3fda
diff --git a/full/src/main/resources/default-config.xml b/full/src/main/resources/default-config.xml
index 955d197..eef04e8 100644
--- a/full/src/main/resources/default-config.xml
+++ b/full/src/main/resources/default-config.xml
@@ -56,11 +56,6 @@
class='org.springframework.cache.ehcache.EhCacheManagerFactoryBean'
p:configLocation='classpath:ehcache.xml' p:shared='true' />
- <!-- props are injected from default-config.xml -->
- <bean id="kustvakt_config" class="de.ids_mannheim.korap.config.FullConfiguration">
- <constructor-arg name="properties" ref="props" />
- </bean>
-
<!--class="org.apache.commons.dbcp2.BasicDataSource" -->
<!-- org.springframework.jdbc.datasource.SingleConnectionDataSource -->
<bean id="dataSource" class="org.apache.commons.dbcp2.BasicDataSource"
@@ -163,7 +158,18 @@
<!-- Data access objects -->
<bean id="resourceDao" class="de.ids_mannheim.korap.dao.ResourceDao" />
- <!-- <bean id="annotationDao" class="de.ids_mannheim.korap.dao.AnnotationDao"/> -->
+ <bean id="accessScopeDao" class="de.ids_mannheim.korap.oauth2.dao.AccessScopeDao" />
+
+ <!-- props are injected from default-config.xml -->
+ <bean id="kustvakt_config" class="de.ids_mannheim.korap.config.FullConfiguration">
+ <constructor-arg name="properties" ref="props" />
+ </bean>
+
+ <bean id="initializator" class="de.ids_mannheim.korap.config.Initializator"
+ init-method="init">
+ <constructor-arg name="config" ref="kustvakt_config" />
+ <constructor-arg name="accessScopeDao" ref="accessScopeDao" />
+ </bean>
<!-- Krill -->
<bean id="search_krill" class="de.ids_mannheim.korap.web.SearchKrill">