-
Notifications
You must be signed in to change notification settings - Fork 28.7k
[SPARK-6980] [CORE] [WIP] Akka timeout exceptions indicate which conf controls them #5741
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Conversation
I am still pretty new with Scala, so any comments/suggestions are much appreciated! @squito |
jenkins, this is ok to test |
Test build #31255 has finished for PR 5741 at commit
|
* @param timeout_duration timeout duration in milliseconds | ||
* @param timeout_description description to be displayed in a timeout exception | ||
*/ | ||
class ConfiguredTimeout(timeout_duration: FiniteDuration, timeout_description: String = null) { |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
scala convention is camelCase, so timeoutDuration
and timeoutDescription
. But in this case, I think timeout
is a little redundant anyway, so maybe just duration
and description
. I don't think you should have a null
default for description
Thanks for working on this @BryanCutler! my major concern at this point is the use of the implicit conversion. Also we need to add a test to |
Thanks for the quick feedback @squito! I probably should have explained a little, but I only added the implicit conversion to maintain api compatibility by also allowing a I'll fix up the code with your suggestions and see what I can do about adding a test case for this. Hopefully, be able to get it done in the next couple days. |
…ite and new test suite ActorSystemSuite
Made another commit with received feedback from @squito. Changes are:
|
Test build #31686 has finished for PR 5741 at commit
|
Hi @BryanCutler, thanks for the updates. I realized that I between the time I dreamed of this in my head, and when I actually created the jira, there was a layer of abstraction put in the RPC layer. So in addition to Sorry I spec'ed this poorly in the beginning and to require more work on this, but I feel pretty strongly that I want to make sure we get all of the timeouts covered, and the best way to do that is make the compiler do the checks for us. Also it makes me to want to fix |
|
||
conf.set(shortProp, "1s") | ||
|
||
ssc = new StreamingContext(master, appName, batchDuration) |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
you don't need to make a streamingContext for this test at all, it just involves akka actors. In fact, I think this test should get moved to AkkaUtilsSuite as well.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
No problem, in my initial tests I created the Actors from the ActorSystem, so I thought that was required. I'll rework this into AkkaUtilsSuite and shorten the timeouts as you mentioned below.
Hey @squito, I agree that it would be best to improve on all of these timeouts. I'll extend the scope to include |
@BryanCutler Could you take a look at |
Sure, I can do that. I'll follow up with another PR soon, thanks! |
Thanks for the feedback @zsxwing ! and thanks for sticking with this Bryan |
@BryanCutler to answer your earlier question about
|
@BryanCutler @squito Also one more confusion I had was how would you differentiate between the constructors (in the apply method) since the description and timeoutProp are both strings. |
Closing, will continue in PR #6205 |
First shot at adding a description for an akka timeout that indicates which configuration property it came from