Documentation
¶
Index ¶
- type ClientCommands
- type ConnectionClientCommands
- type ConnectionDeleteCmd
- type ConnectionGetCmd
- type ConnectionListCmd
- type DatabaseClientCommands
- type DatabaseCreateCmd
- type DatabaseDeleteCmd
- type DatabaseGetCmd
- type DatabaseListCmd
- type DatabaseUpdateCmd
- type ExtensionClientCommands
- type ExtensionCreateCmd
- type ExtensionDeleteCmd
- type ExtensionGetCmd
- type ExtensionListCmd
- type ObjectClientCommands
- type ObjectGetCmd
- type ObjectListCmd
- type PingCmd
- type ReplicationSlotClientCommands
- type ReplicationSlotCreateCmd
- type ReplicationSlotDeleteCmd
- type ReplicationSlotGetCmd
- type ReplicationSlotListCmd
- type RoleClientCommands
- type RoleCreateCmd
- type RoleDeleteCmd
- type RoleGetCmd
- type RoleListCmd
- type RoleUpdateCmd
- type RunServer
- type SchemaClientCommands
- type SchemaCreateCmd
- type SchemaDeleteCmd
- type SchemaGetCmd
- type SchemaListCmd
- type SchemaUpdateCmd
- type ServerCommands
- type SettingCategoryListCmd
- type SettingClientCommands
- type SettingGetCmd
- type SettingListCmd
- type SettingUpdateCmd
- type StatementCommands
- type StatementListCmd
- type StatementResetCmd
- type TablespaceClientCommands
- type TablespaceCreateCmd
- type TablespaceDeleteCmd
- type TablespaceGetCmd
- type TablespaceListCmd
- type TablespaceUpdateCmd
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
This section is empty.
Types ¶
type ClientCommands ¶
type ClientCommands struct {
Ping PingCmd `cmd:"" name:"ping" help:"Ping the server." group:"STATUS"`
RoleClientCommands
DatabaseClientCommands
SchemaClientCommands
ObjectClientCommands
StatementCommands
TablespaceClientCommands
ConnectionClientCommands
ReplicationSlotClientCommands
ExtensionClientCommands
SettingClientCommands
}
type ConnectionClientCommands ¶
type ConnectionClientCommands struct {
ConnectionList ConnectionListCmd `cmd:"" name:"connections" help:"List connections." group:"CONNECTION"`
ConnectionGet ConnectionGetCmd `cmd:"" name:"connection" help:"Get connection details." group:"CONNECTION"`
ConnectionDelete ConnectionDeleteCmd `cmd:"" name:"connection-delete" help:"Delete a connection." group:"CONNECTION"`
}
type ConnectionDeleteCmd ¶
type ConnectionDeleteCmd struct {
Pid uint64 `arg:"" name:"pid" help:"PID of the connection."`
}
type ConnectionGetCmd ¶
type ConnectionGetCmd struct {
Pid uint64 `arg:"" name:"pid" help:"PID of the connection."`
}
type ConnectionListCmd ¶
type ConnectionListCmd struct {
schema.ConnectionListRequest
}
type DatabaseClientCommands ¶
type DatabaseClientCommands struct {
DatabaseList DatabaseListCmd `cmd:"" name:"databases" help:"List databases." group:"DATABASE"`
DatabaseGet DatabaseGetCmd `cmd:"" name:"database" help:"Get database details." group:"DATABASE"`
DatabaseCreate DatabaseCreateCmd `cmd:"" name:"database-create" help:"Create a new database." group:"DATABASE"`
DatabaseDelete DatabaseDeleteCmd `cmd:"" name:"database-delete" help:"Delete a database." group:"DATABASE"`
DatabaseUpdate DatabaseUpdateCmd `cmd:"" name:"database-update" help:"Update a database." group:"DATABASE"`
}
type DatabaseCreateCmd ¶
type DatabaseCreateCmd struct {
schema.DatabaseMeta
}
type DatabaseDeleteCmd ¶
type DatabaseDeleteCmd struct {
Name string `arg:"" name:"name" help:"Name of the database."`
}
type DatabaseGetCmd ¶
type DatabaseGetCmd struct {
Name string `arg:"" name:"name" help:"Name of the database."`
}
type DatabaseListCmd ¶
type DatabaseListCmd struct {
schema.DatabaseListRequest
}
type DatabaseUpdateCmd ¶
type DatabaseUpdateCmd struct {
NewName string `flag:"" name:"name" help:"New name of the database."`
schema.DatabaseMeta
}
type ExtensionClientCommands ¶
type ExtensionClientCommands struct {
ExtensionList ExtensionListCmd `cmd:"" name:"extensions" help:"List extensions." group:"EXTENSION"`
ExtensionGet ExtensionGetCmd `cmd:"" name:"extension" help:"Get extension details." group:"EXTENSION"`
ExtensionCreate ExtensionCreateCmd `cmd:"" name:"extension-install" help:"Install an extension into a database schema." group:"EXTENSION"`
ExtensionDelete ExtensionDeleteCmd `cmd:"" name:"extension-remove" help:"Remove an extension from one or more database schemas." group:"EXTENSION"`
}
type ExtensionCreateCmd ¶
type ExtensionCreateCmd struct {
schema.ExtensionMeta
Cascade bool `flag:"" name:"cascade" help:"Cascade option."`
}
type ExtensionDeleteCmd ¶
type ExtensionGetCmd ¶
type ExtensionGetCmd struct {
Name string `arg:"" name:"name" help:"Name of the extension."`
}
type ExtensionListCmd ¶
type ExtensionListCmd struct {
schema.ExtensionListRequest
}
type ObjectClientCommands ¶
type ObjectClientCommands struct {
ObjectList ObjectListCmd `cmd:"" name:"objects" help:"List objects." group:"OBJECT"`
ObjectGet ObjectGetCmd `cmd:"" name:"object" help:"Get object details." group:"OBJECT"`
}
type ObjectGetCmd ¶
type ObjectListCmd ¶
type ObjectListCmd struct {
schema.ObjectListRequest
}
type ReplicationSlotClientCommands ¶
type ReplicationSlotClientCommands struct {
ReplicationSlotList ReplicationSlotListCmd `cmd:"" name:"replication-slots" help:"List replication slots." group:"REPLICATION SLOT"`
ReplicationSlotGet ReplicationSlotGetCmd `cmd:"" name:"replication-slot" help:"Get replication slot details." group:"REPLICATION SLOT"`
ReplicationSlotCreate ReplicationSlotCreateCmd `cmd:"" name:"replication-slot-create" help:"Create a new replication slot." group:"REPLICATION SLOT"`
ReplicationSlotDelete ReplicationSlotDeleteCmd `cmd:"" name:"replication-slot-delete" help:"Delete a replication slot." group:"REPLICATION SLOT"`
}
type ReplicationSlotCreateCmd ¶
type ReplicationSlotCreateCmd struct {
schema.ReplicationSlotMeta
}
type ReplicationSlotDeleteCmd ¶
type ReplicationSlotDeleteCmd struct {
Name string `arg:"" name:"name" help:"Name of the replication slot."`
}
type ReplicationSlotGetCmd ¶
type ReplicationSlotGetCmd struct {
Name string `arg:"" name:"name" help:"Name of the replication slot."`
}
type ReplicationSlotListCmd ¶
type ReplicationSlotListCmd struct {
schema.ReplicationSlotListRequest
}
type RoleClientCommands ¶
type RoleClientCommands struct {
RoleList RoleListCmd `cmd:"" name:"roles" help:"List roles." group:"ROLE"`
RoleGet RoleGetCmd `cmd:"" name:"role" help:"Get role details." group:"ROLE"`
RoleCreate RoleCreateCmd `cmd:"" name:"role-create" help:"Create a new role." group:"ROLE"`
RoleDelete RoleDeleteCmd `cmd:"" name:"role-delete" help:"Delete a role." group:"ROLE"`
RoleUpdate RoleUpdateCmd `cmd:"" name:"role-update" help:"Update a role." group:"ROLE"`
}
type RoleCreateCmd ¶
type RoleDeleteCmd ¶
type RoleDeleteCmd struct {
Name string `arg:"" name:"name" help:"Name of the role."`
}
type RoleGetCmd ¶
type RoleGetCmd struct {
Name string `arg:"" name:"name" help:"Name of the role."`
}
type RoleListCmd ¶
type RoleListCmd struct {
schema.RoleListRequest
}
type RoleUpdateCmd ¶
type RunServer ¶
type RunServer struct {
cmd.RunServer
pgpkg.PostgresFlags `embed:"" prefix:"pg."`
MCP bool `name:"mcp" help:"Enable an MCP endpoint" negatable:"" default:"false"`
}
func (*RunServer) WithManager ¶
func (runner *RunServer) WithManager(ctx server.Cmd, conn pg.PoolConn, fn func(*manager.Manager) error) error
WithManager creates a manager, with the server's tracer and meter, registers its HTTP handlers, and its MCP endpoint when it's enabled, with the server, and then calls the function with it, returning any error
type SchemaClientCommands ¶
type SchemaClientCommands struct {
SchemaList SchemaListCmd `cmd:"" name:"schemas" help:"List schemas." group:"SCHEMA"`
SchemaGet SchemaGetCmd `cmd:"" name:"schema" help:"Get schema details." group:"SCHEMA"`
SchemaCreate SchemaCreateCmd `cmd:"" name:"schema-create" help:"Create a new schema in a database." group:"SCHEMA"`
SchemaDelete SchemaDeleteCmd `cmd:"" name:"schema-delete" help:"Delete a schema from a database." group:"SCHEMA"`
SchemaUpdate SchemaUpdateCmd `cmd:"" name:"schema-update" help:"Update a schema in a database." group:"SCHEMA"`
}
type SchemaCreateCmd ¶
type SchemaCreateCmd struct {
Database string `arg:"" name:"database" help:"Name of the database."`
schema.SchemaMeta
}
type SchemaDeleteCmd ¶
type SchemaGetCmd ¶
type SchemaListCmd ¶
type SchemaListCmd struct {
schema.SchemaListRequest
}
type SchemaUpdateCmd ¶
type SchemaUpdateCmd struct {
Database string `arg:"" name:"database" help:"Name of the database."`
NewNamespace string `flag:"" name:"name" help:"New name of the schema."`
schema.SchemaMeta
}
type ServerCommands ¶
type ServerCommands struct {
Run RunServer `cmd:"" name:"run" help:"Run the server." group:"SERVER"`
}
type SettingCategoryListCmd ¶
type SettingCategoryListCmd struct {
schema.SettingCategoryListRequest
}
type SettingClientCommands ¶
type SettingClientCommands struct {
SettingList SettingListCmd `cmd:"" name:"settings" help:"List server settings." group:"SETTING"`
SettingCategoryList SettingCategoryListCmd `cmd:"" name:"categories" help:"List distinct setting categories." group:"SETTING"`
SettingGet SettingGetCmd `cmd:"" name:"setting" help:"Get setting details." group:"SETTING"`
SettingUpdate SettingUpdateCmd `cmd:"" name:"setting-update" help:"Update a setting." group:"SETTING"`
}
type SettingGetCmd ¶
type SettingGetCmd struct {
Name string `arg:"" name:"name" help:"Name of the setting."`
}
type SettingListCmd ¶
type SettingListCmd struct {
schema.SettingListRequest
}
type SettingUpdateCmd ¶
type SettingUpdateCmd struct {
Name string `arg:"" name:"name" help:"Name of the setting."`
schema.SettingMeta
}
type StatementCommands ¶
type StatementCommands struct {
StatementList StatementListCmd `cmd:"" name:"statements" help:"Return statement statistics." group:"STATEMENT"`
StatementReset StatementResetCmd `cmd:"" name:"statement-reset" help:"Reset statement statistics." group:"STATEMENT"`
}
type StatementListCmd ¶
type StatementListCmd struct {
schema.StatementListRequest
}
type StatementResetCmd ¶
type StatementResetCmd struct{}
type TablespaceClientCommands ¶
type TablespaceClientCommands struct {
TablespaceList TablespaceListCmd `cmd:"" name:"tablespaces" help:"List tablespaces." group:"TABLESPACE"`
TablespaceGet TablespaceGetCmd `cmd:"" name:"tablespace" help:"Get tablespace details." group:"TABLESPACE"`
TablespaceCreate TablespaceCreateCmd `cmd:"" name:"tablespace-create" help:"Create a new tablespace." group:"TABLESPACE"`
TablespaceDelete TablespaceDeleteCmd `cmd:"" name:"tablespace-delete" help:"Delete a tablespace." group:"TABLESPACE"`
TablespaceUpdate TablespaceUpdateCmd `cmd:"" name:"tablespace-update" help:"Update a tablespace." group:"TABLESPACE"`
}
type TablespaceCreateCmd ¶
type TablespaceCreateCmd struct {
schema.TablespaceMeta
Location string `arg:"" name:"location" help:"Location for the tablespace."`
}
type TablespaceDeleteCmd ¶
type TablespaceDeleteCmd struct {
Name string `arg:"" name:"name" help:"Name of the tablespace."`
}
type TablespaceGetCmd ¶
type TablespaceGetCmd struct {
Name string `arg:"" name:"name" help:"Name of the tablespace."`
}
type TablespaceListCmd ¶
type TablespaceListCmd struct {
schema.TablespaceListRequest
}
type TablespaceUpdateCmd ¶
type TablespaceUpdateCmd struct {
NewName string `flag:"" name:"name" help:"New name of the tablespace."`
schema.TablespaceMeta
}