mirror of
https://github.com/Abdulazizzn/n8n-enterprise-unlocked.git
synced 2025-12-19 19:11:13 +00:00
⚡ Add connection timeout to credentials (MSSQL Node) (#1517)
This commit is contained in:
@@ -50,5 +50,12 @@ export class MicrosoftSql implements ICredentialType {
|
|||||||
type: 'boolean' as NodePropertyTypes,
|
type: 'boolean' as NodePropertyTypes,
|
||||||
default: true,
|
default: true,
|
||||||
},
|
},
|
||||||
|
{
|
||||||
|
displayName: 'Connect Timeout',
|
||||||
|
name: 'connectTimeout',
|
||||||
|
type: 'number' as NodePropertyTypes,
|
||||||
|
default: 15000,
|
||||||
|
description: 'Connection timeout in ms.',
|
||||||
|
},
|
||||||
];
|
];
|
||||||
}
|
}
|
||||||
|
|||||||
@@ -1,4 +1,7 @@
|
|||||||
import { IExecuteFunctions } from 'n8n-core';
|
import {
|
||||||
|
IExecuteFunctions,
|
||||||
|
} from 'n8n-core';
|
||||||
|
|
||||||
import {
|
import {
|
||||||
IDataObject,
|
IDataObject,
|
||||||
INodeExecutionData,
|
INodeExecutionData,
|
||||||
@@ -6,11 +9,16 @@ import {
|
|||||||
INodeTypeDescription,
|
INodeTypeDescription,
|
||||||
} from 'n8n-workflow';
|
} from 'n8n-workflow';
|
||||||
|
|
||||||
import { chunk, flatten } from '../../utils/utilities';
|
import {
|
||||||
|
chunk,
|
||||||
|
flatten,
|
||||||
|
} from '../../utils/utilities';
|
||||||
|
|
||||||
import * as mssql from 'mssql';
|
import * as mssql from 'mssql';
|
||||||
|
|
||||||
import { ITables } from './TableInterface';
|
import {
|
||||||
|
ITables,
|
||||||
|
} from './TableInterface';
|
||||||
|
|
||||||
import {
|
import {
|
||||||
copyInputItem,
|
copyInputItem,
|
||||||
@@ -26,13 +34,13 @@ export class MicrosoftSql implements INodeType {
|
|||||||
description: INodeTypeDescription = {
|
description: INodeTypeDescription = {
|
||||||
displayName: 'Microsoft SQL',
|
displayName: 'Microsoft SQL',
|
||||||
name: 'microsoftSql',
|
name: 'microsoftSql',
|
||||||
icon: 'file:mssql.png',
|
icon: 'file:mssql.svg',
|
||||||
group: ['input'],
|
group: ['input'],
|
||||||
version: 1,
|
version: 1,
|
||||||
description: 'Gets, add and update data in Microsoft SQL.',
|
description: 'Gets, add and update data in Microsoft SQL.',
|
||||||
defaults: {
|
defaults: {
|
||||||
name: 'Microsoft SQL',
|
name: 'Microsoft SQL',
|
||||||
color: '#1d4bab',
|
color: '#bcbcbd',
|
||||||
},
|
},
|
||||||
inputs: ['main'],
|
inputs: ['main'],
|
||||||
outputs: ['main'],
|
outputs: ['main'],
|
||||||
@@ -217,6 +225,7 @@ export class MicrosoftSql implements INodeType {
|
|||||||
user: credentials.user as string,
|
user: credentials.user as string,
|
||||||
password: credentials.password as string,
|
password: credentials.password as string,
|
||||||
domain: credentials.domain ? (credentials.domain as string) : undefined,
|
domain: credentials.domain ? (credentials.domain as string) : undefined,
|
||||||
|
connectTimeout: credentials.connectTimeout as number,
|
||||||
options: {
|
options: {
|
||||||
encrypt: credentials.tls as boolean,
|
encrypt: credentials.tls as boolean,
|
||||||
},
|
},
|
||||||
|
|||||||
Binary file not shown.
|
Before Width: | Height: | Size: 3.4 KiB |
115
packages/nodes-base/nodes/Microsoft/Sql/mssql.svg
Normal file
115
packages/nodes-base/nodes/Microsoft/Sql/mssql.svg
Normal file
File diff suppressed because one or more lines are too long
|
After Width: | Height: | Size: 22 KiB |
Reference in New Issue
Block a user