Fixed the logback serialization issue addressed in Cosmos DB SDK (#447)
This commit is contained in:
Родитель
8dd6025ec7
Коммит
0dedf3db15
2
pom.xml
2
pom.xml
|
@ -58,7 +58,7 @@
|
|||
<gson.version>2.8.4</gson.version>
|
||||
<project.reactor.test.version>3.3.0.RELEASE</project.reactor.test.version>
|
||||
|
||||
<azure.cosmos.version>3.3.0</azure.cosmos.version>
|
||||
<azure.cosmos.version>3.3.1</azure.cosmos.version>
|
||||
<azure.test.resourcegroup>spring-data-cosmosdb-test</azure.test.resourcegroup>
|
||||
<azure.test.dbname>testdb-${maven.build.timestamp}</azure.test.dbname>
|
||||
<skip.integration.tests>true</skip.integration.tests>
|
||||
|
|
|
@ -8,7 +8,6 @@ package com.microsoft.azure.spring.data.cosmosdb.core.convert;
|
|||
import com.azure.data.cosmos.CosmosItemProperties;
|
||||
import com.azure.data.cosmos.internal.Utils;
|
||||
import com.azure.data.cosmos.internal.query.QueryItem;
|
||||
import com.fasterxml.jackson.annotation.JsonIgnore;
|
||||
import com.fasterxml.jackson.core.JsonProcessingException;
|
||||
import com.fasterxml.jackson.databind.ObjectMapper;
|
||||
import com.microsoft.azure.spring.data.cosmosdb.Constants;
|
||||
|
@ -16,7 +15,6 @@ import com.microsoft.azure.spring.data.cosmosdb.core.mapping.CosmosPersistentEnt
|
|||
import com.microsoft.azure.spring.data.cosmosdb.core.mapping.CosmosPersistentProperty;
|
||||
import com.microsoft.azure.spring.data.cosmosdb.exception.CosmosDBAccessException;
|
||||
import org.json.JSONObject;
|
||||
import org.slf4j.Logger;
|
||||
import org.springframework.beans.factory.annotation.Qualifier;
|
||||
import org.springframework.context.ApplicationContext;
|
||||
import org.springframework.context.ApplicationContextAware;
|
||||
|
@ -54,11 +52,6 @@ public class MappingCosmosConverter
|
|||
this.conversionService = new GenericConversionService();
|
||||
this.objectMapper = objectMapper == null ? ObjectMapperFactory.getObjectMapper() :
|
||||
objectMapper;
|
||||
|
||||
// CosmosDB SDK serializes and deserializes logger, which causes this issue:
|
||||
// https://github.com/microsoft/spring-data-cosmosdb/issues/423
|
||||
// This is a temporary fix while CosmosDB fixes this problem.
|
||||
Utils.getSimpleObjectMapper().addMixIn(QueryItem.class, QueryItemMixIn.class);
|
||||
}
|
||||
|
||||
@Override
|
||||
|
@ -185,9 +178,4 @@ public class MappingCosmosConverter
|
|||
|
||||
return fromPropertyValue;
|
||||
}
|
||||
|
||||
interface QueryItemMixIn {
|
||||
@JsonIgnore
|
||||
Logger getLogger();
|
||||
}
|
||||
}
|
||||
|
|
Загрузка…
Ссылка в новой задаче