对外API增加USERTAG

This commit is contained in:
zhangchengwei
2018-09-23 15:35:13 +08:00
committed by zhengchao
parent c974c534d0
commit 282eca63bd
10 changed files with 144 additions and 80 deletions

View File

@@ -39,7 +39,7 @@ struct databuffer
enum CACHE_ERR_CODE cache_evbase_get_last_error(const struct cache_evbase_ctx *ctx_asyn)
{
return ctx_asyn->ctx->error_code;
return tango_cache_get_last_error(ctx_asyn->ctx);
}
enum CACHE_ERR_CODE cache_evbase_ctx_error(const struct cache_evbase_instance *instance)
{
@@ -51,6 +51,11 @@ void cache_evbase_get_statistics(const struct cache_evbase_instance *instance, s
tango_cache_get_statistics(instance->instance, out);
}
struct tango_cache_result *cache_evbase_read_result(void *promise_result)
{
return tango_cache_read_result(promise_result);
}
const char *cache_evbase_get_object_key(struct cache_evbase_ctx *ctx_asyn)
{
return tango_cache_get_object_key(ctx_asyn->ctx);
@@ -351,7 +356,7 @@ int cache_evbase_upload_once_data(struct cache_evbase_instance *instance, struct
}
if(objectkey != NULL)
{
snprintf(objectkey, keysize, "%s", ctx->file_key);
snprintf(objectkey, keysize, "%s", ctx->object_key);
}
ctx_asyn = (struct cache_evbase_ctx *)calloc(1, sizeof(struct cache_evbase_ctx));
@@ -402,7 +407,7 @@ int cache_evbase_upload_once_evbuf(struct cache_evbase_instance *instance, struc
}
if(objectkey != NULL)
{
snprintf(objectkey, keysize, "%s", ctx->file_key);
snprintf(objectkey, keysize, "%s", ctx->object_key);
}
ctx_asyn = (struct cache_evbase_ctx *)calloc(1, sizeof(struct cache_evbase_ctx));