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
Postgres Backend on Azure - Change Feed contantly crashing - ERROR: invalid hexadecimal digit: "-" (SQLSTATE 22023) #29911
Comments
Azure Database for PostgreSQL Single Server is capped at postgres v11 (and will be retired in march 2025), whereas the docs that we're about to merge (😬) will state that we require postgres 13 or later, mostly because of the performance improvements with regards to logical decoding. That being said, I would've still expected it to work on v11. I'll do some test and see what's going on. That being said, I strongly recommend using a Flexible Server, which should support up to postgres v15 on all regions now. |
@anthonysomerset do you have I was able to reproduce this with (for context https://github.com/eulerto/wal2json/blob/30d2ec11dfaa54980db4e2e1e3de8fe7ed71b6cb/wal2json.c#L1321-L1323, tip of master at time of writing) |
thanks i see its set to HEX server side too looking at how to change the conn string in the helm config at moment - will advise |
In the chart you have to override the whole string in If it's not that problem, could you psql in the same database as the backend ( SELECT * FROM pg_create_logical_replication_slot('foobar', 'wal2json', true);
SELECT data FROM pg_logical_slot_get_changes('foobar', NULL, NULL, 'format-version', '2', 'add-tables', 'public.kv', 'include-transaction', 'false'); Repeat the last statement as necessary to get events, as it might return nothing if there's no changes. Disconnect the session to drop the temporary slot that was created. |
Thanks overriding the conn_string ( i also override the audit storage too just in case because same db... ) but still getting the errors running those commands above - i seem to get a number of results - nothing looks out of ordinary they look like plain old json I need to work on migrating this specific postgres instance to flexible anyway will also advise how that goes |
Can I get an example json string? What version of postgres is this? |
"{""action"":""U"",""schema"":""public"",""table"":""kv"",""columns"":[{""name"":""key"",""type"":""bytea"",""value"":""2f6461746162617365536572766572732f64656661756c742f32346662363838342d383962652d346137352d616536342d3065646563356439626235322f6c742d68712d7072642d6d7973716c30322d7a61""},{""name"":""expires"",""type"":""timestamp with time zone"",""value"":""2023-08-02 17:49:01.762002+00""},{""name"":""revision"",""type"":""uuid"",""value"":""57680326-6c23-4155-b3d6-f87f2e8ddf53""}],""identity"":[{""name"":""key"",""type"":""bytea"",""value"":""2f6461746162617365536572766572732f64656661756c742f32346662363838342d383962652d346137352d616536342d3065646563356439626235322f6c742d68712d7072642d6d7973716c30322d7a61""}]}" Its v11 on azure single server right now |
Just to confirm that the issue is what I think it is, could you |
length returns 5919 |
FYI i migrated to postgres flexible (version 15.2) i appear to get the same behaviour |
The issue is that in keepalive operations we don't touch the value, but if the value column is TOASTed for that row, we can't read it in the change feed. #29965 fixes that (with a more long term fix that will probably rely on Sorry about the confusion, although migrating to flexible server was something you should've eventually done regardless I guess 😅 |
@anthonysomerset 13.3.1 was released with a fix for this, could you give it a try? |
already done and confirmed good now thanks! |
Expected behavior:
unclear whats broken and should be expected
Current behavior:
unclear whats actually broken - general working of teleport seems to be OK - but getting constant error about change feed stopping in logs
Bug details:
Deploy Helm chart on AKS using azure config for postgres and storage backend
using postgres single server in azure
The text was updated successfully, but these errors were encountered: