Coverage for mindsdb / integrations / handlers / redshift_handler / connection_args.py: 100%

4 statements  

« prev     ^ index     » next       coverage.py v7.13.1, created at 2026-01-21 00:36 +0000

1from collections import OrderedDict 

2 

3from mindsdb.integrations.libs.const import HANDLER_CONNECTION_ARG_TYPE as ARG_TYPE 

4 

5 

6connection_args = OrderedDict( 

7 host={ 

8 'type': ARG_TYPE.STR, 

9 'description': 'The host name or IP address of the Redshift cluster.', 

10 'required': True, 

11 'label': 'Host' 

12 }, 

13 port={ 

14 'type': ARG_TYPE.INT, 

15 'description': 'The port to use when connecting with the Redshift cluster.', 

16 'required': True, 

17 'label': 'Port' 

18 }, 

19 database={ 

20 'type': ARG_TYPE.STR, 

21 'description': 'The database name to use when connecting with the Redshift cluster.', 

22 'required': True, 

23 'label': 'Database' 

24 }, 

25 user={ 

26 'type': ARG_TYPE.STR, 

27 'description': 'The user name used to authenticate with the Redshift cluster.', 

28 'required': True, 

29 'label': 'User' 

30 }, 

31 password={ 

32 'type': ARG_TYPE.PWD, 

33 'description': 'The password to authenticate the user with the Redshift cluster.', 

34 'required': True, 

35 'label': 'Password', 

36 'secret': True 

37 }, 

38 schema={ 

39 'type': ARG_TYPE.STR, 

40 'description': 'The schema in which objects are searched first.', 

41 'required': False, 

42 'label': 'Schema' 

43 }, 

44 sslmode={ 

45 'type': ARG_TYPE.STR, 

46 'description': 'The SSL mode that will be used for connection.', 

47 'required': False, 

48 'label': 'sslmode' 

49 } 

50) 

51 

52connection_args_example = OrderedDict( 

53 host='examplecluster.abc123xyz789.us-west-1.redshift.amazonaws.com', 

54 port='5439', 

55 database='dev', 

56 user='awsuser', 

57 password='my_password' 

58)