MCPcopy Create free account
hub / github.com/Permify/permify / DataReader

Struct DataReader

internal/storage/postgres/data_reader.go:27–30  ·  view source on GitHub ↗

DataReader is a struct which holds a reference to the database, transaction options and a logger. It is responsible for reading data from the database.

Source from the content-addressed store, hash-verified

25// DataReader is a struct which holds a reference to the database, transaction options and a logger.
26// It is responsible for reading data from the database.
27type DataReader struct {
28 database *db.Postgres // database is an instance of the PostgreSQL database
29 txOptions pgx.TxOptions // txOptions specifies the isolation level for database transaction and sets it as read only
30}
31
32// NewDataReader is a constructor function for DataReader.
33// It initializes a new DataReader with a given database, a logger, and sets transaction options to be read-only with Repeatable Read isolation level.

Callers

nothing calls this directly

Calls

no outgoing calls

Tested by

no test coverage detected