-
Notifications
You must be signed in to change notification settings - Fork 13.7k
[FLINK-5615][query] execute the QueryableStateITCase for all three state back-ends #3194
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
… state backends Querying for a non-existing key for a state that has a default value set currently results in an UnknownKeyOrNamespace exception when the MemoryStateBackend or FsStateBackend is used but results in the default value if RocksDBStateBackend is set. This removes the special handling from the RocksDBStateBackend and makes it consistent with the other two back-ends, i.e. returning null which results in the mentioned UnknownKeyOrNamespace exception.
…test duration This is based on the following points: * slow down QueryableStateITCase#TestKeyRangeSource for the rest of the program to make more progress (we do not need a full-speed source here!) * reduce the checkpointing interval * reduce the amount of progress before starting our own evaluation * reduce the number of checkpoints to wait for before killing a TM * reduce the thread waiting time when asking how many checkpoints exist Note that by slowing down QueryableStateITCase#TestKeyRangeSource, the other tests should only be affected positively, too, since they also did not really need a full-speed source and thus have more CPU cycles for their own tasks. This, among with
This is based on reducing the number of keys the source generates. We do not really need 1024 different keys for the tests - go with 256 now.
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.
Good fixes!
Small suggestion would be to add an abstract createStateBackend
method in the base test class instead of relying on override of the setUp
method and moving the annoated setUp
method to the base class and setting everything up there.
* Several integration tests for queryable state using the {@link RocksDBStateBackend}. | ||
*/ | ||
public class QueryableStateITCaseRocksDBBackend extends AbstractQueryableStateITCase { | ||
|
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.
empty line
* Several integration tests for queryable state using the {@link FsStateBackend}. | ||
*/ | ||
public class QueryableStateITCaseFsBackend extends AbstractQueryableStateITCase { | ||
|
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.
empty line
Thanks to @uce for proposing this.
Thanks for addressing the comments, merging. |
…ackends [FLINK-5615][query] improve testQueryableStateWithTaskManagerFailure test duration This is based on the following points: * slow down QueryableStateITCase#TestKeyRangeSource for the rest of the program to make more progress (we do not need a full-speed source here!) * reduce the checkpointing interval * reduce the amount of progress before starting our own evaluation * reduce the number of checkpoints to wait for before killing a TM * reduce the thread waiting time when asking how many checkpoints exist Note that by slowing down QueryableStateITCase#TestKeyRangeSource, the other tests should only be affected positively, too, since they also did not really need a full-speed source and thus have more CPU cycles for their own tasks. [FLINK-5615][query] speed up some more tests in QueryableStateITCase This is based on reducing the number of keys the source generates. We do not really need 1024 different keys for the tests - go with 256 now. [FLINK-5615][query] execute the QueryableStateITCase for all state back-ends [FLINK-5615][query] nicer test case abstraction This closes #3194.
…ackends [FLINK-5615][query] improve testQueryableStateWithTaskManagerFailure test duration This is based on the following points: * slow down QueryableStateITCase#TestKeyRangeSource for the rest of the program to make more progress (we do not need a full-speed source here!) * reduce the checkpointing interval * reduce the amount of progress before starting our own evaluation * reduce the number of checkpoints to wait for before killing a TM * reduce the thread waiting time when asking how many checkpoints exist Note that by slowing down QueryableStateITCase#TestKeyRangeSource, the other tests should only be affected positively, too, since they also did not really need a full-speed source and thus have more CPU cycles for their own tasks. [FLINK-5615][query] speed up some more tests in QueryableStateITCase This is based on reducing the number of keys the source generates. We do not really need 1024 different keys for the tests - go with 256 now. [FLINK-5615][query] execute the QueryableStateITCase for all state back-ends [FLINK-5615][query] nicer test case abstraction This closes apache#3194.
This extends the
QueryableStateITCase
so that it is able to run with any selected state backend. Some optimisations reduce the total runtime of the test cases so that we are able to run the tests with all three currently available backends, i.e.MemoryStateBackend
,FsStateBackend
, andRocksDBStateBackend
, with little extra costs.This is based upon #3193.