-
Notifications
You must be signed in to change notification settings - Fork 4.2k
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
[BEAM-136] Look up a runner if it is not registered #61
Conversation
If a fully qualified runner is passed as the value of --runner, and it is not present within the map of registered runners, attempts to look up the runner using Class#forName, and uses the result class if the result class is an instance of PipelineRunner. This brings the behavior in line with the described behavior in PipelineOptions.
R: @lukecwik |
"Unknown 'runner' specified '%s', supported pipeline runners %s", | ||
runner, Sets.newTreeSet(SUPPORTED_PIPELINE_RUNNERS.keySet())); | ||
convertedOptions.put("runner", SUPPORTED_PIPELINE_RUNNERS.get(runner)); | ||
if (SUPPORTED_PIPELINE_RUNNERS.containsKey(runner)) { |
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.
Please update the method comment.
In PipelineOptions it is clear what we are supposed to support but from this method description I take it as we only support registered runners and we can select it either by the simple or fully qualified names.
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.
Done.
We only supported registered runners, and it looks like we only ever supported the simple names; this fixes that as well.
I guess this is aimed at what I just filed as https://issues.apache.org/jira/browse/BEAM-136? I'll assign you ;) I am somewhat confused though, because I don't see a hardcoded list in that file. I thought the problem was likely to be fixing the reflection. Can you point out the difference? |
There is no hard coded list. We rely on autoservice which will register all On Fri, Mar 18, 2016, 4:46 PM Daniel Halperin notifications@github.com
|
Update comment of parseObjects for the behavior of resolving the appropriate runner Add a test to demonstrate fully-qualified runner names are handle appropriately
Should we also register Flink and Spark runners? Or maybe file issues against them to add the relevant annotations? |
Yes, Flink and Spark should use AutoService as well to support automatic registration. If they don't already, creating an issue so that they do seems reasonable. |
LGTM |
…riptors apache#61 [euphoria-flink] Do not hold states in memory
…h allowed lateness
apache#61 Allowed lateness unit test
…h allowed lateness
…h allowed lateness
…h allowed lateness
…h allowed lateness
* fix: fix split checker The previous logic was comparing the last claimed position timestamp against the timestamp of the current claimed position. The problem with this is that if the write rate is high, Spanner will have multiple updates at the same timestamp. Because of this, the split checker will, more often than not, return false, preventing splitting from happening. In this PR we compare the claimed position timestamp against the restriction start timestamp. In this sense, we allow for splits if at least 1 microsecond has passed from the start timestamp. This fixes the issue of having multiple records with the same timestamp. * fix: use watermark estimator in bundle finalizer Instead of registering the callback with the current watermark, gives the watermark estimator to the bundle finalizer callback so that the current watermark is retrieved within the callback. * feat: add heartbeat record count metric Adds optional metric to check for heartbeat count. * feat: add debug logging to restriction tracker
PiperOrigin-RevId: 278792316
* feat: add async tests for AsyncClient * feat: add AsyncClient implementation * feat: add AsyncDocument implementation * feat: add AsyncDocument support to AsyncClient * feat: add AsyncDocument tests Note: tests relying on Collection will fail in this commit * feat: add AsyncCollectionReference class * feat: integrate AsyncCollectionReference * feat: add async_collection tests * fix: swap coroutine/function declaration in async_collection * feat: add async_batch implementation * feat: integrate async_batch * feat: add async_batch tests * feat: add async_query implementation * feat: add async_query integration * feat: add async_query tests * fix: AsyncQuery.get async_generator nesting * feat: add async_transaction integration and tests * fix: linter errors * feat: refactor async tests to use aiounittest and pytest-asyncio * feat: remove duplicate code from async_client * feat: remove duplicate code from async_batch * feat: remove duplicate code from async_collection * feat: remove duplicate code from async_document * fix: remove unused imports * fix: remove duplicate test * feat: remove duplicate code from async_transaction * fix: remove unused Python2 compatibility * fix: resolve async generator tests * fix: create mock async generator to get full coverage * fix: copyright date * feat: create Client/AsyncClient superclass * fix: base client test class * feat: create WriteBatch/AsyncWriteBatch superclass * feat: create CollectionReference/AsyncCollectionReference superclass * feat: create DocumentReference/AsyncDocumentReference superclass * fix: base document test class name * feat: create Query/AsyncQuery superclass * refactor: generalize collection tests with mocks * feat: create Transaction/AsyncTransaction superclass * feat: add microgen support to async interface * fix: async client copyright date * fix: standardize assert syntax * fix: incorrect copyright date * fix: incorrect copyright date * fix: clarify _sleep assertions in transaction * fix: clarify error in context manager tests * fix: clarify error in context manager tests
If a fully qualified runner is passed as the value of --runner, and it
is not present within the map of registered runners, attempts to look
up the runner using Class#forName, and uses the result class if the
result class is an instance of PipelineRunner. This brings the behavior
in line with the described behavior in PipelineOptions.