Documentation ¶
Index ¶
- Constants
- Variables
- func ContainsAnyCharType(s *[]string) (bool, int)
- func ContainsAnyStr(s *[]string, e *[]string) bool
- func ContainsStr(s *[]string, e string) bool
- func ExecuteSqlStructWithOpts[T any](ctx context.Context, gpudb Gpudb, statement string, offset int64, limit int64, ...) (T, error)
- func GetRecordsStructWithOpts[T any](ctx context.Context, gpudb Gpudb, table string, offset int64, limit int64, ...) ([]T, error)
- type AdminAddHostRequest
- type AdminAddHostRequestOptions
- type AdminAddHostResponse
- type AdminAddRanksRequest
- type AdminAddRanksRequestOptions
- type AdminAddRanksResponse
- type AdminBackupBeginRequest
- type AdminBackupBeginRequestOptions
- type AdminBackupBeginResponse
- type AdminBackupEndRequest
- type AdminBackupEndRequestOptions
- type AdminBackupEndResponse
- type AdminRemoveHostRequest
- type AdminRemoveHostRequestOptions
- type AdminRemoveHostResponse
- type AdminRemoveRanksRequest
- type AdminRemoveRanksRequestOptions
- type AdminRemoveRanksResponse
- type AdminShutdownRequest
- type AdminShutdownRequestOptions
- type AdminShutdownResponse
- type AggregateGroupByOptions
- type AggregateGroupByRequest
- type AggregateGroupByResponse
- type AggregateStatisticsOptions
- type AggregateStatisticsRequest
- type AggregateStatisticsResponse
- type AlterGraphActionEnum
- type AlterGraphRequest
- type AlterGraphRequestOptions
- type AlterGraphResponse
- type AlterUserActionEnum
- type AlterUserRequest
- type AlterUserRequestOptions
- type AlterUserResponse
- type AvroSchemas
- type CreateJobOptions
- type CreateJobRequest
- type CreateJobResponse
- type CreateResourceGroupRankingEnum
- type CreateResourceGroupRequest
- type CreateResourceGroupRequestOptions
- type CreateResourceGroupResponse
- type CreateSchemaRequest
- type CreateSchemaRequestOptions
- type CreateSchemaResponse
- type DeleteResourceGroupRequest
- type DeleteResourceGroupRequestOptions
- type DeleteResourceGroupResponse
- type DropSchemaRequest
- type DropSchemaRequestOptions
- type DropSchemaResponse
- type ExecuteSqlMapResult
- type ExecuteSqlOptions
- type ExecuteSqlRequest
- type ExecuteSqlResponse
- type ExecuteSqlStructResult
- type GetJobOptions
- type GetJobRequest
- type GetJobResponse
- type GetRecordsOptions
- type GetRecordsRequest
- type GetRecordsResponse
- type Gpudb
- func (gpudb *Gpudb) ExecuteSqlMap(ctx context.Context, sql string, offset int64, limit int64) (*ExecuteSqlMapResult, error)
- func (gpudb *Gpudb) ExecuteSqlMapWithOpts(ctx context.Context, statement string, offset int64, limit int64, ...) (*ExecuteSqlMapResult, error)
- func (gpudb *Gpudb) ExecuteSqlRaw(ctx context.Context, statement string, offset int64, limit int64, ...) (*ExecuteSqlResponse, error)
- func (gpudb *Gpudb) ExecuteSqlRawWithOpts(ctx context.Context, statement string, offset int64, limit int64, ...) (*ExecuteSqlResponse, error)
- func (gpudb *Gpudb) ExecuteSqlStruct(ctx context.Context, statement string, offset int64, limit int64, ...) (*ExecuteSqlStructResult, error)
- func (gpudb *Gpudb) ExecuteSqlStructWithOpts(ctx context.Context, statement string, offset int64, limit int64, ...) (*ExecuteSqlStructResult, error)
- func (gpudb *Gpudb) GetOptions() *GpudbOptions
- func (gpudb *Gpudb) GetRecordsMap(ctx context.Context, table string, offset int64, limit int64) (*[]map[string]interface{}, error)
- func (gpudb *Gpudb) GetRecordsMapWithOpts(ctx context.Context, table string, offset int64, limit int64, ...) (*[]map[string]interface{}, error)
- func (gpudb *Gpudb) GetRecordsRaw(ctx context.Context, table string, offset int64, limit int64) (*GetRecordsResponse, error)
- func (gpudb *Gpudb) GetRecordsRawWithOpts(ctx context.Context, table string, offset int64, limit int64, ...) (*GetRecordsResponse, error)
- func (gpudb *Gpudb) GetRecordsStruct(ctx context.Context, table string, offset int64, limit int64, ...) (*[]interface{}, error)
- func (gpudb *Gpudb) GetRecordsStructSendChannel(ctx context.Context, table string, offset int64, limit int64, ...) (*GetRecordsResponse, error)
- func (gpudb *Gpudb) GetRecordsStructSendChannelWithOpts(ctx context.Context, table string, offset int64, limit int64, ...) (*GetRecordsResponse, error)
- func (gpudb *Gpudb) GetRecordsStructWithOpts(ctx context.Context, table string, offset int64, limit int64, ...) (*[]interface{}, error)
- func (gpudb *Gpudb) InsertRecordsMap(ctx context.Context, table string, data []interface{}) (*InsertRecordsResponse, error)
- func (gpudb *Gpudb) InsertRecordsMapWithOpts(ctx context.Context, table string, data []interface{}, ...) (*InsertRecordsResponse, error)
- func (gpudb *Gpudb) InsertRecordsRaw(ctx context.Context, table string, data []interface{}) (*InsertRecordsResponse, error)
- func (gpudb *Gpudb) InsertRecordsRawWithOpts(ctx context.Context, table string, data []interface{}, ...) (*InsertRecordsResponse, error)
- func (gpudb *Gpudb) InsertRecordsStruct(ctx context.Context, table string, data []interface{}) (*InsertRecordsResponse, error)
- func (gpudb *Gpudb) InsertRecordsStructWithOpts(ctx context.Context, table string, data []interface{}, ...) (*InsertRecordsResponse, error)
- func (gpudb *Gpudb) ShowExplainVerboseAnalyseSqlStatement(ctx context.Context, statement string) (*ShowExplainVerboseSqlResult, error)
- func (gpudb *Gpudb) ShowExplainVerboseSqlStatement(ctx context.Context, statement string) (*ShowExplainVerboseSqlResult, error)
- func (gpudb *Gpudb) ShowStoredProcedureDDL(ctx context.Context, proc string) (*string, error)
- func (gpudb *Gpudb) ShowSystemPropertiesRaw(ctx context.Context) (*ShowSystemPropertiesResponse, error)
- func (gpudb *Gpudb) ShowSystemPropertiesRawWithOpts(ctx context.Context, options *ShowSystemPropertiesOptions) (*ShowSystemPropertiesResponse, error)
- func (gpudb *Gpudb) ShowSystemStatusRaw(ctx context.Context) (*ShowSystemStatusResponse, error)
- func (gpudb *Gpudb) ShowSystemStatusRawWithOpts(ctx context.Context, options *ShowSystemStatusOptions) (*ShowSystemStatusResponse, error)
- func (gpudb *Gpudb) ShowTableDDL(ctx context.Context, table string) (*string, error)
- func (gpudb *Gpudb) ShowTableRaw(ctx context.Context, table string) (*ShowTableResponse, error)
- func (gpudb *Gpudb) ShowTableRawWithOpts(ctx context.Context, table string, options *ShowTableOptions) (*ShowTableResponse, error)
- func (gpudb *Gpudb) ShowTableResourcesBySchema(ctx context.Context, schema string, hideTempTables bool) (*ShowTableResourcesBySchema, error)
- func (gpudb *Gpudb) ShowTableSchemas(ctx context.Context) (*[]string, error)
- func (gpudb *Gpudb) ShowTableSchemasCleaned(ctx context.Context) (*[]string, error)
- type GpudbOptions
- type InsertRecordsOptions
- type InsertRecordsRequest
- type InsertRecordsResponse
- type JobStatusEnum
- type RequestEncodingEnum
- type ShowExplainVerboseSqlPlan
- type ShowExplainVerboseSqlResult
- type ShowResourceGroupsOptions
- type ShowResourceGroupsRequest
- type ShowResourceGroupsResponse
- type ShowResourceStatisticsOptions
- type ShowResourceStatisticsRequest
- type ShowResourceStatisticsResponse
- type ShowSchemaOptions
- type ShowSchemaRequest
- type ShowSchemaResponse
- type ShowSecurityOptions
- type ShowSecurityRequest
- type ShowSecurityResponse
- type ShowSqlProcOptions
- type ShowSqlProcRequest
- type ShowSqlProcResponse
- type ShowSystemPropertiesOptions
- type ShowSystemPropertiesRequest
- type ShowSystemPropertiesResponse
- type ShowSystemStatusOptions
- type ShowSystemStatusRequest
- type ShowSystemStatusResponse
- type ShowSystemTimingOptions
- type ShowSystemTimingRequest
- type ShowSystemTimingResponse
- type ShowTableAdditionalInfo
- type ShowTableChar
- type ShowTableColumn
- type ShowTableDistributionType
- type ShowTableOptions
- type ShowTableRequest
- type ShowTableResource
- type ShowTableResourcesBySchema
- type ShowTableResponse
Constants ¶
const ( Replicated ShowTableDistributionType = "Replicated" Sharded = "Sharded" ShardedRandomly = "Random" ExternalResource = "External Resource" LogicalView = "Logical View" )
Variables ¶
var CharTypes = []ShowTableChar{
{"char1", 1},
{"char2", 2},
{"char4", 4},
{"char8", 8},
{"char16", 16},
{"char32", 32},
{"char64", 64},
{"char128", 128},
{"char256", 256},
}
var Schemas = AvroSchemas{ // contains filtered or unexported fields }
Functions ¶
func ContainsAnyCharType ¶
func ContainsAnyStr ¶
func ContainsStr ¶
func GetRecordsStructWithOpts ¶
func GetRecordsStructWithOpts[T any]( ctx context.Context, gpudb Gpudb, table string, offset int64, limit int64, options *GetRecordsOptions) ([]T, error)
GetRecordsStructWithOpts - GetRecords generic variant to work with any avro tagged struct
@param ctx @param gpudb @param table @param offset @param limit @param options @return []T @return error
Types ¶
type AdminAddHostRequest ¶
type AdminAddHostRequest struct { HostAddress string `avro:"host_address"` Options map[string]string `avro:"options"` }
AdminAddHostsRequest --------------------------------------------
type AdminAddHostResponse ¶
type AdminAddHostResponse struct {
// contains filtered or unexported fields
}
type AdminAddRanksRequest ¶
type AdminAddRanksRequestOptions ¶
type AdminAddRanksRequestOptions struct {
DryRun bool `avro:"dry_run"`
}
AdminAddRanksRequestOptions --------------------------------------------
type AdminAddRanksResponse ¶
type AdminBackupBeginRequest ¶
type AdminBackupBeginRequestOptions ¶
type AdminBackupBeginRequestOptions struct{}
AdminBackupBegin --------------------------------------------
type AdminBackupEndRequest ¶
type AdminBackupEndRequestOptions ¶
type AdminBackupEndRequestOptions struct{}
AdminBackupEnd --------------------------------------------
type AdminBackupEndResponse ¶
type AdminRemoveHostRequest ¶
type AdminRemoveHostRequest struct { Host string `avro:"host"` Options map[string]string `avro:"options"` }
AdminRemoveHostRequest --------------------------------------------
type AdminRemoveHostRequestOptions ¶
type AdminRemoveHostRequestOptions struct {
DryRun bool
}
type AdminRemoveHostResponse ¶
type AdminRemoveHostResponse struct {
// contains filtered or unexported fields
}
type AdminRemoveRanksRequest ¶
type AdminRemoveRanksRequestOptions ¶
type AdminRemoveRanksRequestOptions struct { RebalanceShardedData bool RebalanceUnshardedData bool Aggressiveness int }
AdminRemoveRanksRequestOptions --------------------------------------------
type AdminShutdownRequest ¶
type AdminShutdownRequestOptions ¶
type AdminShutdownRequestOptions struct { }
AdminShutdown --------------------------------------------------------
type AdminShutdownResponse ¶
type AggregateGroupByOptions ¶
type AggregateGroupByOptions struct { Encoding string FilterExpression string HavingClause string SortOrder string SortBy string ResultTable string ResultTablePersist bool ResultTableForceReplicated bool ResultTableGeneratePk bool Ttl int64 ChunkSize int64 CreateIndexes string ViewId string PivotColumn string PivotValues string GroupingSets string Rollup string Cube string }
AggregateGroupByOptions --------------------------------------------
type AggregateGroupByRequest ¶
type AggregateGroupByResponse ¶
type AggregateGroupByResponse struct { ResponseSchema string `avro:"response_schema_str"` BinaryEncodedResponse []byte `avro:"binary_encoded_response"` JsonEncodedResponse string `avro:"json_encoded_response"` TotalNumberOfRecords int64 `avro:"total_number_of_records"` HasMoreRecords bool `avro:"has_more_records"` PagingTable string `avro:"paging_table"` Info map[string]string `avro:"info"` }
type AggregateStatisticsOptions ¶
AggregateStatisticsOptions --------------------------------------------
type AggregateStatisticsRequest ¶
type AggregateStatisticsRequest struct { TableName string `avro:"table_name"` ColumnName string `avro:"column_name"` // Find supported values for Stats here: https://www.kinetica.com/docs/api/rest/aggregate_statistics_rest.html Stats string `avro:"stats"` Options map[string]string `avro:"options"` }
type AlterGraphActionEnum ¶
type AlterGraphActionEnum string
AlterGraphActionEnum - Actions that can be used on AlterGraphRequest
const ( // AlterGraphActionAddTableMonitor - Add a table monitor to a graph. // The table name is specified as the action argument. AlterGraphActionAddTableMonitor AlterGraphActionEnum = "add_table_monitor" // AlterGraphActionResetClient - The job execution has successfully completed and the response is included in the // output parameter job_response or output parameter job_response_str field AlterGraphActionResetClient AlterGraphActionEnum = "reset_client" // AlterGraphActionResetServer - Reset all current operations on the server side. This is also sent on (re)start. AlterGraphActionResetServer AlterGraphActionEnum = "reset_server" // AlterGraphActionCancelTask - Cancel a specific task on the graph server. AlterGraphActionCancelTask AlterGraphActionEnum = "cancel_task" // AlterGraphActionAlterLogger - Change the server side log level; e.g., 'GraphServer.GraphSolver=DEBUG' AlterGraphActionAlterLogger AlterGraphActionEnum = "alter_logger" // AlterGraphActionDeleteAll - Delete all graphs, and remove any persistence info. AlterGraphActionDeleteAll AlterGraphActionEnum = "delete_all" // AlterGraphActionStatus - Current status of the graph client (db side). AlterGraphActionStatus AlterGraphActionEnum = "status" // AlterGraphActionCollectGraphs - Get the create command for all persisted graphs. AlterGraphActionCollectGraphs AlterGraphActionEnum = "collect_graphs" // AlterGraphActionRestoreGraphs - Re-creates all graphs from persist info on rank0. AlterGraphActionRestoreGraphs AlterGraphActionEnum = "restore_graphs" )
func (AlterGraphActionEnum) String ¶
func (agae AlterGraphActionEnum) String() string
type AlterGraphRequest ¶
type AlterGraphRequest struct { // GraphName - Graph on which the operation should be applied. // If empty then it will apply to all graphs. // This request can be sent from the graph server to the graph client, // or from the client to the server depending on the type of operation. GraphName string `avro:"graph_name"` // Action - Operation to be applied Action AlterGraphActionEnum `avro:"action"` // ActionArg - Action specific argument. ActionArg string `avro:"action_arg"` Options map[string]string `avro:"options"` }
type AlterGraphRequestOptions ¶
type AlterGraphRequestOptions struct { // ServerId - Indicates which graph server(s) to send the request to. // Default is to send to get information about all the servers. ServerID string `avro:"server_id"` // BypassClientCheck - Set for non-user requests. BypassClientCheck bool `avro:"bypass_client_check"` }
AlterGraphRequestOptions --------------------------------------------
type AlterGraphResponse ¶
type AlterGraphResponse struct { // Action - Operation to be applied Action AlterGraphActionEnum `avro:"action"` // ActionArg - Action specific argument. ActionArg string `avro:"action_arg"` // Info - Info map[string]string `avro:"info"` }
type AlterUserActionEnum ¶
type AlterUserActionEnum string
AlterUserRequest -------------------------------------------- RequestEncodingEnum - the encoding of the request payload for the job.
const ( AlterUserActionSetPassword AlterUserActionEnum = "set_password" AlterUserActionSetResourceGroup AlterUserActionEnum = "set_resource_group" AlterUserActionSetDefaultSchema AlterUserActionEnum = "set_default_schema" )
func (AlterUserActionEnum) String ¶
func (auae AlterUserActionEnum) String() string
type AlterUserRequest ¶
type AlterUserRequest struct { // Name of the user to be altered. Must be an existing user. Name string `avro:"name"` // Modification operation to be applied to the user. Action AlterUserActionEnum `avro:"action"` // The value of the modification, depending on input parameter action. Value string `avro:"value"` // The value of the modification, depending on input parameter action. Options map[string]string `avro:"options"` }
type AlterUserRequestOptions ¶
type AlterUserRequestOptions struct{}
type AlterUserResponse ¶
type AlterUserResponse struct{}
type AvroSchemas ¶
type AvroSchemas struct {
// contains filtered or unexported fields
}
type CreateJobOptions ¶
CreateJobOptions --------------------------------------------
type CreateJobRequest ¶
type CreateJobRequest struct { // Indicates which endpoint to execute, e.g. '/alter/table'. Endpoint string `avro:"endpoint"` // The encoding of the request payload for the job. RequestEncoding RequestEncodingEnum `avro:"request_encoding"` // Binary-encoded payload for the job to be run asynchronously. // The payload must contain the relevant input parameters for the endpoint indicated in @{input endpoint}. // Please see the documentation for the appropriate endpoint to see what values must (or can) be specified. // If this parameter is used, then @{input request_encoding} must be {binary}@{choice of input request_encoding} // or {snappy}@{choice of input request_encoding}. Data []byte `avro:"data"` // JSON-encoded payload for the job to be run asynchronously. // The payload must contain the relevant input parameters for the endpoint indicated in @{input endpoint}. // Please see the documentation for the appropriate endpoint to see what values must (or can) be specified. // If this parameter is used, then @{input request_encoding} must be {json}@{choice of input request_encoding}. DataStr string `avro:"data_str"` Options map[string]string `avro:"options"` }
type CreateJobResponse ¶
type CreateResourceGroupRankingEnum ¶
type CreateResourceGroupRankingEnum string
const ( CreateResourceGroupRankingFirst CreateResourceGroupRankingEnum = "first" CreateResourceGroupRankingLast CreateResourceGroupRankingEnum = "last" CreateResourceGroupRankingBefore CreateResourceGroupRankingEnum = "before" CreateResourceGroupRankingAfter CreateResourceGroupRankingEnum = "after" )
func (CreateResourceGroupRankingEnum) String ¶
func (crgre CreateResourceGroupRankingEnum) String() string
type CreateResourceGroupRequest ¶
type CreateResourceGroupRequest struct { // Name -Name of the group to be created. // Must contain only letters, digits, and underscores, and cannot begin with a digit. // Must not match existing resource group name. Name string `avro:"name"` // TierAttributes - Optional map containing tier names and their respective attribute group limits. // The only valid attribute limit that can be set is max_memory (in bytes) for the VRAM & RAM tiers. // For instance, to set max VRAM capacity to 1GB and max RAM capacity to 10GB, // // use: {'VRAM':{'max_memory':'1000000000'}, 'RAM':{'max_memory':'10000000000'}}. // // The default value is an empty map ( {} ). TierAttributes map[string]map[string]string `avro:"tier_attributes"` // Ranking - Indicates the relative ranking among existing resource groups where this // new resource group will be placed. When using before or after, // specify which resource group this one will be inserted before or after in input parameter // adjoining_resource_group. Ranking CreateResourceGroupRankingEnum `avro:"ranking"` // AdjoiningResourceGroup - Indicates the relative ranking among existing resource groups where this // new resource group will be placed. // When using before or after, specify which resource group this one will be inserted before or after // in input parameter adjoining_resource_group. The supported values are: // // first // last // before // after AdjoiningResourceGroup string `avro:"adjoining_resource_group"` Options map[string]string `avro:"options"` }
type CreateResourceGroupRequestOptions ¶
type CreateResourceGroupRequestOptions struct { // MaxCpuConcurrency - Maximum number of simultaneous threads that will be used to execute a request // for this group. // The minimum allowed value is 4. MaxCpuConcurrency string `avro:"max_cpu_concurrency"` // MaxData - Maximum amount of cumulative ram usage regardless of tier status for this group. // The minimum allowed value is -1. MaxData string `avro:"max_data"` // MaxSchedulingPriority - Maximum priority of a scheduled task for this group. // The minimum allowed value is 1. // The maximum allowed value is 100. MaxSchedulingPriority string `avro:"max_scheduling_priority"` // MaxTierPriority - Maximum priority of a tiered object for this group. // The minimum allowed value is 1. // The maximum allowed value is 10. MaxTierPriority string `avro:"max_tier_priority"` }
type CreateSchemaRequest ¶
type CreateSchemaRequest struct { Name string `avro:"schema_name"` Options map[string]string `avro:"options"` }
CreateSchemaRequest --------------------------------------------
type CreateSchemaRequestOptions ¶
type CreateSchemaRequestOptions struct { // NoErrorIfExists - If true, prevents an error from occurring if the schema already exists. // The default value is false. The supported values are: // // true // false NoErrorIfExists bool `avro:"no_error_if_exists"` }
type CreateSchemaResponse ¶
type DeleteResourceGroupRequestOptions ¶
type DeleteResourceGroupRequestOptions struct {
Cascade bool `avro:"cascade_delete"`
}
type DropSchemaRequest ¶
type DropSchemaResponse ¶
type ExecuteSqlMapResult ¶
type ExecuteSqlMapResult struct { *ExecuteSqlResponse ResultsMap *[]map[string]interface{} }
type ExecuteSqlOptions ¶
type ExecuteSqlOptions struct { Encoding string ParallelExecution bool CostBasedOptimization bool PlanCache bool RuleBasedOptimization bool ResultsCaching bool PagingTable string PagingTableTtl int64 DistributedJoins bool DistributedOperations bool SsqOptimization bool LateMaterialization bool Ttl int64 UpdateOnExistingPk bool PreserveDictEncoding bool ValidateChangeColumn bool PrepareMode bool }
ExecuteSqlOptions --------------------------------------------
func NewDefaultExecuteSqlOptions ¶
func NewDefaultExecuteSqlOptions() *ExecuteSqlOptions
type ExecuteSqlRequest ¶
type ExecuteSqlResponse ¶
type ExecuteSqlResponse struct { CountAffected int64 `avro:"count_affected"` ResponseSchema string `avro:"response_schema_str"` BinaryEncodedResponse []byte `avro:"binary_encoded_response"` JsonEncodedResponse string `avro:"json_encoded_response"` TotalNumberOfRecords int64 `avro:"total_number_of_records"` HasMoreRecords bool `avro:"has_more_records"` PagingTable string `avro:"paging_table"` Info map[string]string `avro:"info"` }
type ExecuteSqlStructResult ¶
type ExecuteSqlStructResult struct { *ExecuteSqlResponse ResultsStruct *[]interface{} }
type GetJobOptions ¶
type GetJobOptions struct {
JobTag string
}
GetJobOptions --------------------------------------------
type GetJobRequest ¶
type GetJobResponse ¶
type GetJobResponse struct { // Indicates which endpoint to execute, e.g. '/alter/table'. Endpoint string `avro:"endpoint"` // Status of the submitted job // RUNNING The job is currently executing. // DONE The job execution has successfully completed and the response is included in the output parameter // job_response or output parameter job_response_str field // ERROR The job was attempted, but an error was encountered. The output parameter status_map // contains the details of the error in error_message // CANCELLED Job cancellation was requested while the execution was in progress. JobStatus JobStatusEnum `avro:"job_status"` // True if the end point is still executing. Running bool `avro:"running"` // Approximate percentage of the job completed. Progress int `avro:"progress"` // True if the job execution completed and no errors were encountered. Successful bool `avro:"successful"` // The encoding of the job result (contained in output parameter job_response or output parameter job_response_str. ResponseEncoding string `avro:"response_encoding"` // The binary-encoded response of the job. This field is populated only when the job has completed and // output parameter response_encoding is binary JobResponse []byte `avro:"job_response"` // The json-encoded response of the job. This field is populated only when the job has completed and // output parameter response_encoding is json JobResponseStr string `avro:"job_response_str"` // Map of various status strings for the executed job. StatusMap map[string]string `avro:"status_map"` // Additional information. Info map[string]string `avro:"info"` }
type GetRecordsOptions ¶
type GetRecordsOptions struct { Expression string FastIndexLookup bool SortBy string SortOrder string Encoding string }
GetRecordsOptions --------------------------------------------
func NewDefaultGetRecordsOptions ¶
func NewDefaultGetRecordsOptions() *GetRecordsOptions
type GetRecordsRequest ¶
type GetRecordsResponse ¶
type GetRecordsResponse struct { TableName string `avro:"table_name"` TypeName string `avro:"type_name"` TypeSchema string `avro:"type_schema"` RecordsBinary [][]byte `avro:"records_binary"` RecordsJson []string `avro:"records_json"` TotalNumberOfRecords int64 `avro:"total_number_of_records"` HasMoreRecords bool `avro:"has_more_records"` Info map[string]string `avro:"info"` }
type Gpudb ¶
type Gpudb struct {
// contains filtered or unexported fields
}
func NewWithOptions ¶
func NewWithOptions(ctx context.Context, url string, options *GpudbOptions) *Gpudb
func (*Gpudb) ExecuteSqlMap ¶
func (*Gpudb) ExecuteSqlMapWithOpts ¶
func (gpudb *Gpudb) ExecuteSqlMapWithOpts( ctx context.Context, statement string, offset int64, limit int64, options *ExecuteSqlOptions) (*ExecuteSqlMapResult, error)
func (*Gpudb) ExecuteSqlRaw ¶
func (*Gpudb) ExecuteSqlRawWithOpts ¶
func (*Gpudb) ExecuteSqlStruct ¶
func (*Gpudb) ExecuteSqlStructWithOpts ¶
func (gpudb *Gpudb) ExecuteSqlStructWithOpts( ctx context.Context, statement string, offset int64, limit int64, options *ExecuteSqlOptions, newInstance func() interface{}) (*ExecuteSqlStructResult, error)
func (*Gpudb) GetOptions ¶
func (gpudb *Gpudb) GetOptions() *GpudbOptions
GetOptions
@receiver gpudb @return *GpudbOptions
func (*Gpudb) GetRecordsMap ¶
func (*Gpudb) GetRecordsMapWithOpts ¶
func (*Gpudb) GetRecordsRaw ¶
func (*Gpudb) GetRecordsRawWithOpts ¶
func (gpudb *Gpudb) GetRecordsRawWithOpts( ctx context.Context, table string, offset int64, limit int64, options *GetRecordsOptions) (*GetRecordsResponse, error)
func (*Gpudb) GetRecordsStruct ¶
func (*Gpudb) GetRecordsStructSendChannel ¶
func (*Gpudb) GetRecordsStructSendChannelWithOpts ¶
func (gpudb *Gpudb) GetRecordsStructSendChannelWithOpts( ctx context.Context, table string, offset int64, limit int64, options *GetRecordsOptions, resultChannel chan interface{}, newInstance func() interface{}) (*GetRecordsResponse, error)
func (*Gpudb) GetRecordsStructWithOpts ¶
func (*Gpudb) InsertRecordsMap ¶
func (gpudb *Gpudb) InsertRecordsMap( ctx context.Context, table string, data []interface{}) (*InsertRecordsResponse, error)
InsertRecordsMap //
@receiver gpudb @param ctx @param table @param data @return *InsertRecordsResponse @return error
func (*Gpudb) InsertRecordsMapWithOpts ¶
func (gpudb *Gpudb) InsertRecordsMapWithOpts( ctx context.Context, table string, data []interface{}, options *InsertRecordsOptions) (*InsertRecordsResponse, error)
InsertRecordsMapWithOpts
@receiver gpudb @param ctx @param table @param data @param options @return *InsertRecordsResponse @return error
func (*Gpudb) InsertRecordsRaw ¶
func (gpudb *Gpudb) InsertRecordsRaw( ctx context.Context, table string, data []interface{}) (*InsertRecordsResponse, error)
InsertRecordsRaw //
@receiver gpudb @param ctx @param table @param data @return *InsertRecordsResponse @return error
func (*Gpudb) InsertRecordsRawWithOpts ¶
func (gpudb *Gpudb) InsertRecordsRawWithOpts( ctx context.Context, table string, data []interface{}, options *InsertRecordsOptions) (*InsertRecordsResponse, error)
InsertRecordsRawWithOpts //
@receiver gpudb @param ctx @param table @param data @param options @return *InsertRecordsResponse @return error
func (*Gpudb) InsertRecordsStruct ¶
func (gpudb *Gpudb) InsertRecordsStruct( ctx context.Context, table string, data []interface{}) (*InsertRecordsResponse, error)
InsertRecordsStruct
@receiver gpudb @param ctx @param table @param data @return *InsertRecordsResponse @return error
func (*Gpudb) InsertRecordsStructWithOpts ¶
func (gpudb *Gpudb) InsertRecordsStructWithOpts( ctx context.Context, table string, data []interface{}, options *InsertRecordsOptions) (*InsertRecordsResponse, error)
InsertRecordsStructWithOpts
@receiver gpudb @param ctx @param table @param data @param options @return *InsertRecordsResponse @return error
func (*Gpudb) ShowExplainVerboseAnalyseSqlStatement ¶
func (*Gpudb) ShowExplainVerboseSqlStatement ¶
func (*Gpudb) ShowStoredProcedureDDL ¶
func (*Gpudb) ShowSystemPropertiesRaw ¶
func (gpudb *Gpudb) ShowSystemPropertiesRaw(ctx context.Context) (*ShowSystemPropertiesResponse, error)
func (*Gpudb) ShowSystemPropertiesRawWithOpts ¶
func (gpudb *Gpudb) ShowSystemPropertiesRawWithOpts( ctx context.Context, options *ShowSystemPropertiesOptions) (*ShowSystemPropertiesResponse, error)
func (*Gpudb) ShowSystemStatusRaw ¶
func (gpudb *Gpudb) ShowSystemStatusRaw(ctx context.Context) (*ShowSystemStatusResponse, error)
func (*Gpudb) ShowSystemStatusRawWithOpts ¶
func (gpudb *Gpudb) ShowSystemStatusRawWithOpts( ctx context.Context, options *ShowSystemStatusOptions) (*ShowSystemStatusResponse, error)
func (*Gpudb) ShowTableDDL ¶
func (*Gpudb) ShowTableRaw ¶
func (*Gpudb) ShowTableRawWithOpts ¶
func (gpudb *Gpudb) ShowTableRawWithOpts( ctx context.Context, table string, options *ShowTableOptions) (*ShowTableResponse, error)
func (*Gpudb) ShowTableResourcesBySchema ¶
func (*Gpudb) ShowTableSchemas ¶
Might be required for 7.0 which does not support /show/schemas
type GpudbOptions ¶
type InsertRecordsOptions ¶
type InsertRecordsOptions struct { UpdateOnExistingPk bool IgnoreExistingPk bool ReturnRecordIDs bool TruncateStrings bool ReturnIndividualErrors bool AllowPartialBatch bool }
InsertRecords ---------------------------
func NewDefaultInsertRecordsOptions ¶
func NewDefaultInsertRecordsOptions() *InsertRecordsOptions
NewDefaultInsertRecordsOptions
@return *InsertRecordsOptions
type InsertRecordsRequest ¶
type InsertRecordsResponse ¶
type JobStatusEnum ¶
type JobStatusEnum string
JobStatusEnum - Status of the submitted job
const ( // JobStatusRunning - The job is currently executing. JobStatusRunning JobStatusEnum = "RUNNING" // JobStatusDone - The job execution has successfully completed and the response is included in the output // parameter job_response or output parameter job_response_str field JobStatusDone JobStatusEnum = "DONE" // JobStatusError - The job was attempted, but an error was encountered. The output parameter status_map // contains the details of the error in error_message JobStatusError JobStatusEnum = "ERROR" // JobStatusCancelled - Job cancellation was requested while the execution was in progress. JobStatusCancelled JobStatusEnum = "CANCELLED" )
func (JobStatusEnum) String ¶
func (jse JobStatusEnum) String() string
type RequestEncodingEnum ¶
type RequestEncodingEnum string
RequestEncodingEnum - the encoding of the request payload for the job.
const ( RequestEncodingBinary RequestEncodingEnum = "binary" RequestEncodingJSON RequestEncodingEnum = "json" RequestEncodingSnappy RequestEncodingEnum = "snappy" )
func (RequestEncodingEnum) String ¶
func (ree RequestEncodingEnum) String() string
type ShowExplainVerboseSqlPlan ¶
type ShowExplainVerboseSqlPlan struct { Id int `json:"ID,string"` /* {2 @ rank:1, tom:0 filter-plan-in |--alias--|-num_chunks-|---count----|-set-name---- filter-plan-in | TableAlias_0_ | 1 | 17 | sys_sql_temp.40375_Aggregate_2_692dc858-7a90-11eb-b9ee-0242ac110002 filter-plan-in | TableAlias_1_ | 1 | 34 | sys_sql_temp.40375_Aggregate_4_692dc8b2-7a90-11eb-ba54-0242ac110002 filter-plan-step|--i-|----time----|----count----|---in_count--|--out_count--|-J-|-----filter-type-|---set-indices---|---------stencil-types----------|---expression filter-plan-step| 0 | 0.002362 | 578 | | | | start | | B0 B1 | filter-plan-step| 1 | 0.001226 | 122 | 578 | 122 | | equi-join:1:1 | 1,0 | E1 E1 | (TableAlias_0_.vendor_id == TableAlias_1_.vendor_id) filter-plan-out | count-time = 8e-07 | count = 122 | set-name = filter_planner_view_65 */ AdditionalInfo string `json:"ADDITIONAL_INFO"` // this is a large text block Columns string `json:"COLUMNS"` Options string `json:"OPTIONS"` RunTime float64 `json:"RUN_TIME,string"` TableDefinitions string `json:"TABLE_DEFINITIONS"` Dependencies string `json:"DEPENDENCIES"` Endpoint string `json:"ENDPOINT"` JsonRequest string `json:"JSON_REQUEST"` LastUseTables string `json:"LAST_USE_TABLES"` Expressions string `json:"EXPRESSIONS"` ResultDistribution string `json:"RESULT_DISTRIBUTION"` // e.g. "NA / replicated" or "shardkey10,shardkey20; / shardkey1,shardkey2;" ResultRows int64 `json:"RESULT_ROWS,string"` Parent *ShowExplainVerboseSqlResult }
func (*ShowExplainVerboseSqlPlan) FindDependentPlans ¶
func (plan *ShowExplainVerboseSqlPlan) FindDependentPlans() (*[]ShowExplainVerboseSqlPlan, error)
func (*ShowExplainVerboseSqlPlan) JsonRequestMap ¶
func (plan *ShowExplainVerboseSqlPlan) JsonRequestMap() (*map[string]interface{}, error)
type ShowExplainVerboseSqlResult ¶
type ShowExplainVerboseSqlResult struct {
Plans *[]ShowExplainVerboseSqlPlan `json:"PLAN"`
}
type ShowResourceGroupsOptions ¶
ShowResourceGroupsOptions --------------------------------------------
type ShowResourceStatisticsOptions ¶
type ShowResourceStatisticsOptions struct {
TableNames string
}
ShowResourceStatisticsOptions --------------------------------------------
type ShowSchemaOptions ¶
type ShowSchemaOptions struct {
NoErrorIfNotExists bool
}
ShowSchemaOptions --------------------------------------------
type ShowSchemaRequest ¶
type ShowSchemaResponse ¶
type ShowSecurityOptions ¶
type ShowSecurityOptions struct { }
ShowSecurityOptions --------------------------------------------
type ShowSecurityRequest ¶
type ShowSecurityResponse ¶
type ShowSqlProcOptions ¶
type ShowSqlProcOptions struct {
NoErrorIfNotExists bool
}
ShowSqlProcOptions --------------------------------------------
type ShowSqlProcRequest ¶
type ShowSqlProcResponse ¶
type ShowSystemPropertiesOptions ¶
type ShowSystemPropertiesOptions struct {
Properties string
}
ShowSystemPropertiesOptions --------------------------------------------
func NewDefaultShowSystemPropertiesOptions ¶
func NewDefaultShowSystemPropertiesOptions() *ShowSystemPropertiesOptions
type ShowSystemStatusOptions ¶
type ShowSystemStatusOptions struct { }
ShowSystemStatusOptions --------------------------------------------
func NewDefaultShowSystemStatusOptions ¶
func NewDefaultShowSystemStatusOptions() *ShowSystemStatusOptions
type ShowSystemStatusRequest ¶
type ShowSystemTimingOptions ¶
type ShowSystemTimingOptions struct { }
ShowSystemTimingOptions --------------------------------------------
type ShowSystemTimingRequest ¶
type ShowTableAdditionalInfo ¶
type ShowTableAdditionalInfo struct { AttributeIndexes []string // sep by ; CollectionNames string GlobalAccessMode string IsDirty bool RecordBytes int64 RefreshMethod string RemainingTableTtl int64 StrategyDefinition string PartitionDefinitionsJson string RequestAvroJson string RequestAvroType string TableTtl int64 CompressedColumns map[string]string ForeignKeys string // verify with TPC-DS ForeignShardKey string // verify with TPC-DS IsViewPersisted bool // seems always be false LastRefreshTime string NextRefreshTime string PartitionType string // NONE, LIST, ... IsAutomaticPartition bool PartitionKeys []string // sep by , SchemaName string TableMonitor string UserChunkSize int64 ViewTableName string ColumnMemoryUsageTotal int64 ColumnMemoryUsage map[string]int64 IndexMemoryUsageTotal int64 IndexMemoryUsage map[string]int64 }
type ShowTableChar ¶
type ShowTableColumn ¶
type ShowTableDistributionType ¶
type ShowTableDistributionType string
type ShowTableOptions ¶
type ShowTableOptions struct { ForceSynchronous bool GetSizes bool ShowChildren bool NoErrorIfNotExists bool GetColumnInfo bool }
ShowTableOptions --------------------------------------------
func NewDefaultShowTableOptions ¶
func NewDefaultShowTableOptions() *ShowTableOptions
type ShowTableRequest ¶
type ShowTableResource ¶
type ShowTableResource struct { Name string TableType ShowTableDistributionType ResultTable bool TypeId string TypeSchema map[string]interface{} // JSON TypeLabel string Columns []ShowTableColumn Size int64 FullSize int64 ShowTableAdditionalInfo *ShowTableAdditionalInfo }
type ShowTableResourcesBySchema ¶
type ShowTableResourcesBySchema struct { Tables []ShowTableResource MaterializedViews []ShowTableResource MaterializedExternalTables []ShowTableResource LogicalExternalTable []ShowTableResource LogicalViews []ShowTableResource }
type ShowTableResponse ¶
type ShowTableResponse struct { TableName string `avro:"table_name"` TableNames []string `avro:"table_names"` TableDescriptions [][]string `avro:"table_descriptions"` TypeIds []string `avro:"type_ids"` TypeSchemas []string `avro:"type_schemas"` TypeLabels []string `avro:"type_labels"` Properties []map[string][]string `avro:"properties"` AdditionalInfo []map[string]string `avro:"additional_info"` Sizes []int64 `avro:"sizes"` FullSizes []int64 `avro:"full_sizes"` JoinSizes []float64 `avro:"join_sizes"` TotalSize int64 `avro:"total_size"` TotalFullSize int64 `avro:"total_full_size"` Info map[string]string `avro:"info"` }