feat(datasync): add GIW connection type to DbQuerySource

Add support for "giw" connection type in DbQuerySource to enable
the StatusCode pipeline to query from the GIW Oracle database.
This commit is contained in:
Joseph Doherty
2026-01-07 00:58:56 -05:00
parent c59a3160d0
commit 4b3c900d52
2 changed files with 14 additions and 2 deletions
@@ -12,7 +12,7 @@ public class DbQuerySource : IImportSource
{
private static readonly HashSet<string> ValidConnectionTypes = new(StringComparer.OrdinalIgnoreCase)
{
"jde", "cms", "lotfinder"
"jde", "cms", "lotfinder", "giw"
};
private readonly IDbConnectionFactory _connectionFactory;
@@ -48,7 +48,7 @@ public class DbQuerySource : IImportSource
if (!ValidConnectionTypes.Contains(connectionType))
{
throw new ArgumentException($"Unknown connection type: {connectionType}. Valid types are: jde, cms, lotfinder.", nameof(connectionType));
throw new ArgumentException($"Unknown connection type: {connectionType}. Valid types are: jde, cms, lotfinder, giw.", nameof(connectionType));
}
_connectionFactory = connectionFactory;
@@ -77,6 +77,7 @@ public class DbQuerySource : IImportSource
{
"jde" => await _connectionFactory.CreateJdeConnectionAsync(cancellationToken),
"cms" => await _connectionFactory.CreateCmsConnectionAsync(cancellationToken),
"giw" => await _connectionFactory.CreateGiwConnectionAsync(cancellationToken),
"lotfinder" => await _connectionFactory.CreateLotFinderConnectionAsync(cancellationToken),
_ => throw new InvalidOperationException($"Unknown connection type: {_connectionType}")
};