Documentation
¶
Index ¶
- type AttributeMetadata
- type AttributeStorageLocation
- type BatchConfig
- type BatchOperation
- type BatchResult
- type CascadeAction
- type CascadeRule
- type CompositeCondition
- type Condition
- type Config
- type ConfigError
- type CrossSchemaRequest
- type CursorQueryResult
- type DataRecord
- type DatabaseConfig
- type EntityConfig
- type EntityIdentifier
- type EntityManager
- type EntityOperation
- type EntityUpdate
- type FilterField
- type FilterType
- type JSONSchema
- type KvCondition
- type LoggingConfig
- type Logic
- type MainColumn
- type MainColumnBinding
- type MainColumnEncoding
- type MainColumnType
- type MetricsConfig
- type OperationError
- type OperationType
- type OrderBy
- type PerformanceConfig
- type PropertySchema
- type QueryConfig
- type QueryRequest
- type QueryResult
- type Reference
- type ReferenceConfig
- type ReferenceType
- type RelationSchema
- type SchemaAttributeCache
- type SchemaRegistry
- type SortOrder
- type TableNames
- type TransactionConfig
- type ValueType
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
This section is empty.
Types ¶
type AttributeMetadata ¶ added in v0.0.3
type AttributeMetadata struct {
AttributeName string `json:"attr_name"` // attr_name, JSON Path
AttributeID int16 `json:"attr_id"` // attr_id
ValueType ValueType `json:"value_type"` // 'text', 'numeric', 'date', 'bool'
ColumnBinding *MainColumnBinding `json:"column_binding,omitempty"`
}
AttributeMetadata stores cached metadata from the attributes table.
func (AttributeMetadata) IsInsideArray ¶ added in v0.0.3
func (m AttributeMetadata) IsInsideArray() bool
IsInsideArray infers if the attribute is inside an array based on its name.
func (AttributeMetadata) Location ¶ added in v0.0.3
func (m AttributeMetadata) Location() AttributeStorageLocation
Location returns where the attribute is stored. If ColumnBinding is nil, the attribute is in EAV; otherwise in main table.
type AttributeStorageLocation ¶ added in v0.0.3
type AttributeStorageLocation string
AttributeStorageLocation enumerates where the attribute physically resides.
const ( AttributeStorageLocationUnknown AttributeStorageLocation = "" AttributeStorageLocationMain AttributeStorageLocation = "main" AttributeStorageLocationEAV AttributeStorageLocation = "eav" )
type BatchConfig ¶ added in v0.0.2
type BatchConfig struct {
EnableDynamicSizing bool `json:"enableDynamicSizing"`
EnableParallelProcessing bool `json:"enableParallelProcessing"`
EnableBatchStreaming bool `json:"enableBatchStreaming"`
ParallelThreshold int `json:"parallelThreshold"`
StreamingThreshold int `json:"streamingThreshold"`
MaxParallelWorkers int `json:"maxParallelWorkers"`
StreamingChunkSize int `json:"streamingChunkSize"`
StreamingDelay int `json:"streamingDelay"` // milliseconds
MaxComplexityPerBatch int `json:"maxComplexityPerBatch"`
AttributeComplexityScore int `json:"attributeComplexityScore"`
OptimalChunkSize int `json:"optimalChunkSize"`
}
BatchConfig contains batch processing settings
type BatchOperation ¶
type BatchOperation struct {
Operations []EntityOperation `json:"operations"`
Atomic bool `json:"atomic"` // Whether to use transactions
}
BatchOperation represents batch entity operations
type BatchResult ¶
type BatchResult struct {
Successful []*DataRecord `json:"successful"`
Failed []OperationError `json:"failed"`
TotalCount int `json:"totalCount"`
Duration int64 `json:"duration"` // microseconds
}
BatchResult represents results from batch operations
type CascadeAction ¶ added in v0.0.2
type CascadeAction string
CascadeAction defines the type of cascade action
const ( CascadeActionDelete CascadeAction = "delete" CascadeActionUpdate CascadeAction = "update" CascadeActionNullify CascadeAction = "nullify" CascadeActionRestrict CascadeAction = "restrict" )
type CascadeRule ¶ added in v0.0.2
type CascadeRule struct {
SourceSchema string `json:"sourceSchema"`
TargetSchema string `json:"targetSchema"`
Action CascadeAction `json:"action"`
MaxDepth int `json:"maxDepth,omitempty"`
}
CascadeRule defines cascade behavior for specific schema relationships
type CompositeCondition ¶
--- 3. Composite Condition (Non-Leaf Node) ---
func (*CompositeCondition) IsLeaf ¶
func (c *CompositeCondition) IsLeaf() bool
func (*CompositeCondition) UnmarshalJSON ¶
func (c *CompositeCondition) UnmarshalJSON(data []byte) error
UnmarshalJSON customizes decoding so that nested conditions are turned into the appropriate concrete condition implementations.
type Config ¶ added in v0.0.2
type Config struct {
Database DatabaseConfig `json:"database"`
Query QueryConfig `json:"query"`
Entity EntityConfig `json:"entity"`
Transaction TransactionConfig `json:"transaction"`
Performance PerformanceConfig `json:"performance"`
Logging LoggingConfig `json:"logging"`
Metrics MetricsConfig `json:"metrics"`
Reference ReferenceConfig `json:"reference"`
SchemaRegistry SchemaRegistry `json:"-"` // Custom schema registry implementation (optional)
}
Config consolidates settings from both modules
func DefaultConfig ¶ added in v0.0.2
func DefaultConfig(schemaRegistry SchemaRegistry) *Config
DefaultConfig returns a default configuration
type ConfigError ¶ added in v0.0.2
ConfigError represents a configuration validation error
func (*ConfigError) Error ¶ added in v0.0.2
func (e *ConfigError) Error() string
type CrossSchemaRequest ¶
type CrossSchemaRequest struct {
SchemaNames []string `json:"schema_names" validate:"required"`
SearchTerm string `json:"search_term" validate:"required"`
Page int `json:"page" validate:"min=1"`
ItemsPerPage int `json:"items_per_page" validate:"min=1,max=100"`
Condition Condition `json:"-"` // Custom unmarshal, can be CompositeCondition or KvCondition
Attrs []string `json:"attrs,omitempty"` // Attributes to return (field projection)
}
CrossSchemaRequest represents a cross-schema search request
func (CrossSchemaRequest) MarshalJSON ¶
func (r CrossSchemaRequest) MarshalJSON() ([]byte, error)
MarshalJSON implements custom JSON marshaling for CrossSchemaRequest.
func (*CrossSchemaRequest) UnmarshalJSON ¶
func (r *CrossSchemaRequest) UnmarshalJSON(data []byte) error
UnmarshalJSON implements custom JSON unmarshaling for CrossSchemaRequest. It allows the Condition field to be either a CompositeCondition or KvCondition.
type CursorQueryResult ¶
type CursorQueryResult struct {
Data []*DataRecord `json:"data"`
NextCursor string `json:"next_cursor,omitempty"`
HasMore bool `json:"has_more"`
ExecutionTime time.Duration `json:"execution_time"`
}
CursorQueryResult represents cursor-based pagination results.
type DataRecord ¶
type DatabaseConfig ¶ added in v0.0.2
type DatabaseConfig struct {
Host string `json:"host"`
Port int `json:"port"`
Database string `json:"database"`
Username string `json:"username"`
Password string `json:"password"`
SSLMode string `json:"sslMode"`
MaxConnections int `json:"maxConnections"`
MaxIdleConns int `json:"maxIdleConns"`
ConnMaxLifetime time.Duration `json:"connMaxLifetime"`
ConnMaxIdleTime time.Duration `json:"connMaxIdleTime"`
Timeout time.Duration `json:"timeout"`
TableNames TableNames `json:"tableNames"`
}
DatabaseConfig contains database connection settings
type EntityConfig ¶ added in v0.0.2
type EntityConfig struct {
EnableReferenceValidation bool `json:"enableReferenceValidation"`
EnableCascadeDelete bool `json:"enableCascadeDelete"`
BatchSize int `json:"batchSize"`
CacheEnabled bool `json:"cacheEnabled"`
CacheTTL time.Duration `json:"cacheTTL"`
MaxEntitySize int `json:"maxEntitySize"`
EnableVersioning bool `json:"enableVersioning"`
SchemaDirectory string `json:"schemaDirectory"`
}
EntityConfig contains entity management settings
type EntityIdentifier ¶
type EntityIdentifier struct {
SchemaName string `json:"schemaName"`
RowID uuid.UUID `json:"rowId"`
}
EntityIdentifier identifies an entity for operations
type EntityManager ¶
type EntityManager interface {
// Entity CRUD operations
Create(ctx context.Context, req *EntityOperation) (*DataRecord, error)
Get(ctx context.Context, req *QueryRequest) (*DataRecord, error)
Update(ctx context.Context, req *EntityOperation) (*DataRecord, error)
Delete(ctx context.Context, req *EntityOperation) error
// Query operations
Query(ctx context.Context, req *QueryRequest) (*QueryResult, error)
CrossSchemaSearch(ctx context.Context, req *CrossSchemaRequest) (*QueryResult, error)
// Batch operations
BatchCreate(ctx context.Context, req *BatchOperation) (*BatchResult, error)
BatchUpdate(ctx context.Context, req *BatchOperation) (*BatchResult, error)
BatchDelete(ctx context.Context, req *BatchOperation) (*BatchResult, error)
}
EntityManager provides comprehensive entity and query operations
type EntityOperation ¶
type EntityOperation struct {
EntityIdentifier
Type OperationType `json:"type"`
Data map[string]any `json:"data,omitempty"`
Updates map[string]any `json:"updates,omitempty"`
}
EntityOperation represents CRUD operations
type EntityUpdate ¶
type EntityUpdate struct {
EntityIdentifier
Updates any `json:"updates"`
}
EntityUpdate represents an update operation
type FilterField ¶
type FilterField string
const ( FilterFieldAttributeName FilterField = "attr_name" FilterFieldValueText FilterField = "value_text" FilterFieldValueNumeric FilterField = "value_numeric" FilterFieldRowID FilterField = "row_id" FilterFieldSchemaName FilterField = "schema_name" )
type FilterType ¶
type FilterType string
FilterType defines supported filter operations
const ( FilterEquals FilterType = "equals" FilterNotEquals FilterType = "not_equals" FilterStartsWith FilterType = "starts_with" FilterContains FilterType = "contains" FilterGreaterThan FilterType = "gt" FilterLessThan FilterType = "lt" FilterGreaterEq FilterType = "gte" FilterLessEq FilterType = "lte" FilterIn FilterType = "in" FilterNotIn FilterType = "not_in" )
type JSONSchema ¶ added in v0.0.15
type JSONSchema struct {
ID int16 `json:"id"`
Name string `json:"name"`
Version int `json:"version"`
Schema string `json:"schema"`
Properties map[string]*PropertySchema `json:"properties"`
Required []string `json:"required"`
CreatedAt int64 `json:"created_at"`
}
JSONSchema represents a schema definition.
type KvCondition ¶
--- 4. KvCondition (Leaf Node) ---
func (*KvCondition) IsLeaf ¶
func (kv *KvCondition) IsLeaf() bool
func (*KvCondition) UnmarshalJSON ¶
func (kv *KvCondition) UnmarshalJSON(data []byte) error
UnmarshalJSON ensures short-hand keys are present.
type LoggingConfig ¶ added in v0.0.2
type LoggingConfig struct {
Level string `json:"level"`
Format string `json:"format"`
EnableStructured bool `json:"enableStructured"`
EnablePerformance bool `json:"enablePerformance"`
EnableQueryLogging bool `json:"enableQueryLogging"`
LogSlowQueries bool `json:"logSlowQueries"`
SlowQueryThreshold time.Duration `json:"slowQueryThreshold"`
MaxLogSize int `json:"maxLogSize"`
LogRotation bool `json:"logRotation"`
SanitizeParameters bool `json:"sanitizeParameters"`
LogQueries bool `json:"logQueries"`
LogErrors bool `json:"logErrors"`
LogSecurityEvents bool `json:"logSecurityEvents"`
LogPerformanceWarnings bool `json:"logPerformanceWarnings"`
LogAllOperations bool `json:"logAllOperations"`
EnableDetailedLogging bool `json:"enableDetailedLogging"`
}
LoggingConfig contains logging settings
type MainColumn ¶ added in v0.0.3
type MainColumn string
MainColumn represents column names in the main entity table.
const ( MainColumnText01 MainColumn = "text_01" MainColumnText02 MainColumn = "text_02" MainColumnText03 MainColumn = "text_03" MainColumnText04 MainColumn = "text_04" MainColumnText05 MainColumn = "text_05" MainColumnText06 MainColumn = "text_06" MainColumnText07 MainColumn = "text_07" MainColumnText08 MainColumn = "text_08" MainColumnText09 MainColumn = "text_09" MainColumnText10 MainColumn = "text_10" MainColumnSmallint01 MainColumn = "smallint_01" MainColumnSmallint02 MainColumn = "smallint_02" MainColumnInteger01 MainColumn = "integer_01" MainColumnInteger02 MainColumn = "integer_02" MainColumnInteger03 MainColumn = "integer_03" MainColumnBigint01 MainColumn = "bigint_01" MainColumnBigint02 MainColumn = "bigint_02" MainColumnBigint03 MainColumn = "bigint_03" MainColumnBigint04 MainColumn = "bigint_04" MainColumnBigint05 MainColumn = "bigint_05" MainColumnDouble01 MainColumn = "double_01" MainColumnDouble02 MainColumn = "double_02" MainColumnDouble03 MainColumn = "double_03" MainColumnDouble04 MainColumn = "double_04" MainColumnDouble05 MainColumn = "double_05" MainColumnUUID01 MainColumn = "uuid_01" MainColumnUUID02 MainColumn = "uuid_02" MainColumnCreatedAt MainColumn = "ltbase_created_at" MainColumnUpdatedAt MainColumn = "ltbase_updated_at" MainColumnDeletedAt MainColumn = "ltbase_deleted_at" MainColumnSchemaID MainColumn = "ltbase_schema_id" MainColumnRowID MainColumn = "ltbase_row_id" )
type MainColumnBinding ¶ added in v0.0.3
type MainColumnBinding struct {
ColumnName MainColumn `json:"col_name"`
Encoding MainColumnEncoding `json:"encoding,omitempty"`
}
MainColumnBinding describes how a schema attribute maps into a hot attribute column.
func (*MainColumnBinding) ColumnType ¶ added in v0.0.3
func (m *MainColumnBinding) ColumnType() MainColumnType
ColumnType derives the column type from the column name prefix.
type MainColumnEncoding ¶ added in v0.0.3
type MainColumnEncoding string
MainColumnEncoding represents special encoding for main column values.
const ( MainColumnEncodingDefault MainColumnEncoding = "default" MainColumnEncodingBoolText MainColumnEncoding = "bool_text" // "true"/"false" string MainColumnEncodingUnixMs MainColumnEncoding = "unix_ms" MainColumnEncodingBoolInt MainColumnEncoding = "bool_smallint" MainColumnEncodingISO8601 MainColumnEncoding = "iso8601" )
type MainColumnType ¶ added in v0.0.3
type MainColumnType string
MainColumnType represents the data type of a main column.
const ( MainColumnTypeText MainColumnType = "text" MainColumnTypeSmallint MainColumnType = "smallint" MainColumnTypeInteger MainColumnType = "integer" MainColumnTypeBigint MainColumnType = "bigint" MainColumnTypeDouble MainColumnType = "double" MainColumnTypeUUID MainColumnType = "uuid" )
type MetricsConfig ¶ added in v0.0.2
type MetricsConfig struct {
Enabled bool `json:"enabled"`
Provider string `json:"provider"` // prometheus, statsd, etc.
Endpoint string `json:"endpoint"`
CollectionInterval time.Duration `json:"collectionInterval"`
EnableHistograms bool `json:"enableHistograms"`
EnableCounters bool `json:"enableCounters"`
EnableGauges bool `json:"enableGauges"`
Namespace string `json:"namespace"`
Labels map[string]string `json:"labels"`
MaxSamples int `json:"maxSamples"`
EnableOperationMetrics bool `json:"enableOperationMetrics"`
EnableTransactionMetrics bool `json:"enableTransactionMetrics"`
EnablePatternMetrics bool `json:"enablePatternMetrics"`
}
MetricsConfig contains metrics collection settings
type OperationError ¶
type OperationError struct {
Operation EntityOperation `json:"operation"`
Error string `json:"error"`
Code string `json:"code"`
Details map[string]any `json:"details,omitempty"`
}
OperationError represents an error for a specific operation
type OperationType ¶
type OperationType string
OperationType represents CRUD operations
const ( OperationCreate OperationType = "create" OperationRead OperationType = "read" OperationUpdate OperationType = "update" OperationDelete OperationType = "delete" OperationQuery OperationType = "query" )
type PerformanceConfig ¶ added in v0.0.2
type PerformanceConfig struct {
EnableMonitoring bool `json:"enableMonitoring"`
SlowQueryThreshold time.Duration `json:"slowQueryThreshold"`
SlowOperationThreshold time.Duration `json:"slowOperationThreshold"`
MetricsCollectionInterval time.Duration `json:"metricsCollectionInterval"`
BatchSize int `json:"batchSize"`
MaxBatchSize int `json:"maxBatchSize"`
Batch BatchConfig `json:"batch"`
// Unified monitoring settings
MaxMetricsHistory int `json:"maxMetricsHistory"`
MaxAlertsHistory int `json:"maxAlertsHistory"`
MaxRecommendations int `json:"maxRecommendations"`
EnableAlerting bool `json:"enableAlerting"`
EnableRecommendations bool `json:"enableRecommendations"`
AlertingInterval time.Duration `json:"alertingInterval"`
RecommendationInterval time.Duration `json:"recommendationInterval"`
// Memory monitoring
EnableMemoryMonitoring bool `json:"enableMemoryMonitoring"`
MemoryThreshold int64 `json:"memoryThreshold"`
// Correlation tracking
EnableCorrelationTracking bool `json:"enableCorrelationTracking"`
CorrelationTTL time.Duration `json:"correlationTTL"`
}
PerformanceConfig contains performance monitoring settings
type PropertySchema ¶ added in v0.0.15
type PropertySchema struct {
Name string `json:"name"`
Type string `json:"type"` // "string", "integer", "number", "boolean", "array", "object", "null"
Format string `json:"format,omitempty"`
Items *PropertySchema `json:"items,omitempty"`
Properties map[string]*PropertySchema `json:"properties,omitempty"`
Required bool `json:"required"`
Default any `json:"default,omitempty"`
Enum []any `json:"enum,omitempty"`
Minimum *float64 `json:"minimum,omitempty"`
Maximum *float64 `json:"maximum,omitempty"`
MinLength *int `json:"minLength,omitempty"`
MaxLength *int `json:"maxLength,omitempty"`
Pattern string `json:"pattern,omitempty"`
Relation *RelationSchema `json:"x-relation,omitempty"`
LTBaseType string `json:"x-ltbase-type,omitempty"` // "virtual" for virtual fields that are populated dynamically
LTBaseNote string `json:"x-ltbase-note-prop,omitempty"` // Reference to note field: "${note_id}", "${owner_id}", "${note_data}"
}
PropertySchema defines the schema for a single property.
type QueryConfig ¶ added in v0.0.2
type QueryConfig struct {
DefaultTimeout time.Duration `json:"defaultTimeout"`
MaxRows int `json:"maxRows"`
DefaultPageSize int `json:"defaultPageSize"`
MaxPageSize int `json:"maxPageSize"`
EnableQueryPlan bool `json:"enableQueryPlan"`
EnableOptimization bool `json:"enableOptimization"`
CacheQueryPlans bool `json:"cacheQueryPlans"`
QueryPlanCacheTTL time.Duration `json:"queryPlanCacheTTL"`
}
QueryConfig contains query execution settings
type QueryRequest ¶
type QueryRequest struct {
SchemaName string `json:"schema_name" validate:"required"`
Page int `json:"page" validate:"min=1"`
ItemsPerPage int `json:"items_per_page" validate:"min=1,max=100"`
Condition Condition `json:"-"` // Custom unmarshal, can be CompositeCondition or KvCondition
SortBy []string `json:"sort_by,omitempty"`
SortOrder SortOrder `json:"sort_order,omitempty"`
RowID *uuid.UUID `json:"row_id,omitempty"` // For entity-specific operations
Attrs []string `json:"attrs,omitempty"` // Attributes to return (field projection)
}
QueryRequest represents a pagination query request.
func (QueryRequest) MarshalJSON ¶
func (r QueryRequest) MarshalJSON() ([]byte, error)
MarshalJSON implements custom JSON marshaling for QueryRequest.
func (*QueryRequest) UnmarshalJSON ¶
func (r *QueryRequest) UnmarshalJSON(data []byte) error
UnmarshalJSON implements custom JSON unmarshaling for QueryRequest. It allows the Condition field to be either a CompositeCondition or KvCondition.
type QueryResult ¶
type QueryResult struct {
Data []*DataRecord `json:"data"`
TotalRecords int `json:"total_records"`
TotalPages int `json:"total_pages"`
CurrentPage int `json:"current_page"`
ItemsPerPage int `json:"items_per_page"`
HasNext bool `json:"has_next"`
HasPrevious bool `json:"has_previous"`
ExecutionTime time.Duration `json:"execution_time"`
}
QueryResult represents paginated query results.
type Reference ¶
type Reference struct {
SourceSchemaName string `json:"sourceSchemaName"`
SourceRowID uuid.UUID `json:"sourceRowId"`
SourceFieldName string `json:"sourceFieldName"`
TargetSchemaName string `json:"targetSchemaName"`
TargetRowID uuid.UUID `json:"targetRowId"`
ReferenceType ReferenceType `json:"referenceType"`
}
Reference represents a reference from one entity to another
type ReferenceConfig ¶ added in v0.0.2
type ReferenceConfig struct {
ValidateOnCreate bool `json:"validateOnCreate"`
ValidateOnUpdate bool `json:"validateOnUpdate"`
CheckIntegrity bool `json:"checkIntegrity"`
CascadeDelete bool `json:"cascadeDelete"`
CascadeUpdate bool `json:"cascadeUpdate"`
MaxCascadeDepth int `json:"maxCascadeDepth"`
CascadeRules map[string]CascadeRule `json:"cascadeRules,omitempty"`
EnableCaching bool `json:"enableCaching"`
CacheTTL time.Duration `json:"cacheTTL"`
MaxCacheSize int `json:"maxCacheSize"`
BatchSize int `json:"batchSize"`
}
ReferenceConfig contains reference management settings
type ReferenceType ¶
type ReferenceType string
ReferenceType represents the type of reference
const ( ReferenceTypeSingle ReferenceType = "single" ReferenceTypeArray ReferenceType = "array" ReferenceTypeNested ReferenceType = "nested" )
type RelationSchema ¶ added in v0.0.15
type RelationSchema struct {
Target string `json:"target"` // Target schema name
Type string `json:"type"` // "reference" for foreign key relationships
KeyProperty string `json:"key_property"` // child-side foreign key attribute
}
RelationSchema defines reference relationships between objects.
type SchemaAttributeCache ¶ added in v0.0.3
type SchemaAttributeCache map[string]AttributeMetadata
SchemaAttributeCache is a mapping of attr_name -> metadata. Strongly recommended to populate per schema_id at application startup.
type SchemaRegistry ¶ added in v0.0.3
type SchemaRegistry interface {
// GetSchemaAttributeCacheByName retrieves schema ID and attribute cache by schema name
GetSchemaAttributeCacheByName(name string) (int16, SchemaAttributeCache, error)
// GetSchemaAttributeCacheByID retrieves schema name and attribute cache by schema ID
GetSchemaAttributeCacheByID(id int16) (string, SchemaAttributeCache, error)
GetSchemaByName(name string) (int16, JSONSchema, error)
// GetSchemaAttributeCacheByID retrieves schema name and attribute cache by schema ID
GetSchemaByID(id int16) (string, JSONSchema, error)
ListSchemas() []string
}
SchemaRegistry provides schema lookup operations. Implementations can load schemas from files, databases, or other sources.
type TableNames ¶ added in v0.0.2
type TableNames struct {
SchemaRegistry string `json:"schemaRegistry"`
EntityMain string `json:"entityMain"`
EAVData string `json:"eavData"`
}
TableNames generates the table names for a specific client and project
type TransactionConfig ¶ added in v0.0.2
type TransactionConfig struct {
DefaultTimeout time.Duration `json:"defaultTimeout"`
MaxTimeout time.Duration `json:"maxTimeout"`
MaxRetryAttempts int `json:"maxRetryAttempts"`
RetryAttempts int `json:"retryAttempts"`
RetryDelay time.Duration `json:"retryDelay"`
IsolationLevel string `json:"isolationLevel"`
EnableDeadlockDetection bool `json:"enableDeadlockDetection"`
DeadlockCheckInterval time.Duration `json:"deadlockCheckInterval"`
DeadlockMaxWaitTime time.Duration `json:"deadlockMaxWaitTime"`
SlowTransactionThreshold time.Duration `json:"slowTransactionThreshold"`
MinSuccessRate float64 `json:"minSuccessRate"`
MaxAverageDuration time.Duration `json:"maxAverageDuration"`
MaxConnectionPoolUsage float64 `json:"maxConnectionPoolUsage"`
}
TransactionConfig contains transaction settings
type ValueType ¶ added in v0.0.3
type ValueType string
ValueType represents supported attribute value types.
const ( ValueTypeText ValueType = "text" ValueTypeSmallInt ValueType = "smallint" ValueTypeInteger ValueType = "integer" ValueTypeBigInt ValueType = "bigint" ValueTypeNumeric ValueType = "numeric" // double precision ValueTypeDate ValueType = "date" // for JSON attributes with format `date` ValueTypeDateTime ValueType = "datetime" // for JSON attributes with format `date-time` ValueTypeUUID ValueType = "uuid" ValueTypeBool ValueType = "bool" )