4.7 KiB
source_files, generated_at, model, schema_version, sha256
| source_files | generated_at | model | schema_version | sha256 | ||
|---|---|---|---|---|---|---|
|
2026-04-16T02:11:21.572661+00:00 | Qwen/Qwen3-Coder-Next-FP8 | 1 | 192083dd898290ec |
Properties
Documentation: DTS.Common.DBSyncService
1. Purpose
This module is a .NET assembly (DTS.Common.DBSyncService) that provides shared configuration and metadata for a database synchronization service. It does not contain business logic or synchronization implementations itself, but rather defines assembly-level attributes (e.g., version, title, COM visibility) and exposes strongly-typed application settings (e.g., Monitoring, Interval, ServiceName, Service) via a generated settings class. Its role is to centralize and standardize configuration and assembly identity for the DB Sync Service across deployment and runtime.
2. Public Interface
DTS.Common.DBSyncService.Properties.Settings
A sealed, auto-generated class derived from System.Configuration.ApplicationSettingsBase. Provides read-only access to application-scoped configuration values. Accessed via the static property Settings.Default.
-
public static Settings Default { get; }
Returns the singleton instance ofSettings. Thread-safe due toSynchronized()wrapping. -
public bool Monitoring { get; }
Returns the value of theMonitoringsetting. Default:false. Application-scoped; cannot be changed at runtime. -
public int Interval { get; }
Returns the value of theIntervalsetting (in milliseconds). Default:60000(i.e., 60 seconds). Application-scoped. -
public string ServiceName { get; }
Returns the value of theServiceNamesetting. Default:"DTS DB Sync Service". Application-scoped. -
public string Service { get; }
Returns the value of theServicesetting. Default:"DB Sync Service". Application-scoped.
Note
: All properties are read-only (
getonly), and values are determined at compile-time via[DefaultSettingValueAttribute]. No setters or runtime modification is supported.
3. Invariants
- The
Settingsclass is application-scoped and immutable at runtime (noUserScopedsettings present). - All settings values are validated only at design time (via
Settings.Designer.csgeneration); no runtime validation occurs. - The assembly is not COM-visible (
ComVisible(false)), and the GUID5f8e95eb-e89c-4fdc-9bde-3e78dd56ad6fis reserved for typelib identification if exposed to COM. - Assembly version is fixed at
1.0.0.0(bothAssemblyVersionandAssemblyFileVersion). - Thread-safety of
Settings.Defaultis ensured viaApplicationSettingsBase.Synchronized().
4. Dependencies
Dependencies of this module:
System.Configuration(forApplicationSettingsBase,ApplicationScopedSettingAttribute, etc.)System.Runtime.CompilerServices,System.Runtime.InteropServices,System.CodeDom.Compiler,System.Diagnostics(for attributes and COM interop)System(implicit base forAssemblyInfoandSettingstypes)
Dependencies on this module:
- Any service or library referencing
DTS.Common.DBSyncServicecan accessProperties.Settings.Defaultto retrieve configuration. - The assembly is likely referenced by the main DB Sync Service executable or related components (e.g., Windows Service host), though this is inferred from naming and not explicit in the provided files.
5. Gotchas
- No runtime configuration: Settings are compile-time constants; changing them requires rebuilding the assembly or modifying the
.configfile if the settings were user-scoped (but they are not — they are application-scoped and read fromapp.configonly at startup, with no override capability). - Hardcoded defaults: The
Intervalvalue (60000) is in milliseconds but not documented as such in code; callers must infer the unit. - Redundant naming: Two settings (
ServiceNameandService) both appear to represent the service name, with identical default values ("DTS DB Sync Service"vs"DB Sync Service"). This may indicate legacy duplication or ambiguity in usage context. - Auto-generated code:
Settings.Designer.csis explicitly marked as auto-generated; manual edits will be overwritten. - Version lock:
AssemblyVersion("1.0.0.0")with no*wildcard disables automatic build/revision incrementing, which may complicate deployment tracking. - No public API surface beyond
Settings: This module provides no executable logic—only configuration metadata—so callers must not expect any other public types or methods.
None identified from source alone beyond the above.