You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
A typical output of the /test location defined above is:
72
74
@@ -85,6 +87,7 @@ A typical output of the /test location defined above is:
85
87
86
88
You can use the [lua-resty-string](https://github.com/agentzh/lua-resty-string) library to compute SHA-1 and MD5 digest of the file data incrementally. Here is such an example:
87
89
90
+
```lua
88
91
localresty_sha1=require"resty.sha1"
89
92
localupload=require"resty.upload"
90
93
@@ -130,9 +133,10 @@ You can use the [lua-resty-string](https://github.com/agentzh/lua-resty-string)
130
133
-- do nothing
131
134
end
132
135
end
136
+
```
133
137
134
138
If you want to copmute MD5 sums for the uploaded files, just use the
135
-
resty.md5 module shipped by the lua-resty-string library. It has
139
+
resty.md5 module shipped by the [lua-resty-string](https://github.com/agentzh/lua-resty-string) library. It has
136
140
a similar API as resty.sha1.
137
141
138
142
For big file uploading, it is important not to buffer all the data in memory.
0 commit comments