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
e2e: fill schema with many namespaces to span ranges #349
Conversation
6a4e5a4
to
4e1a7c4
Compare
@@ -29,7 +29,7 @@ type Manager interface { | |||
// ReadNamespaceAndTypes reads a namespace definition, version, and type system and returns it if found. | |||
ReadNamespaceAndTypes(ctx context.Context, nsName string, revision decimal.Decimal) (*v0.NamespaceDefinition, *NamespaceTypeSystem, error) | |||
|
|||
// Closes the namespace manager, disposing of any resources. | |||
// Close closes the namespace manager, disposing of any resources. |
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.
Are we going to enforce linting rules on the e2e code? Because it's a separate project almost all the tooling doesn't run on this code.
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.
this is actually in the main module, not e2e
but yeah we should probably run the linters over this too
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.
this is actually in the main module, not e2e
Yep, the fact that this is a lint fix just reminded me that the other files are not being checked.
f200428
to
c4cc7d9
Compare
in order for the newenemy test to work, we need to ensure that the additional reads for namespaces that have been added for namespace versioning do not re-sync timestamps across cockroach nodes. by first filling the datastore with a large number of namespaces, we can pick one that has a range leader on the slow node, so that future writes to the slow node don't involve reads from other nodes the core of the test is otherwise the same, though extra machinery for reasoning about range leaders was added
This PR restores the e2e test suite after #332 broke them. Now that namespaces are read at specific revisions on tuple read/write, it's more difficult to reason about which cockroach nodes will be used for a given operation. This PR accounts for the additional namespace reads in the test.
What the test used to do:
What the test does now: