(control) Move message queue monitor to control
This commit is contained in:
parent
436a55ee1e
commit
84cdac83d6
@ -1,6 +1,8 @@
|
||||
package nu.marginalia.control.actor;
|
||||
|
||||
public enum ControlActor {
|
||||
|
||||
MONITOR_MESSAGE_QUEUE,
|
||||
REBALANCE;
|
||||
|
||||
public String id() {
|
||||
|
@ -7,6 +7,7 @@ import lombok.SneakyThrows;
|
||||
import nu.marginalia.actor.ActorStateMachine;
|
||||
import nu.marginalia.actor.prototype.ActorPrototype;
|
||||
import nu.marginalia.actor.state.ActorStateInstance;
|
||||
import nu.marginalia.control.actor.monitor.MessageQueueMonitorActor;
|
||||
import nu.marginalia.control.actor.rebalance.RebalanceActor;
|
||||
import nu.marginalia.model.gson.GsonFactory;
|
||||
import nu.marginalia.mq.MessageQueueFactory;
|
||||
@ -30,6 +31,7 @@ public class ControlActorService {
|
||||
@Inject
|
||||
public ControlActorService(MessageQueueFactory messageQueueFactory,
|
||||
BaseServiceParams baseServiceParams,
|
||||
MessageQueueMonitorActor messageQueueMonitor,
|
||||
RebalanceActor rebalanceActor
|
||||
) {
|
||||
this.messageQueueFactory = messageQueueFactory;
|
||||
@ -37,6 +39,8 @@ public class ControlActorService {
|
||||
this.gson = GsonFactory.get();
|
||||
this.node = baseServiceParams.configuration.node();
|
||||
|
||||
|
||||
register(ControlActor.MONITOR_MESSAGE_QUEUE, messageQueueMonitor);
|
||||
// register(ControlActor.REBALANCE, rebalanceActor);
|
||||
}
|
||||
|
||||
|
@ -1,4 +1,4 @@
|
||||
package nu.marginalia.actor.monitor;
|
||||
package nu.marginalia.control.actor.monitor;
|
||||
|
||||
import com.google.gson.Gson;
|
||||
import com.google.inject.Inject;
|
||||
@ -47,7 +47,4 @@ public class MessageQueueMonitorActor extends RecordActorPrototype {
|
||||
return "Periodically run maintenance tasks on the message queue";
|
||||
}
|
||||
|
||||
|
||||
|
||||
|
||||
}
|
@ -7,7 +7,6 @@ public enum ExecutorActor {
|
||||
PROC_CONVERTER_SPAWNER,
|
||||
PROC_LOADER_SPAWNER,
|
||||
PROC_CRAWLER_SPAWNER,
|
||||
MONITOR_MESSAGE_QUEUE,
|
||||
MONITOR_PROCESS_LIVENESS,
|
||||
MONITOR_FILE_STORAGE,
|
||||
ADJACENCY_CALCULATION,
|
||||
|
@ -41,7 +41,6 @@ public class ExecutorActorControlService {
|
||||
ConverterMonitorActor converterMonitorFSM,
|
||||
CrawlerMonitorActor crawlerMonitorActor,
|
||||
LoaderMonitorActor loaderMonitor,
|
||||
MessageQueueMonitorActor messageQueueMonitor,
|
||||
ProcessLivenessMonitorActor processMonitorFSM,
|
||||
FileStorageMonitorActor fileStorageMonitorActor,
|
||||
IndexConstructorMonitorActor indexConstructorMonitorActor,
|
||||
@ -65,7 +64,6 @@ public class ExecutorActorControlService {
|
||||
register(ExecutorActor.PROC_LOADER_SPAWNER, loaderMonitor);
|
||||
register(ExecutorActor.PROC_CRAWLER_SPAWNER, crawlerMonitorActor);
|
||||
|
||||
register(ExecutorActor.MONITOR_MESSAGE_QUEUE, messageQueueMonitor);
|
||||
register(ExecutorActor.MONITOR_PROCESS_LIVENESS, processMonitorFSM);
|
||||
register(ExecutorActor.MONITOR_FILE_STORAGE, fileStorageMonitorActor);
|
||||
|
||||
|
@ -86,7 +86,6 @@ public class ExecutorSvc extends Service {
|
||||
logger.info("Initializing default actors");
|
||||
actorControlService.start(ExecutorActor.MONITOR_PROCESS_LIVENESS);
|
||||
actorControlService.start(ExecutorActor.MONITOR_FILE_STORAGE);
|
||||
actorControlService.start(ExecutorActor.MONITOR_MESSAGE_QUEUE);
|
||||
actorControlService.start(ExecutorActor.PROC_CONVERTER_SPAWNER);
|
||||
actorControlService.start(ExecutorActor.PROC_CRAWLER_SPAWNER);
|
||||
actorControlService.start(ExecutorActor.PROC_INDEX_CONSTRUCTOR_SPAWNER);
|
||||
|
Loading…
Reference in New Issue
Block a user