[TIL] 1007 Redis , AWS S3 bucket
Today I Learnt
Busy with school assignment
Assignment prac 1 :
• You check the (Redis) cache as before. If it is there, serve it.
• If it isn’t there, you check to see if it is in S3. If it is in S3, serve it, but also store it in the cache.
• If it isn’t in S3 either, go and get it from Wikipedia and store it in S3 and in the Cache
.
Redis -
One type of database by key:value format.
Fast since its stored in the cache
Caching is the process of storing data into a cache. A cache is a temporary data store where data is kept for later use.
A cache as a data store is easier for the client (or server) to reach, as opposed to a permanent data store that might be located on a different service, which takes more time and resources to reach (a database or an external API endpoint)
Reids
https://www.codementor.io/@brainyfarm/introduction-to-caching-and-redis-h6o16p4qx
Introduction to Caching and Redis | Codementor
A simple introduction to the importance and practical benefits of caching and Redis.
www.codementor.io
Follow this tutorial for simple Node JS + Redis
https://www.codementor.io/@brainyfarm/caching-with-redis-node-js-example-h6o9ii72i
Caching with Redis: Node.js Example | Codementor
Building faster Node.js apps using Redis.
www.codementor.io
Redis-CLI
Sudo redis-cli // open redis
flushdb // delete all the db
keys * // check all the stored data
AWS -SDK Node JS
Loading Credentials in Node.js from the Shared Credentials File - AWS SDK for JavaScript
When setting environment variables, be sure to take appropriate actions afterwards (according to the needs of your operating system) to make the variables available in the shell or command environment.
docs.aws.amazon.com
make sure all the credential is stored and load from aws-sdk
have to use the aws_session_token
[default]
aws_access_key_id=aabc
aws_secret_access_key= aabb
aws_session_token=mtabVQVubEdApdnlW
AWS CLI
https://docs.aws.amazon.com/cli/latest/userguide/install-cliv2-mac.html#cliv2-mac-install-confirm
Installing, updating, and uninstalling the AWS CLI version 2 on macOS - AWS Command Line Interface
You can view debug logs for the installation by pressing Cmd+L anywhere in the installer. This opens a log pane that enables you to filter and save the log. The log file is also automatically saved to /var/log/install.log.
docs.aws.amazon.com
'IT > TIL(Today I Learnt)' 카테고리의 다른 글
[TIL] 1010 Technology Trend (1) | 2021.10.11 |
---|---|
[TIL] 1009 취업! (8) | 2021.10.09 |
[TIL] 1005실력이 답이다. (4) | 2021.10.06 |
[TIL] 0930 코딩테스트 (2) | 2021.10.01 |
[TIL] 0929 기술면접 준비 (0) | 2021.09.29 |