1 | "use strict";
|
2 |
|
3 |
|
4 |
|
5 |
|
6 |
|
7 |
|
8 |
|
9 |
|
10 |
|
11 |
|
12 |
|
13 |
|
14 |
|
15 |
|
16 |
|
17 |
|
18 | Object.defineProperty(exports, "__esModule", { value: true });
|
19 | exports.channelOptionsEqual = exports.recognizedOptions = void 0;
|
20 |
|
21 |
|
22 |
|
23 |
|
24 | exports.recognizedOptions = {
|
25 | 'grpc.ssl_target_name_override': true,
|
26 | 'grpc.primary_user_agent': true,
|
27 | 'grpc.secondary_user_agent': true,
|
28 | 'grpc.default_authority': true,
|
29 | 'grpc.keepalive_time_ms': true,
|
30 | 'grpc.keepalive_timeout_ms': true,
|
31 | 'grpc.keepalive_permit_without_calls': true,
|
32 | 'grpc.service_config': true,
|
33 | 'grpc.max_concurrent_streams': true,
|
34 | 'grpc.initial_reconnect_backoff_ms': true,
|
35 | 'grpc.max_reconnect_backoff_ms': true,
|
36 | 'grpc.use_local_subchannel_pool': true,
|
37 | 'grpc.max_send_message_length': true,
|
38 | 'grpc.max_receive_message_length': true,
|
39 | 'grpc.enable_http_proxy': true,
|
40 | 'grpc-node.max_session_memory': true,
|
41 | };
|
42 | function channelOptionsEqual(options1, options2) {
|
43 | const keys1 = Object.keys(options1).sort();
|
44 | const keys2 = Object.keys(options2).sort();
|
45 | if (keys1.length !== keys2.length) {
|
46 | return false;
|
47 | }
|
48 | for (let i = 0; i < keys1.length; i += 1) {
|
49 | if (keys1[i] !== keys2[i]) {
|
50 | return false;
|
51 | }
|
52 | if (options1[keys1[i]] !== options2[keys2[i]]) {
|
53 | return false;
|
54 | }
|
55 | }
|
56 | return true;
|
57 | }
|
58 | exports.channelOptionsEqual = channelOptionsEqual;
|
59 |
|
\ | No newline at end of file |