diff --git a/flink-runtime-web/web-dashboard/.eslintignore b/flink-runtime-web/web-dashboard/.eslintignore index 8a6dedf35589c..aa93ecd4c6834 100644 --- a/flink-runtime-web/web-dashboard/.eslintignore +++ b/flink-runtime-web/web-dashboard/.eslintignore @@ -1,11 +1,11 @@ .idea gen web -tsc-out -dist +/tsc-out +/dist # Logs -logs +/logs *.log npm-debug.log* diff --git a/flink-runtime-web/web-dashboard/src/app/pages/job-manager/logs/job-manager-logs.component.ts b/flink-runtime-web/web-dashboard/src/app/pages/job-manager/logs/job-manager-logs.component.ts index 9593722885250..000f7faf043b3 100644 --- a/flink-runtime-web/web-dashboard/src/app/pages/job-manager/logs/job-manager-logs.component.ts +++ b/flink-runtime-web/web-dashboard/src/app/pages/job-manager/logs/job-manager-logs.component.ts @@ -17,29 +17,27 @@ */ import { ChangeDetectorRef, Component, OnInit, ChangeDetectionStrategy, OnDestroy, Inject } from '@angular/core'; -import { ConfigService, JobManagerService } from '@flink-runtime-web/services'; -import { EditorOptions } from 'ng-zorro-antd/code-editor'; +import { FormsModule } from '@angular/forms'; +import { of, Subject } from 'rxjs'; +import { catchError, takeUntil } from 'rxjs/operators'; + +import { AddonCompactComponent } from '@flink-runtime-web/components/addon-compact/addon-compact.component'; +import { AutoResizeDirective } from '@flink-runtime-web/components/editor/auto-resize.directive'; import { flinkEditorOptions } from '@flink-runtime-web/components/editor/editor-config'; -import {of, Subject} from 'rxjs'; -import {catchError, takeUntil} from 'rxjs/operators'; import { JOB_MANAGER_MODULE_CONFIG, JOB_MANAGER_MODULE_DEFAULT_CONFIG, JobManagerModuleConfig } from '@flink-runtime-web/pages/job-manager/job-manager.config'; -import {NzCodeEditorModule} from "ng-zorro-antd/code-editor"; -import {AutoResizeDirective} from "@flink-runtime-web/components/editor/auto-resize.directive"; -import {FormsModule} from "@angular/forms"; -import { - AddonCompactComponent -} from "@flink-runtime-web/components/addon-compact/addon-compact.component"; +import { ConfigService, JobManagerService } from '@flink-runtime-web/services'; +import { EditorOptions, NzCodeEditorModule } from 'ng-zorro-antd/code-editor'; @Component({ - selector: 'flink-job-manager-logs', - templateUrl: './job-manager-logs.component.html', - styleUrls: ['./job-manager-logs.component.less'], - changeDetection: ChangeDetectionStrategy.OnPush, - imports: [NzCodeEditorModule, AutoResizeDirective, FormsModule, AddonCompactComponent] + selector: 'flink-job-manager-logs', + templateUrl: './job-manager-logs.component.html', + styleUrls: ['./job-manager-logs.component.less'], + changeDetection: ChangeDetectionStrategy.OnPush, + imports: [NzCodeEditorModule, AutoResizeDirective, FormsModule, AddonCompactComponent] }) export class JobManagerLogsComponent implements OnInit, OnDestroy { public readonly downloadName = `jobmanager_log`; @@ -60,7 +58,7 @@ export class JobManagerLogsComponent implements OnInit, OnDestroy { this.downloadUrl = `${this.configService.BASE_URL}/jobmanager/log`; } - public ngOnInit() { + public ngOnInit(): void { this.reload(); } @@ -69,7 +67,7 @@ export class JobManagerLogsComponent implements OnInit, OnDestroy { this.destroy$.complete(); } - public reload() { + public reload(): void { this.loading = true; this.cdr.markForCheck(); this.jobManagerService diff --git a/flink-runtime-web/web-dashboard/src/app/pages/task-manager/logs/task-manager-logs.component.ts b/flink-runtime-web/web-dashboard/src/app/pages/task-manager/logs/task-manager-logs.component.ts index d2ca9a7468912..b8cff88bd8d95 100644 --- a/flink-runtime-web/web-dashboard/src/app/pages/task-manager/logs/task-manager-logs.component.ts +++ b/flink-runtime-web/web-dashboard/src/app/pages/task-manager/logs/task-manager-logs.component.ts @@ -17,29 +17,27 @@ */ import { ChangeDetectorRef, Component, OnInit, ChangeDetectionStrategy, OnDestroy, Inject } from '@angular/core'; -import {catchError, takeUntil} from 'rxjs/operators'; -import { ConfigService, TaskManagerService } from '@flink-runtime-web/services'; -import { EditorOptions } from 'ng-zorro-antd/code-editor'; -import {of, Subject} from 'rxjs'; +import { FormsModule } from '@angular/forms'; import { ActivatedRoute } from '@angular/router'; +import { of, Subject } from 'rxjs'; +import { catchError, takeUntil } from 'rxjs/operators'; + +import { AddonCompactComponent } from '@flink-runtime-web/components/addon-compact/addon-compact.component'; +import { AutoResizeDirective } from '@flink-runtime-web/components/editor/auto-resize.directive'; +import { ModuleConfig } from '@flink-runtime-web/core/module-config'; import { TASK_MANAGER_MODULE_CONFIG, - TASK_MANAGER_MODULE_DEFAULT_CONFIG, + TASK_MANAGER_MODULE_DEFAULT_CONFIG } from '@flink-runtime-web/pages/task-manager/task-manager.config'; -import {ModuleConfig} from "@flink-runtime-web/core/module-config"; -import {NzCodeEditorModule} from "ng-zorro-antd/code-editor"; -import {AutoResizeDirective} from "@flink-runtime-web/components/editor/auto-resize.directive"; -import {FormsModule} from "@angular/forms"; -import { - AddonCompactComponent -} from "@flink-runtime-web/components/addon-compact/addon-compact.component"; +import { ConfigService, TaskManagerService } from '@flink-runtime-web/services'; +import { EditorOptions, NzCodeEditorModule } from 'ng-zorro-antd/code-editor'; @Component({ - selector: 'flink-task-manager-logs', - templateUrl: './task-manager-logs.component.html', - styleUrls: ['./task-manager-logs.component.less'], - changeDetection: ChangeDetectionStrategy.OnPush, - imports: [NzCodeEditorModule, AutoResizeDirective, FormsModule, AddonCompactComponent] + selector: 'flink-task-manager-logs', + templateUrl: './task-manager-logs.component.html', + styleUrls: ['./task-manager-logs.component.less'], + changeDetection: ChangeDetectionStrategy.OnPush, + imports: [NzCodeEditorModule, AutoResizeDirective, FormsModule, AddonCompactComponent] }) export class TaskManagerLogsComponent implements OnInit, OnDestroy { public editorOptions: EditorOptions; @@ -61,7 +59,7 @@ export class TaskManagerLogsComponent implements OnInit, OnDestroy { this.editorOptions = moduleConfig.editorOptions || TASK_MANAGER_MODULE_DEFAULT_CONFIG.editorOptions; } - public ngOnInit() { + public ngOnInit(): void { this.taskManagerId = this.activatedRoute.parent!.snapshot.params.taskManagerId; this.downloadUrl = `${this.configService.BASE_URL}/taskmanagers/${this.taskManagerId}/log`; this.downloadName = `taskmanager_${this.taskManagerId}_log`; @@ -73,7 +71,7 @@ export class TaskManagerLogsComponent implements OnInit, OnDestroy { this.destroy$.complete(); } - public reload() { + public reload(): void { this.loading = true; this.cdr.markForCheck(); this.taskManagerService