Тёмный

🚀 New in Spring Framework 6.1: RestClient 

Maciej Walkowiak 🍃 Spring Academy
Подписаться 17 тыс.
Просмотров 10 тыс.
50% 1

#springboot #springframework
Spring Framework 6.1 introduces a new way to interact with HTTP services: RestClient.
In this video you will learn:
- why a new HTTP client in Spring stack
- how RestClient is different from RestTemplate and WebClient
- how to use RestClient with Spring Boot
- how to use RestClient with declarative HTTP interfaces introduced in Spring Framework 6
Follow me on twitter for more Java & Spring updates: / maciejwalkowiak
0:00 Why do we need a new HTTP client?
1:45 RestClient in action
8:03 RestClient with declarative HTTP interfaces
10:32 Things you should know
11:57 Will I use RestClient in new project?

Наука

Опубликовано:

 

26 июл 2024

Поделиться:

Ссылка:

Скачать:

Готовим ссылку...

Добавить в:

Мой плейлист
Посмотреть позже
Комментарии : 43   
@pad5724
@pad5724 11 месяцев назад
Excellent, thanks.. I hope you will continue to upload often ☺️
@SpringAcademy
@SpringAcademy 11 месяцев назад
Thank you! That's the plan 🙂
@LeonardoMarcelino
@LeonardoMarcelino 9 месяцев назад
That's so nice! The declarative option using interface is very useful.
@oddybassey8474
@oddybassey8474 11 месяцев назад
loved how you gave really good and concise examples and explanation. Thanks for making the video!
@SpringAcademy
@SpringAcademy 11 месяцев назад
Thank you for such a nice feedback! I'm super happy you found it useful!
@KonstantinZheludkov
@KonstantinZheludkov 7 месяцев назад
Thanks, it is nice material. Good overall overview without annoying details.
@MrSurprise777
@MrSurprise777 7 месяцев назад
Briefly and understandable, thanks! Important note that by default RestClient uses Java HttpClient introduced in Java 11
@ViniciusVille
@ViniciusVille 5 месяцев назад
Congratulations! Great content 👏
@ebenezerbuabeng6961
@ebenezerbuabeng6961 11 месяцев назад
Great Insight
@gialnetantonio
@gialnetantonio 11 месяцев назад
Great presentation. Thanks a lot
@SpringAcademy
@SpringAcademy 11 месяцев назад
Thank you!
@Mohamed-uf5jh
@Mohamed-uf5jh 3 месяца назад
thanks, you make very easy !
@Eagle3302PL
@Eagle3302PL 11 месяцев назад
Nice, using the interfaces will make things much cleaner.
@SpringAcademy
@SpringAcademy 11 месяцев назад
Indeed!
@user-jb8we4ly1s
@user-jb8we4ly1s 9 месяцев назад
But how can we manage errors? For example: external api returns 404. How can I handle that api response body to return that exact same message using my own ApiErrorDTO?
@janetkalu3064
@janetkalu3064 10 месяцев назад
I subscribed❤
@zenhsuld
@zenhsuld 11 месяцев назад
Great...
@SpringAcademy
@SpringAcademy 11 месяцев назад
Thanks!
@kc_official
@kc_official 10 месяцев назад
Thanks for the video. I would like to understand how to enable micrometer tracing with RestClient? using RestClient.Builder when creating the bean and using that is not propagating the traceparent header to other api service.
@rubenqba
@rubenqba 11 месяцев назад
Awesome new component! I was messing around with it but i didn't get working the RestClient with OAuth2 client_credentials, it could be that spring security support is currently a WIP? Excelent channel BTW!!
@SpringAcademy
@SpringAcademy 11 месяцев назад
Likely. It's still few months before the RC so I'm pretty sure they'll fill the gaps
@nbugash
@nbugash 11 месяцев назад
Well done. Quick question can you use still flux / mono in the interface? E.g `public Flux …..`
@SpringAcademy
@SpringAcademy 11 месяцев назад
Not sure if RestClient handles it but anyway I don't think it would bring any value. For reactive interfaces you can still use WebClient under the hood
@chardou85
@chardou85 9 месяцев назад
It's look like Spring Cloud OpenFeign. Is there any difference between this two ? The usage of RestClient over Feign is now recommended by Spring ?
@rustemtaralov3884
@rustemtaralov3884 11 месяцев назад
what about FeignClient is it stil good
@rahuldebnath3919
@rahuldebnath3919 7 месяцев назад
How to configure RestClient with OAuth2 and call protected endpoints
@avalagum7957
@avalagum7957 11 месяцев назад
Does anybody know which Spring Boot version will use the Spring Framework 6.1?
@SpringAcademy
@SpringAcademy 11 месяцев назад
Spring Boot 3.2. Check calendar.spring.io/ for release dates
@anthonya880
@anthonya880 11 месяцев назад
Hi, Will learning Spring Webflux boost my resume ? Please give me your opinion.
@SpringAcademy
@SpringAcademy 11 месяцев назад
It definitely will but considering how niche the reactive programming is I would recommend learning something more mainstream to boost your resume
@Eagle3302PL
@Eagle3302PL 11 месяцев назад
As long as you don't become one of those devs that uses reactive for everything, recently had to refactor a whole new service because an overeager dev used reactive for a simple rest microservice and FE guys said they wanted pagination after I took over. It's important to learn when to use reactive programming, it's an overkill tool for simple services.
@anthonya880
@anthonya880 11 месяцев назад
Thank you guys for replying.
@Chrisbees
@Chrisbees 7 месяцев назад
@@SpringAcademywhat are the mainstream alternatives to webflux? I just learnt vertx and use it instead of webflux. So I’m wondering if I really need to learn webflux
@Razpirato
@Razpirato 11 месяцев назад
Does this also work with virtual threads?
@SpringAcademy
@SpringAcademy 11 месяцев назад
It depends if the underlying low level HTTP client works with virtual threads. I'm sure that all major ones eventually will or they already do considering how virtual threads are easy to use in existing application.
@Razpirato
@Razpirato 11 месяцев назад
Out of curiousity, why didn't you want add Webflux and WebClient as a dependency?
@SpringAcademy
@SpringAcademy 11 месяцев назад
If dependency brings no to little value I just prefer to avoid it. Especially considering how spring boot autoconfiguration behavior changes depending on what's on the class path
@noodleslee4871
@noodleslee4871 10 месяцев назад
More like a feign set with fixed lookup
@HasNoName69
@HasNoName69 11 месяцев назад
i cannot hear you
@SpringAcademy
@SpringAcademy 11 месяцев назад
Why's that so? Too quiet or not clear?
@HasNoName69
@HasNoName69 11 месяцев назад
i turned off my headphones@@SpringAcademy
Далее
A First Look at the new Rest Client in Spring Boot 3.2
18:03
Базовый iPhone 16
00:38
Просмотров 336 тыс.
🚀  New in Spring Framework 6: HTTP Interfaces
11:33
The Best .NET REST API Client You Didn't Know About
12:55
🍃 Introduction to Spring GraphQL with Spring Boot
19:14
5 Common Mistakes Spring Developers Make
18:06
Просмотров 16 тыс.
How To Call a REST API In Java - Simple Tutorial
29:14
Просмотров 263 тыс.
Новодельный ноутбук Pocket386
1:16:17
Красиво, но телефон жаль
0:32
Просмотров 1,5 млн
APPLE дают это нам БЕСПЛАТНО!
1:01
Просмотров 754 тыс.