Skip to content
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

sqllogictest: parallelize test #2692

Closed
skyzh opened this issue May 20, 2022 · 9 comments
Closed

sqllogictest: parallelize test #2692

skyzh opened this issue May 20, 2022 · 9 comments

Comments

@skyzh
Copy link
Contributor

skyzh commented May 20, 2022

depends on create database #2529

Just as what @lmatz has proposed, we can use database to isolate different test cases, and run them in parallel.

@lmatz
Copy link
Contributor

lmatz commented May 20, 2022

Actually, it's @wangrunji0408 who proposed to use create database. I thought it is a very neat idea.

Now on second thought, I find this may have some potential problems:

  1. if we are testing crate database switch to these types of statements, will the test produce unexpected results?
  2. the database is created for each .slt file or each .slt.part file? Do we allow a .slt.part file to include other slt.part files?

@skyzh
Copy link
Contributor Author

skyzh commented May 20, 2022

For 1, maybe yes. I'm thinking of users should explicitly write create database and use database at the beginning of the sqllogictest files as statement ok. This solution might also solve 2. So the only thing sqllogictest itself needs to support if to run tests in parallel.

@lmatz
Copy link
Contributor

lmatz commented May 20, 2022

users should explicitly write create database and use database

We may need to hack the name a bit to avoid different test files using the same database name when running tests in parallel.

@skyzh
Copy link
Contributor Author

skyzh commented May 20, 2022

We may need to hack the name a bit to avoid different test files using the same database name when running tests in parallel.

Yes, that's true.

@wangrunji0408
Copy link
Contributor

We may introduce a new command to make the tester create an anonymous database for the current file. As an alias for create database XXX; use database XXX and implicitly drop database XXX on exit.

@skyzh
Copy link
Contributor Author

skyzh commented Jun 7, 2022

implemented in risinglightdb/sqllogictest-rs#45, we can integrate it with our CI soon 🥰

@xxchan
Copy link
Member

xxchan commented Jun 15, 2022

resolved by #3046

@xxchan xxchan closed this as completed Jun 15, 2022
@skyzh
Copy link
Contributor Author

skyzh commented Jun 15, 2022

Still not resolved, parallel test can only be running in in-memory mode. There're bugs with concurrent query in production code.

@xxchan xxchan reopened this Jun 15, 2022
@lmatz
Copy link
Contributor

lmatz commented Nov 9, 2022

Is it solved now?
ci/scripts/e2e-test-parallel.sh is currently being enabled for each PR

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

No branches or pull requests

5 participants