mirror of
https://github.com/dadosfera/maestro.git
synced 2026-12-02 06:20:04 +00:00
FEAT: new conection test module
This commit is contained in:
@@ -0,0 +1,42 @@
|
||||
import { Injectable } from '@nestjs/common';
|
||||
import {
|
||||
ConnectionTestCredentialsReq,
|
||||
ConnectionTestCredentialsRes,
|
||||
ConnectionTestListSchemasReq,
|
||||
ConnectionTestListSchemasRes,
|
||||
ConnectionTestListTablesReq,
|
||||
ConnectionTestListTablesRes,
|
||||
ConnectionTestPingReq,
|
||||
ConnectionTestPingRes,
|
||||
GetTableMetadataReq,
|
||||
GetTableMetadataRes,
|
||||
} from './dto/connection-test';
|
||||
|
||||
@Injectable()
|
||||
export class ConnectionTestService {
|
||||
async connectionTestPing(
|
||||
body: ConnectionTestPingReq,
|
||||
): Promise<ConnectionTestPingRes> {
|
||||
return { operation_result: true };
|
||||
}
|
||||
async connectionTestCredentials(
|
||||
body: ConnectionTestCredentialsReq,
|
||||
): Promise<ConnectionTestCredentialsRes> {
|
||||
return { operation_result: true, connection_id: '' };
|
||||
}
|
||||
async connectionTestListSchemas(
|
||||
body: ConnectionTestListSchemasReq,
|
||||
): Promise<ConnectionTestListSchemasRes> {
|
||||
return { operation_result: true, schema_list: [] };
|
||||
}
|
||||
async connectionTestListTables(
|
||||
body: ConnectionTestListTablesReq,
|
||||
): Promise<ConnectionTestListTablesRes> {
|
||||
return { operation_result: true, table_list: [] };
|
||||
}
|
||||
async getTableMetadata(
|
||||
body: GetTableMetadataReq,
|
||||
): Promise<GetTableMetadataRes> {
|
||||
return { table_metadata: [{ columns: [], table_name: '' }] };
|
||||
}
|
||||
}
|
||||
Reference in New Issue
Block a user