AZ-204 Cache Flashcards
What are the Service tiers for Redis?
Basic - An OSS Redis cache running on a single VM. This tier has no service-level agreement (SLA) and is ideal for development/test and non-critical workloads.
Standard - An OSS Redis cache running on two VMs in a replicated configuration.
Premium - High-performance OSS Redis caches. This tier offers higher throughput, lower latency, better availability, and more features. Premium caches are deployed on more powerful VMs compared to the VMs for Basic or Standard caches.
Enterprise - High-performance caches powered by Redis Labs’ Redis Enterprise software. This tier supports Redis modules including RediSearch, RedisBloom, and RedisTimeSeries. Also, it offers even higher availability than the Premium tier.
Enterprise Flash - Cost-effective large caches powered by Redis Labs’ Redis Enterprise software. This tier extends Redis data storage to non-volatile memory, which is cheaper than DRAM, on a VM. It reduces the overall per-GB memory cost.
What is the Data Cache pattern?
Databases are often too large to load directly into a cache. It’s common to use the cache-aside pattern to load data into the cache only as needed. When the system makes changes to the data, the system can also update the cache, which is then distributed to other clients.
What is the Content Cache pattern?
Many web pages are generated from templates that use static content such as headers, footers, banners. These static items shouldn’t change often. Using an in-memory cache provides quick access to static content compared to backend datastores.
What is the Session Store pattern?
This pattern is commonly used with shopping carts and other user history data that a web application might associate with user cookies. Storing too much in a cookie can have a negative effect on performance as the cookie size grows and is passed and validated with every request. A typical solution uses the cookie as a key to query the data in a database. Using an in-memory cache, like Azure Cache for Redis, to associate information with a user is much faster than interacting with a full relational database.
What is the job and messaging queue pattern?
Applications often add tasks to a queue when the operations associated with the request take time to execute. Longer running operations are queued to be processed in sequence, often by another server. This method of deferring work is called task queuing.
What is the distributed transactions pattern?
Applications sometimes require a series of commands against a backend data-store to execute as a single atomic operation. All commands must succeed, or all must be rolled back to the initial state. Azure Cache for Redis supports executing a batch of commands as a single transaction.
What are the 3 pricing tiers for Redis?
- Basic: Basic cache ideal for development/testing. Is limited to a single server, 53 GB of memory, and 20,000 connections. There is no SLA for this service tier.
- Standard: Production cache which supports replication and includes an SLA. It supports two servers, and has the same memory/connection limits as the Basic tier.
- Premium: Enterprise tier which builds on the Standard tier and includes persistence, clustering, and scale-out cache support. This is the highest performing tier with up to 530 GB of memory and 40,000 simultaneous connections.
What are the recommendations for configuring Cache for Redis?
-Name needs to be globally unique
- Location and app should be in the same region
- standard/premium tier for prod
-if a vnet is needed use premium tier
- if clustering/sharding needed use preimium
What do you need to access Redis from a client?
To connect to an Azure Cache for Redis instance, you’ll need several pieces of information. Clients need the host name, port, and an access key for the cache. You can retrieve this information in the Azure portal through the Settings > Access Keys page.
How do you connect the Redis cache using StackExchange.Redis?
using StackExchange.Redis;
…
var connectionString = “[cache-name].redis.cache.windows.net:6380,password=[password-here],ssl=True,abortConnect=False”;
var redisConnection = ConnectionMultiplexer.Connect(connectionString);
How do you access a redi db?
IDatabase db = redisConnection.GetDatabase();
How do you close the Redi connection?
redisConnection.Dispose();
redisConnection = null;
How do Azure CDNs work?
User requests a file from any type of server, if no edge servers in the POP have the file the server returns the file to the edge server. An edge sever in the POP stores the file in the cache and delivers it to the requested user. For the rest of the TTL the file is stored in cache and will be significantly faster for other users requesting the same file.
What is a CDN profile?
Collection of CDN endpoints. at least 1 cdn profile is required to use Azure CDN.
What are the Azure subscription limitations?
The number of CDN profiles that can be created.
The number of endpoints that can be created in a CDN profile.
The number of custom domains that can be mapped to an endpoint.