Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Push to production #467

Merged
merged 2 commits into from
Jan 27, 2024
Merged
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
9 changes: 5 additions & 4 deletions TaskEngine/Tasks/QueueAwakerTask.cs
Original file line number Diff line number Diff line change
@@ -28,7 +28,7 @@ class QueueAwakerTask : RabbitMQTask<JObject>
private readonly SceneDetectionTask _sceneDetectionTask;
private readonly PythonCrawlerTask _pythonCrawlerTask;
private readonly CreateBoxTokenTask _createBoxTokenTask;
private readonly UpdateBoxTokenTask _updateBoxTokenTask;
// private readonly UpdateBoxTokenTask _updateBoxTokenTask;
private readonly BuildElasticIndexTask _buildElasticIndexTask;
private readonly CleanUpElasticIndexTask _cleanUpElasticIndexTask;
// private readonly ExampleTask _exampleTask;
@@ -42,7 +42,8 @@ public QueueAwakerTask(RabbitMQConnection rabbitMQ, DownloadPlaylistInfoTask dow
TranscriptionTask transcriptionTask, ProcessVideoTask processVideoTask,
// GenerateVTTFileTask generateVTTFileTask,
SceneDetectionTask sceneDetectionTask,
CreateBoxTokenTask createBoxTokenTask, UpdateBoxTokenTask updateBoxTokenTask, PythonCrawlerTask pythonCrawlerTask,
CreateBoxTokenTask createBoxTokenTask,// UpdateBoxTokenTask updateBoxTokenTask,
PythonCrawlerTask pythonCrawlerTask,
BuildElasticIndexTask buildElasticIndexTask, CleanUpElasticIndexTask cleanUpElasticIndexTask,

DescribeVideoTask describeVideoTask,// DescribeImageTask describeImageTask,ExampleTask exampleTask,
@@ -58,7 +59,7 @@ public QueueAwakerTask(RabbitMQConnection rabbitMQ, DownloadPlaylistInfoTask dow
_sceneDetectionTask = sceneDetectionTask;
_pythonCrawlerTask = pythonCrawlerTask;
_createBoxTokenTask = createBoxTokenTask;
_updateBoxTokenTask = updateBoxTokenTask;
// _updateBoxTokenTask = updateBoxTokenTask;
_buildElasticIndexTask = buildElasticIndexTask;
_cleanUpElasticIndexTask = cleanUpElasticIndexTask;
_describeVideoTask = describeVideoTask;
@@ -145,7 +146,7 @@ private async Task PendingJobs()


// Update Box Token every few hours
_updateBoxTokenTask.Publish("");
// _updateBoxTokenTask.Publish("");

//We will use these outside of the DB scope
// List<String> todoVTTs ;
2 changes: 2 additions & 0 deletions TaskEngine/Tasks/UpdateBoxTokenTask.cs
Original file line number Diff line number Diff line change
@@ -8,6 +8,8 @@
// https://learn.microsoft.com/en-us/dotnet/fundamentals/code-analysis/quality-rules/ca2007
// We are okay awaiting on a task in the same thread


// !!! May be removed in the future
namespace TaskEngine.Tasks
{
[SuppressMessage("Microsoft.Performance", "CA1812:MarkMembersAsStatic")] // This class is never directly instantiated
6 changes: 3 additions & 3 deletions TaskEngine/TempCode.cs
Original file line number Diff line number Diff line change
@@ -19,7 +19,7 @@ class TempCode

private readonly CTDbContext context;
private readonly CreateBoxTokenTask _createBoxTokenTask;
private readonly UpdateBoxTokenTask _updateBoxTokenTask;
// private readonly UpdateBoxTokenTask _updateBoxTokenTask;
private readonly SceneDetectionTask _sceneDetectionTask;
private readonly PythonCrawlerTask _pythonCrawlerTask;
private readonly ProcessVideoTask _processVideoTask;
@@ -32,7 +32,7 @@ class TempCode
private readonly QueueAwakerTask _queueAwakerTask;
private readonly CleanUpElasticIndexTask _cleanUpElasticIndexTask;

public TempCode(CTDbContext c, CreateBoxTokenTask createBoxTokenTask, UpdateBoxTokenTask updateBoxTokenTask,
public TempCode(CTDbContext c, CreateBoxTokenTask createBoxTokenTask, //UpdateBoxTokenTask updateBoxTokenTask,
SceneDetectionTask ePubGeneratorTask, ProcessVideoTask processVideoTask,
TranscriptionTask transcriptionTask, ConvertVideoToWavTask convertVideoToWavTask, DownloadMediaTask downloadMediaTask,
DownloadPlaylistInfoTask downloadPlaylistInfoTask, QueueAwakerTask queueAwakerTask,
@@ -41,7 +41,7 @@ public TempCode(CTDbContext c, CreateBoxTokenTask createBoxTokenTask, UpdateBoxT
{
context = c;
_createBoxTokenTask = createBoxTokenTask;
_updateBoxTokenTask = updateBoxTokenTask;
// _updateBoxTokenTask = updateBoxTokenTask;
_sceneDetectionTask = ePubGeneratorTask;
_processVideoTask = processVideoTask;
// _generateVTTFileTask = generateVTTFileTask;
Loading