express-sweet 1.0.41 → 1.0.42
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/CHANGELOG.md +12 -1
- package/INSTALL-Redis.md +65 -39
- package/README.md +7 -0
- package/dist/build.common.js +66 -19
- package/dist/build.esm.js +66 -19
- package/docs/index.html +3 -3
- package/package.json +12 -20
- package/types/database/Database.d.ts +181 -181
- package/types/database/Model.d.ts +221 -221
- package/types/database/index.d.ts +3 -4
- package/types/database/loadModels.d.ts +6 -6
- package/types/exceptions/FaceCollectionCreateFailed.d.ts +25 -25
- package/types/exceptions/FaceCollectionDeleteFailed.d.ts +25 -25
- package/types/exceptions/FaceIndexFailed.d.ts +20 -20
- package/types/exceptions/FaceMissingInPhoto.d.ts +11 -11
- package/types/exceptions/FacesMultipleInPhoto.d.ts +11 -11
- package/types/exceptions/index.d.ts +5 -6
- package/types/handlebars_helpers/comparison.d.ts +351 -351
- package/types/handlebars_helpers/date.d.ts +19 -19
- package/types/handlebars_helpers/html.d.ts +12 -12
- package/types/handlebars_helpers/index.d.ts +7 -8
- package/types/handlebars_helpers/math.d.ts +81 -81
- package/types/handlebars_helpers/number.d.ts +18 -18
- package/types/handlebars_helpers/object.d.ts +21 -21
- package/types/handlebars_helpers/string.d.ts +50 -50
- package/types/index.d.ts +7 -8
- package/types/interfaces/AuthenticationConfig.d.ts +108 -108
- package/types/interfaces/BasicConfig.d.ts +74 -74
- package/types/interfaces/BoundingBox.d.ts +25 -25
- package/types/interfaces/DatabaseConfig.d.ts +7 -7
- package/types/interfaces/FaceDetails.d.ts +30 -0
- package/types/interfaces/FaceDetailsEmotions.d.ts +40 -40
- package/types/interfaces/FaceMatch.d.ts +31 -31
- package/types/interfaces/IndexFaceDetails.d.ts +29 -0
- package/types/interfaces/RekognitionOptions.d.ts +26 -26
- package/types/interfaces/SesOptions.d.ts +27 -27
- package/types/interfaces/ViewConfig.d.ts +44 -44
- package/types/interfaces/index.d.ts +8 -9
- package/types/middlewares/Authentication.d.ts +13 -13
- package/types/middlewares/CORS.d.ts +10 -10
- package/types/middlewares/Environment.d.ts +10 -10
- package/types/middlewares/ErrorHandler.d.ts +10 -10
- package/types/middlewares/Global.d.ts +13 -13
- package/types/middlewares/Http.d.ts +10 -10
- package/types/middlewares/Local.d.ts +13 -13
- package/types/middlewares/View.d.ts +14 -14
- package/types/middlewares/index.d.ts +7 -8
- package/types/mount.d.ts +7 -7
- package/types/routing/Router.d.ts +13 -13
- package/types/routing/index.d.ts +1 -2
- package/types/services/AWSRekognitionClient.d.ts +126 -126
- package/types/services/AWSSesClient.d.ts +57 -57
- package/types/services/Authentication.d.ts +34 -34
- package/types/services/index.d.ts +3 -4
- package/types/utils/Types.d.ts +24 -24
- package/types/utils/index.d.ts +9 -12
- package/types/utils/isArray.d.ts +8 -8
- package/types/utils/isAsyncFunction.d.ts +12 -12
- package/types/utils/isFunction.d.ts +13 -13
- package/types/utils/isObject.d.ts +8 -8
- package/types/utils/isString.d.ts +8 -8
- package/types/utils/loadAuthenticationConfig.d.ts +8 -8
- package/types/utils/loadBasicConfig.d.ts +8 -8
- package/types/utils/loadDatabaseConfig.d.ts +8 -8
- package/types/utils/loadViewConfig.d.ts +8 -8
- package/types/services/RedisClient.d.ts +0 -80
package/CHANGELOG.md
CHANGED
|
@@ -1,6 +1,16 @@
|
|
|
1
1
|
# Changelog
|
|
2
2
|
All notable changes to this project will be documented in this file.
|
|
3
3
|
|
|
4
|
+
## [1.0.42] - 2023/8/31
|
|
5
|
+
### Changed
|
|
6
|
+
- Update TypeScript version from 4.8.4 to 5.2.2.
|
|
7
|
+
- Update redis dependency package used for user authentication.
|
|
8
|
+
- Updated redis package version from 4.3.1 to 4.6.8.
|
|
9
|
+
[Here](https://github.com/redis/node-redis/blob/master/CHANGELOG.md) are the changes.
|
|
10
|
+
- Updated connect-redis package version from 6.1.3 to 7.1.0.
|
|
11
|
+
[Here](https://github.com/tj/connect-redis/releases) are the changes.
|
|
12
|
+
|
|
13
|
+
|
|
4
14
|
## [1.0.41] - 2023/8/4
|
|
5
15
|
### Changed
|
|
6
16
|
- Added an option to the method that searches for faces in the collection to throw an exception if a face is not found or if multiple faces are found.
|
|
@@ -828,4 +838,5 @@ All notable changes to this project will be documented in this file.
|
|
|
828
838
|
[1.0.38]: https://github.com/takuya-motoshima/express-sweet/compare/v1.0.37...v1.0.38
|
|
829
839
|
[1.0.39]: https://github.com/takuya-motoshima/express-sweet/compare/v1.0.38...v1.0.39
|
|
830
840
|
[1.0.40]: https://github.com/takuya-motoshima/express-sweet/compare/v1.0.39...v1.0.40
|
|
831
|
-
[1.0.41]: https://github.com/takuya-motoshima/express-sweet/compare/v1.0.40...v1.0.41
|
|
841
|
+
[1.0.41]: https://github.com/takuya-motoshima/express-sweet/compare/v1.0.40...v1.0.41
|
|
842
|
+
[1.0.42]: https://github.com/takuya-motoshima/express-sweet/compare/v1.0.41...v1.0.42
|
package/INSTALL-Redis.md
CHANGED
|
@@ -1,51 +1,77 @@
|
|
|
1
1
|
# Install Redis
|
|
2
2
|
==============
|
|
3
3
|
|
|
4
|
+
## Environment for this procedure
|
|
4
5
|
* OS: `Amazon Linux 2`
|
|
5
6
|
* Redis: `v6.2.6 or later`
|
|
6
7
|
* see more: https://redis.io/download#installation
|
|
7
8
|
|
|
8
|
-
Check the version of Redis that can be installed.
|
|
9
|
-
```sh
|
|
10
|
-
amazon-linux-extras list|grep redis
|
|
11
|
-
# Below is an example of the output.
|
|
12
|
-
# 56 redis6 available [ =stable ]
|
|
13
|
-
```
|
|
14
9
|
|
|
15
|
-
Install Redis
|
|
16
|
-
|
|
17
|
-
|
|
18
|
-
|
|
10
|
+
## Install Redis
|
|
11
|
+
1. Check the version of Redis that can be installed.
|
|
12
|
+
```sh
|
|
13
|
+
amazon-linux-extras list|grep redis
|
|
14
|
+
# Below is an example of the output.
|
|
15
|
+
# 56 redis6 available [ =stable ]
|
|
16
|
+
```
|
|
19
17
|
|
|
20
|
-
|
|
21
|
-
```sh
|
|
22
|
-
sudo
|
|
23
|
-
|
|
24
|
-
|
|
25
|
-
|
|
26
|
-
|
|
18
|
+
1. Install Redis by specifying the version.
|
|
19
|
+
```sh
|
|
20
|
+
sudo amazon-linux-extras install -y redis6
|
|
21
|
+
```
|
|
22
|
+
1. Configure and start Redis autostart.
|
|
23
|
+
```sh
|
|
24
|
+
sudo systemctl status redis.service
|
|
25
|
+
sudo systemctl start redis.service
|
|
26
|
+
sudo systemctl enable redis.service
|
|
27
|
+
sudo systemctl is-enabled redis.service
|
|
28
|
+
```
|
|
29
|
+
1. Check Redis process.
|
|
30
|
+
```sh
|
|
31
|
+
ps -ef | grep redis | grep -v grep
|
|
32
|
+
# Below is an example of the output.
|
|
33
|
+
# redis 5407 1 0 11:02 ? 00:00:00 /usr/bin/redis-server 127.0.0.1:6379
|
|
34
|
+
```
|
|
35
|
+
1. Check Redis behavior. If "redis-cli ping" returns PONG, it is success.
|
|
36
|
+
```sh
|
|
37
|
+
redis-cli ping
|
|
38
|
+
# Below is an example of the output.
|
|
39
|
+
# PONG
|
|
40
|
+
```
|
|
41
|
+
1. Test Redis read/write.
|
|
42
|
+
```sh
|
|
43
|
+
redis-cli
|
|
27
44
|
|
|
28
|
-
|
|
29
|
-
|
|
30
|
-
ps -ef | grep redis | grep -v grep
|
|
31
|
-
# Below is an example of the output.
|
|
32
|
-
# redis 5407 1 0 11:02 ? 00:00:00 /usr/bin/redis-server 127.0.0.1:6379
|
|
33
|
-
```
|
|
45
|
+
set myMessage "hello world"
|
|
46
|
+
# OK
|
|
34
47
|
|
|
35
|
-
|
|
36
|
-
|
|
37
|
-
|
|
38
|
-
# Below is an example of the output.
|
|
39
|
-
# PONG
|
|
40
|
-
```
|
|
48
|
+
get myMessage
|
|
49
|
+
# "hello world"
|
|
50
|
+
```
|
|
41
51
|
|
|
42
|
-
|
|
43
|
-
|
|
44
|
-
|
|
45
|
-
|
|
46
|
-
|
|
47
|
-
|
|
48
|
-
|
|
49
|
-
|
|
50
|
-
|
|
51
|
-
|
|
52
|
+
## Commonly used Redis commands
|
|
53
|
+
- Start Redis CLI
|
|
54
|
+
```sh
|
|
55
|
+
redis-cli
|
|
56
|
+
```
|
|
57
|
+
- Key List
|
|
58
|
+
```sh
|
|
59
|
+
redis-cli --raw keys \*
|
|
60
|
+
```
|
|
61
|
+
|
|
62
|
+
or
|
|
63
|
+
```sh
|
|
64
|
+
redis-cli --scan
|
|
65
|
+
```
|
|
66
|
+
- Value List
|
|
67
|
+
```sh
|
|
68
|
+
redis-cli --raw mget $(redis-cli --scan)
|
|
69
|
+
```
|
|
70
|
+
- Key and Value List
|
|
71
|
+
```sh
|
|
72
|
+
for i in $(redis-cli keys \*); do echo $i: $(redis-cli GET $i); done
|
|
73
|
+
```
|
|
74
|
+
- Delete key
|
|
75
|
+
```sh
|
|
76
|
+
redis-cli del myMessage
|
|
77
|
+
```
|
package/README.md
CHANGED