-
Notifications
You must be signed in to change notification settings - Fork 110
Introduce WorkflowInterceptor. #42
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
36f97c9
to
f840429
Compare
* is intercepting. | ||
*/ | ||
@ExperimentalWorkflowApi | ||
interface WorkflowInstance { |
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.
Is this name confusing? It's hard to talk about "instances of Workflow classes" vs this. We typically call these "sessions" offline, should we just use that term here? Also cc @square/mobile-foundation-ios for their thoughts on this. (Scroll up to the documentation on WorkflowInterceptor
to read a detailed description of what this is.)
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.
Glad you asked, I was biting my tongue. I prefer Session
.
* also knows the [key][WorkflowInstance.renderKey] used to render the workflow and the | ||
* [WorkflowInstance] of the [parent][WorkflowInstance.parent] workflow that is rendering it. | ||
* | ||
* Each instance is also assigned a numerical ID that uniquely identifies the instance over the |
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.
pedant: what if it wraps?
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.
Oh, it's a Long
. Wrapping those is…challenging. Although we did it once at Google.
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.
These track in-memory objects. If you wrap that you've got more than 18446744073 GB of RAM in your phone so good for you.
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.
"18 ZB ought to be enough for anybody." a famous person once said, I think.
* is intercepting. | ||
*/ | ||
@ExperimentalWorkflowApi | ||
interface WorkflowInstance { |
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.
Glad you asked, I was biting my tongue. I prefer Session
.
f840429
to
b0344ed
Compare
Renamed Instance to Session and added some documentation. |
See the documentation on the `WorkflowInterceptor` interface for an explanation of what this type is and how it can be used. It is intended to replace `WorkflowDiagnosticListener`, as well as the custom double-rendering behavior used to verify render idempotency in testing infrastructure. Closes #33.
b0344ed
to
cad6331
Compare
See the documentation on the
WorkflowInterceptor
interface for an explanation of what thistype is and how it can be used. It is intended to replace
WorkflowDiagnosticListener
, aswell as the custom double-rendering behavior used to verify render idempotency in testing
infrastructure.
Closes #33.
Checklist