DATACOUCH-30 - ObjectMapper configuration must be supported
Allow for a custom ObjectMapper to be used.
This commit is contained in:
committed by
Michael Nitschinger
parent
51dea603de
commit
7d79d79e28
@@ -7,6 +7,10 @@
|
||||
|
||||
<couchbase:couchbase/>
|
||||
|
||||
<couchbase:couchbase id="couchbase2" host="localhost" bucket="default" password="" />
|
||||
<couchbase:couchbase id="couchbase2" host="localhost" bucket="default" password=""/>
|
||||
|
||||
<couchbase:translation-service objectMapper="myCustomObjectMapper"/>
|
||||
|
||||
<bean id="myCustomObjectMapper" class="com.fasterxml.jackson.databind.ObjectMapper"/>
|
||||
|
||||
</beans>
|
||||
@@ -0,0 +1,14 @@
|
||||
<?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:couchbase="http://www.springframework.org/schema/data/couchbase"
|
||||
xsi:schemaLocation="http://www.springframework.org/schema/data/couchbase http://www.springframework.org/schema/data/couchbase/spring-couchbase.xsd
|
||||
http://www.springframework.org/schema/beans http://www.springframework.org/schema/beans/spring-beans.xsd">
|
||||
|
||||
<couchbase:couchbase/>
|
||||
|
||||
<couchbase:template translation-service-ref="myCustomTranslationService"/>
|
||||
|
||||
<bean id="myCustomTranslationService" class="org.springframework.data.couchbase.core.convert.translation.JacksonTranslationService"/>
|
||||
|
||||
</beans>
|
||||
Reference in New Issue
Block a user