【1】修复HTTP Expect头部缺失时POST卡顿的问题;
【2】TODO:尝试增加multiple delete objects API,尚未成功(AccessDenied);
This commit is contained in:
10
cache/tango_cache_client_in.h
vendored
10
cache/tango_cache_client_in.h
vendored
@@ -19,6 +19,7 @@ enum CACHE_REQUEST_METHOD
|
||||
CACHE_REQUEST_GET=0,
|
||||
CACHE_REQUEST_PUT,
|
||||
CACHE_REQUEST_DELETE,
|
||||
CACHE_REQUEST_DELETE_MUL,
|
||||
};
|
||||
|
||||
enum GET_OBJECT_STATE
|
||||
@@ -98,6 +99,12 @@ struct cache_ctx_data_put
|
||||
bool close_state; //<2F><><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD>ùر<C3B9>
|
||||
};
|
||||
|
||||
struct cache_ctx_multi_delete
|
||||
{
|
||||
u_int32_t succ_num;
|
||||
u_int32_t fail_num;
|
||||
};
|
||||
|
||||
struct tango_cache_ctx
|
||||
{
|
||||
CURL *curl;
|
||||
@@ -117,6 +124,7 @@ struct tango_cache_ctx
|
||||
union{
|
||||
struct cache_ctx_data_put put;
|
||||
struct cache_ctx_data_get get;
|
||||
struct cache_ctx_multi_delete del;
|
||||
};
|
||||
struct tango_cache_instance *instance;
|
||||
};
|
||||
@@ -126,6 +134,8 @@ struct curl_socket_data
|
||||
struct event sock_event;
|
||||
};
|
||||
|
||||
void caculate_sha256(const char *data, unsigned long len, char *result, u_int32_t size);
|
||||
|
||||
void easy_string_savedata(struct easy_string *estr, const char *data, size_t len);
|
||||
void easy_string_destroy(struct easy_string *estr);
|
||||
|
||||
|
||||
Reference in New Issue
Block a user