namespace SwDAL.Enums; /// What kind of operation an LSWPROVISIONINGLOG row records. public enum ProvisioningLogType : byte { DdlExecution = 0 } /// DDL script lifecycle: Draft → Reviewed → Approved → Deployed public enum DdlScriptStatus : byte { Draft = 0, Reviewed = 1, Approved = 2, Deployed = 3 } /// Metadata version lifecycle public enum MetaVersionStatus : byte { Draft = 0, Testing = 1, Released = 2, Deprecated = 3 } /// Client database provisioning status public enum ClientDbStatus : byte { Pending = 0, Active = 1, Suspended = 2, Decommissioned = 3, Failed = 4 } /// Upgrade package lifecycle public enum PkgStatus : byte { Draft = 0, Testing = 1, Released = 2, Deprecated = 3 } /// Which dimension an UpgradePackage's SCOPEVALUE is matched against during /// provisioning-chain resolution (039_ALTER_MSWUPGRADEPACKAGE_PackageChain.sql). A /// Universal package applies to every client on its DbModel; the others are overlay /// packages that only apply when the provisioning caller's own scope value matches. /// Whole-package scoping (not per-script) — a confirmed design decision. public enum PackageScopeType : byte { Universal = 0, PartnerProduct = 1, Industry = 2, Country = 3, Client = 4 } // How widely rolled out a package version is, independent of ScopeType/ScopeValue (which // clients are eligible at all). Mirrors Entitlement's MENTITLEMENTFEATUREFLAG.RolloutType // numbering (0=Global 1=Beta 2=SelClients 3=SelUsers 4=Percentage) so the two mechanisms read // the same way — SelUsers is intentionally absent: packages provision per-client, not per-user. // Only Global and Percentage are enforced by GetProvisioningChain today (tracker §36.5) — // UpgradePackageBLL.Save() rejects Beta/SelClients rather than silently ignoring them, since no // per-client rollout-membership table exists yet for either. public enum PackageRolloutType : byte { Global = 0, Beta = 1, SelClients = 2, Percentage = 4 } // Entitlement-aware provisioning/rollout gating (tracker §40). Schema packages are ALWAYS // delivered in full to every eligible client — the user's own confirmed, settled decision — and // never feature-gated. MetadataOrStandardData packages are subject to Gate B (feature/module // licensing): a non-null MSWUPGRADEPACKAGE.REQUIREDFEATURECODE is checked against the target // client's enabled Plan features before the package is queued for that client. public enum PackageContentType : byte { Schema = 0, MetadataOrStandardData = 1 } /// Script branch type public enum BranchType : byte { Main = 0, Develop = 1, Feature = 2, Release = 3, Hotfix = 4 } /// Script branch status public enum BranchStatus : byte { Active = 0, Merged = 1, Abandoned = 2 } /// DDL execution result status (used in LSWDDLEXECUTION) public enum DdlExecStatus : byte { Success = 0, Failed = 1, RolledBack = 2 } /// Target database type public enum DbType : byte { SqlServer = 0, PostgreSQL = 1, MySQL = 2, Oracle = 3 } /// Metadata sync behavior for a table in a sync group public enum SyncBehavior : byte { InsertOnly = 0, Upsert = 1, DeleteInsert = 2 } /// Change Request lifecycle: Draft → Submitted → UnderReview → Approved → Executed public enum ChangeRequestStatus : byte { Draft = 0, Submitted = 1, UnderReview = 2, Approved = 3, Rejected = 4, Executed = 5 } /// Type of SQL contained in or linked to a Change Request public enum ChangeRequestQueryType : byte { Select = 0, Insert = 1, Update = 2, Delete = 3, DDL = 4, Other = 5 } /// Business category of a Change Request public enum ChangeRequestCategory : byte { SchemaChange = 0, DataMigration = 1, Performance = 2, Security = 3, Feature = 4, BugFix = 5, ClientProvisioning = 6 } /// Which physical database a MSWCLIENTDATABASE row represents for a given client. /// A client has exactly one Main row, at most one Report row, and zero-or-more Archive rows /// (one per retention period, mirroring the legacy DataArchiveProcessBLL precedent of a fresh /// physical database per archive period rather than one shared archive DB). public enum DatabaseRole : byte { Main = 0, Report = 1, Archive = 2 } /// How ChangeRequestBLL.Execute() should create the physical database for a /// ClientProvisioning-category Change Request. public enum ProvisioningMode : byte { FromSnapshot = 1, FromScripts = 2 } /// The three contained-database-user roles created for every client database at /// provisioning time. See ClientDatabaseProvisioner — contained users are scoped entirely /// inside their own database, so a credential for one client's database cannot even attempt /// to authenticate against a different client's database. public enum ClientDbLoginRole : byte { Dba = 0, App = 1, ReadOnly = 2 } /// Event types recorded in LSWCHANGEREQUESTTIMELINE public enum CrTimelineEventType : byte { Created = 0, Submitted = 1, ReviewStarted = 2, Approved = 3, Rejected = 4, Returned = 5, Executed = 6, Comment = 7, Queued = 8 } /// Background-execution state of a Change Request (MSWCHANGEREQUEST.EXECUTIONSTATUS, /// tracker §37). Independent of CrStatus — a CR only ever reaches Executed once its /// ExecutionStatus (if it went through the queued path at all) is Done. NotQueued is the default /// for every ordinary synchronous Execute() call; the other four values are only ever set by /// QueueExecutionAsync/ProcessQueuedExecutionsAsync. public enum ChangeRequestExecutionStatus : byte { NotQueued = 0, Queued = 1, Running = 2, Done = 3, Failed = 4 }