huaweicloudsdkmrs 3.1.70__py2.py3-none-any.whl → 3.1.72__py2.py3-none-any.whl

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Files changed (40) hide show
  1. huaweicloudsdkmrs/v1/__init__.py +9 -0
  2. huaweicloudsdkmrs/v1/model/__init__.py +9 -0
  3. huaweicloudsdkmrs/v1/model/component_external_datasource.py +144 -0
  4. huaweicloudsdkmrs/v1/model/flavor_lists.py +173 -0
  5. huaweicloudsdkmrs/v1/model/node_constraint.py +376 -0
  6. huaweicloudsdkmrs/v1/model/node_constraints.py +315 -0
  7. huaweicloudsdkmrs/v1/model/role_deploy_meta.py +637 -0
  8. huaweicloudsdkmrs/v1/model/show_mrs_version_metadata_request.py +143 -0
  9. huaweicloudsdkmrs/v1/model/show_mrs_version_metadata_response.py +456 -0
  10. huaweicloudsdkmrs/v1/model/version_component.py +434 -0
  11. huaweicloudsdkmrs/v1/model/version_constraint.py +169 -0
  12. huaweicloudsdkmrs/v1/mrs_async_client.py +75 -0
  13. huaweicloudsdkmrs/v1/mrs_client.py +75 -0
  14. huaweicloudsdkmrs/v1/region/mrs_region.py +3 -0
  15. huaweicloudsdkmrs/v2/__init__.py +15 -0
  16. huaweicloudsdkmrs/v2/model/__init__.py +15 -0
  17. huaweicloudsdkmrs/v2/model/auto_scaling_policy_delete_req.py +142 -0
  18. huaweicloudsdkmrs/v2/model/auto_scaling_policy_info.py +257 -0
  19. huaweicloudsdkmrs/v2/model/auto_scaling_policy_v2.py +11 -12
  20. huaweicloudsdkmrs/v2/model/create_auto_scaling_policy_request.py +139 -0
  21. huaweicloudsdkmrs/v2/model/create_auto_scaling_policy_response.py +85 -0
  22. huaweicloudsdkmrs/v2/model/delete_auto_scaling_policy_request.py +139 -0
  23. huaweicloudsdkmrs/v2/model/delete_auto_scaling_policy_response.py +85 -0
  24. huaweicloudsdkmrs/v2/model/modify_default_tags_request_body.py +114 -0
  25. huaweicloudsdkmrs/v2/model/show_tag_quota_request.py +143 -0
  26. huaweicloudsdkmrs/v2/model/show_tag_quota_response.py +145 -0
  27. huaweicloudsdkmrs/v2/model/show_tag_status_request.py +114 -0
  28. huaweicloudsdkmrs/v2/model/show_tag_status_response.py +145 -0
  29. huaweicloudsdkmrs/v2/model/switch_cluster_tags_request.py +139 -0
  30. huaweicloudsdkmrs/v2/model/switch_cluster_tags_response.py +85 -0
  31. huaweicloudsdkmrs/v2/model/update_auto_scaling_policy_request.py +139 -0
  32. huaweicloudsdkmrs/v2/model/update_auto_scaling_policy_response.py +85 -0
  33. huaweicloudsdkmrs/v2/mrs_async_client.py +400 -0
  34. huaweicloudsdkmrs/v2/mrs_client.py +400 -0
  35. huaweicloudsdkmrs/v2/region/mrs_region.py +3 -0
  36. {huaweicloudsdkmrs-3.1.70.dist-info → huaweicloudsdkmrs-3.1.72.dist-info}/METADATA +2 -2
  37. {huaweicloudsdkmrs-3.1.70.dist-info → huaweicloudsdkmrs-3.1.72.dist-info}/RECORD +40 -16
  38. {huaweicloudsdkmrs-3.1.70.dist-info → huaweicloudsdkmrs-3.1.72.dist-info}/LICENSE +0 -0
  39. {huaweicloudsdkmrs-3.1.70.dist-info → huaweicloudsdkmrs-3.1.72.dist-info}/WHEEL +0 -0
  40. {huaweicloudsdkmrs-3.1.70.dist-info → huaweicloudsdkmrs-3.1.72.dist-info}/top_level.txt +0 -0
@@ -0,0 +1,637 @@
1
+ # coding: utf-8
2
+
3
+ import six
4
+
5
+ from huaweicloudsdkcore.utils.http_utils import sanitize_for_serialization
6
+
7
+
8
+ class RoleDeployMeta:
9
+
10
+ """
11
+ Attributes:
12
+ openapi_types (dict): The key is attribute name
13
+ and the value is attribute type.
14
+ attribute_map (dict): The key is attribute name
15
+ and the value is json key in definition.
16
+ """
17
+ sensitive_list = []
18
+
19
+ openapi_types = {
20
+ 'other': 'dict(str, object)',
21
+ 'name': 'str',
22
+ 'code_name': 'str',
23
+ 'component': 'str',
24
+ 'node_preference': 'str',
25
+ 'count': 'str',
26
+ 'affinity': 'str',
27
+ 'affinity_target': 'str',
28
+ 'multi_instance': 'int',
29
+ 'role_kind': 'str',
30
+ 'constraints': 'list[str]',
31
+ 'multi_az_placement': 'str',
32
+ 'arbitration_deployment': 'bool',
33
+ 'support_elb': 'bool',
34
+ 'multi_affinity_group_enable': 'bool',
35
+ 'local_disks_anti_affinity': 'bool',
36
+ 'multi_instance_name_pattern': 'str',
37
+ 'private_ip': 'str',
38
+ 'weight': 'str'
39
+ }
40
+
41
+ attribute_map = {
42
+ 'other': 'other',
43
+ 'name': 'name',
44
+ 'code_name': 'code_name',
45
+ 'component': 'component',
46
+ 'node_preference': 'node_preference',
47
+ 'count': 'count',
48
+ 'affinity': 'affinity',
49
+ 'affinity_target': 'affinity_target',
50
+ 'multi_instance': 'multi_instance',
51
+ 'role_kind': 'role_kind',
52
+ 'constraints': 'constraints',
53
+ 'multi_az_placement': 'multi_az_placement',
54
+ 'arbitration_deployment': 'arbitration_deployment',
55
+ 'support_elb': 'support_elb',
56
+ 'multi_affinity_group_enable': 'multi_affinity_group_enable',
57
+ 'local_disks_anti_affinity': 'local_disks_anti_affinity',
58
+ 'multi_instance_name_pattern': 'multi_instance_name_pattern',
59
+ 'private_ip': 'private_ip',
60
+ 'weight': 'weight'
61
+ }
62
+
63
+ def __init__(self, other=None, name=None, code_name=None, component=None, node_preference=None, count=None, affinity=None, affinity_target=None, multi_instance=None, role_kind=None, constraints=None, multi_az_placement=None, arbitration_deployment=None, support_elb=None, multi_affinity_group_enable=None, local_disks_anti_affinity=None, multi_instance_name_pattern=None, private_ip=None, weight=None):
64
+ """RoleDeployMeta
65
+
66
+ The model defined in huaweicloud sdk
67
+
68
+ :param other: 其他扩展属性
69
+ :type other: dict(str, object)
70
+ :param name: 角色名称
71
+ :type name: str
72
+ :param code_name: 角色简称
73
+ :type code_name: str
74
+ :param component: 角色所属组件
75
+ :type component: str
76
+ :param node_preference: 部署倾向
77
+ :type node_preference: str
78
+ :param count: 角色数量限制
79
+ :type count: str
80
+ :param affinity: 亲和
81
+ :type affinity: str
82
+ :param affinity_target: 亲和目标
83
+ :type affinity_target: str
84
+ :param multi_instance: 多实例
85
+ :type multi_instance: int
86
+ :param role_kind: 角色类型
87
+ :type role_kind: str
88
+ :param constraints: 角色限制,包含当前组件角色的一些功能限制,例如:\"no_scale_in\"
89
+ :type constraints: list[str]
90
+ :param multi_az_placement: 多az部署
91
+ :type multi_az_placement: str
92
+ :param arbitration_deployment: 仲裁部署
93
+ :type arbitration_deployment: bool
94
+ :param support_elb: 支持ELB
95
+ :type support_elb: bool
96
+ :param multi_affinity_group_enable: 启用多亲和组
97
+ :type multi_affinity_group_enable: bool
98
+ :param local_disks_anti_affinity: 本地盘反亲和
99
+ :type local_disks_anti_affinity: bool
100
+ :param multi_instance_name_pattern: 多实例名称模式
101
+ :type multi_instance_name_pattern: str
102
+ :param private_ip: 私有IP
103
+ :type private_ip: str
104
+ :param weight: 权重
105
+ :type weight: str
106
+ """
107
+
108
+
109
+
110
+ self._other = None
111
+ self._name = None
112
+ self._code_name = None
113
+ self._component = None
114
+ self._node_preference = None
115
+ self._count = None
116
+ self._affinity = None
117
+ self._affinity_target = None
118
+ self._multi_instance = None
119
+ self._role_kind = None
120
+ self._constraints = None
121
+ self._multi_az_placement = None
122
+ self._arbitration_deployment = None
123
+ self._support_elb = None
124
+ self._multi_affinity_group_enable = None
125
+ self._local_disks_anti_affinity = None
126
+ self._multi_instance_name_pattern = None
127
+ self._private_ip = None
128
+ self._weight = None
129
+ self.discriminator = None
130
+
131
+ if other is not None:
132
+ self.other = other
133
+ if name is not None:
134
+ self.name = name
135
+ if code_name is not None:
136
+ self.code_name = code_name
137
+ if component is not None:
138
+ self.component = component
139
+ if node_preference is not None:
140
+ self.node_preference = node_preference
141
+ if count is not None:
142
+ self.count = count
143
+ if affinity is not None:
144
+ self.affinity = affinity
145
+ if affinity_target is not None:
146
+ self.affinity_target = affinity_target
147
+ if multi_instance is not None:
148
+ self.multi_instance = multi_instance
149
+ if role_kind is not None:
150
+ self.role_kind = role_kind
151
+ if constraints is not None:
152
+ self.constraints = constraints
153
+ if multi_az_placement is not None:
154
+ self.multi_az_placement = multi_az_placement
155
+ if arbitration_deployment is not None:
156
+ self.arbitration_deployment = arbitration_deployment
157
+ if support_elb is not None:
158
+ self.support_elb = support_elb
159
+ if multi_affinity_group_enable is not None:
160
+ self.multi_affinity_group_enable = multi_affinity_group_enable
161
+ if local_disks_anti_affinity is not None:
162
+ self.local_disks_anti_affinity = local_disks_anti_affinity
163
+ if multi_instance_name_pattern is not None:
164
+ self.multi_instance_name_pattern = multi_instance_name_pattern
165
+ if private_ip is not None:
166
+ self.private_ip = private_ip
167
+ if weight is not None:
168
+ self.weight = weight
169
+
170
+ @property
171
+ def other(self):
172
+ """Gets the other of this RoleDeployMeta.
173
+
174
+ 其他扩展属性
175
+
176
+ :return: The other of this RoleDeployMeta.
177
+ :rtype: dict(str, object)
178
+ """
179
+ return self._other
180
+
181
+ @other.setter
182
+ def other(self, other):
183
+ """Sets the other of this RoleDeployMeta.
184
+
185
+ 其他扩展属性
186
+
187
+ :param other: The other of this RoleDeployMeta.
188
+ :type other: dict(str, object)
189
+ """
190
+ self._other = other
191
+
192
+ @property
193
+ def name(self):
194
+ """Gets the name of this RoleDeployMeta.
195
+
196
+ 角色名称
197
+
198
+ :return: The name of this RoleDeployMeta.
199
+ :rtype: str
200
+ """
201
+ return self._name
202
+
203
+ @name.setter
204
+ def name(self, name):
205
+ """Sets the name of this RoleDeployMeta.
206
+
207
+ 角色名称
208
+
209
+ :param name: The name of this RoleDeployMeta.
210
+ :type name: str
211
+ """
212
+ self._name = name
213
+
214
+ @property
215
+ def code_name(self):
216
+ """Gets the code_name of this RoleDeployMeta.
217
+
218
+ 角色简称
219
+
220
+ :return: The code_name of this RoleDeployMeta.
221
+ :rtype: str
222
+ """
223
+ return self._code_name
224
+
225
+ @code_name.setter
226
+ def code_name(self, code_name):
227
+ """Sets the code_name of this RoleDeployMeta.
228
+
229
+ 角色简称
230
+
231
+ :param code_name: The code_name of this RoleDeployMeta.
232
+ :type code_name: str
233
+ """
234
+ self._code_name = code_name
235
+
236
+ @property
237
+ def component(self):
238
+ """Gets the component of this RoleDeployMeta.
239
+
240
+ 角色所属组件
241
+
242
+ :return: The component of this RoleDeployMeta.
243
+ :rtype: str
244
+ """
245
+ return self._component
246
+
247
+ @component.setter
248
+ def component(self, component):
249
+ """Sets the component of this RoleDeployMeta.
250
+
251
+ 角色所属组件
252
+
253
+ :param component: The component of this RoleDeployMeta.
254
+ :type component: str
255
+ """
256
+ self._component = component
257
+
258
+ @property
259
+ def node_preference(self):
260
+ """Gets the node_preference of this RoleDeployMeta.
261
+
262
+ 部署倾向
263
+
264
+ :return: The node_preference of this RoleDeployMeta.
265
+ :rtype: str
266
+ """
267
+ return self._node_preference
268
+
269
+ @node_preference.setter
270
+ def node_preference(self, node_preference):
271
+ """Sets the node_preference of this RoleDeployMeta.
272
+
273
+ 部署倾向
274
+
275
+ :param node_preference: The node_preference of this RoleDeployMeta.
276
+ :type node_preference: str
277
+ """
278
+ self._node_preference = node_preference
279
+
280
+ @property
281
+ def count(self):
282
+ """Gets the count of this RoleDeployMeta.
283
+
284
+ 角色数量限制
285
+
286
+ :return: The count of this RoleDeployMeta.
287
+ :rtype: str
288
+ """
289
+ return self._count
290
+
291
+ @count.setter
292
+ def count(self, count):
293
+ """Sets the count of this RoleDeployMeta.
294
+
295
+ 角色数量限制
296
+
297
+ :param count: The count of this RoleDeployMeta.
298
+ :type count: str
299
+ """
300
+ self._count = count
301
+
302
+ @property
303
+ def affinity(self):
304
+ """Gets the affinity of this RoleDeployMeta.
305
+
306
+ 亲和
307
+
308
+ :return: The affinity of this RoleDeployMeta.
309
+ :rtype: str
310
+ """
311
+ return self._affinity
312
+
313
+ @affinity.setter
314
+ def affinity(self, affinity):
315
+ """Sets the affinity of this RoleDeployMeta.
316
+
317
+ 亲和
318
+
319
+ :param affinity: The affinity of this RoleDeployMeta.
320
+ :type affinity: str
321
+ """
322
+ self._affinity = affinity
323
+
324
+ @property
325
+ def affinity_target(self):
326
+ """Gets the affinity_target of this RoleDeployMeta.
327
+
328
+ 亲和目标
329
+
330
+ :return: The affinity_target of this RoleDeployMeta.
331
+ :rtype: str
332
+ """
333
+ return self._affinity_target
334
+
335
+ @affinity_target.setter
336
+ def affinity_target(self, affinity_target):
337
+ """Sets the affinity_target of this RoleDeployMeta.
338
+
339
+ 亲和目标
340
+
341
+ :param affinity_target: The affinity_target of this RoleDeployMeta.
342
+ :type affinity_target: str
343
+ """
344
+ self._affinity_target = affinity_target
345
+
346
+ @property
347
+ def multi_instance(self):
348
+ """Gets the multi_instance of this RoleDeployMeta.
349
+
350
+ 多实例
351
+
352
+ :return: The multi_instance of this RoleDeployMeta.
353
+ :rtype: int
354
+ """
355
+ return self._multi_instance
356
+
357
+ @multi_instance.setter
358
+ def multi_instance(self, multi_instance):
359
+ """Sets the multi_instance of this RoleDeployMeta.
360
+
361
+ 多实例
362
+
363
+ :param multi_instance: The multi_instance of this RoleDeployMeta.
364
+ :type multi_instance: int
365
+ """
366
+ self._multi_instance = multi_instance
367
+
368
+ @property
369
+ def role_kind(self):
370
+ """Gets the role_kind of this RoleDeployMeta.
371
+
372
+ 角色类型
373
+
374
+ :return: The role_kind of this RoleDeployMeta.
375
+ :rtype: str
376
+ """
377
+ return self._role_kind
378
+
379
+ @role_kind.setter
380
+ def role_kind(self, role_kind):
381
+ """Sets the role_kind of this RoleDeployMeta.
382
+
383
+ 角色类型
384
+
385
+ :param role_kind: The role_kind of this RoleDeployMeta.
386
+ :type role_kind: str
387
+ """
388
+ self._role_kind = role_kind
389
+
390
+ @property
391
+ def constraints(self):
392
+ """Gets the constraints of this RoleDeployMeta.
393
+
394
+ 角色限制,包含当前组件角色的一些功能限制,例如:\"no_scale_in\"
395
+
396
+ :return: The constraints of this RoleDeployMeta.
397
+ :rtype: list[str]
398
+ """
399
+ return self._constraints
400
+
401
+ @constraints.setter
402
+ def constraints(self, constraints):
403
+ """Sets the constraints of this RoleDeployMeta.
404
+
405
+ 角色限制,包含当前组件角色的一些功能限制,例如:\"no_scale_in\"
406
+
407
+ :param constraints: The constraints of this RoleDeployMeta.
408
+ :type constraints: list[str]
409
+ """
410
+ self._constraints = constraints
411
+
412
+ @property
413
+ def multi_az_placement(self):
414
+ """Gets the multi_az_placement of this RoleDeployMeta.
415
+
416
+ 多az部署
417
+
418
+ :return: The multi_az_placement of this RoleDeployMeta.
419
+ :rtype: str
420
+ """
421
+ return self._multi_az_placement
422
+
423
+ @multi_az_placement.setter
424
+ def multi_az_placement(self, multi_az_placement):
425
+ """Sets the multi_az_placement of this RoleDeployMeta.
426
+
427
+ 多az部署
428
+
429
+ :param multi_az_placement: The multi_az_placement of this RoleDeployMeta.
430
+ :type multi_az_placement: str
431
+ """
432
+ self._multi_az_placement = multi_az_placement
433
+
434
+ @property
435
+ def arbitration_deployment(self):
436
+ """Gets the arbitration_deployment of this RoleDeployMeta.
437
+
438
+ 仲裁部署
439
+
440
+ :return: The arbitration_deployment of this RoleDeployMeta.
441
+ :rtype: bool
442
+ """
443
+ return self._arbitration_deployment
444
+
445
+ @arbitration_deployment.setter
446
+ def arbitration_deployment(self, arbitration_deployment):
447
+ """Sets the arbitration_deployment of this RoleDeployMeta.
448
+
449
+ 仲裁部署
450
+
451
+ :param arbitration_deployment: The arbitration_deployment of this RoleDeployMeta.
452
+ :type arbitration_deployment: bool
453
+ """
454
+ self._arbitration_deployment = arbitration_deployment
455
+
456
+ @property
457
+ def support_elb(self):
458
+ """Gets the support_elb of this RoleDeployMeta.
459
+
460
+ 支持ELB
461
+
462
+ :return: The support_elb of this RoleDeployMeta.
463
+ :rtype: bool
464
+ """
465
+ return self._support_elb
466
+
467
+ @support_elb.setter
468
+ def support_elb(self, support_elb):
469
+ """Sets the support_elb of this RoleDeployMeta.
470
+
471
+ 支持ELB
472
+
473
+ :param support_elb: The support_elb of this RoleDeployMeta.
474
+ :type support_elb: bool
475
+ """
476
+ self._support_elb = support_elb
477
+
478
+ @property
479
+ def multi_affinity_group_enable(self):
480
+ """Gets the multi_affinity_group_enable of this RoleDeployMeta.
481
+
482
+ 启用多亲和组
483
+
484
+ :return: The multi_affinity_group_enable of this RoleDeployMeta.
485
+ :rtype: bool
486
+ """
487
+ return self._multi_affinity_group_enable
488
+
489
+ @multi_affinity_group_enable.setter
490
+ def multi_affinity_group_enable(self, multi_affinity_group_enable):
491
+ """Sets the multi_affinity_group_enable of this RoleDeployMeta.
492
+
493
+ 启用多亲和组
494
+
495
+ :param multi_affinity_group_enable: The multi_affinity_group_enable of this RoleDeployMeta.
496
+ :type multi_affinity_group_enable: bool
497
+ """
498
+ self._multi_affinity_group_enable = multi_affinity_group_enable
499
+
500
+ @property
501
+ def local_disks_anti_affinity(self):
502
+ """Gets the local_disks_anti_affinity of this RoleDeployMeta.
503
+
504
+ 本地盘反亲和
505
+
506
+ :return: The local_disks_anti_affinity of this RoleDeployMeta.
507
+ :rtype: bool
508
+ """
509
+ return self._local_disks_anti_affinity
510
+
511
+ @local_disks_anti_affinity.setter
512
+ def local_disks_anti_affinity(self, local_disks_anti_affinity):
513
+ """Sets the local_disks_anti_affinity of this RoleDeployMeta.
514
+
515
+ 本地盘反亲和
516
+
517
+ :param local_disks_anti_affinity: The local_disks_anti_affinity of this RoleDeployMeta.
518
+ :type local_disks_anti_affinity: bool
519
+ """
520
+ self._local_disks_anti_affinity = local_disks_anti_affinity
521
+
522
+ @property
523
+ def multi_instance_name_pattern(self):
524
+ """Gets the multi_instance_name_pattern of this RoleDeployMeta.
525
+
526
+ 多实例名称模式
527
+
528
+ :return: The multi_instance_name_pattern of this RoleDeployMeta.
529
+ :rtype: str
530
+ """
531
+ return self._multi_instance_name_pattern
532
+
533
+ @multi_instance_name_pattern.setter
534
+ def multi_instance_name_pattern(self, multi_instance_name_pattern):
535
+ """Sets the multi_instance_name_pattern of this RoleDeployMeta.
536
+
537
+ 多实例名称模式
538
+
539
+ :param multi_instance_name_pattern: The multi_instance_name_pattern of this RoleDeployMeta.
540
+ :type multi_instance_name_pattern: str
541
+ """
542
+ self._multi_instance_name_pattern = multi_instance_name_pattern
543
+
544
+ @property
545
+ def private_ip(self):
546
+ """Gets the private_ip of this RoleDeployMeta.
547
+
548
+ 私有IP
549
+
550
+ :return: The private_ip of this RoleDeployMeta.
551
+ :rtype: str
552
+ """
553
+ return self._private_ip
554
+
555
+ @private_ip.setter
556
+ def private_ip(self, private_ip):
557
+ """Sets the private_ip of this RoleDeployMeta.
558
+
559
+ 私有IP
560
+
561
+ :param private_ip: The private_ip of this RoleDeployMeta.
562
+ :type private_ip: str
563
+ """
564
+ self._private_ip = private_ip
565
+
566
+ @property
567
+ def weight(self):
568
+ """Gets the weight of this RoleDeployMeta.
569
+
570
+ 权重
571
+
572
+ :return: The weight of this RoleDeployMeta.
573
+ :rtype: str
574
+ """
575
+ return self._weight
576
+
577
+ @weight.setter
578
+ def weight(self, weight):
579
+ """Sets the weight of this RoleDeployMeta.
580
+
581
+ 权重
582
+
583
+ :param weight: The weight of this RoleDeployMeta.
584
+ :type weight: str
585
+ """
586
+ self._weight = weight
587
+
588
+ def to_dict(self):
589
+ """Returns the model properties as a dict"""
590
+ result = {}
591
+
592
+ for attr, _ in six.iteritems(self.openapi_types):
593
+ value = getattr(self, attr)
594
+ if isinstance(value, list):
595
+ result[attr] = list(map(
596
+ lambda x: x.to_dict() if hasattr(x, "to_dict") else x,
597
+ value
598
+ ))
599
+ elif hasattr(value, "to_dict"):
600
+ result[attr] = value.to_dict()
601
+ elif isinstance(value, dict):
602
+ result[attr] = dict(map(
603
+ lambda item: (item[0], item[1].to_dict())
604
+ if hasattr(item[1], "to_dict") else item,
605
+ value.items()
606
+ ))
607
+ else:
608
+ if attr in self.sensitive_list:
609
+ result[attr] = "****"
610
+ else:
611
+ result[attr] = value
612
+
613
+ return result
614
+
615
+ def to_str(self):
616
+ """Returns the string representation of the model"""
617
+ import simplejson as json
618
+ if six.PY2:
619
+ import sys
620
+ reload(sys)
621
+ sys.setdefaultencoding("utf-8")
622
+ return json.dumps(sanitize_for_serialization(self), ensure_ascii=False)
623
+
624
+ def __repr__(self):
625
+ """For `print`"""
626
+ return self.to_str()
627
+
628
+ def __eq__(self, other):
629
+ """Returns true if both objects are equal"""
630
+ if not isinstance(other, RoleDeployMeta):
631
+ return False
632
+
633
+ return self.__dict__ == other.__dict__
634
+
635
+ def __ne__(self, other):
636
+ """Returns true if both objects are not equal"""
637
+ return not self == other