-
Notifications
You must be signed in to change notification settings - Fork 41.5k
Closed
Description
Version: Spring Boot 2.3.x
Minimal example: Autowiring for instance an objectMapper into a custom AttributeConverter works fine with all versions of spring-boot v2.2.x. However, when upgrading to spring-boot 2.3.0 the objectMapper is no longer autowired and the application freezes indefinitely and doesn't start up.
Example of AttributeConverter:
@Component
public class StringListToJsonConverter implements AttributeConverter<List<String>, String> {
private static ObjectMapper objectMapper;
@Autowired
public void init(ObjectMapper objectMapper) {
this.objectMapper = objectMapper;
}
@Override
public String convertToDatabaseColumn(List<String> documentObj) {
// Do some logic...
}
@Override
public List<String> convertToEntityAttribute(String documentStr) {
// Do some logic...
}
}
Metadata
Metadata
Assignees
Labels
type: documentationA documentation updateA documentation update