mirror of
https://github.com/MindWorkAI/AI-Studio.git
synced 2026-10-04 16:09:40 +00:00
moved datasource indexing to lower level
This commit is contained in:
1 parent
b4e916e166
commit
202e37410b
6 files changed
+14
-11
No files matched your search
@@ -15,7 +15,7 @@ public sealed partial class DataSourceEmbeddingService
|
||||
|
||||
private void RefreshWatchers()
|
||||
{
|
||||
if (!settingsManager.ConfigurationData.DataSourceIndexing.AutomaticRefresh)
|
||||
if (!settingsManager.ConfigurationData.App.DataSourceIndexing.AutomaticRefresh)
|
||||
{
|
||||
this.RemoveAllWatchers();
|
||||
return;
|
||||
@@ -41,7 +41,7 @@ public sealed partial class DataSourceEmbeddingService
|
||||
|
||||
private void EnsureWatcher(IDataSource dataSource)
|
||||
{
|
||||
if (!settingsManager.ConfigurationData.DataSourceIndexing.AutomaticRefresh)
|
||||
if (!settingsManager.ConfigurationData.App.DataSourceIndexing.AutomaticRefresh)
|
||||
return;
|
||||
|
||||
var configuration = GetWatchConfiguration(dataSource);
|
||||
@@ -143,7 +143,7 @@ public sealed partial class DataSourceEmbeddingService
|
||||
|
||||
private void ScheduleWatchedDataSourceRefresh(string dataSourceId)
|
||||
{
|
||||
if (!settingsManager.ConfigurationData.DataSourceIndexing.AutomaticRefresh)
|
||||
if (!settingsManager.ConfigurationData.App.DataSourceIndexing.AutomaticRefresh)
|
||||
return;
|
||||
|
||||
var debounceToken = new CancellationTokenSource();
|
||||
|
||||
@@ -136,7 +136,7 @@ public sealed partial class DataSourceEmbeddingService(SettingsManager settingsM
|
||||
|
||||
public Task QueueAllInternalDataSourcesIfAutomaticRefreshAsync()
|
||||
{
|
||||
if (!settingsManager.ConfigurationData.DataSourceIndexing.AutomaticRefresh)
|
||||
if (!settingsManager.ConfigurationData.App.DataSourceIndexing.AutomaticRefresh)
|
||||
{
|
||||
this.RefreshWatchers();
|
||||
return Task.CompletedTask;
|
||||
@@ -148,7 +148,7 @@ public sealed partial class DataSourceEmbeddingService(SettingsManager settingsM
|
||||
|
||||
public void RefreshAutomaticWatchers()
|
||||
{
|
||||
if (!settingsManager.ConfigurationData.DataSourceIndexing.AutomaticRefresh)
|
||||
if (!settingsManager.ConfigurationData.App.DataSourceIndexing.AutomaticRefresh)
|
||||
{
|
||||
Volatile.Write(ref this.startupHashCheckCompleted, 0);
|
||||
Interlocked.Exchange(ref this.startupHashCheckStarted, 0);
|
||||
@@ -959,7 +959,7 @@ public sealed partial class DataSourceEmbeddingService(SettingsManager settingsM
|
||||
|
||||
private async Task RunInitialDataSourceHashCheckAsync(CancellationToken token)
|
||||
{
|
||||
if (!settingsManager.ConfigurationData.DataSourceIndexing.AutomaticRefresh)
|
||||
if (!settingsManager.ConfigurationData.App.DataSourceIndexing.AutomaticRefresh)
|
||||
{
|
||||
logger.LogInformation("Automatic local data source refresh is disabled. Startup hash checks and file watchers are disabled.");
|
||||
this.RemoveAllWatchers();
|
||||
@@ -997,7 +997,7 @@ public sealed partial class DataSourceEmbeddingService(SettingsManager settingsM
|
||||
}
|
||||
}
|
||||
|
||||
if (!settingsManager.ConfigurationData.DataSourceIndexing.AutomaticRefresh)
|
||||
if (!settingsManager.ConfigurationData.App.DataSourceIndexing.AutomaticRefresh)
|
||||
{
|
||||
Volatile.Write(ref this.startupHashCheckCompleted, 0);
|
||||
Interlocked.Exchange(ref this.startupHashCheckStarted, 0);
|
||||
|
||||
Reference in new issue
Block a user