java - Spring boot 配置spring.jackson.serialization-inclusion無效
問題描述
在學習spring boot時配置Jackson遇到一個配置spring.jackson.serialization-inclusion無效,配置在一起的date-format是有效的,查了一大圈資料,感覺應該可以才對!
github上的問題鏈接:https://github.com/spring-pro...
參照github上配的,spring boot是 1.5.1版本,不知道為什么不起作用,項目中的配置:
#Jackson配置spring.jackson: serialization-inclusion: non_null date-format: yyyy/MM/dd HH:mm:ss
界面的輸出:
{ 'color': '#1e90ff', 'color0': null, 'type': 'dashed', 'width': 2, 'shadowColor': null, 'shadowBlur': null, 'shadowOffsetX': null, 'shadowOffsetY': null, 'normal': null, 'emphasis': null}##這是另一個例子{'id':1,'email':null,'name':'jack','birth':'2017/02/28 14:43:00'}
問題解答
回答1:配置 spring.jackson.default-property-inclusion
相關文章:
1. mac里的docker如何命令行開啟呢?2. 關于docker下的nginx壓力測試3. docker - 各位電腦上有多少個容器?。咳萜饕欢?,自己都搞混了,咋辦呢?4. nignx - docker內nginx 80端口被占用5. 關docker hub上有些鏡像的tag被標記““This image has vulnerabilities””6. docker容器呢SSH為什么連不通呢?7. Docker for Mac 創建的dnsmasq容器連不上/不工作的問題8. docker 下面創建的IMAGE 他們的 ID 一樣?這個是怎么回事????9. angular.js使用$resource服務把數據存入mongodb的問題。10. docker-compose 為何找不到配置文件?

網公網安備