1 <?xml version=
"1.0" encoding=
"UTF-8"?>
2 <beans xmlns=
"http://www.springframework.org/schema/beans"
3 xmlns:
xsi=
"http://www.w3.org/2001/XMLSchema-instance"
4 xmlns:
tx=
"http://www.springframework.org/schema/tx"
5 xmlns:
context=
"http://www.springframework.org/schema/context"
6 xsi:
schemaLocation=
"http://www.springframework.org/schema/beans http://www.springframework.org/schema/beans/spring-beans-2.5.xsd
7 http://www.springframework.org/schema/context http://www.springframework.org/schema/context/spring-context-2.5.xsd
8 http://www.springframework.org/schema/tx http://www.springframework.org/schema/tx/spring-tx-2.5.xsd
11 <bean id=
"genericApiCardinalityPropertyFilter" class=
"eu.etaxonomy.cdm.remote.json.util.CardinalityPropertyFilter">
12 <property name=
"includeToOneRelations" value=
"false" />
13 <property name=
"includeToManyRelations" value=
"false" />
14 <property name=
"exceptions">
16 <value>FeatureTree.root
</value>
17 <value>FeatureNode.children
</value>
18 <value>FeatureNode.feature
</value>
20 <value>TreeNode.data
</value>
21 <value>TreeNode.data
</value>
23 <value>PolytomousKey.root
</value>
24 <value>PolytomousKeyNode.children
</value>
25 <value>PolytomousKeyNode.question
</value>
26 <value>PolytomousKeyNode.feature
</value>
27 <value>PolytomousKeyNode.statement
</value>
28 <value>PolytomousKeyNode.modifyingText
</value>
30 <value>Media.representations
</value>
31 <value>MediaRepresentation.parts
</value>
33 <value>Annotation.annotationType
</value>
35 <value>DerivationEvent.derivatives
</value>
36 <value>DerivationEvent.originals
</value>
38 <!-- CardinalityPropertyFilter should allow defining exceptions for abstract super classes : -->
39 <!-- <value>eu.etaxonomy.cdm.model.description.DescriptionElementBase.feature</value> -->
41 <value>Synonym.sec
</value>
42 <value>Taxon.sec
</value>
44 <value>TextData.feature
</value>
45 <value>CategoricalData.feature
</value>
46 <value>CommonTaxonName.feature
</value>
47 <value>Distribution.feature
</value>
48 <value>IndividualsAssociation.feature
</value>
49 <value>QuantitativeData.feature
</value>
50 <value>TaxonInteraction.feature
</value>
51 <value>TextData.feature
</value>
52 <value>IdentifiableSource.citation
</value>
54 <value>SearchResult.entity
</value>
59 <bean id=
"nameCatalogueApiCardinalityPropertyFilter" class=
"eu.etaxonomy.cdm.remote.json.util.CardinalityPropertyFilter">
60 <property name=
"includeToOneRelations" value=
"true" />
61 <property name=
"includeToManyRelations" value=
"true" />
62 <property name=
"exceptions">
69 =================================================
70 default configuration for RESTful read(/write) service
71 =================================================
73 <bean name=
"jsonConfig" class=
"eu.etaxonomy.cdm.remote.json.JsonConfigFactoryBean"
75 <property name=
"jsonBeanProcessorMatcher">
77 class=
"eu.etaxonomy.cdm.remote.json.processor.matcher.CdmProxyBeanProcessorMatcher" />
79 <property name=
"jsonBeanProcessors">
81 <entry key=
"org.hibernate.proxy.HibernateProxy">
82 <bean class=
"eu.etaxonomy.cdm.remote.json.processor.bean.HibernateProxyBeanProcessor" />
84 <entry key=
"eu.etaxonomy.cdm.model.common.TermBase">
85 <bean class=
"eu.etaxonomy.cdm.remote.json.processor.bean.TermBaseBeanProcessor">
86 <property name=
"excludes">
87 <set value-type=
"java.lang.String">
88 <value>partOf
</value><!-- FIXME exclude partOf to avoid lazy loading exceptions -->
89 <value>kindOf
</value><!-- FIXME exclude kindOf to avoid lazy loading exceptions -->
90 <value>infraGenericMarker
</value><!-- FIXME leads to IllegalStateException if not excluded -->
95 <entry key=
"eu.etaxonomy.cdm.model.description.TextData">
96 <bean class=
"eu.etaxonomy.cdm.remote.json.processor.bean.TextDataBeanProcessor" />
98 <entry key=
"eu.etaxonomy.cdm.model.taxon.TaxonNode">
99 <bean class=
"eu.etaxonomy.cdm.remote.json.processor.bean.TaxonNodeBeanProcessor" />
101 <entry key=
"eu.etaxonomy.cdm.model.reference.Reference">
102 <bean class=
"eu.etaxonomy.cdm.remote.json.processor.bean.ReferenceBaseBeanProcessor"/>
104 <entry key=
"eu.etaxonomy.cdm.model.name.TypeDesignationBase">
105 <bean class=
"eu.etaxonomy.cdm.remote.json.processor.bean.TypeDesignationBaseBeanProcessor"/>
107 <entry key=
"eu.etaxonomy.cdm.model.description.KeyStatement">
108 <bean class=
"eu.etaxonomy.cdm.remote.json.processor.bean.KeyStatementBeanProcessor" />
110 <entry key=
"eu.etaxonomy.cdm.model.agent.TeamOrPersonBase">
111 <bean class=
"eu.etaxonomy.cdm.remote.json.processor.bean.TeamOrPersonBaseBeanProcessor" />
113 <entry key=
"org.apache.lucene.document.Document">
114 <bean class=
"eu.etaxonomy.cdm.remote.json.processor.bean.LuceneDocumentBeanProcessor" />
118 <property name=
"jsonPropertyFilter">
119 <bean class=
"net.sf.json.filters.OrPropertyFilter">
121 <bean class=
"eu.etaxonomy.cdm.remote.json.util.InitializedHibernatePropertyFilter" />
123 <constructor-arg ref=
"genericApiCardinalityPropertyFilter">
127 <property name=
"jsonValueProcessors">
129 <entry key=
"org.hibernate.proxy.HibernateProxy">
131 class=
"eu.etaxonomy.cdm.remote.json.processor.value.HibernateJSONValueProcessor" />
133 <entry key=
"java.util.UUID">
135 class=
"eu.etaxonomy.cdm.remote.json.processor.value.UUIDJSONValueProcessor" />
137 <entry key=
"org.joda.time.DateTime">
139 class=
"eu.etaxonomy.cdm.remote.json.processor.value.DateTimeJSONValueProcessor" />
141 <entry key=
"java.util.Calendar">
143 class=
"eu.etaxonomy.cdm.remote.json.processor.value.CalendarJSONValueProcessor" />
145 <entry key=
"org.joda.time.Partial">
147 class=
"eu.etaxonomy.cdm.remote.json.processor.value.PartialJSONValueProcessor" />
149 <entry key=
"java.lang.Class">
151 class=
"eu.etaxonomy.cdm.remote.json.processor.value.ClassJSONValueProcessor" />
153 <entry key=
"java.util.Map">
154 <bean class=
"eu.etaxonomy.cdm.remote.json.processor.value.MapJSONValueProcessor" />
156 <entry key=
"java.net.URI">
157 <bean class=
"eu.etaxonomy.cdm.remote.json.processor.value.URIJSONValueProcessor"/>
161 <property name=
"ignoreDefaultExcludes" value=
"true" />
162 <property name=
"excludes">
163 <list value-type=
"java.lang.String">
164 <value>declaringClass
</value><!-- DefaultExclude -->
165 <value>metaClass
</value><!-- DefaultExclude -->
167 <value>cacheStrategy
</value>
168 <value>createdBy
</value>
169 <value>updatedBy
</value>
175 =================================================
176 configuration for RESTful classification service
177 =================================================
179 <bean name=
"jsonConfigClassification" class=
"eu.etaxonomy.cdm.remote.json.JsonConfigFactoryBean"
181 <property name=
"jsonBeanProcessorMatcher">
183 class=
"eu.etaxonomy.cdm.remote.json.processor.matcher.HibernateProxyBeanProcessorMatcher" />
185 <property name=
"jsonBeanProcessors">
187 <entry key=
"org.hibernate.proxy.HibernateProxy">
189 class=
"eu.etaxonomy.cdm.remote.json.processor.bean.HibernateProxyBeanProcessor" />
191 <entry key=
"eu.etaxonomy.cdm.model.taxon.TaxonNode">
193 class=
"eu.etaxonomy.cdm.remote.json.processor.bean.TaxonNodeDaoBeanProcessor" />
197 <property name=
"jsonPropertyFilter">
198 <bean class=
"net.sf.json.filters.OrPropertyFilter">
200 <bean class=
"eu.etaxonomy.cdm.remote.json.util.InitializedHibernatePropertyFilter" />
202 <constructor-arg ref=
"genericApiCardinalityPropertyFilter">
206 <property name=
"jsonValueProcessors">
208 <entry key=
"org.hibernate.proxy.HibernateProxy">
210 class=
"eu.etaxonomy.cdm.remote.json.processor.value.HibernateJSONValueProcessor" />
212 <entry key=
"java.util.UUID">
214 class=
"eu.etaxonomy.cdm.remote.json.processor.value.UUIDJSONValueProcessor" />
216 <entry key=
"org.joda.time.DateTime">
218 class=
"eu.etaxonomy.cdm.remote.json.processor.value.DateTimeJSONValueProcessor" />
220 <entry key=
"java.util.Calendar">
222 class=
"eu.etaxonomy.cdm.remote.json.processor.value.CalendarJSONValueProcessor" />
224 <entry key=
"org.joda.time.Partial">
226 class=
"eu.etaxonomy.cdm.remote.json.processor.value.PartialJSONValueProcessor" />
228 <entry key=
"java.lang.Class">
230 class=
"eu.etaxonomy.cdm.remote.json.processor.value.ClassJSONValueProcessor" />
232 <entry key=
"java.util.Map">
233 <bean class=
"eu.etaxonomy.cdm.remote.json.processor.value.MapJSONValueProcessor" />
235 <entry key=
"java.net.URI">
236 <bean class=
"eu.etaxonomy.cdm.remote.json.processor.value.URIJSONValueProcessor"/>
240 <property name=
"ignoreDefaultExcludes" value=
"true" />
241 <property name=
"excludes">
242 <list value-type=
"java.lang.String">
243 <value>declaringClass
</value><!-- DefaultExclude -->
244 <value>metaClass
</value><!-- DefaultExclude -->
246 <value>cacheStrategy
</value>
247 <value>createdBy
</value>
248 <value>updatedBy
</value>
254 =================================================
255 configuration for RESTful portal service
256 =================================================
259 <bean name=
"jsonConfigPortal" class=
"eu.etaxonomy.cdm.remote.json.JsonConfigFactoryBean"
261 <property name=
"jsonBeanProcessorMatcher">
263 class=
"eu.etaxonomy.cdm.remote.json.processor.matcher.CdmProxyBeanProcessorMatcher" />
265 <property name=
"jsonBeanProcessors">
267 <entry key=
"org.hibernate.proxy.HibernateProxy">
269 class=
"eu.etaxonomy.cdm.remote.json.processor.bean.HibernateProxyBeanProcessor" />
271 <entry key=
"eu.etaxonomy.cdm.model.taxon.Taxon">
272 <bean class=
"eu.etaxonomy.cdm.remote.json.processor.bean.TaxonBeanProcessor" />
274 <entry key=
"eu.etaxonomy.cdm.model.name.TaxonNameBase">
276 class=
"eu.etaxonomy.cdm.remote.json.processor.bean.TaxonNameBaseBeanProcessor" />
278 <entry key=
"eu.etaxonomy.cdm.model.name.NameRelationship">
280 class=
"eu.etaxonomy.cdm.remote.json.processor.bean.NameRelationshipBeanProcessor" />
282 <entry key=
"eu.etaxonomy.cdm.model.taxon.TaxonRelationship">
284 class=
"eu.etaxonomy.cdm.remote.json.processor.bean.TaxonRelationshipBeanProcessor" />
286 <entry key=
"eu.etaxonomy.cdm.model.common.TermBase">
288 class=
"eu.etaxonomy.cdm.remote.json.processor.bean.TermBaseBeanProcessor">
289 <property name=
"replaceRepresentations" value=
"true" />
290 <property name=
"excludes">
291 <set value-type=
"java.lang.String">
292 <value>infraGenericMarker
</value><!-- FIXME leads to IllegalStateException if not excluded -->
293 <value>partOf
</value><!-- DefinedTermBase -->
294 <value>kindOf
</value><!-- DefinedTermBase -->
295 <value>includes
</value><!-- DefinedTermBase -->
296 <value>generalizationOf
</value><!-- DefinedTermBase -->
297 <value>vocabulary
</value><!-- DefinedTermBase -->
299 FIXME must exclude partOf, kindOf, includes, generalizationOf .. to
300 avoid class cast or lazy loading exceptions in TDWG Areas
306 <entry key=
"eu.etaxonomy.cdm.model.description.TextData">
308 class=
"eu.etaxonomy.cdm.remote.json.processor.bean.TextDataBeanProcessor">
309 <property name=
"replaceMultilanguageText" value=
"true" />
312 <entry key=
"eu.etaxonomy.cdm.model.media.Media">
313 <bean class=
"eu.etaxonomy.cdm.remote.json.processor.bean.MediaBeanProcessor">
314 <property name=
"replaceTitle" value=
"true" />
315 <property name=
"replaceDescription" value=
"true" />
318 <entry key=
"eu.etaxonomy.cdm.model.reference.Reference">
319 <bean class=
"eu.etaxonomy.cdm.remote.json.processor.bean.ReferenceBaseBeanProcessor"/>
321 <entry key=
"eu.etaxonomy.cdm.model.description.TaxonNameDescription">
322 <bean class=
"eu.etaxonomy.cdm.remote.json.processor.bean.TaxonNameDescriptionBeanProcessor">
323 <property name=
"excludes">
324 <set value-type=
"java.lang.String">
325 <value>taxonName
</value>
330 <entry key=
"eu.etaxonomy.cdm.api.facade.DerivedUnitFacade">
331 <bean class=
"eu.etaxonomy.cdm.remote.json.processor.bean.DerivedUnitFacadeBeanProcessor"/>
333 <entry key=
"eu.etaxonomy.cdm.model.location.Point">
334 <bean class=
"eu.etaxonomy.cdm.remote.json.processor.bean.PointBeanProcessor"/>
336 <entry key=
"eu.etaxonomy.cdm.model.agent.TeamOrPersonBase">
337 <bean class=
"eu.etaxonomy.cdm.remote.json.processor.bean.TeamOrPersonBaseBeanProcessor" />
339 <entry key=
"org.apache.lucene.document.Document">
340 <bean class=
"eu.etaxonomy.cdm.remote.json.processor.bean.LuceneDocumentBeanProcessor" />
344 <property name=
"jsonPropertyFilter">
345 <bean class=
"eu.etaxonomy.cdm.remote.json.util.InitializedHibernatePropertyFilter" />
347 <property name=
"jsonValueProcessors">
349 <entry key=
"org.hibernate.proxy.HibernateProxy">
351 class=
"eu.etaxonomy.cdm.remote.json.processor.value.HibernateJSONValueProcessor" />
353 <entry key=
"java.util.UUID">
355 class=
"eu.etaxonomy.cdm.remote.json.processor.value.UUIDJSONValueProcessor" />
357 <entry key=
"org.joda.time.DateTime">
359 class=
"eu.etaxonomy.cdm.remote.json.processor.value.DateTimeJSONValueProcessor" />
361 <entry key=
"java.util.Calendar">
363 class=
"eu.etaxonomy.cdm.remote.json.processor.value.CalendarJSONValueProcessor" />
365 <entry key=
"org.joda.time.Partial">
367 class=
"eu.etaxonomy.cdm.remote.json.processor.value.PartialJSONValueProcessor" />
371 <entry key=
"java.lang.Class">
373 class=
"eu.etaxonomy.cdm.remote.json.processor.value.ClassJSONValueProcessor" />
375 <entry key=
"java.util.Map">
376 <bean class=
"eu.etaxonomy.cdm.remote.json.processor.value.MapJSONValueProcessor" />
378 <entry key=
"java.net.URI">
379 <bean class=
"eu.etaxonomy.cdm.remote.json.processor.value.URIJSONValueProcessor"/>
383 <property name=
"ignoreDefaultExcludes" value=
"true" />
384 <property name=
"excludes">
385 <list value-type=
"java.lang.String">
386 <value>declaringClass
</value><!-- DefaultExclude -->
387 <value>metaClass
</value><!-- DefaultExclude -->
389 <value>annotations
</value>
390 <value>cacheStrategy
</value>
391 <value>markers
</value>
392 <value>createdBy
</value>
393 <value>updatedBy
</value>
394 <value>inDescription
</value>
400 =================================================
401 default configuration name catalogue service
402 =================================================
404 <bean name=
"nameCatalogueJsonConfig" class=
"eu.etaxonomy.cdm.remote.json.JsonConfigFactoryBean"
406 <property name=
"jsonPropertyFilter">
407 <bean class=
"net.sf.json.filters.OrPropertyFilter">
409 <bean class=
"eu.etaxonomy.cdm.remote.json.util.InitializedHibernatePropertyFilter" />
411 <constructor-arg ref=
"nameCatalogueApiCardinalityPropertyFilter">
415 <property name=
"jsonValueProcessors">
417 <entry key=
"org.hibernate.proxy.HibernateProxy">
419 class=
"eu.etaxonomy.cdm.remote.json.processor.value.HibernateJSONValueProcessor" />
421 <entry key=
"java.util.UUID">
423 class=
"eu.etaxonomy.cdm.remote.json.processor.value.UUIDJSONValueProcessor" />
425 <entry key=
"org.joda.time.DateTime">
427 class=
"eu.etaxonomy.cdm.remote.json.processor.value.DateTimeJSONValueProcessor" />
429 <entry key=
"java.util.Calendar">
431 class=
"eu.etaxonomy.cdm.remote.json.processor.value.CalendarJSONValueProcessor" />
433 <entry key=
"org.joda.time.Partial">
435 class=
"eu.etaxonomy.cdm.remote.json.processor.value.PartialJSONValueProcessor" />
437 <entry key=
"java.util.Map">
438 <bean class=
"eu.etaxonomy.cdm.remote.json.processor.value.MapJSONValueProcessor" />
440 <entry key=
"java.net.URI">
441 <bean class=
"eu.etaxonomy.cdm.remote.json.processor.value.URIJSONValueProcessor"/>
446 <property name=
"ignoreDefaultExcludes" value=
"true" />
447 <property name=
"excludes">
448 <list value-type=
"java.lang.String">
450 <value>declaringClass
</value><!-- DefaultExclude -->
451 <value>metaClass
</value><!-- DefaultExclude -->
453 <value>cacheStrategy
</value>
454 <value>createdBy
</value>
455 <value>updatedBy
</value>