aliyun-log-python-sdk 0.9.2__tar.gz → 0.9.3__tar.gz

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 (125) hide show
  1. {aliyun-log-python-sdk-0.9.2/aliyun_log_python_sdk.egg-info → aliyun-log-python-sdk-0.9.3}/PKG-INFO +1 -1
  2. {aliyun-log-python-sdk-0.9.2 → aliyun-log-python-sdk-0.9.3}/aliyun/log/auth.py +24 -15
  3. aliyun-log-python-sdk-0.9.3/aliyun/log/credentials.py +33 -0
  4. {aliyun-log-python-sdk-0.9.2 → aliyun-log-python-sdk-0.9.3}/aliyun/log/getlogsresponse.py +13 -12
  5. {aliyun-log-python-sdk-0.9.2 → aliyun-log-python-sdk-0.9.3}/aliyun/log/index_config.py +1 -1
  6. aliyun-log-python-sdk-0.9.3/aliyun/log/log_logs_pb2.py +33 -0
  7. aliyun-log-python-sdk-0.9.3/aliyun/log/log_logs_raw_pb2.py +33 -0
  8. {aliyun-log-python-sdk-0.9.2 → aliyun-log-python-sdk-0.9.3}/aliyun/log/logclient.py +11 -6
  9. {aliyun-log-python-sdk-0.9.2 → aliyun-log-python-sdk-0.9.3}/aliyun/log/version.py +1 -1
  10. {aliyun-log-python-sdk-0.9.2 → aliyun-log-python-sdk-0.9.3/aliyun_log_python_sdk.egg-info}/PKG-INFO +1 -1
  11. {aliyun-log-python-sdk-0.9.2 → aliyun-log-python-sdk-0.9.3}/aliyun_log_python_sdk.egg-info/SOURCES.txt +1 -0
  12. aliyun-log-python-sdk-0.9.2/aliyun/log/log_logs_pb2.py +0 -297
  13. aliyun-log-python-sdk-0.9.2/aliyun/log/log_logs_raw_pb2.py +0 -297
  14. {aliyun-log-python-sdk-0.9.2 → aliyun-log-python-sdk-0.9.3}/LICENSE +0 -0
  15. {aliyun-log-python-sdk-0.9.2 → aliyun-log-python-sdk-0.9.3}/README.md +0 -0
  16. {aliyun-log-python-sdk-0.9.2 → aliyun-log-python-sdk-0.9.3}/aliyun/__init__.py +0 -0
  17. {aliyun-log-python-sdk-0.9.2 → aliyun-log-python-sdk-0.9.3}/aliyun/log/__init__.py +0 -0
  18. {aliyun-log-python-sdk-0.9.2 → aliyun-log-python-sdk-0.9.3}/aliyun/log/acl_config.py +0 -0
  19. {aliyun-log-python-sdk-0.9.2 → aliyun-log-python-sdk-0.9.3}/aliyun/log/acl_response.py +0 -0
  20. {aliyun-log-python-sdk-0.9.2 → aliyun-log-python-sdk-0.9.3}/aliyun/log/common_response.py +0 -0
  21. {aliyun-log-python-sdk-0.9.2 → aliyun-log-python-sdk-0.9.3}/aliyun/log/consumer/__init__.py +0 -0
  22. {aliyun-log-python-sdk-0.9.2 → aliyun-log-python-sdk-0.9.3}/aliyun/log/consumer/checkpoint_tracker.py +0 -0
  23. {aliyun-log-python-sdk-0.9.2 → aliyun-log-python-sdk-0.9.3}/aliyun/log/consumer/config.py +0 -0
  24. {aliyun-log-python-sdk-0.9.2 → aliyun-log-python-sdk-0.9.3}/aliyun/log/consumer/consumer_client.py +0 -0
  25. {aliyun-log-python-sdk-0.9.2 → aliyun-log-python-sdk-0.9.3}/aliyun/log/consumer/exceptions.py +0 -0
  26. {aliyun-log-python-sdk-0.9.2 → aliyun-log-python-sdk-0.9.3}/aliyun/log/consumer/fetched_log_group.py +0 -0
  27. {aliyun-log-python-sdk-0.9.2 → aliyun-log-python-sdk-0.9.3}/aliyun/log/consumer/heart_beat.py +0 -0
  28. {aliyun-log-python-sdk-0.9.2 → aliyun-log-python-sdk-0.9.3}/aliyun/log/consumer/shard_worker.py +0 -0
  29. {aliyun-log-python-sdk-0.9.2 → aliyun-log-python-sdk-0.9.3}/aliyun/log/consumer/tasks.py +0 -0
  30. {aliyun-log-python-sdk-0.9.2 → aliyun-log-python-sdk-0.9.3}/aliyun/log/consumer/worker.py +0 -0
  31. {aliyun-log-python-sdk-0.9.2 → aliyun-log-python-sdk-0.9.3}/aliyun/log/consumer_group_request.py +0 -0
  32. {aliyun-log-python-sdk-0.9.2 → aliyun-log-python-sdk-0.9.3}/aliyun/log/consumer_group_response.py +0 -0
  33. {aliyun-log-python-sdk-0.9.2 → aliyun-log-python-sdk-0.9.3}/aliyun/log/cursor_response.py +0 -0
  34. {aliyun-log-python-sdk-0.9.2 → aliyun-log-python-sdk-0.9.3}/aliyun/log/cursor_time_response.py +0 -0
  35. {aliyun-log-python-sdk-0.9.2 → aliyun-log-python-sdk-0.9.3}/aliyun/log/es_migration/__init__.py +0 -0
  36. {aliyun-log-python-sdk-0.9.2 → aliyun-log-python-sdk-0.9.3}/aliyun/log/es_migration/doc_logitem_converter.py +0 -0
  37. {aliyun-log-python-sdk-0.9.2 → aliyun-log-python-sdk-0.9.3}/aliyun/log/es_migration/index_logstore_mappings.py +0 -0
  38. {aliyun-log-python-sdk-0.9.2 → aliyun-log-python-sdk-0.9.3}/aliyun/log/es_migration/mapping_index_converter.py +0 -0
  39. {aliyun-log-python-sdk-0.9.2 → aliyun-log-python-sdk-0.9.3}/aliyun/log/es_migration/migration_log.py +0 -0
  40. {aliyun-log-python-sdk-0.9.2 → aliyun-log-python-sdk-0.9.3}/aliyun/log/es_migration/migration_manager.py +0 -0
  41. {aliyun-log-python-sdk-0.9.2 → aliyun-log-python-sdk-0.9.3}/aliyun/log/es_migration/migration_response.py +0 -0
  42. {aliyun-log-python-sdk-0.9.2 → aliyun-log-python-sdk-0.9.3}/aliyun/log/es_migration/migration_task.py +0 -0
  43. {aliyun-log-python-sdk-0.9.2 → aliyun-log-python-sdk-0.9.3}/aliyun/log/es_migration/util.py +0 -0
  44. {aliyun-log-python-sdk-0.9.2 → aliyun-log-python-sdk-0.9.3}/aliyun/log/etl_config_response.py +0 -0
  45. {aliyun-log-python-sdk-0.9.2 → aliyun-log-python-sdk-0.9.3}/aliyun/log/etl_core/__init__.py +0 -0
  46. {aliyun-log-python-sdk-0.9.2 → aliyun-log-python-sdk-0.9.3}/aliyun/log/etl_core/config_parser.py +0 -0
  47. {aliyun-log-python-sdk-0.9.2 → aliyun-log-python-sdk-0.9.3}/aliyun/log/etl_core/etl_util.py +0 -0
  48. {aliyun-log-python-sdk-0.9.2 → aliyun-log-python-sdk-0.9.3}/aliyun/log/etl_core/exceptions.py +0 -0
  49. {aliyun-log-python-sdk-0.9.2 → aliyun-log-python-sdk-0.9.3}/aliyun/log/etl_core/restrict_config_parser.py +0 -0
  50. {aliyun-log-python-sdk-0.9.2 → aliyun-log-python-sdk-0.9.3}/aliyun/log/etl_core/runner.py +0 -0
  51. {aliyun-log-python-sdk-0.9.2 → aliyun-log-python-sdk-0.9.3}/aliyun/log/etl_core/settings.py +0 -0
  52. {aliyun-log-python-sdk-0.9.2 → aliyun-log-python-sdk-0.9.3}/aliyun/log/etl_core/trans_comp/__init__.py +0 -0
  53. {aliyun-log-python-sdk-0.9.2 → aliyun-log-python-sdk-0.9.3}/aliyun/log/etl_core/trans_comp/trans_base.py +0 -0
  54. {aliyun-log-python-sdk-0.9.2 → aliyun-log-python-sdk-0.9.3}/aliyun/log/etl_core/trans_comp/trans_csv.py +0 -0
  55. {aliyun-log-python-sdk-0.9.2 → aliyun-log-python-sdk-0.9.3}/aliyun/log/etl_core/trans_comp/trans_json.py +0 -0
  56. {aliyun-log-python-sdk-0.9.2 → aliyun-log-python-sdk-0.9.3}/aliyun/log/etl_core/trans_comp/trans_kv.py +0 -0
  57. {aliyun-log-python-sdk-0.9.2 → aliyun-log-python-sdk-0.9.3}/aliyun/log/etl_core/trans_comp/trans_lookup.py +0 -0
  58. {aliyun-log-python-sdk-0.9.2 → aliyun-log-python-sdk-0.9.3}/aliyun/log/etl_core/trans_comp/trans_mv.py +0 -0
  59. {aliyun-log-python-sdk-0.9.2 → aliyun-log-python-sdk-0.9.3}/aliyun/log/etl_core/trans_comp/trans_regex.py +0 -0
  60. {aliyun-log-python-sdk-0.9.2 → aliyun-log-python-sdk-0.9.3}/aliyun/log/etl_core/trans_comp/trans_set_field.py +0 -0
  61. {aliyun-log-python-sdk-0.9.2 → aliyun-log-python-sdk-0.9.3}/aliyun/log/etl_core/transform/__init__.py +0 -0
  62. {aliyun-log-python-sdk-0.9.2 → aliyun-log-python-sdk-0.9.3}/aliyun/log/etl_core/transform/condition_list.py +0 -0
  63. {aliyun-log-python-sdk-0.9.2 → aliyun-log-python-sdk-0.9.3}/aliyun/log/etl_core/transform/condition_transform.py +0 -0
  64. {aliyun-log-python-sdk-0.9.2 → aliyun-log-python-sdk-0.9.3}/aliyun/log/etl_core/transform/condition_util.py +0 -0
  65. {aliyun-log-python-sdk-0.9.2 → aliyun-log-python-sdk-0.9.3}/aliyun/log/etl_core/transform/transform_base.py +0 -0
  66. {aliyun-log-python-sdk-0.9.2 → aliyun-log-python-sdk-0.9.3}/aliyun/log/etl_core/transform/transform_list.py +0 -0
  67. {aliyun-log-python-sdk-0.9.2 → aliyun-log-python-sdk-0.9.3}/aliyun/log/etl_core/transform/transform_meta.py +0 -0
  68. {aliyun-log-python-sdk-0.9.2 → aliyun-log-python-sdk-0.9.3}/aliyun/log/export_response.py +0 -0
  69. {aliyun-log-python-sdk-0.9.2 → aliyun-log-python-sdk-0.9.3}/aliyun/log/ext/__init__.py +0 -0
  70. {aliyun-log-python-sdk-0.9.2 → aliyun-log-python-sdk-0.9.3}/aliyun/log/ext/jupyter_magic.py +0 -0
  71. {aliyun-log-python-sdk-0.9.2 → aliyun-log-python-sdk-0.9.3}/aliyun/log/ext/syslogclient.py +0 -0
  72. {aliyun-log-python-sdk-0.9.2 → aliyun-log-python-sdk-0.9.3}/aliyun/log/external_store_config.py +0 -0
  73. {aliyun-log-python-sdk-0.9.2 → aliyun-log-python-sdk-0.9.3}/aliyun/log/external_store_config_response.py +0 -0
  74. {aliyun-log-python-sdk-0.9.2 → aliyun-log-python-sdk-0.9.3}/aliyun/log/getcontextlogsresponse.py +0 -0
  75. {aliyun-log-python-sdk-0.9.2 → aliyun-log-python-sdk-0.9.3}/aliyun/log/gethistogramsrequest.py +0 -0
  76. {aliyun-log-python-sdk-0.9.2 → aliyun-log-python-sdk-0.9.3}/aliyun/log/gethistogramsresponse.py +0 -0
  77. {aliyun-log-python-sdk-0.9.2 → aliyun-log-python-sdk-0.9.3}/aliyun/log/getlogsrequest.py +0 -0
  78. {aliyun-log-python-sdk-0.9.2 → aliyun-log-python-sdk-0.9.3}/aliyun/log/histogram.py +0 -0
  79. {aliyun-log-python-sdk-0.9.2 → aliyun-log-python-sdk-0.9.3}/aliyun/log/index_config_response.py +0 -0
  80. {aliyun-log-python-sdk-0.9.2 → aliyun-log-python-sdk-0.9.3}/aliyun/log/ingestion_response.py +0 -0
  81. {aliyun-log-python-sdk-0.9.2 → aliyun-log-python-sdk-0.9.3}/aliyun/log/job.py +0 -0
  82. {aliyun-log-python-sdk-0.9.2 → aliyun-log-python-sdk-0.9.3}/aliyun/log/listlogstoresrequest.py +0 -0
  83. {aliyun-log-python-sdk-0.9.2 → aliyun-log-python-sdk-0.9.3}/aliyun/log/listlogstoresresponse.py +0 -0
  84. {aliyun-log-python-sdk-0.9.2 → aliyun-log-python-sdk-0.9.3}/aliyun/log/listtopicsrequest.py +0 -0
  85. {aliyun-log-python-sdk-0.9.2 → aliyun-log-python-sdk-0.9.3}/aliyun/log/listtopicsresponse.py +0 -0
  86. {aliyun-log-python-sdk-0.9.2 → aliyun-log-python-sdk-0.9.3}/aliyun/log/logclient_core.py +0 -0
  87. {aliyun-log-python-sdk-0.9.2 → aliyun-log-python-sdk-0.9.3}/aliyun/log/logclient_operator.py +0 -0
  88. {aliyun-log-python-sdk-0.9.2 → aliyun-log-python-sdk-0.9.3}/aliyun/log/logexception.py +0 -0
  89. {aliyun-log-python-sdk-0.9.2 → aliyun-log-python-sdk-0.9.3}/aliyun/log/logger_hanlder.py +0 -0
  90. {aliyun-log-python-sdk-0.9.2 → aliyun-log-python-sdk-0.9.3}/aliyun/log/logitem.py +0 -0
  91. {aliyun-log-python-sdk-0.9.2 → aliyun-log-python-sdk-0.9.3}/aliyun/log/logrequest.py +0 -0
  92. {aliyun-log-python-sdk-0.9.2 → aliyun-log-python-sdk-0.9.3}/aliyun/log/logresponse.py +0 -0
  93. {aliyun-log-python-sdk-0.9.2 → aliyun-log-python-sdk-0.9.3}/aliyun/log/logstore_config_response.py +0 -0
  94. {aliyun-log-python-sdk-0.9.2 → aliyun-log-python-sdk-0.9.3}/aliyun/log/logtail_config_detail.py +0 -0
  95. {aliyun-log-python-sdk-0.9.2 → aliyun-log-python-sdk-0.9.3}/aliyun/log/logtail_config_response.py +0 -0
  96. {aliyun-log-python-sdk-0.9.2 → aliyun-log-python-sdk-0.9.3}/aliyun/log/machine_group_detail.py +0 -0
  97. {aliyun-log-python-sdk-0.9.2 → aliyun-log-python-sdk-0.9.3}/aliyun/log/machinegroup_response.py +0 -0
  98. {aliyun-log-python-sdk-0.9.2 → aliyun-log-python-sdk-0.9.3}/aliyun/log/odps_sink.py +0 -0
  99. {aliyun-log-python-sdk-0.9.2 → aliyun-log-python-sdk-0.9.3}/aliyun/log/oss_sink.py +0 -0
  100. {aliyun-log-python-sdk-0.9.2 → aliyun-log-python-sdk-0.9.3}/aliyun/log/pluralize.py +0 -0
  101. {aliyun-log-python-sdk-0.9.2 → aliyun-log-python-sdk-0.9.3}/aliyun/log/project_response.py +0 -0
  102. {aliyun-log-python-sdk-0.9.2 → aliyun-log-python-sdk-0.9.3}/aliyun/log/pulllog_response.py +0 -0
  103. {aliyun-log-python-sdk-0.9.2 → aliyun-log-python-sdk-0.9.3}/aliyun/log/putlogsrequest.py +0 -0
  104. {aliyun-log-python-sdk-0.9.2 → aliyun-log-python-sdk-0.9.3}/aliyun/log/putlogsresponse.py +0 -0
  105. {aliyun-log-python-sdk-0.9.2 → aliyun-log-python-sdk-0.9.3}/aliyun/log/queriedlog.py +0 -0
  106. {aliyun-log-python-sdk-0.9.2 → aliyun-log-python-sdk-0.9.3}/aliyun/log/resource_params.py +0 -0
  107. {aliyun-log-python-sdk-0.9.2 → aliyun-log-python-sdk-0.9.3}/aliyun/log/resource_response.py +0 -0
  108. {aliyun-log-python-sdk-0.9.2 → aliyun-log-python-sdk-0.9.3}/aliyun/log/scheduled_sql.py +0 -0
  109. {aliyun-log-python-sdk-0.9.2 → aliyun-log-python-sdk-0.9.3}/aliyun/log/scheduled_sql_response.py +0 -0
  110. {aliyun-log-python-sdk-0.9.2 → aliyun-log-python-sdk-0.9.3}/aliyun/log/shard_response.py +0 -0
  111. {aliyun-log-python-sdk-0.9.2 → aliyun-log-python-sdk-0.9.3}/aliyun/log/shipper_config.py +0 -0
  112. {aliyun-log-python-sdk-0.9.2 → aliyun-log-python-sdk-0.9.3}/aliyun/log/shipper_response.py +0 -0
  113. {aliyun-log-python-sdk-0.9.2 → aliyun-log-python-sdk-0.9.3}/aliyun/log/sink.py +0 -0
  114. {aliyun-log-python-sdk-0.9.2 → aliyun-log-python-sdk-0.9.3}/aliyun/log/sql_instance_response.py +0 -0
  115. {aliyun-log-python-sdk-0.9.2 → aliyun-log-python-sdk-0.9.3}/aliyun/log/substore_config_response.py +0 -0
  116. {aliyun-log-python-sdk-0.9.2 → aliyun-log-python-sdk-0.9.3}/aliyun/log/tag_response.py +0 -0
  117. {aliyun-log-python-sdk-0.9.2 → aliyun-log-python-sdk-0.9.3}/aliyun/log/topostore_params.py +0 -0
  118. {aliyun-log-python-sdk-0.9.2 → aliyun-log-python-sdk-0.9.3}/aliyun/log/topostore_response.py +0 -0
  119. {aliyun-log-python-sdk-0.9.2 → aliyun-log-python-sdk-0.9.3}/aliyun/log/util.py +0 -0
  120. {aliyun-log-python-sdk-0.9.2 → aliyun-log-python-sdk-0.9.3}/aliyun_log_python_sdk.egg-info/dependency_links.txt +0 -0
  121. {aliyun-log-python-sdk-0.9.2 → aliyun-log-python-sdk-0.9.3}/aliyun_log_python_sdk.egg-info/requires.txt +0 -0
  122. {aliyun-log-python-sdk-0.9.2 → aliyun-log-python-sdk-0.9.3}/aliyun_log_python_sdk.egg-info/top_level.txt +0 -0
  123. {aliyun-log-python-sdk-0.9.2 → aliyun-log-python-sdk-0.9.3}/setup.cfg +0 -0
  124. {aliyun-log-python-sdk-0.9.2 → aliyun-log-python-sdk-0.9.3}/setup.py +0 -0
  125. {aliyun-log-python-sdk-0.9.2 → aliyun-log-python-sdk-0.9.3}/tests/test_alert.py +0 -0
@@ -1,6 +1,6 @@
1
1
  Metadata-Version: 2.1
2
2
  Name: aliyun-log-python-sdk
3
- Version: 0.9.2
3
+ Version: 0.9.3
4
4
  Summary: Aliyun log service Python client SDK
5
5
  Home-page: https://github.com/aliyun/aliyun-log-python-sdk
6
6
  Author: Aliyun
@@ -32,17 +32,16 @@ AUTH_VERSION_1 = 'v1'
32
32
  AUTH_VERSION_4 = 'v4'
33
33
 
34
34
 
35
- def make_auth(access_key_id, access_key_secret, auth_version=AUTH_VERSION_1, region=''):
35
+ def make_auth(credentials_provider, auth_version=AUTH_VERSION_1, region=''):
36
36
  if auth_version == AUTH_VERSION_4:
37
- return AuthV4(access_key_id, access_key_secret, region)
37
+ return AuthV4(credentials_provider, region)
38
38
  else:
39
- return AuthV1(access_key_id, access_key_secret)
39
+ return AuthV1(credentials_provider)
40
40
 
41
41
 
42
42
  class AuthBase(object):
43
- def __init__(self, access_key_id, access_key_secret):
44
- self.access_key_id = access_key_id
45
- self.access_key_secret = access_key_secret
43
+ def __init__(self, credentials_provider):
44
+ self.credentials_provider = credentials_provider
46
45
 
47
46
  def sign_request(self, method, resource, params, headers, body):
48
47
  pass
@@ -50,8 +49,8 @@ class AuthBase(object):
50
49
 
51
50
  class AuthV1(AuthBase):
52
51
 
53
- def __init__(self, access_key_id, access_key_secret):
54
- AuthBase.__init__(self, access_key_id, access_key_secret)
52
+ def __init__(self, credentials_provider):
53
+ AuthBase.__init__(self, credentials_provider)
55
54
 
56
55
  @staticmethod
57
56
  def _getGMT():
@@ -62,12 +61,16 @@ class AuthV1(AuthBase):
62
61
  return datetime.utcnow().strftime('%a, %d %b %Y %H:%M:%S GMT')
63
62
 
64
63
  def sign_request(self, method, resource, params, headers, body):
64
+ credentials = self.credentials_provider.get_credentials()
65
+ if credentials.get_security_token():
66
+ headers['x-acs-security-token'] = credentials.get_security_token()
67
+
65
68
  headers['x-log-signaturemethod'] = 'hmac-sha1'
66
69
  headers['Date'] = self._getGMT()
67
70
 
68
71
  if body:
69
72
  headers['Content-MD5'] = Util.cal_md5(body)
70
- if not self.access_key_secret:
73
+ if not credentials.get_access_key_secret():
71
74
  return six.b('')
72
75
  content = method + '\n'
73
76
  if 'Content-MD5' in headers:
@@ -79,14 +82,14 @@ class AuthV1(AuthBase):
79
82
  content += headers['Date'] + '\n'
80
83
  content += Util.canonicalized_log_headers(headers)
81
84
  content += Util.canonicalized_resource(resource, params)
82
- signature = Util.hmac_sha1(content, self.access_key_secret)
83
- headers['Authorization'] = 'LOG ' + self.access_key_id + ':' + signature
85
+ signature = Util.hmac_sha1(content, credentials.get_access_key_secret())
86
+ headers['Authorization'] = 'LOG ' + credentials.get_access_key_id() + ':' + signature
84
87
  headers['x-log-date'] = headers['Date'] # bypass some proxy doesn't allow "Date" in header issue.
85
88
 
86
89
 
87
90
  class AuthV4(AuthBase):
88
- def __init__(self, access_key_id, access_key_secret, region):
89
- AuthBase.__init__(self, access_key_id, access_key_secret)
91
+ def __init__(self, credentials_provider, region):
92
+ AuthBase.__init__(self, credentials_provider)
90
93
  self._region = region
91
94
 
92
95
  def sign_request(self, method, resource, params, headers, body):
@@ -94,6 +97,11 @@ class AuthV4(AuthBase):
94
97
  headers['Authorization'] = self._do_sign_request(method, resource, params, headers, body, current_time)
95
98
 
96
99
  def _do_sign_request(self, method, resource, params, headers, body, current_time):
100
+ credentials = self.credentials_provider.get_credentials()
101
+
102
+ if credentials.get_security_token():
103
+ headers['x-acs-security-token'] = credentials.get_security_token()
104
+
97
105
  content_sha256 = sha256(body).hexdigest() \
98
106
  if body else 'e3b0c44298fc1c149afbf4c8996fb92427ae41e4649b934ca495991b7852b855'
99
107
  headers['x-log-content-sha256'] = content_sha256
@@ -119,8 +127,9 @@ class AuthV4(AuthBase):
119
127
  + current_time + '\n' \
120
128
  + scope + '\n' \
121
129
  + sha256(canonical_request.encode('utf-8')).hexdigest()
122
- signature = self.build_sign_key(self.access_key_secret, self._region, current_date, string_to_sign)
123
- return 'SLS4-HMAC-SHA256 Credential=%s/%s,Signature=%s' % (self.access_key_id, scope, signature)
130
+ signature = self.build_sign_key(credentials.get_access_key_secret(),
131
+ self._region, current_date, string_to_sign)
132
+ return 'SLS4-HMAC-SHA256 Credential=%s/%s,Signature=%s' % (credentials.get_access_key_id(), scope, signature)
124
133
 
125
134
  @staticmethod
126
135
  def build_canonical_request(method, resource, params, canonical_headers, signed_headers, hashed_payload):
@@ -0,0 +1,33 @@
1
+ #!/usr/bin/env python
2
+ # encoding: utf-8
3
+
4
+ # Copyright (C) Alibaba Cloud Computing
5
+ # All rights reserved.
6
+
7
+ class Credentials(object):
8
+ def __init__(self, access_key_id, access_key_secret, security_token=None):
9
+ self.access_key_id = access_key_id
10
+ self.access_key_secret = access_key_secret
11
+ self.security_token = security_token
12
+
13
+ def get_access_key_id(self):
14
+ return self.access_key_id
15
+
16
+ def get_access_key_secret(self):
17
+ return self.access_key_secret
18
+
19
+ def get_security_token(self):
20
+ return self.security_token
21
+
22
+
23
+ class CredentialsProvider(object):
24
+ def get_credentials(self):
25
+ return
26
+
27
+
28
+ class StaticCredentialsProvider(CredentialsProvider):
29
+ def __init__(self, access_key_id="", access_key_secret="", security_token=""):
30
+ self.credentials = Credentials(access_key_id, access_key_secret, security_token)
31
+
32
+ def get_credentials(self):
33
+ return self.credentials
@@ -63,18 +63,19 @@ class GetLogsResponse(LogResponse):
63
63
  }
64
64
  # parse query info
65
65
  query_info_str = Util.h_v_td(header, 'x-log-query-info', '')
66
- query_info = json.loads(query_info_str)
67
- meta_dict['mode'] = Util.h_v_td(query_info, 'mode', 0)
68
- query_mode = GetLogsResponse.QueryMode(meta_dict['mode'])
69
- if query_mode in (GetLogsResponse.QueryMode.SCAN, GetLogsResponse.QueryMode.SCAN_SQL):
70
- meta_dict['scanBytes'] = Util.h_v_td(query_info, 'scanBytes', 0)
71
- if query_mode in (GetLogsResponse.QueryMode.PHRASE, GetLogsResponse.QueryMode.SCAN):
72
- scan_query_info = Util.h_v_td(query_info, 'phraseQueryInfo', dict())
73
- meta_dict['phraseQueryInfo'] = {
74
- 'scanAll': (Util.h_v_td(scan_query_info, 'scanAll', 'false') != 'false'),
75
- 'beginOffset': int(Util.h_v_td(scan_query_info, 'beginOffset', '0')),
76
- 'endOffset': int(Util.h_v_td(scan_query_info, 'endOffset', '0'))
77
- }
66
+ if query_info_str != '':
67
+ query_info = json.loads(query_info_str)
68
+ meta_dict['mode'] = Util.h_v_td(query_info, 'mode', 0)
69
+ query_mode = GetLogsResponse.QueryMode(meta_dict['mode'])
70
+ if query_mode in (GetLogsResponse.QueryMode.SCAN, GetLogsResponse.QueryMode.SCAN_SQL):
71
+ meta_dict['scanBytes'] = Util.h_v_td(query_info, 'scanBytes', 0)
72
+ if query_mode in (GetLogsResponse.QueryMode.PHRASE, GetLogsResponse.QueryMode.SCAN):
73
+ scan_query_info = Util.h_v_td(query_info, 'phraseQueryInfo', dict())
74
+ meta_dict['phraseQueryInfo'] = {
75
+ 'scanAll': (Util.h_v_td(scan_query_info, 'scanAll', 'false') != 'false'),
76
+ 'beginOffset': int(Util.h_v_td(scan_query_info, 'beginOffset', '0')),
77
+ 'endOffset': int(Util.h_v_td(scan_query_info, 'endOffset', '0'))
78
+ }
78
79
 
79
80
  return GetLogsResponse({
80
81
  "meta": meta_dict,
@@ -193,7 +193,7 @@ class IndexLineConfig(object):
193
193
  def from_json(self, json_value):
194
194
  self.token_list = json_value["token"]
195
195
  self.case_sensitive = bool(json_value.get("caseSensitive", False))
196
- self.chn = bool(json_value["caseSensitive"]) if "caseSensitive" in json_value else None
196
+ self.chn = bool(json_value["chn"]) if "chn" in json_value else None
197
197
 
198
198
 
199
199
  class IndexConfig(object):
@@ -0,0 +1,33 @@
1
+ # -*- coding: utf-8 -*-
2
+ # Generated by the protocol buffer compiler. DO NOT EDIT!
3
+ # source: log_logs.proto
4
+ """Generated protocol buffer code."""
5
+ from google.protobuf.internal import builder as _builder
6
+ from google.protobuf import descriptor as _descriptor
7
+ from google.protobuf import descriptor_pool as _descriptor_pool
8
+ from google.protobuf import symbol_database as _symbol_database
9
+ # @@protoc_insertion_point(imports)
10
+
11
+ _sym_db = _symbol_database.Default()
12
+
13
+
14
+
15
+
16
+ DESCRIPTOR = _descriptor_pool.Default().AddSerializedFile(b'\n\x0elog_logs.proto\"k\n\x03Log\x12\x0c\n\x04Time\x18\x01 \x02(\r\x12\x1e\n\x08\x43ontents\x18\x02 \x03(\x0b\x32\x0c.Log.Content\x12\x0f\n\x07Time_ns\x18\x04 \x01(\x07\x1a%\n\x07\x43ontent\x12\x0b\n\x03Key\x18\x01 \x02(\t\x12\r\n\x05Value\x18\x02 \x02(\t\"$\n\x06LogTag\x12\x0b\n\x03Key\x18\x01 \x02(\t\x12\r\n\x05Value\x18\x02 \x02(\t\"~\n\x08LogGroup\x12\x12\n\x04Logs\x18\x01 \x03(\x0b\x32\x04.Log\x12\x10\n\x08Reserved\x18\x02 \x01(\t\x12\r\n\x05Topic\x18\x03 \x01(\t\x12\x0e\n\x06Source\x18\x04 \x01(\t\x12\x13\n\x0bMachineUUID\x18\x05 \x01(\t\x12\x18\n\x07LogTags\x18\x06 \x03(\x0b\x32\x07.LogTag\",\n\x0cLogGroupList\x12\x1c\n\tLogGroups\x18\x01 \x03(\x0b\x32\t.LogGroup')
17
+
18
+ _builder.BuildMessageAndEnumDescriptors(DESCRIPTOR, globals())
19
+ _builder.BuildTopDescriptorsAndMessages(DESCRIPTOR, 'log_logs_pb2', globals())
20
+ if _descriptor._USE_C_DESCRIPTORS == False:
21
+
22
+ DESCRIPTOR._options = None
23
+ _LOG._serialized_start=18
24
+ _LOG._serialized_end=125
25
+ _LOG_CONTENT._serialized_start=88
26
+ _LOG_CONTENT._serialized_end=125
27
+ _LOGTAG._serialized_start=127
28
+ _LOGTAG._serialized_end=163
29
+ _LOGGROUP._serialized_start=165
30
+ _LOGGROUP._serialized_end=291
31
+ _LOGGROUPLIST._serialized_start=293
32
+ _LOGGROUPLIST._serialized_end=337
33
+ # @@protoc_insertion_point(module_scope)
@@ -0,0 +1,33 @@
1
+ # -*- coding: utf-8 -*-
2
+ # Generated by the protocol buffer compiler. DO NOT EDIT!
3
+ # source: log_logs_raw.proto
4
+ """Generated protocol buffer code."""
5
+ from google.protobuf.internal import builder as _builder
6
+ from google.protobuf import descriptor as _descriptor
7
+ from google.protobuf import descriptor_pool as _descriptor_pool
8
+ from google.protobuf import symbol_database as _symbol_database
9
+ # @@protoc_insertion_point(imports)
10
+
11
+ _sym_db = _symbol_database.Default()
12
+
13
+
14
+
15
+
16
+ DESCRIPTOR = _descriptor_pool.Default().AddSerializedFile(b'\n\x12log_logs_raw.proto\"q\n\x06LogRaw\x12\x0c\n\x04Time\x18\x01 \x02(\r\x12!\n\x08\x43ontents\x18\x02 \x03(\x0b\x32\x0f.LogRaw.Content\x12\x0f\n\x07Time_ns\x18\x04 \x01(\x07\x1a%\n\x07\x43ontent\x12\x0b\n\x03Key\x18\x01 \x02(\t\x12\r\n\x05Value\x18\x02 \x02(\x0c\"\'\n\tLogTagRaw\x12\x0b\n\x03Key\x18\x01 \x02(\t\x12\r\n\x05Value\x18\x02 \x02(\t\"\x87\x01\n\x0bLogGroupRaw\x12\x15\n\x04Logs\x18\x01 \x03(\x0b\x32\x07.LogRaw\x12\x10\n\x08Reserved\x18\x02 \x01(\t\x12\r\n\x05Topic\x18\x03 \x01(\t\x12\x0e\n\x06Source\x18\x04 \x01(\t\x12\x13\n\x0bMachineUUID\x18\x05 \x01(\t\x12\x1b\n\x07LogTags\x18\x06 \x03(\x0b\x32\n.LogTagRaw\"2\n\x0fLogGroupListRaw\x12\x1f\n\tLogGroups\x18\x01 \x03(\x0b\x32\x0c.LogGroupRaw')
17
+
18
+ _builder.BuildMessageAndEnumDescriptors(DESCRIPTOR, globals())
19
+ _builder.BuildTopDescriptorsAndMessages(DESCRIPTOR, 'log_logs_raw_pb2', globals())
20
+ if _descriptor._USE_C_DESCRIPTORS == False:
21
+
22
+ DESCRIPTOR._options = None
23
+ _LOGRAW._serialized_start=22
24
+ _LOGRAW._serialized_end=135
25
+ _LOGRAW_CONTENT._serialized_start=98
26
+ _LOGRAW_CONTENT._serialized_end=135
27
+ _LOGTAGRAW._serialized_start=137
28
+ _LOGTAGRAW._serialized_end=176
29
+ _LOGGROUPRAW._serialized_start=179
30
+ _LOGGROUPRAW._serialized_end=314
31
+ _LOGGROUPLISTRAW._serialized_start=316
32
+ _LOGGROUPLISTRAW._serialized_end=366
33
+ # @@protoc_insertion_point(module_scope)
@@ -12,6 +12,7 @@ import time
12
12
  import zlib
13
13
  from datetime import datetime
14
14
  import logging
15
+ from .credentials import StaticCredentialsProvider
15
16
  from .scheduled_sql import ScheduledSQLConfiguration
16
17
  from .scheduled_sql_response import *
17
18
  from itertools import cycle
@@ -154,8 +155,8 @@ class LogClient(object):
154
155
  __version__ = API_VERSION
155
156
  Version = __version__
156
157
 
157
- def __init__(self, endpoint, accessKeyId, accessKey, securityToken=None, source=None,
158
- auth_version=AUTH_VERSION_1, region=''):
158
+ def __init__(self, endpoint, accessKeyId=None, accessKey=None, securityToken=None, source=None,
159
+ auth_version=AUTH_VERSION_1, region='', credentials_provider=None):
159
160
  self._isRowIp = Util.is_row_ip(endpoint)
160
161
  self._setendpoint(endpoint)
161
162
  self._accessKeyId = accessKeyId
@@ -172,7 +173,11 @@ class LogClient(object):
172
173
  self._last_refresh = 0
173
174
  self._auth_version = auth_version
174
175
  self._region = region
175
- self._auth = make_auth(accessKeyId, accessKey, auth_version, region)
176
+ if credentials_provider is not None:
177
+ self._auth = make_auth(credentials_provider, auth_version, region)
178
+ else:
179
+ self._auth = make_auth(StaticCredentialsProvider(accessKeyId, accessKey, securityToken),
180
+ auth_version, region)
176
181
  self._get_logs_v2_enabled = True
177
182
 
178
183
  def _replace_credentials(self):
@@ -185,8 +190,8 @@ class LogClient(object):
185
190
  self._last_refresh = time.time()
186
191
  for tries in range(DEFAULT_REFRESH_RETRY_COUNT + 1):
187
192
  try:
188
- self._accessKeyId, self._accessKey, self._securityToken = self._credentials_auto_refresher()
189
- self._auth = make_auth(self._accessKeyId, self._accessKey, self._auth_version, self._region)
193
+ self._auth = make_auth(StaticCredentialsProvider(self._credentials_auto_refresher()),
194
+ self._auth_version, self._region)
190
195
  except Exception as ex:
191
196
  logger.error(
192
197
  "failed to call _credentials_auto_refresher to refresh credentials, details: {0}".format(str(ex)))
@@ -949,7 +954,7 @@ class LogClient(object):
949
954
  project = request.get_project()
950
955
  resource = "/logs"
951
956
  (resp, header) = self._send("GET", project, None, resource, params, headers)
952
- return GetLogsResponse(resp, header)
957
+ return GetLogsResponse._from_v1_resp(resp, header)
953
958
 
954
959
  def get_cursor(self, project_name, logstore_name, shard_id, start_time):
955
960
  """ Get cursor from log service for batch pull logs
@@ -1,4 +1,4 @@
1
- __version__ = '0.9.2'
1
+ __version__ = '0.9.3'
2
2
 
3
3
  import sys
4
4
  OS_VERSION = str(sys.platform)
@@ -1,6 +1,6 @@
1
1
  Metadata-Version: 2.1
2
2
  Name: aliyun-log-python-sdk
3
- Version: 0.9.2
3
+ Version: 0.9.3
4
4
  Summary: Aliyun log service Python client SDK
5
5
  Home-page: https://github.com/aliyun/aliyun-log-python-sdk
6
6
  Author: Aliyun
@@ -9,6 +9,7 @@ aliyun/log/auth.py
9
9
  aliyun/log/common_response.py
10
10
  aliyun/log/consumer_group_request.py
11
11
  aliyun/log/consumer_group_response.py
12
+ aliyun/log/credentials.py
12
13
  aliyun/log/cursor_response.py
13
14
  aliyun/log/cursor_time_response.py
14
15
  aliyun/log/etl_config_response.py
@@ -1,297 +0,0 @@
1
- # -*- coding: utf-8 -*-
2
- # Generated by the protocol buffer compiler. DO NOT EDIT!
3
- # source: log_logs.proto
4
- """Generated protocol buffer code."""
5
- from google.protobuf import descriptor as _descriptor
6
- from google.protobuf import message as _message
7
- from google.protobuf import reflection as _reflection
8
- from google.protobuf import symbol_database as _symbol_database
9
- # @@protoc_insertion_point(imports)
10
-
11
- _sym_db = _symbol_database.Default()
12
-
13
-
14
-
15
-
16
- DESCRIPTOR = _descriptor.FileDescriptor(
17
- name='log_logs.proto',
18
- package='',
19
- syntax='proto2',
20
- serialized_options=None,
21
- create_key=_descriptor._internal_create_key,
22
- serialized_pb=b'\n\x0elog_logs.proto\"k\n\x03Log\x12\x0c\n\x04Time\x18\x01 \x02(\r\x12\x1e\n\x08\x43ontents\x18\x02 \x03(\x0b\x32\x0c.Log.Content\x12\x0f\n\x07Time_ns\x18\x04 \x01(\x07\x1a%\n\x07\x43ontent\x12\x0b\n\x03Key\x18\x01 \x02(\t\x12\r\n\x05Value\x18\x02 \x02(\t\"$\n\x06LogTag\x12\x0b\n\x03Key\x18\x01 \x02(\t\x12\r\n\x05Value\x18\x02 \x02(\t\"~\n\x08LogGroup\x12\x12\n\x04Logs\x18\x01 \x03(\x0b\x32\x04.Log\x12\x10\n\x08Reserved\x18\x02 \x01(\t\x12\r\n\x05Topic\x18\x03 \x01(\t\x12\x0e\n\x06Source\x18\x04 \x01(\t\x12\x13\n\x0bMachineUUID\x18\x05 \x01(\t\x12\x18\n\x07LogTags\x18\x06 \x03(\x0b\x32\x07.LogTag\",\n\x0cLogGroupList\x12\x1c\n\tLogGroups\x18\x01 \x03(\x0b\x32\t.LogGroup'
23
- )
24
-
25
-
26
-
27
-
28
- _LOG_CONTENT = _descriptor.Descriptor(
29
- name='Content',
30
- full_name='Log.Content',
31
- filename=None,
32
- file=DESCRIPTOR,
33
- containing_type=None,
34
- create_key=_descriptor._internal_create_key,
35
- fields=[
36
- _descriptor.FieldDescriptor(
37
- name='Key', full_name='Log.Content.Key', index=0,
38
- number=1, type=9, cpp_type=9, label=2,
39
- has_default_value=False, default_value=b"".decode('utf-8'),
40
- message_type=None, enum_type=None, containing_type=None,
41
- is_extension=False, extension_scope=None,
42
- serialized_options=None, file=DESCRIPTOR, create_key=_descriptor._internal_create_key),
43
- _descriptor.FieldDescriptor(
44
- name='Value', full_name='Log.Content.Value', index=1,
45
- number=2, type=9, cpp_type=9, label=2,
46
- has_default_value=False, default_value=b"".decode('utf-8'),
47
- message_type=None, enum_type=None, containing_type=None,
48
- is_extension=False, extension_scope=None,
49
- serialized_options=None, file=DESCRIPTOR, create_key=_descriptor._internal_create_key),
50
- ],
51
- extensions=[
52
- ],
53
- nested_types=[],
54
- enum_types=[
55
- ],
56
- serialized_options=None,
57
- is_extendable=False,
58
- syntax='proto2',
59
- extension_ranges=[],
60
- oneofs=[
61
- ],
62
- serialized_start=88,
63
- serialized_end=125,
64
- )
65
-
66
- _LOG = _descriptor.Descriptor(
67
- name='Log',
68
- full_name='Log',
69
- filename=None,
70
- file=DESCRIPTOR,
71
- containing_type=None,
72
- create_key=_descriptor._internal_create_key,
73
- fields=[
74
- _descriptor.FieldDescriptor(
75
- name='Time', full_name='Log.Time', index=0,
76
- number=1, type=13, cpp_type=3, label=2,
77
- has_default_value=False, default_value=0,
78
- message_type=None, enum_type=None, containing_type=None,
79
- is_extension=False, extension_scope=None,
80
- serialized_options=None, file=DESCRIPTOR, create_key=_descriptor._internal_create_key),
81
- _descriptor.FieldDescriptor(
82
- name='Contents', full_name='Log.Contents', index=1,
83
- number=2, type=11, cpp_type=10, label=3,
84
- has_default_value=False, default_value=[],
85
- message_type=None, enum_type=None, containing_type=None,
86
- is_extension=False, extension_scope=None,
87
- serialized_options=None, file=DESCRIPTOR, create_key=_descriptor._internal_create_key),
88
- _descriptor.FieldDescriptor(
89
- name='Time_ns', full_name='Log.Time_ns', index=2,
90
- number=4, type=7, cpp_type=3, label=1,
91
- has_default_value=False, default_value=0,
92
- message_type=None, enum_type=None, containing_type=None,
93
- is_extension=False, extension_scope=None,
94
- serialized_options=None, file=DESCRIPTOR, create_key=_descriptor._internal_create_key),
95
- ],
96
- extensions=[
97
- ],
98
- nested_types=[_LOG_CONTENT, ],
99
- enum_types=[
100
- ],
101
- serialized_options=None,
102
- is_extendable=False,
103
- syntax='proto2',
104
- extension_ranges=[],
105
- oneofs=[
106
- ],
107
- serialized_start=18,
108
- serialized_end=125,
109
- )
110
-
111
-
112
- _LOGTAG = _descriptor.Descriptor(
113
- name='LogTag',
114
- full_name='LogTag',
115
- filename=None,
116
- file=DESCRIPTOR,
117
- containing_type=None,
118
- create_key=_descriptor._internal_create_key,
119
- fields=[
120
- _descriptor.FieldDescriptor(
121
- name='Key', full_name='LogTag.Key', index=0,
122
- number=1, type=9, cpp_type=9, label=2,
123
- has_default_value=False, default_value=b"".decode('utf-8'),
124
- message_type=None, enum_type=None, containing_type=None,
125
- is_extension=False, extension_scope=None,
126
- serialized_options=None, file=DESCRIPTOR, create_key=_descriptor._internal_create_key),
127
- _descriptor.FieldDescriptor(
128
- name='Value', full_name='LogTag.Value', index=1,
129
- number=2, type=9, cpp_type=9, label=2,
130
- has_default_value=False, default_value=b"".decode('utf-8'),
131
- message_type=None, enum_type=None, containing_type=None,
132
- is_extension=False, extension_scope=None,
133
- serialized_options=None, file=DESCRIPTOR, create_key=_descriptor._internal_create_key),
134
- ],
135
- extensions=[
136
- ],
137
- nested_types=[],
138
- enum_types=[
139
- ],
140
- serialized_options=None,
141
- is_extendable=False,
142
- syntax='proto2',
143
- extension_ranges=[],
144
- oneofs=[
145
- ],
146
- serialized_start=127,
147
- serialized_end=163,
148
- )
149
-
150
-
151
- _LOGGROUP = _descriptor.Descriptor(
152
- name='LogGroup',
153
- full_name='LogGroup',
154
- filename=None,
155
- file=DESCRIPTOR,
156
- containing_type=None,
157
- create_key=_descriptor._internal_create_key,
158
- fields=[
159
- _descriptor.FieldDescriptor(
160
- name='Logs', full_name='LogGroup.Logs', index=0,
161
- number=1, type=11, cpp_type=10, label=3,
162
- has_default_value=False, default_value=[],
163
- message_type=None, enum_type=None, containing_type=None,
164
- is_extension=False, extension_scope=None,
165
- serialized_options=None, file=DESCRIPTOR, create_key=_descriptor._internal_create_key),
166
- _descriptor.FieldDescriptor(
167
- name='Reserved', full_name='LogGroup.Reserved', index=1,
168
- number=2, type=9, cpp_type=9, label=1,
169
- has_default_value=False, default_value=b"".decode('utf-8'),
170
- message_type=None, enum_type=None, containing_type=None,
171
- is_extension=False, extension_scope=None,
172
- serialized_options=None, file=DESCRIPTOR, create_key=_descriptor._internal_create_key),
173
- _descriptor.FieldDescriptor(
174
- name='Topic', full_name='LogGroup.Topic', index=2,
175
- number=3, type=9, cpp_type=9, label=1,
176
- has_default_value=False, default_value=b"".decode('utf-8'),
177
- message_type=None, enum_type=None, containing_type=None,
178
- is_extension=False, extension_scope=None,
179
- serialized_options=None, file=DESCRIPTOR, create_key=_descriptor._internal_create_key),
180
- _descriptor.FieldDescriptor(
181
- name='Source', full_name='LogGroup.Source', index=3,
182
- number=4, type=9, cpp_type=9, label=1,
183
- has_default_value=False, default_value=b"".decode('utf-8'),
184
- message_type=None, enum_type=None, containing_type=None,
185
- is_extension=False, extension_scope=None,
186
- serialized_options=None, file=DESCRIPTOR, create_key=_descriptor._internal_create_key),
187
- _descriptor.FieldDescriptor(
188
- name='MachineUUID', full_name='LogGroup.MachineUUID', index=4,
189
- number=5, type=9, cpp_type=9, label=1,
190
- has_default_value=False, default_value=b"".decode('utf-8'),
191
- message_type=None, enum_type=None, containing_type=None,
192
- is_extension=False, extension_scope=None,
193
- serialized_options=None, file=DESCRIPTOR, create_key=_descriptor._internal_create_key),
194
- _descriptor.FieldDescriptor(
195
- name='LogTags', full_name='LogGroup.LogTags', index=5,
196
- number=6, type=11, cpp_type=10, label=3,
197
- has_default_value=False, default_value=[],
198
- message_type=None, enum_type=None, containing_type=None,
199
- is_extension=False, extension_scope=None,
200
- serialized_options=None, file=DESCRIPTOR, create_key=_descriptor._internal_create_key),
201
- ],
202
- extensions=[
203
- ],
204
- nested_types=[],
205
- enum_types=[
206
- ],
207
- serialized_options=None,
208
- is_extendable=False,
209
- syntax='proto2',
210
- extension_ranges=[],
211
- oneofs=[
212
- ],
213
- serialized_start=165,
214
- serialized_end=291,
215
- )
216
-
217
-
218
- _LOGGROUPLIST = _descriptor.Descriptor(
219
- name='LogGroupList',
220
- full_name='LogGroupList',
221
- filename=None,
222
- file=DESCRIPTOR,
223
- containing_type=None,
224
- create_key=_descriptor._internal_create_key,
225
- fields=[
226
- _descriptor.FieldDescriptor(
227
- name='LogGroups', full_name='LogGroupList.LogGroups', index=0,
228
- number=1, type=11, cpp_type=10, label=3,
229
- has_default_value=False, default_value=[],
230
- message_type=None, enum_type=None, containing_type=None,
231
- is_extension=False, extension_scope=None,
232
- serialized_options=None, file=DESCRIPTOR, create_key=_descriptor._internal_create_key),
233
- ],
234
- extensions=[
235
- ],
236
- nested_types=[],
237
- enum_types=[
238
- ],
239
- serialized_options=None,
240
- is_extendable=False,
241
- syntax='proto2',
242
- extension_ranges=[],
243
- oneofs=[
244
- ],
245
- serialized_start=293,
246
- serialized_end=337,
247
- )
248
-
249
- _LOG_CONTENT.containing_type = _LOG
250
- _LOG.fields_by_name['Contents'].message_type = _LOG_CONTENT
251
- _LOGGROUP.fields_by_name['Logs'].message_type = _LOG
252
- _LOGGROUP.fields_by_name['LogTags'].message_type = _LOGTAG
253
- _LOGGROUPLIST.fields_by_name['LogGroups'].message_type = _LOGGROUP
254
- DESCRIPTOR.message_types_by_name['Log'] = _LOG
255
- DESCRIPTOR.message_types_by_name['LogTag'] = _LOGTAG
256
- DESCRIPTOR.message_types_by_name['LogGroup'] = _LOGGROUP
257
- DESCRIPTOR.message_types_by_name['LogGroupList'] = _LOGGROUPLIST
258
- _sym_db.RegisterFileDescriptor(DESCRIPTOR)
259
-
260
- Log = _reflection.GeneratedProtocolMessageType('Log', (_message.Message,), {
261
-
262
- 'Content' : _reflection.GeneratedProtocolMessageType('Content', (_message.Message,), {
263
- 'DESCRIPTOR' : _LOG_CONTENT,
264
- '__module__' : 'log_logs_pb2'
265
- # @@protoc_insertion_point(class_scope:Log.Content)
266
- })
267
- ,
268
- 'DESCRIPTOR' : _LOG,
269
- '__module__' : 'log_logs_pb2'
270
- # @@protoc_insertion_point(class_scope:Log)
271
- })
272
- _sym_db.RegisterMessage(Log)
273
- _sym_db.RegisterMessage(Log.Content)
274
-
275
- LogTag = _reflection.GeneratedProtocolMessageType('LogTag', (_message.Message,), {
276
- 'DESCRIPTOR' : _LOGTAG,
277
- '__module__' : 'log_logs_pb2'
278
- # @@protoc_insertion_point(class_scope:LogTag)
279
- })
280
- _sym_db.RegisterMessage(LogTag)
281
-
282
- LogGroup = _reflection.GeneratedProtocolMessageType('LogGroup', (_message.Message,), {
283
- 'DESCRIPTOR' : _LOGGROUP,
284
- '__module__' : 'log_logs_pb2'
285
- # @@protoc_insertion_point(class_scope:LogGroup)
286
- })
287
- _sym_db.RegisterMessage(LogGroup)
288
-
289
- LogGroupList = _reflection.GeneratedProtocolMessageType('LogGroupList', (_message.Message,), {
290
- 'DESCRIPTOR' : _LOGGROUPLIST,
291
- '__module__' : 'log_logs_pb2'
292
- # @@protoc_insertion_point(class_scope:LogGroupList)
293
- })
294
- _sym_db.RegisterMessage(LogGroupList)
295
-
296
-
297
- # @@protoc_insertion_point(module_scope)