![](https://img-blog.csdnimg.cn/20201014180756780.png?x-oss-process=image/resize,m_fixed,h_64,w_64)
spring
mengmengdastyle
天地有情尽白发,人间无意了沧桑!
展开
-
spring5 | 学习途径
之前用的是spring4,最近研究一下spring5的特性。喜欢系统化的学习,做个学习目录笔记。 未完待续。。。原创 2018-05-08 16:12:34 · 619 阅读 · 0 评论 -
使用 RestTemplate 发送 post 或请求传递参数
一、介绍 传统情况下在java代码里访问restful服务,一般使用Apache的HttpClient。不过此种方法使用起来太过繁琐。spring提供了一种简单便捷的模板类来进行操作,这就是RestTemplate。 二、添加header 在我们向服务端发送请求时,还必须向服务器发送一个叫“Content-Length”的请求头(Request Header)。 作用:在header中...原创 2018-07-13 13:37:00 · 29562 阅读 · 6 评论