well-goknown/vendor/github.com/fiatjaf/eventstore/postgresql/postgresql.go

24 lines
340 B
Go
Raw Normal View History

package postgresql
import (
2025-01-14 04:43:49 +00:00
"sync"
"github.com/jmoiron/sqlx"
)
type PostgresBackend struct {
2025-01-14 04:43:49 +00:00
sync.Mutex
*sqlx.DB
DatabaseURL string
QueryLimit int
QueryIDsLimit int
QueryAuthorsLimit int
QueryKindsLimit int
QueryTagsLimit int
KeepRecentEvents bool
}
func (b *PostgresBackend) Close() {
b.DB.Close()
}