2022-10-25 18:34:33 +08:00
|
|
|
import { ReqPage } from '.';
|
|
|
|
|
2022-10-20 18:45:47 +08:00
|
|
|
export namespace Database {
|
2022-10-25 18:34:33 +08:00
|
|
|
export interface Search extends ReqPage {
|
2022-10-31 23:52:39 +08:00
|
|
|
mysqlName: string;
|
2022-10-25 18:34:33 +08:00
|
|
|
}
|
2022-10-27 23:09:39 +08:00
|
|
|
export interface SearchBackupRecord extends ReqPage {
|
2022-10-31 23:52:39 +08:00
|
|
|
mysqlName: string;
|
2022-10-27 23:09:39 +08:00
|
|
|
dbName: string;
|
|
|
|
}
|
|
|
|
export interface Backup {
|
2022-10-31 23:52:39 +08:00
|
|
|
mysqlName: string;
|
2022-10-27 23:09:39 +08:00
|
|
|
dbName: string;
|
|
|
|
}
|
|
|
|
export interface Recover {
|
2022-10-31 23:52:39 +08:00
|
|
|
mysqlName: string;
|
2022-10-27 23:09:39 +08:00
|
|
|
dbName: string;
|
|
|
|
backupName: string;
|
|
|
|
}
|
2022-10-20 18:45:47 +08:00
|
|
|
export interface MysqlDBInfo {
|
|
|
|
id: number;
|
|
|
|
createdAt: Date;
|
|
|
|
name: string;
|
|
|
|
format: string;
|
|
|
|
username: string;
|
|
|
|
password: string;
|
|
|
|
permission: string;
|
|
|
|
description: string;
|
|
|
|
}
|
2022-10-25 18:34:33 +08:00
|
|
|
export interface BaseInfo {
|
|
|
|
name: string;
|
|
|
|
port: number;
|
|
|
|
password: string;
|
|
|
|
remoteConn: boolean;
|
2022-10-31 23:52:39 +08:00
|
|
|
mysqlKey: string;
|
2022-10-25 18:34:33 +08:00
|
|
|
}
|
2022-11-02 18:30:22 +08:00
|
|
|
export interface MysqlConfUpdateByFile {
|
|
|
|
mysqlName: string;
|
|
|
|
file: string;
|
|
|
|
}
|
2022-10-20 18:45:47 +08:00
|
|
|
export interface MysqlDBCreate {
|
|
|
|
name: string;
|
2022-10-31 23:52:39 +08:00
|
|
|
mysqlName: string;
|
2022-10-20 18:45:47 +08:00
|
|
|
format: string;
|
|
|
|
username: string;
|
|
|
|
password: string;
|
|
|
|
permission: string;
|
|
|
|
description: string;
|
|
|
|
}
|
2022-10-21 18:50:38 +08:00
|
|
|
export interface MysqlVariables {
|
2022-10-31 23:52:39 +08:00
|
|
|
mysqlName: string;
|
2022-10-21 18:50:38 +08:00
|
|
|
binlog_cache_size: number;
|
|
|
|
innodb_buffer_pool_size: number;
|
|
|
|
innodb_log_buffer_size: number;
|
|
|
|
join_buffer_size: number;
|
|
|
|
key_buffer_size: number;
|
|
|
|
max_connections: number;
|
|
|
|
query_cache_size: number;
|
|
|
|
read_buffer_size: number;
|
|
|
|
read_rnd_buffer_size: number;
|
|
|
|
sort_buffer_size: number;
|
|
|
|
table_open_cache: number;
|
|
|
|
thread_cache_size: number;
|
|
|
|
thread_stack: number;
|
|
|
|
tmp_table_size: number;
|
|
|
|
}
|
|
|
|
export interface MysqlStatus {
|
|
|
|
Aborted_clients: number;
|
|
|
|
Aborted_connects: number;
|
|
|
|
Bytes_received: number;
|
|
|
|
Bytes_sent: number;
|
|
|
|
Com_commit: number;
|
|
|
|
Com_rollback: number;
|
|
|
|
Connections: number;
|
|
|
|
Created_tmp_disk_tables: number;
|
|
|
|
Created_tmp_tables: number;
|
|
|
|
Innodb_buffer_pool_pages_dirty: number;
|
|
|
|
Innodb_buffer_pool_read_requests: number;
|
|
|
|
Innodb_buffer_pool_reads: number;
|
|
|
|
Key_read_requests: number;
|
|
|
|
Key_reads: number;
|
|
|
|
Key_write_requests: number;
|
|
|
|
Key_writes: number;
|
|
|
|
Max_used_connections: number;
|
|
|
|
Open_tables: number;
|
|
|
|
Opened_files: number;
|
|
|
|
Opened_tables: number;
|
|
|
|
Qcache_hits: number;
|
|
|
|
Qcache_inserts: number;
|
|
|
|
Questions: number;
|
|
|
|
Select_full_join: number;
|
|
|
|
Select_range_check: number;
|
|
|
|
Sort_merge_passes: number;
|
|
|
|
Table_locks_waited: number;
|
|
|
|
Threads_cached: number;
|
|
|
|
Threads_connected: number;
|
|
|
|
Threads_created: number;
|
|
|
|
Threads_running: number;
|
|
|
|
Uptime: number;
|
|
|
|
Run: number;
|
|
|
|
File: string;
|
|
|
|
Position: number;
|
|
|
|
}
|
2022-10-24 18:46:19 +08:00
|
|
|
export interface ChangeInfo {
|
|
|
|
id: number;
|
2022-10-31 23:52:39 +08:00
|
|
|
mysqlName: string;
|
2022-10-24 18:46:19 +08:00
|
|
|
operation: string;
|
|
|
|
value: string;
|
|
|
|
}
|
2022-10-31 17:26:15 +08:00
|
|
|
|
|
|
|
// redis
|
2022-10-31 23:52:39 +08:00
|
|
|
export interface RedisConfUpdate {
|
2022-11-02 18:30:22 +08:00
|
|
|
timeout: string;
|
|
|
|
maxclients: string;
|
|
|
|
requirepass: string;
|
|
|
|
maxmemory: string;
|
|
|
|
}
|
2022-11-03 23:42:42 +08:00
|
|
|
export interface RedisConfPersistenceUpdate {
|
|
|
|
type: string;
|
|
|
|
appendonly: string;
|
|
|
|
appendfsync: string;
|
|
|
|
save: string;
|
|
|
|
}
|
2022-11-02 18:30:22 +08:00
|
|
|
export interface RedisConfUpdateByFile {
|
|
|
|
file: string;
|
2022-11-03 23:42:42 +08:00
|
|
|
restartNow: boolean;
|
2022-10-31 23:52:39 +08:00
|
|
|
}
|
|
|
|
export interface RedisStatus {
|
|
|
|
tcp_port: string;
|
|
|
|
uptime_in_days: string;
|
|
|
|
connected_clients: string;
|
|
|
|
used_memory: string;
|
|
|
|
used_memory_rss: string;
|
|
|
|
used_memory_peak: string;
|
|
|
|
mem_fragmentation_ratio: string;
|
|
|
|
total_connections_received: string;
|
|
|
|
total_commands_processed: string;
|
|
|
|
instantaneous_ops_per_sec: string;
|
|
|
|
keyspace_hits: string;
|
|
|
|
keyspace_misses: string;
|
|
|
|
latest_fork_usec: string;
|
|
|
|
}
|
|
|
|
export interface RedisConf {
|
2022-11-02 16:28:54 +08:00
|
|
|
name: string;
|
2022-10-31 23:52:39 +08:00
|
|
|
timeout: number;
|
|
|
|
maxclients: number;
|
|
|
|
requirepass: string;
|
|
|
|
maxmemory: number;
|
2022-11-02 16:28:54 +08:00
|
|
|
}
|
|
|
|
export interface RedisPersistenceConf {
|
2022-10-31 23:52:39 +08:00
|
|
|
appendonly: string;
|
|
|
|
appendfsync: string;
|
|
|
|
save: string;
|
|
|
|
}
|
2022-11-03 23:42:42 +08:00
|
|
|
export interface RedisBackupRecord {
|
|
|
|
fileName: string;
|
|
|
|
fileDir: string;
|
|
|
|
createdAt: string;
|
|
|
|
size: string;
|
|
|
|
}
|
|
|
|
export interface RedisBackupDelete {
|
|
|
|
fileDir: string;
|
|
|
|
names: Array<string>;
|
|
|
|
}
|
|
|
|
export interface RedisRecover {
|
|
|
|
fileName: string;
|
|
|
|
fileDir: string;
|
|
|
|
}
|
2022-10-20 18:45:47 +08:00
|
|
|
}
|