mirror of
https://github.com/MindWorkAI/AI-Studio.git
synced 2026-10-18 03:57:59 +00:00
Fixed secret retrieval for connection testing while adding an ERI data source (#325)
This commit is contained in:
1 parent
0125f48f61
commit
2429788ccc
10 files changed
+53
-40
No files matched your search
@@ -1,10 +1,14 @@
|
||||
using System.Text.Json;
|
||||
using System.Text.Json.Serialization;
|
||||
|
||||
using AIStudio.Settings;
|
||||
|
||||
namespace AIStudio.Tools.ERIClient;
|
||||
|
||||
public abstract class ERIClientBase(string baseAddress) : IDisposable
|
||||
public abstract class ERIClientBase(IERIDataSource dataSource) : IDisposable
|
||||
{
|
||||
protected readonly IERIDataSource dataSource = dataSource;
|
||||
|
||||
protected static readonly JsonSerializerOptions JSON_OPTIONS = new()
|
||||
{
|
||||
WriteIndented = true,
|
||||
@@ -21,7 +25,7 @@ public abstract class ERIClientBase(string baseAddress) : IDisposable
|
||||
|
||||
protected readonly HttpClient httpClient = new()
|
||||
{
|
||||
BaseAddress = new Uri(baseAddress),
|
||||
BaseAddress = new Uri($"{dataSource.Hostname}:{dataSource.Port}"),
|
||||
};
|
||||
|
||||
protected string securityToken = string.Empty;
|
||||
|
||||
Reference in new issue
Block a user