Use different API versions for different services

This commit is contained in:
Jinming Hu 2019-12-30 12:10:27 +08:00 коммит произвёл Vincent Jiang (LEI)
Родитель 868c703282
Коммит 033ca6b23b
28 изменённых файлов: 29 добавлений и 29 удалений

Просмотреть файл

@ -22,7 +22,7 @@ namespace azure { namespace storage_adls {
add_content_length(http, headers, m_length);
http.add_header(constants::header_user_agent, constants::header_value_user_agent);
add_ms_header(http, headers, constants::header_ms_date, get_ms_date(date_format::rfc_1123));
add_ms_header(http, headers, constants::header_ms_version, constants::header_value_storage_version);
add_ms_header(http, headers, constants::header_ms_version, constants::header_value_storage_blob_version);
account.credential()->sign_request(*this, http, url, headers);
}

Просмотреть файл

@ -21,7 +21,7 @@ namespace azure { namespace storage_adls {
add_content_length(http, headers, 0);
http.add_header(constants::header_user_agent, constants::header_value_user_agent);
add_ms_header(http, headers, constants::header_ms_date, get_ms_date(date_format::rfc_1123));
add_ms_header(http, headers, constants::header_ms_version, constants::header_value_storage_version);
add_ms_header(http, headers, constants::header_ms_version, constants::header_value_storage_blob_version);
account.credential()->sign_request(*this, http, url, headers);
}

Просмотреть файл

@ -21,7 +21,7 @@ namespace azure { namespace storage_adls {
add_content_length(http, headers, 0);
http.add_header(constants::header_user_agent, constants::header_value_user_agent);
add_ms_header(http, headers, constants::header_ms_date, get_ms_date(date_format::rfc_1123));
add_ms_header(http, headers, constants::header_ms_version, constants::header_value_storage_version);
add_ms_header(http, headers, constants::header_ms_version, constants::header_value_storage_blob_version);
account.credential()->sign_request(*this, http, url, headers);
}

Просмотреть файл

@ -21,7 +21,7 @@ namespace azure { namespace storage_adls {
storage_headers headers;
http.add_header(constants::header_user_agent, constants::header_value_user_agent);
add_ms_header(http, headers, constants::header_ms_date, get_ms_date(date_format::rfc_1123));
add_ms_header(http, headers, constants::header_ms_version, constants::header_value_storage_version);
add_ms_header(http, headers, constants::header_ms_version, constants::header_value_storage_blob_version);
account.credential()->sign_request(*this, http, url, headers);
}

Просмотреть файл

@ -22,7 +22,7 @@ namespace azure { namespace storage_adls {
add_content_length(http, headers, 0);
http.add_header(constants::header_user_agent, constants::header_value_user_agent);
add_ms_header(http, headers, constants::header_ms_date, get_ms_date(date_format::rfc_1123));
add_ms_header(http, headers, constants::header_ms_version, constants::header_value_storage_version);
add_ms_header(http, headers, constants::header_ms_version, constants::header_value_storage_blob_version);
account.credential()->sign_request(*this, http, url, headers);
}

Просмотреть файл

@ -20,7 +20,7 @@ namespace azure { namespace storage_adls {
storage_headers headers;
http.add_header(constants::header_user_agent, constants::header_value_user_agent);
add_ms_header(http, headers, constants::header_ms_date, get_ms_date(date_format::rfc_1123));
add_ms_header(http, headers, constants::header_ms_version, constants::header_value_storage_version);
add_ms_header(http, headers, constants::header_ms_version, constants::header_value_storage_blob_version);
account.credential()->sign_request(*this, http, url, headers);
}

Просмотреть файл

@ -24,7 +24,7 @@ namespace azure { namespace storage_adls {
storage_headers headers;
http.add_header(constants::header_user_agent, constants::header_value_user_agent);
add_ms_header(http, headers, constants::header_ms_date, get_ms_date(date_format::rfc_1123));
add_ms_header(http, headers, constants::header_ms_version, constants::header_value_storage_version);
add_ms_header(http, headers, constants::header_ms_version, constants::header_value_storage_blob_version);
account.credential()->sign_request(*this, http, url, headers);
}

Просмотреть файл

@ -20,7 +20,7 @@ namespace azure { namespace storage_adls {
add_content_length(http, headers, 0);
http.add_header(constants::header_user_agent, constants::header_value_user_agent);
add_ms_header(http, headers, constants::header_ms_date, get_ms_date(date_format::rfc_1123));
add_ms_header(http, headers, constants::header_ms_version, constants::header_value_storage_version);
add_ms_header(http, headers, constants::header_ms_version, constants::header_value_storage_blob_version);
add_ms_header(http, headers, constants::header_ms_rename_source, encode_url_path("/" + m_source_filesystem + "/" + m_source_path));
account.credential()->sign_request(*this, http, url, headers);

Просмотреть файл

@ -21,7 +21,7 @@ namespace azure { namespace storage_adls {
add_content_length(http, headers, 0);
http.add_header(constants::header_user_agent, constants::header_value_user_agent);
add_ms_header(http, headers, constants::header_ms_date, get_ms_date(date_format::rfc_1123));
add_ms_header(http, headers, constants::header_ms_version, constants::header_value_storage_version);
add_ms_header(http, headers, constants::header_ms_version, constants::header_value_storage_blob_version);
add_ms_header(http, headers, constants::header_ms_owner, m_acl.owner, true);
add_ms_header(http, headers, constants::header_ms_group, m_acl.group, true);
add_ms_header(http, headers, constants::header_ms_permissions, m_acl.permissions, true);

Просмотреть файл

@ -114,7 +114,7 @@ DAT(header_value_page_write_update, "update")
DAT(header_value_page_write_clear, "clear")
DAT(header_value_payload_format_nometadata, "application/json;odata=nometadata")
DAT(header_value_payload_format_fullmetadata, "application/json;odata=fullmetadata")
DAT(header_value_storage_version, "2018-11-09")
DAT(header_value_storage_blob_version, "2018-11-09")
DAT(header_value_user_agent, "azure-storage-cpplite/0.2.0")

Просмотреть файл

@ -33,7 +33,7 @@ namespace azure { namespace storage_lite {
h.add_header(constants::header_user_agent, constants::header_value_user_agent);
add_ms_header(h, headers, constants::header_ms_date, get_ms_date(date_format::rfc_1123));
add_ms_header(h, headers, constants::header_ms_version, constants::header_value_storage_version);
add_ms_header(h, headers, constants::header_ms_version, constants::header_value_storage_blob_version);
a.credential()->sign_request(r, h, url, headers);
}

Просмотреть файл

@ -33,7 +33,7 @@ namespace azure { namespace storage_lite {
h.add_header(constants::header_user_agent, constants::header_value_user_agent);
add_ms_header(h, headers, constants::header_ms_date, get_ms_date(date_format::rfc_1123));
add_ms_header(h, headers, constants::header_ms_version, constants::header_value_storage_version);
add_ms_header(h, headers, constants::header_ms_version, constants::header_value_storage_blob_version);
// set copy src
add_ms_header(h, headers, constants::header_ms_copy_source, a.credential()->transform_url(source_url.get_domain() + source_url.get_path()));

Просмотреть файл

@ -40,7 +40,7 @@ namespace azure { namespace storage_lite {
h.add_header(constants::header_user_agent, constants::header_value_user_agent);
add_ms_header(h, headers, constants::header_ms_date, get_ms_date(date_format::rfc_1123));
add_ms_header(h, headers, constants::header_ms_version, constants::header_value_storage_version);
add_ms_header(h, headers, constants::header_ms_version, constants::header_value_storage_blob_version);
a.credential()->sign_request(r, h, url, headers);
}

Просмотреть файл

@ -42,7 +42,7 @@ namespace azure { namespace storage_lite {
h.add_header(constants::header_user_agent, constants::header_value_user_agent);
add_ms_header(h, headers, constants::header_ms_date, get_ms_date(date_format::rfc_1123));
add_ms_header(h, headers, constants::header_ms_version, constants::header_value_storage_version);
add_ms_header(h, headers, constants::header_ms_version, constants::header_value_storage_blob_version);
a.credential()->sign_request(r, h, url, headers);
}

Просмотреть файл

@ -26,7 +26,7 @@ namespace azure { namespace storage_lite {
h.add_header(constants::header_user_agent, constants::header_value_user_agent);
add_ms_header(h, headers, constants::header_ms_date, get_ms_date(date_format::rfc_1123));
add_ms_header(h, headers, constants::header_ms_version, constants::header_value_storage_version);
add_ms_header(h, headers, constants::header_ms_version, constants::header_value_storage_blob_version);
a.credential()->sign_request(r, h, url, headers);
}

Просмотреть файл

@ -28,7 +28,7 @@ namespace azure { namespace storage_lite {
h.add_header(constants::header_user_agent, constants::header_value_user_agent);
add_ms_header(h, headers, constants::header_ms_date, get_ms_date(date_format::rfc_1123));
add_ms_header(h, headers, constants::header_ms_version, constants::header_value_storage_version);
add_ms_header(h, headers, constants::header_ms_version, constants::header_value_storage_blob_version);
a.credential()->sign_request(r, h, url, headers);
}

Просмотреть файл

@ -36,7 +36,7 @@ namespace azure { namespace storage_lite {
h.add_header(constants::header_user_agent, constants::header_value_user_agent);
add_ms_header(h, headers, constants::header_ms_date, get_ms_date(date_format::rfc_1123));
add_ms_header(h, headers, constants::header_ms_version, constants::header_value_storage_version);
add_ms_header(h, headers, constants::header_ms_version, constants::header_value_storage_blob_version);
a.credential()->sign_request(r, h, url, headers);
}

Просмотреть файл

@ -41,7 +41,7 @@ namespace azure { namespace storage_lite {
h.add_header(constants::header_user_agent, constants::header_value_user_agent);
add_ms_header(h, headers, constants::header_ms_date, get_ms_date(date_format::rfc_1123));
add_ms_header(h, headers, constants::header_ms_version, constants::header_value_storage_version);
add_ms_header(h, headers, constants::header_ms_version, constants::header_value_storage_blob_version);
a.credential()->sign_request(r, h, url, headers);
}

Просмотреть файл

@ -28,7 +28,7 @@ namespace azure { namespace storage_lite {
h.add_header(constants::header_user_agent, constants::header_value_user_agent);
add_ms_header(h, headers, constants::header_ms_date, get_ms_date(date_format::rfc_1123));
add_ms_header(h, headers, constants::header_ms_version, constants::header_value_storage_version);
add_ms_header(h, headers, constants::header_ms_version, constants::header_value_storage_blob_version);
a.credential()->sign_request(r, h, url, headers);
}

Просмотреть файл

@ -30,7 +30,7 @@ namespace azure { namespace storage_lite {
h.add_header(constants::header_user_agent, constants::header_value_user_agent);
add_ms_header(h, headers, constants::header_ms_date, get_ms_date(date_format::rfc_1123));
add_ms_header(h, headers, constants::header_ms_version, constants::header_value_storage_version);
add_ms_header(h, headers, constants::header_ms_version, constants::header_value_storage_blob_version);
a.credential()->sign_request(r, h, url, headers);
}

Просмотреть файл

@ -48,7 +48,7 @@ void list_blobs_request_base::build_request(const storage_account &a, http_base
h.add_header(constants::header_user_agent, constants::header_value_user_agent);
add_ms_header(h, headers, constants::header_ms_date, get_ms_date(date_format::rfc_1123));
add_ms_header(h, headers, constants::header_ms_version, constants::header_value_storage_version);
add_ms_header(h, headers, constants::header_ms_version, constants::header_value_storage_blob_version);
a.credential()->sign_request(r, h, url, headers);
}
@ -108,7 +108,7 @@ void list_blobs_segmented_request_base::build_request(const storage_account &a,
h.add_header(constants::header_user_agent, constants::header_value_user_agent);
add_ms_header(h, headers, constants::header_ms_date, get_ms_date(date_format::rfc_1123));
add_ms_header(h, headers, constants::header_ms_version, constants::header_value_storage_version);
add_ms_header(h, headers, constants::header_ms_version, constants::header_value_storage_blob_version);
a.credential()->sign_request(r, h, url, headers);
}

Просмотреть файл

@ -31,7 +31,7 @@ namespace azure { namespace storage_lite {
h.add_header(constants::header_user_agent, constants::header_value_user_agent);
add_ms_header(h, headers, constants::header_ms_date, get_ms_date(date_format::rfc_1123));
add_ms_header(h, headers, constants::header_ms_version, constants::header_value_storage_version);
add_ms_header(h, headers, constants::header_ms_version, constants::header_value_storage_blob_version);
a.credential()->sign_request(r, h, url, headers);
}

Просмотреть файл

@ -71,7 +71,7 @@ void put_blob_request_base::build_request(const storage_account &a, http_base &h
h.add_header(constants::header_user_agent, constants::header_value_user_agent);
add_ms_header(h, headers, constants::header_ms_date, get_ms_date(date_format::rfc_1123));
add_ms_header(h, headers, constants::header_ms_version, constants::header_value_storage_version);
add_ms_header(h, headers, constants::header_ms_version, constants::header_value_storage_blob_version);
a.credential()->sign_request(r, h, url, headers);
}

Просмотреть файл

@ -52,7 +52,7 @@ void put_block_list_request_base::build_request(const storage_account &a, http_b
h.add_header(constants::header_user_agent, constants::header_value_user_agent);
add_ms_header(h, headers, constants::header_ms_date, get_ms_date(date_format::rfc_1123));
add_ms_header(h, headers, constants::header_ms_version, constants::header_value_storage_version);
add_ms_header(h, headers, constants::header_ms_version, constants::header_value_storage_blob_version);
a.credential()->sign_request(r, h, url, headers);
}

Просмотреть файл

@ -28,7 +28,7 @@ namespace azure { namespace storage_lite {
h.add_header(constants::header_user_agent, constants::header_value_user_agent);
add_ms_header(h, headers, constants::header_ms_date, get_ms_date(date_format::rfc_1123));
add_ms_header(h, headers, constants::header_ms_version, constants::header_value_storage_version);
add_ms_header(h, headers, constants::header_ms_version, constants::header_value_storage_blob_version);
a.credential()->sign_request(r, h, url, headers);
}

Просмотреть файл

@ -46,7 +46,7 @@ namespace azure { namespace storage_lite {
h.add_header(constants::header_user_agent, constants::header_value_user_agent);
add_ms_header(h, headers, constants::header_ms_date, get_ms_date(date_format::rfc_1123));
add_ms_header(h, headers, constants::header_ms_version, constants::header_value_storage_version);
add_ms_header(h, headers, constants::header_ms_version, constants::header_value_storage_blob_version);
a.credential()->sign_request(r, h, url, headers);
}

Просмотреть файл

@ -29,7 +29,7 @@ namespace azure { namespace storage_lite {
h.add_header(constants::header_user_agent, constants::header_value_user_agent);
add_ms_header(h, headers, constants::header_ms_date, get_ms_date(date_format::rfc_1123));
add_ms_header(h, headers, constants::header_ms_version, constants::header_value_storage_version);
add_ms_header(h, headers, constants::header_ms_version, constants::header_value_storage_blob_version);
for (const auto& m : metadata())
{

Просмотреть файл

@ -30,7 +30,7 @@ namespace azure { namespace storage_lite {
h.add_header(constants::header_user_agent, constants::header_value_user_agent);
add_ms_header(h, headers, constants::header_ms_date, get_ms_date(date_format::rfc_1123));
add_ms_header(h, headers, constants::header_ms_version, constants::header_value_storage_version);
add_ms_header(h, headers, constants::header_ms_version, constants::header_value_storage_blob_version);
for (const auto& m : metadata())
{