{-# OPTIONS_GHC -fno-warn-orphans #-} module Hasura.Backends.MySQL.Instances.Metadata () where import Hasura.Backends.MySQL.Connection qualified as MySQL import Hasura.Prelude import Hasura.RQL.Types.EventTrigger (RecreateEventTriggers (RETDoNothing)) import Hasura.RQL.Types.Metadata.Backend import Hasura.SQL.Backend instance BackendMetadata 'MySQL where prepareCatalog :: SourceConfig 'MySQL -> ExceptT QErr m RecreateEventTriggers prepareCatalog SourceConfig 'MySQL _ = RecreateEventTriggers -> ExceptT QErr m RecreateEventTriggers forall (f :: * -> *) a. Applicative f => a -> f a pure RecreateEventTriggers RETDoNothing buildComputedFieldInfo :: HashSet (TableName 'MySQL) -> TableName 'MySQL -> HashSet (Column 'MySQL) -> ComputedFieldName -> ComputedFieldDefinition 'MySQL -> RawFunctionInfo 'MySQL -> Comment -> m (ComputedFieldInfo 'MySQL) buildComputedFieldInfo = [Char] -> HashSet TableName -> TableName -> HashSet Column -> ComputedFieldName -> Void -> Void -> Comment -> m (ComputedFieldInfo 'MySQL) forall a. HasCallStack => [Char] -> a error [Char] "buildComputedFieldInfo: MySQL backend does not support this operation yet." fetchAndValidateEnumValues :: SourceConfig 'MySQL -> TableName 'MySQL -> Maybe (PrimaryKey 'MySQL (RawColumnInfo 'MySQL)) -> [RawColumnInfo 'MySQL] -> m (Either QErr EnumValues) fetchAndValidateEnumValues = [Char] -> SourceConfig -> TableName -> Maybe (PrimaryKey 'MySQL (RawColumnInfo 'MySQL)) -> [RawColumnInfo 'MySQL] -> m (Either QErr EnumValues) forall a. HasCallStack => [Char] -> a error [Char] "fetchAndValidateEnumValues: MySQL backend does not support this operation yet." resolveSourceConfig :: Logger Hasura -> SourceName -> SourceConnConfiguration 'MySQL -> BackendSourceKind 'MySQL -> BackendConfig 'MySQL -> Environment -> Manager -> m (Either QErr (SourceConfig 'MySQL)) resolveSourceConfig = Logger Hasura -> SourceName -> SourceConnConfiguration 'MySQL -> BackendSourceKind 'MySQL -> BackendConfig 'MySQL -> Environment -> Manager -> m (Either QErr (SourceConfig 'MySQL)) forall (m :: * -> *) environment manager. MonadIO m => Logger Hasura -> SourceName -> ConnSourceConfig -> BackendSourceKind 'MySQL -> BackendConfig 'MySQL -> environment -> manager -> m (Either QErr SourceConfig) MySQL.resolveSourceConfig resolveDatabaseMetadata :: SourceMetadata 'MySQL -> SourceConfig 'MySQL -> SourceTypeCustomization -> m (Either QErr (ResolvedSource 'MySQL)) resolveDatabaseMetadata SourceMetadata 'MySQL _ = SourceConfig 'MySQL -> SourceTypeCustomization -> m (Either QErr (ResolvedSource 'MySQL)) forall (m :: * -> *). MonadIO m => SourceConfig -> SourceTypeCustomization -> m (Either QErr (ResolvedSource 'MySQL)) MySQL.resolveDatabaseMetadata parseBoolExpOperations :: ValueParser 'MySQL m v -> TableName 'MySQL -> FieldInfoMap (FieldInfo 'MySQL) -> ColumnReference 'MySQL -> Value -> m [OpExpG 'MySQL v] parseBoolExpOperations = [Char] -> ValueParser 'MySQL m v -> TableName -> FieldInfoMap (FieldInfo 'MySQL) -> ColumnReference 'MySQL -> Value -> m [OpExpG 'MySQL v] forall a. HasCallStack => [Char] -> a error [Char] "parseBoolExpOperations: MySQL backend does not support this operation yet." buildFunctionInfo :: SourceName -> FunctionName 'MySQL -> SystemDefined -> FunctionConfig -> FunctionPermissionsMap -> RawFunctionInfo 'MySQL -> Maybe Text -> NamingCase -> m (FunctionInfo 'MySQL, SchemaDependency) buildFunctionInfo = [Char] -> SourceName -> FunctionName -> SystemDefined -> FunctionConfig -> FunctionPermissionsMap -> Void -> Maybe Text -> NamingCase -> m (FunctionInfo 'MySQL, SchemaDependency) forall a. HasCallStack => [Char] -> a error [Char] "buildFunctionInfo: MySQL backend does not support this operation yet." updateColumnInEventTrigger :: TableName 'MySQL -> Column 'MySQL -> Column 'MySQL -> TableName 'MySQL -> EventTriggerConf 'MySQL -> EventTriggerConf 'MySQL updateColumnInEventTrigger = [Char] -> TableName -> Column -> Column -> TableName -> EventTriggerConf 'MySQL -> EventTriggerConf 'MySQL forall a. HasCallStack => [Char] -> a error [Char] "updateColumnInEventTrigger: MySQL backend does not support this operation yet." parseCollectableType :: CollectableType (ColumnType 'MySQL) -> Value -> m (PartialSQLExp 'MySQL) parseCollectableType = [Char] -> CollectableType (ColumnType 'MySQL) -> Value -> m (PartialSQLExp 'MySQL) forall a. HasCallStack => [Char] -> a error [Char] "parseCollectableType: MySQL backend does not support this operation yet." postDropSourceHook :: SourceConfig 'MySQL -> TableEventTriggers 'MySQL -> m () postDropSourceHook = SourceConfig 'MySQL -> TableEventTriggers 'MySQL -> m () forall (m :: * -> *). MonadIO m => SourceConfig -> TableEventTriggers 'MySQL -> m () MySQL.postDropSourceHook buildComputedFieldBooleanExp :: BoolExpResolver 'MySQL m v -> BoolExpRHSParser 'MySQL m v -> TableName 'MySQL -> FieldInfoMap (FieldInfo 'MySQL) -> ComputedFieldInfo 'MySQL -> Value -> m (AnnComputedFieldBoolExp 'MySQL v) buildComputedFieldBooleanExp BoolExpResolver 'MySQL m v _ BoolExpRHSParser 'MySQL m v _ TableName 'MySQL _ FieldInfoMap (FieldInfo 'MySQL) _ ComputedFieldInfo 'MySQL _ Value _ = [Char] -> m (AnnComputedFieldBoolExp 'MySQL v) forall a. HasCallStack => [Char] -> a error [Char] "buildComputedFieldBooleanExp: MySQL backend does not support this operation yet."