command
Version:
v0.1.0
Opens a new window with list of versions in this module.
Published: Dec 18, 2025
License: Apache-2.0
Opens a new window with license information.
Imports: 14
Opens a new window with list of imports.
Imported by: 0
Opens a new window with list of known importers.
README
¶
PostgreSQL Integration Example
This example demonstrates a production-like setup where PostgreSQL is used for both:
- Persistence: Saving the scanner's current block height (cursor).
- Sink: Storing the actual event data into a relational table.
Prerequisites
- A running PostgreSQL instance.
- Set the
PG_URL environment variable.
How to Run
-
Start Postgres (using Docker):
docker run --name some-postgres -e POSTGRES_PASSWORD=postgres -p 5432:5432 -d postgres
-
Run the example:
export PG_URL="postgres://postgres:postgres@localhost:5432/postgres?sslmode=disable"
go run main.go
What happens?
Documentation
¶
There is no documentation for this package.
Source Files
¶
Click to show internal directories.
Click to hide internal directories.