Похожие чаты

Thank you. Which of the following ways do you recommend? Netty Rx-Netty Spring Reactor

for netty

I have a TCP server based on netty framework that is embedded (as jar file) within my spring boot project.
In fact I want to do some non-blocking activities (for example CRUD in db or calling restful web services) when the following method of tcp netty is called:
channelRead method of ChannelInboundHandlerAdapter class
Which is the best scenario for this mode?

2 ответов

13 просмотров

For the "CRUD in db or calling restful web services" I would recommend none of the mentioned. Why not just use Spring for that? I would use netty only if there's absolutely no need to parse responses, i.e. if you work only with strings and/or byte buffers or *maybe* one-three objects that you have to write parsers for. At the point where you see that you need to understand what that web service has just sent to you, you face the need to express your data in object form. Spring+rxjava2 or spring+reactor would be my choice for the task you've described (if I understand it right). Netty is way much lower level

P.S.: one more thing - rx-netty is pretty idle, while rxjava2 was very active from beginning and is very mature at the moment. So, I would use it only as a last option. Digging in bugs of an outdated project that integrates two asynchronous tools... just a "hell" synonym))

Похожие вопросы

Обсуждают сегодня

30500 за редактор? )
Владимир
47
а через ESC-код ?
Alexey Kulakov
29
Anyone knows where there are some instructions or discort about failed bridge transactions ?
Jochem
21
Чёт не понял, я ж правильной функцией воспользовался чтобы вывести отладочную информацию? но что-то она не ловится
notme
18
Привет)) уже кажется эту тему перемусолили, но вот я так и не понял. Я сейчас сижу на 27дюймов 2к мониторе. На Актуальной макоси, если я куплю 27д 4к монитор: - будет ли изобр...
Vladislav Piskunov
16
Also, why can’t the community have a vote/ say when it comes to initiatives like buybacks. Isn’t the point of crypto decentralisation? Don’t we deserve input as long term supp...
👨🏽‍🦰
13
any reference of this implementation?
BitBuddha
29
Страшнейшая правда про списки ЦБ. С первых дней жизни P2P сферы, молодые человеки, начитавшись законодательной базы и "внутренних" документов, решили, что им противостоит сер...
Foxcool
3
У меня есть функция где происходит это: write_bit(buffer, 1); write_bit(buffer, 0); write_bit(buffer, 1); write_bit(buffer, 1); write_bit(buffer, 1); w...
~
14
Hi guys, any problem with Pulsebrige? Trying to transfer from wETH to ETH. First it tells me to connect my metamask "through mobile app" not desktop. Then I did and confirmed ...
Snowflakecrypto
13
Карта сайта