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">
17 the exceptions listed here should be covered by implementations of
18 eu.etaxonomy.cdm.persistence.dao.AutoPropertyInitializer.
19 The according configuration files are
20 - /cdmlib-persistence/src/main/resources/eu/etaxonomy/cdm/persistence_security.xml
21 - /cdmlib-persistence/src/main/resources/eu/etaxonomy/cdm/persistence.xml
22 whereas persistence.xml will be removed in the near future.
24 <value>FeatureTree.root
</value>
25 <value>FeatureNode.children
</value>
26 <value>FeatureNode.feature
</value>
28 <value>TreeNode.data
</value>
29 <value>TreeNode.data
</value>
31 <value>PolytomousKey.root
</value>
32 <value>PolytomousKeyNode.children
</value>
33 <value>PolytomousKeyNode.question
</value>
34 <value>PolytomousKeyNode.feature
</value>
35 <value>PolytomousKeyNode.statement
</value>
36 <value>PolytomousKeyNode.modifyingText
</value>
38 <value>LinkedPolytomousKeyNodeRowDto.childStatement
</value>
39 <value>LinkedPolytomousKeyNodeRowDto.rowQuestion
</value>
40 <value>LinkedPolytomousKeyNodeRowDto.rowFeature
</value>
41 <!-- value>LinkedPolytomousKeyNodeRowDto.keyNode</value-->
43 <value>Media.representations</value>
44 <value>MediaRepresentation.parts</value>
46 <value>Sequence.locus</value>
47 <value>Sequence.genBankAccession</value>
49 <value>Annotation.annotationType</value>
51 <value>DerivationEvent.derivatives</value>
52 <value>DerivationEvent.originals</value>
54 <value>Point.referenceSystem</value>
56 <!-- CardinalityPropertyFilter should allow defining exceptions for abstract super classes : -->
57 <!-- <value>eu.etaxonomy.cdm.model.description.DescriptionElementBase.feature</value> -->
59 <value>Synonym.sec
</value>
60 <value>Taxon.sec
</value>
62 <value>StateData.state
</value>
63 <value>StateData.modifiers
</value>
64 <value>StateData.modifyingText
</value>
66 <value>TextData.feature
</value>
67 <value>CategoricalData.feature
</value>
68 <value>CommonTaxonName.feature
</value>
69 <value>Distribution.feature
</value>
70 <value>IndividualsAssociation.feature
</value>
71 <value>QuantitativeData.feature
</value>
72 <value>TaxonInteraction.feature
</value>
73 <value>TextData.feature
</value>
74 <value>IdentifiableSource.citation
</value>
76 <value>SearchResult.entity
</value>
81 <bean id=
"nameCatalogueApiCardinalityPropertyFilter" class=
"eu.etaxonomy.cdm.remote.json.util.CardinalityPropertyFilter">
82 <property name=
"includeToOneRelations" value=
"true" />
83 <property name=
"includeToManyRelations" value=
"true" />
84 <property name=
"exceptions">
91 =================================================
92 default configuration for RESTful read(/write) service
93 =================================================
95 <bean name=
"jsonConfig" class=
"eu.etaxonomy.cdm.remote.json.JsonConfigFactoryBean"
97 <property name=
"jsonBeanProcessorMatcher">
99 class=
"eu.etaxonomy.cdm.remote.json.processor.matcher.CdmProxyBeanProcessorMatcher" />
101 <property name=
"jsonBeanProcessors">
103 <entry key=
"org.hibernate.proxy.HibernateProxy">
104 <bean class=
"eu.etaxonomy.cdm.remote.json.processor.bean.HibernateProxyBeanProcessor" />
106 <entry key=
"eu.etaxonomy.cdm.model.common.TermBase">
107 <bean class=
"eu.etaxonomy.cdm.remote.json.processor.bean.TermBaseBeanProcessor">
108 <property name=
"excludes">
109 <set value-type=
"java.lang.String">
110 <value>partOf
</value><!-- FIXME exclude partOf to avoid lazy loading exceptions -->
111 <value>kindOf
</value><!-- FIXME exclude kindOf to avoid lazy loading exceptions -->
112 <value>infraGenericMarker
</value><!-- FIXME leads to IllegalStateException if not excluded -->
117 <entry key=
"eu.etaxonomy.cdm.model.description.TextData">
118 <bean class=
"eu.etaxonomy.cdm.remote.json.processor.bean.TextDataBeanProcessor" />
120 <entry key=
"eu.etaxonomy.cdm.model.taxon.TaxonNode">
121 <bean class=
"eu.etaxonomy.cdm.remote.json.processor.bean.TaxonNodeBeanProcessor" />
123 <entry key=
"eu.etaxonomy.cdm.model.reference.Reference">
124 <bean class=
"eu.etaxonomy.cdm.remote.json.processor.bean.ReferenceBaseBeanProcessor"/>
126 <entry key=
"eu.etaxonomy.cdm.model.name.TypeDesignationBase">
127 <bean class=
"eu.etaxonomy.cdm.remote.json.processor.bean.TypeDesignationBaseBeanProcessor"/>
129 <entry key=
"eu.etaxonomy.cdm.model.description.KeyStatement">
130 <bean class=
"eu.etaxonomy.cdm.remote.json.processor.bean.KeyStatementBeanProcessor" />
132 <entry key=
"eu.etaxonomy.cdm.model.agent.TeamOrPersonBase">
133 <bean class=
"eu.etaxonomy.cdm.remote.json.processor.bean.TeamOrPersonBaseBeanProcessor" />
135 <entry key=
"org.apache.lucene.document.Document">
136 <bean class=
"eu.etaxonomy.cdm.remote.json.processor.bean.LuceneDocumentBeanProcessor" />
140 <property name=
"jsonPropertyFilter">
141 <bean class=
"net.sf.json.filters.OrPropertyFilter">
143 <bean class=
"eu.etaxonomy.cdm.remote.json.util.InitializedHibernatePropertyFilter" />
145 <constructor-arg ref=
"genericApiCardinalityPropertyFilter">
149 <property name=
"jsonValueProcessors">
151 <entry key=
"org.hibernate.proxy.HibernateProxy">
153 class=
"eu.etaxonomy.cdm.remote.json.processor.value.HibernateJSONValueProcessor" />
155 <entry key=
"java.util.UUID">
157 class=
"eu.etaxonomy.cdm.remote.json.processor.value.UUIDJSONValueProcessor" />
159 <entry key=
"org.joda.time.DateTime">
161 class=
"eu.etaxonomy.cdm.remote.json.processor.value.DateTimeJSONValueProcessor" />
163 <entry key=
"java.util.Calendar">
165 class=
"eu.etaxonomy.cdm.remote.json.processor.value.CalendarJSONValueProcessor" />
167 <entry key=
"org.joda.time.Partial">
169 class=
"eu.etaxonomy.cdm.remote.json.processor.value.PartialJSONValueProcessor" />
171 <entry key=
"java.lang.Class">
173 class=
"eu.etaxonomy.cdm.remote.json.processor.value.ClassJSONValueProcessor" />
175 <entry key=
"java.util.Map">
176 <bean class=
"eu.etaxonomy.cdm.remote.json.processor.value.MapJSONValueProcessor" />
178 <entry key=
"java.net.URI">
179 <bean class=
"eu.etaxonomy.cdm.remote.json.processor.value.URIJSONValueProcessor"/>
183 <property name=
"ignoreDefaultExcludes" value=
"true" />
184 <property name=
"excludes">
185 <list value-type=
"java.lang.String">
186 <value>declaringClass
</value><!-- DefaultExclude -->
187 <value>metaClass
</value><!-- DefaultExclude -->
189 <value>cacheStrategy
</value>
190 <value>createdBy
</value>
191 <value>updatedBy
</value>
197 =================================================
198 configuration for RESTful classification service
199 =================================================
201 <bean name=
"jsonConfigClassification" class=
"eu.etaxonomy.cdm.remote.json.JsonConfigFactoryBean"
203 <property name=
"jsonBeanProcessorMatcher">
205 class=
"eu.etaxonomy.cdm.remote.json.processor.matcher.HibernateProxyBeanProcessorMatcher" />
207 <property name=
"jsonBeanProcessors">
209 <entry key=
"org.hibernate.proxy.HibernateProxy">
211 class=
"eu.etaxonomy.cdm.remote.json.processor.bean.HibernateProxyBeanProcessor" />
213 <entry key=
"eu.etaxonomy.cdm.model.taxon.TaxonNode">
215 class=
"eu.etaxonomy.cdm.remote.json.processor.bean.TaxonNodeDaoBeanProcessor" />
219 <property name=
"jsonPropertyFilter">
220 <bean class=
"net.sf.json.filters.OrPropertyFilter">
222 <bean class=
"eu.etaxonomy.cdm.remote.json.util.InitializedHibernatePropertyFilter" />
224 <constructor-arg ref=
"genericApiCardinalityPropertyFilter">
228 <property name=
"jsonValueProcessors">
230 <entry key=
"org.hibernate.proxy.HibernateProxy">
232 class=
"eu.etaxonomy.cdm.remote.json.processor.value.HibernateJSONValueProcessor" />
234 <entry key=
"java.util.UUID">
236 class=
"eu.etaxonomy.cdm.remote.json.processor.value.UUIDJSONValueProcessor" />
238 <entry key=
"org.joda.time.DateTime">
240 class=
"eu.etaxonomy.cdm.remote.json.processor.value.DateTimeJSONValueProcessor" />
242 <entry key=
"java.util.Calendar">
244 class=
"eu.etaxonomy.cdm.remote.json.processor.value.CalendarJSONValueProcessor" />
246 <entry key=
"org.joda.time.Partial">
248 class=
"eu.etaxonomy.cdm.remote.json.processor.value.PartialJSONValueProcessor" />
250 <entry key=
"java.lang.Class">
252 class=
"eu.etaxonomy.cdm.remote.json.processor.value.ClassJSONValueProcessor" />
254 <entry key=
"java.util.Map">
255 <bean class=
"eu.etaxonomy.cdm.remote.json.processor.value.MapJSONValueProcessor" />
257 <entry key=
"java.net.URI">
258 <bean class=
"eu.etaxonomy.cdm.remote.json.processor.value.URIJSONValueProcessor"/>
262 <property name=
"ignoreDefaultExcludes" value=
"true" />
263 <property name=
"excludes">
264 <list value-type=
"java.lang.String">
265 <value>declaringClass
</value><!-- DefaultExclude -->
266 <value>metaClass
</value><!-- DefaultExclude -->
268 <value>cacheStrategy
</value>
269 <value>createdBy
</value>
270 <value>updatedBy
</value>
276 =================================================
277 configuration for RESTful portal service
278 =================================================
281 <bean name=
"jsonConfigPortal" class=
"eu.etaxonomy.cdm.remote.json.JsonConfigFactoryBean"
283 <property name=
"jsonBeanProcessorMatcher">
285 class=
"eu.etaxonomy.cdm.remote.json.processor.matcher.CdmProxyBeanProcessorMatcher" />
287 <property name=
"jsonBeanProcessors">
289 <entry key=
"org.hibernate.proxy.HibernateProxy">
291 class=
"eu.etaxonomy.cdm.remote.json.processor.bean.HibernateProxyBeanProcessor" />
293 <entry key=
"eu.etaxonomy.cdm.model.taxon.Taxon">
294 <bean class=
"eu.etaxonomy.cdm.remote.json.processor.bean.TaxonBeanProcessor" />
296 <entry key=
"eu.etaxonomy.cdm.model.name.TaxonNameBase">
298 class=
"eu.etaxonomy.cdm.remote.json.processor.bean.TaxonNameBaseBeanProcessor" />
300 <entry key=
"eu.etaxonomy.cdm.model.name.NameRelationship">
302 class=
"eu.etaxonomy.cdm.remote.json.processor.bean.NameRelationshipBeanProcessor" />
304 <entry key=
"eu.etaxonomy.cdm.model.taxon.TaxonRelationship">
306 class=
"eu.etaxonomy.cdm.remote.json.processor.bean.TaxonRelationshipBeanProcessor" />
308 <entry key=
"eu.etaxonomy.cdm.model.common.TermBase">
310 class=
"eu.etaxonomy.cdm.remote.json.processor.bean.TermBaseBeanProcessor">
311 <property name=
"replaceRepresentations" value=
"true" />
312 <property name=
"excludes">
313 <set value-type=
"java.lang.String">
314 <value>infraGenericMarker
</value><!-- FIXME leads to IllegalStateException if not excluded -->
315 <value>partOf
</value><!-- DefinedTermBase -->
316 <value>kindOf
</value><!-- DefinedTermBase -->
317 <value>includes
</value><!-- DefinedTermBase -->
318 <value>generalizationOf
</value><!-- DefinedTermBase -->
319 <value>vocabulary
</value><!-- DefinedTermBase -->
321 FIXME must exclude partOf, kindOf, includes, generalizationOf .. to
322 avoid class cast or lazy loading exceptions in TDWG Areas
328 <entry key=
"eu.etaxonomy.cdm.model.description.TextData">
330 class=
"eu.etaxonomy.cdm.remote.json.processor.bean.TextDataBeanProcessor">
331 <property name=
"replaceMultilanguageText" value=
"true" />
334 <entry key=
"eu.etaxonomy.cdm.model.media.Media">
335 <bean class=
"eu.etaxonomy.cdm.remote.json.processor.bean.MediaBeanProcessor">
336 <property name=
"replaceTitle" value=
"true" />
337 <property name=
"replaceDescription" value=
"true" />
340 <entry key=
"eu.etaxonomy.cdm.model.reference.Reference">
341 <bean class=
"eu.etaxonomy.cdm.remote.json.processor.bean.ReferenceBaseBeanProcessor"/>
343 <entry key=
"eu.etaxonomy.cdm.model.description.TaxonNameDescription">
344 <bean class=
"eu.etaxonomy.cdm.remote.json.processor.bean.TaxonNameDescriptionBeanProcessor">
345 <property name=
"excludes">
346 <set value-type=
"java.lang.String">
347 <value>taxonName
</value>
352 <entry key=
"eu.etaxonomy.cdm.api.facade.DerivedUnitFacade">
353 <bean class=
"eu.etaxonomy.cdm.remote.json.processor.bean.DerivedUnitFacadeBeanProcessor"/>
355 <entry key=
"eu.etaxonomy.cdm.model.location.Point">
356 <bean class=
"eu.etaxonomy.cdm.remote.json.processor.bean.PointBeanProcessor"/>
358 <entry key=
"eu.etaxonomy.cdm.model.agent.TeamOrPersonBase">
359 <bean class=
"eu.etaxonomy.cdm.remote.json.processor.bean.TeamOrPersonBaseBeanProcessor" />
361 <entry key=
"org.apache.lucene.document.Document">
362 <bean class=
"eu.etaxonomy.cdm.remote.json.processor.bean.LuceneDocumentBeanProcessor" />
366 <property name=
"jsonPropertyFilter">
367 <bean class=
"eu.etaxonomy.cdm.remote.json.util.InitializedHibernatePropertyFilter" />
369 <property name=
"jsonValueProcessors">
371 <entry key=
"org.hibernate.proxy.HibernateProxy">
373 class=
"eu.etaxonomy.cdm.remote.json.processor.value.HibernateJSONValueProcessor" />
375 <entry key=
"java.util.UUID">
377 class=
"eu.etaxonomy.cdm.remote.json.processor.value.UUIDJSONValueProcessor" />
379 <entry key=
"org.joda.time.DateTime">
381 class=
"eu.etaxonomy.cdm.remote.json.processor.value.DateTimeJSONValueProcessor" />
383 <entry key=
"java.util.Calendar">
385 class=
"eu.etaxonomy.cdm.remote.json.processor.value.CalendarJSONValueProcessor" />
387 <entry key=
"org.joda.time.Partial">
389 class=
"eu.etaxonomy.cdm.remote.json.processor.value.PartialJSONValueProcessor" />
391 <entry key=
"java.lang.Class">
393 class=
"eu.etaxonomy.cdm.remote.json.processor.value.ClassJSONValueProcessor" />
395 <entry key=
"java.util.Map">
396 <bean class=
"eu.etaxonomy.cdm.remote.json.processor.value.MapJSONValueProcessor" />
398 <entry key=
"java.net.URI">
399 <bean class=
"eu.etaxonomy.cdm.remote.json.processor.value.URIJSONValueProcessor"/>
403 <property name=
"ignoreDefaultExcludes" value=
"true" />
404 <property name=
"excludes">
405 <list value-type=
"java.lang.String">
406 <value>declaringClass
</value><!-- DefaultExclude -->
407 <value>metaClass
</value><!-- DefaultExclude -->
409 <value>annotations
</value>
410 <value>cacheStrategy
</value>
411 <value>markers
</value>
412 <value>createdBy
</value>
413 <value>updatedBy
</value>
414 <value>inDescription
</value>
420 =================================================
421 default configuration name catalogue service
422 =================================================
424 <bean name=
"nameCatalogueJsonConfig" class=
"eu.etaxonomy.cdm.remote.json.JsonConfigFactoryBean"
426 <property name=
"jsonPropertyFilter">
427 <bean class=
"net.sf.json.filters.OrPropertyFilter">
429 <bean class=
"eu.etaxonomy.cdm.remote.json.util.InitializedHibernatePropertyFilter" />
431 <constructor-arg ref=
"nameCatalogueApiCardinalityPropertyFilter">
435 <property name=
"jsonValueProcessors">
437 <entry key=
"org.hibernate.proxy.HibernateProxy">
439 class=
"eu.etaxonomy.cdm.remote.json.processor.value.HibernateJSONValueProcessor" />
441 <entry key=
"java.util.UUID">
443 class=
"eu.etaxonomy.cdm.remote.json.processor.value.UUIDJSONValueProcessor" />
445 <entry key=
"org.joda.time.DateTime">
447 class=
"eu.etaxonomy.cdm.remote.json.processor.value.DateTimeJSONValueProcessor" />
449 <entry key=
"java.util.Calendar">
451 class=
"eu.etaxonomy.cdm.remote.json.processor.value.CalendarJSONValueProcessor" />
453 <entry key=
"org.joda.time.Partial">
455 class=
"eu.etaxonomy.cdm.remote.json.processor.value.PartialJSONValueProcessor" />
457 <entry key=
"java.util.Map">
458 <bean class=
"eu.etaxonomy.cdm.remote.json.processor.value.MapJSONValueProcessor" />
460 <entry key=
"java.net.URI">
461 <bean class=
"eu.etaxonomy.cdm.remote.json.processor.value.URIJSONValueProcessor"/>
466 <property name=
"ignoreDefaultExcludes" value=
"true" />
467 <property name=
"excludes">
468 <list value-type=
"java.lang.String">
470 <value>declaringClass
</value><!-- DefaultExclude -->
471 <value>metaClass
</value><!-- DefaultExclude -->
473 <value>cacheStrategy
</value>
474 <value>createdBy
</value>
475 <value>updatedBy
</value>