Giter Site home page Giter Site logo

Comments (6)

seeflood avatar seeflood commented on June 9, 2024 2

这个有人修么,没人修的话我来?正好最近没事干

from sofa-rpc.

OrezzerO avatar OrezzerO commented on June 9, 2024

Agree! How about submit a pr to fix it @zonghaishang

from sofa-rpc.

EvenLjj avatar EvenLjj commented on June 9, 2024

在多笔请求合并时,bolt 层会共用同一个RemotingContext,到rpc侧处理不同的请求时,根据bizCtx.isRequestTimeout() 这种判断方式去判定超时不一定准确。如果某个接口设置比较小的超时时间,和其他请求合并处理时,会造成预期之外的超时问题。
@seeflood 修这个问题的时候,一并看下怎么处理这块吧。
image

from sofa-rpc.

chuailiwu avatar chuailiwu commented on June 9, 2024

在多笔请求合并时和这个超时检查应该是冲突的
可以做一个修复逻辑,即如果是多笔请求合并,让超时检查失效
image

另看代码里还留了一个口子,com.alipay.remoting.codec.AbstractBatchDecoder#setSingleDecode 控制只返回一个msg,可以一起评估下怎么来提供这个能力比较好

from sofa-rpc.

seeflood avatar seeflood commented on June 9, 2024

我不太了解“多笔请求合并”场景的已有逻辑,我确认下:
看上面的讨论,意思是期望改成啥样:合并请求场景,不做超时检查?
不做超时检查的话有点奇怪啊,那业务处理耗时太长咋办……

具体修改方法:是不是在 bolt 里,判断 msg 是 List后,直接 setTimeout(0) 就行? 设置为0后,后面的超时检查就失效了(永远不会超时)
image

或者哪位老哥明天语音聊下?

from sofa-rpc.

EvenLjj avatar EvenLjj commented on June 9, 2024

@seeflood 这个并发问题在 bolt 1.6.8 版本修复了,sofastack/sofa-bolt#347

from sofa-rpc.

Related Issues (20)

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. 📊📈🎉

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❤️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.