forked from alibaba/nginx-tfs
-
Notifications
You must be signed in to change notification settings - Fork 0
/
Copy pathngx_http_tfs_restful.h
53 lines (36 loc) · 1.43 KB
/
ngx_http_tfs_restful.h
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
/*
* Copyright (C) 2010-2012 Alibaba Group Holding Limited
*/
#ifndef _NGX_HTTP_TFS_RESTFUL_H_INCLUDED_
#define _NGX_HTTP_TFS_RESTFUL_H_INCLUDED_
#include <ngx_core.h>
#include <ngx_http.h>
#include <ngx_http_tfs_raw_fsname.h>
typedef struct {
ngx_str_t file_path_s;
ngx_str_t file_path_d;
ngx_str_t file_suffix;
ngx_http_tfs_raw_fsname_t fsname;
ngx_str_t appkey;
uint64_t app_id;
uint64_t user_id;
/* action */
ngx_http_tfs_action_t action;
int64_t offset;
uint64_t size;
ngx_int_t unlink_type;
ngx_int_t simple_name;
uint8_t version;
uint8_t file_type;
ngx_int_t large_file;
ngx_int_t read_stat_type;
ngx_int_t write_meta_segment;
ngx_int_t no_dedup;
ngx_int_t chk_file_hole;
unsigned meta:1;
unsigned get_appid:1;
unsigned chk_exist:1;
unsigned recursive:1;
} ngx_http_tfs_restful_ctx_t;
ngx_int_t ngx_http_restful_parse(ngx_http_request_t *r, ngx_http_tfs_restful_ctx_t *ctx);
#endif /* _NGX_HTTP_TFS_RESTFUL_H_INCLUDED_ */