mirror of
https://github.com/Abdulazizzn/n8n-enterprise-unlocked.git
synced 2025-12-17 01:56:46 +00:00
refactor(core): Refactor WorkflowStatistics code (no-changelog) (#6617)
refactor(core): Refactor WorkflowStatistics code
This commit is contained in:
committed by
GitHub
parent
e7091d6726
commit
f4a18ba87d
@@ -97,10 +97,10 @@ import {
|
||||
TagsController,
|
||||
TranslationController,
|
||||
UsersController,
|
||||
WorkflowStatisticsController,
|
||||
} from '@/controllers';
|
||||
|
||||
import { executionsController } from '@/executions/executions.controller';
|
||||
import { workflowStatsController } from '@/api/workflowStats.api';
|
||||
import { isApiEnabled, loadPublicApiVersions } from '@/PublicApi';
|
||||
import {
|
||||
getInstanceBaseUrl,
|
||||
@@ -136,7 +136,6 @@ import { isLogStreamingEnabled } from '@/eventbus/MessageEventBus/MessageEventBu
|
||||
import { licenseController } from './license/license.controller';
|
||||
import { Push, setupPushServer, setupPushHandler } from '@/push';
|
||||
import { setupAuthMiddlewares } from './middlewares';
|
||||
import { initEvents } from './events';
|
||||
import {
|
||||
getLdapLoginLabel,
|
||||
handleLdapInit,
|
||||
@@ -383,9 +382,6 @@ export class Server extends AbstractServer {
|
||||
saml_enabled: isSamlCurrentAuthenticationMethod(),
|
||||
};
|
||||
|
||||
// Set up event handling
|
||||
initEvents();
|
||||
|
||||
if (inDevelopment && process.env.N8N_DEV_RELOAD === 'true') {
|
||||
const { reloadNodesAndCredentials } = await import('@/ReloadNodesAndCredentials');
|
||||
await reloadNodesAndCredentials(this.loadNodesAndCredentials, this.nodeTypes, this.push);
|
||||
@@ -496,6 +492,7 @@ export class Server extends AbstractServer {
|
||||
}),
|
||||
Container.get(SamlController),
|
||||
Container.get(SourceControlController),
|
||||
Container.get(WorkflowStatisticsController),
|
||||
];
|
||||
|
||||
if (isLdapEnabled()) {
|
||||
@@ -604,11 +601,6 @@ export class Server extends AbstractServer {
|
||||
// ----------------------------------------
|
||||
this.app.use(`/${this.restEndpoint}/license`, licenseController);
|
||||
|
||||
// ----------------------------------------
|
||||
// Workflow Statistics
|
||||
// ----------------------------------------
|
||||
this.app.use(`/${this.restEndpoint}/workflow-stats`, workflowStatsController);
|
||||
|
||||
// ----------------------------------------
|
||||
// SAML
|
||||
// ----------------------------------------
|
||||
|
||||
Reference in New Issue
Block a user