Skip to content

Instantly share code, notes, and snippets.

View ololobus's full-sized avatar
👹

Alexey Kondratov ololobus

👹
View GitHub Profile
#!/usr/bin/env sh
export PATH=$(pwd)/target/debug/:$(pwd)/tmp_install/bin:$PATH
# Remove all traces of the previous run
killall pageserver
killall wal_acceptor
killall postgres
rm -rf zenith_tmp
@ololobus
ololobus / neon_wal_redo.c
Last active April 27, 2022 15:37
WAL redo checksum
// @@ -569,6 +569,21 @@ PushPage(StringInfo input_message)
/*
* Every backend on the compute side will verify the page checksum
* after reading it from pageserver using GetPage@LSN. Here in the
* WAL redo process we are reading pages directly from stdin, so we
* would better verify checksum too before applying any WAL records
* on top of it.
*/
if (!PageIsVerifiedExtended((Page) content, blknum,
PIV_LOG_WARNING | PIV_REPORT_STAT))
@ololobus
ololobus / branch-latency-test.py
Created March 22, 2023 16:10
Neon API latency test
#!/usr/bin/env python3
import requests
import time
import contextlib
from pprint import pprint
import psycopg2