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

Fix for refreshing schema after update #3574

Merged
merged 2 commits into from
Jan 23, 2018
Merged

Conversation

rafael
Copy link
Member

@rafael rafael commented Jan 23, 2018

Description

I think there was a bug introduced in 3539 where after updating a vschema, vtgate is not properly updating it's version of it.

Steps to reproduce

  1. Add a new table schema to a keyspace with:
vtctlclient ApplyVSchema -vschema_file schema-file keyspace
  1. Updated schema is not shown in /debug/vschema and vtgate can't issue queries to that table.

After some debugging, I noticed that the callback was always passing nil in the changes and the vschema doesn't get updated.

This PR fixes this and seems to be working as expected. However, not sure if I'm missing something and nil here is needed.

@derekperkins
Copy link
Member

This is likely the cause of #3567

@alainjobart
Copy link
Contributor

Ouch I'm sorry about that...

Looking at the test, we have a test case for this, except the test is broken: can you also change resilient_server_test.go line 239 from 'ks1' to 'ks2', so the value we try to update is actually different? With that test change, it fails, and with your fix, it passes as it should... Thanks!

@sougou sougou merged commit 90a8904 into vitessio:master Jan 23, 2018
@rafael rafael deleted the fix-for-topo branch January 23, 2018 20:53
frouioui pushed a commit to planetscale/vitess that referenced this pull request Nov 21, 2023
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

6 participants