Monitor, troubleshoot, and optimize Azure solutions (15–20%) Flashcards

1
Q

Your company has recently undergone a rebranding exercise and updated its corporate logo. This logo is shown at the top of every page on the company’s website. The website is hosted in an Azure Web Apps resource. You are uisng an Azure CDN Standard from Verizon profile to cache the logo.

You upload the new corporate logo to the website but 24 hours later, the CDN is still serving th eold image to the website viewers. You need to force the CDN to serve the new image ASAP. You must do this without changing the Azure Web Apps resource. What 2 actions could you perform to meet there requirements?

A

Purge the Azure CDN endpoint

Delete and recreate the Azure CDN endpoint

How well did you know this?
1
Not at all
2
3
4
5
Perfectly
2
Q

You configure a caching option for your web app. You want to enable an eviction policy so that your app services fo not fail when the cache is full.

You need to ensure that the acche evicts the oldest data first.

Which eviction policy should you enable?

A

First-in-first-out (FIFO)

You should enable the FIFO eviction policy. With this policy, the caching solution monitors the order in which the items are added. This ensures that the oldest data, i.e., the first to be added, is evicted first when the cache needs to be freed for new items.

You should not use explicit item removal triggered by its modification in the main database. With this eviction policy, you can replace outdated items in the cache with their more up-to-date versions from the main database.

You should not use the LRU eviction policy. This policy tries to remove the items that have been used least recently. However, the policy does not consider the order in which the items were added to the cache to determine the oldest ones.

You should not use the MRU eviction policy. This policy is useful when the business logic of your app does not require access to items that were already retrieved from the cache at least once. The MRU eviction policy evicts the most recently used items first but ignores the age of the items in the cache.

How well did you know this?
1
Not at all
2
3
4
5
Perfectly
3
Q

Your company is developing and deploying several ASP.NET web applications to Azure App Service. You must configure a method to store session state information that meets the following requirements:
- Share session state across ASP.NET web applications.
- Persist session state information as a snapshot.
- Provide multiple readers with concurrent access to the same session state data.
- Minimize latency when retrieving session state information.

You need to identify the best method to store session state.

Solution: Deploy and configure an Azure Cosmos DB instance and update the web apps to store session state to the database.

Solution: Configure the web apps to use the ASP.NET Memory Session State Provider

Solution: Deploy and configure a Premium tier Azure Cache for Redis instance. Update the web apps

Does this solution meet the goal?

A

No

No

Yes

The guidance from MS is to leverage Azure Cosmos DB for building highly scalable, fault-resilient, globally replicated LOB apps which require built-in scale and enhanced transactional throughput and performance.

ASP.NET Memory Session State Provider minimizes latency but data is not distributed and it would not be available to all web apps

How well did you know this?
1
Not at all
2
3
4
5
Perfectly
4
Q

You create an Azure Function app.

You want to save info log data in an existing App Insights.

Which 2 tasks should you perform?

A
  • Store the name of the instrumentation key in an app setting names APPINSIGHTS_INSTRUMENTATIONKEY.
  • Call the LogInformation method of the ILogger class
How well did you know this?
1
Not at all
2
3
4
5
Perfectly
5
Q

You have the following code:

String connectionstring = Getconnectionstring ();  
$\operatorname{var} \mathrm{obj}=$ ConnectionMultiplexer.Connect (connectionstring);  
var database $=$ obj.GetDatabase ();  
var tables = database.StringGet ("Tables");  
You need to determine what this code does.  

What does this code retrieve?

A

Data from an Azure Cache for Redis

This code retrieves data from an Azure Cache for Redis. Azure cache for Redis allows you to store frequently accessed data in a cloud location close to your application. It stores the data in memory instead of in data storage.

This code does not retrieve table names from an Azure table storage account. To retrieve rows from Azure table storage, you use the CloudTableClient class.

This code does not retrieve rows from an Easy Table in Azure Mobile App Service. To retrieve rows, you use the MobileServiceClient class.

This code does not retrieve docs from an Azure Cosmos DB database. for that, use CosmosClient class

How well did you know this?
1
Not at all
2
3
4
5
Perfectly
6
Q

You have the following code in an ASP.NET web application:

try  
\{  
Save ();  
\}  
catch (Exception ex)  
\{  
var client = new Telemetryclient();  
client.TrackException (ex) ;  
\}  

You need to determine where the exception gets logged.

Where is the exception logged?

A

Application Insights

The exception gets logged to Application Insights. The TelemetryClient class allows you to log different types of telemetry data, including exceptions. The TrackException method allows you to log exceptions.

The exception does not get logged to Event Log. The Write method of the EventSource class allows you to log data to the Event Log.

The exception does not get logged to a diagnostic trace listener. The Trace.Error method allows you to log exceptions to a diagnostic trace listener. Alternatively, you would need to use the TrackTrace method of the TelemetryClient class, and configure tracing for the application.

The exception does not get logged to Trace.aspx. To do this, you must call Trace.Write.

How well did you know this?
1
Not at all
2
3
4
5
Perfectly
7
Q

You have the following code:

TelemetryClient client = new TelemetryClient ();
client.TrackTrace("This is a test");

You need to view the trace message that is written. What should you do?

A

Open Application Insights in Azure

How well did you know this?
1
Not at all
2
3
4
5
Perfectly
8
Q

You deploy an ASP.NET web app to a dev server on your corporate network. The web application will be accessed by users around the world.

You need to capture performance metrics from multiple geographies before you move the application to a production server on the network.

What should you do?

A

Create a URL ping test in Application Insights.

You should create a URL ping test in Application Insights. This allows you to test the performance of your web application from multiple geographical locations, up to 16 . You can configure the test to notify you if a response does not contain particular content, or if a response is not received within a particular time frame.

You should not create HTTP redirection with Application Gateway. Application Gateway is a firewall solution that provides load balancing. HTTP redirection allows you to redirect HTTP requests to HTTPS endpoints.

You should not configure endpoint monitoring on a Traffic Manager profile. Traffic Manager allows you to create endpoints that are nearest to the user. This improves performance by ensuring that requests do not have to travel far geographically. Endpoint monitoring allows you to determine which endpoints are healthy and which ones are not by using a Traffic Manager probing agent.

You should not configure a Load Balancer with multiple availability zones. A Load Balancer allows you to distribute inbound TCP and UDP traffic to different virtual machines.

How well did you know this?
1
Not at all
2
3
4
5
Perfectly
9
Q

You develop a web application for your organization. You want to instrument the application using Azure Application Insights to capture the usage analytics of your application.

You need to determine what telemetry data you need to capture to provide behavior analytics to your sales team.

Which two telemetry elements should you capture?

A
  • Session Id
  • User Id

You should capture Session Id and User Id. For Application Insights to provide necessary views about usage behavior by an individual user, you should set the telemetry context on the initialization of the user session and capture the session and user id. Any usage during that session will then log information tied back to the session id and user id associated to the telemetry data.

You should not capture Exceptions. Even though exceptions provide important information about analytics over types of errors in your application, the requirement is to collect data for user behavior analytics.

You should not capture Events. Events are used to capture analytics across user sessions, and run analytics on types of events being raised by your application. They do not provide data that will provide insights into user behavior.

How well did you know this?
1
Not at all
2
3
4
5
Perfectly
10
Q

The users of your e-commerce site are complaining about slow performance. You discover that the latency is being caused by the concurrent retrieval of the same large volumes of data from the remote product catalog database.

Product catalog data remains relatively static. You want to use data caching to improve your site’s performance.

You need to implement the right application cache pattern.

For each of the following statements, select Yes if the statement is true. Otherwise, select No.

Statement
Shared caching is faster than private caching.

Private caching guarantees that all application instances see the same view of cached data.

Shared caching provides better scalability than private caching

A

No

No

Yes

Shared caching is not faster than private caching. With private caching, data is held locally to each application instance and it can therefore be accessed faster. With shared caching, data is held in a separate, centralized location, which slows the access from the different application instances.

Private caching does not guarantee that all application instances see the same view of cached data. Data may change over time, so the different application instances may hold different versions of the cached data in their local in-memory store. This concern is addressed in the shared caching approach, where cached data is held in a separate, centralized location.

Shared caching provides better scalability than private caching. With this approach, caching is provided by a dedicated service that runs on a cluster of servers. Adjusting the number of cluster servers enables better scalability than scaling the caching store on the machine of each application instance.

How well did you know this?
1
Not at all
2
3
4
5
Perfectly
11
Q

You are developing an application that uses Azure Cache for Redis as a caching solution. The app must cache the response of an external service as a string value for 30 minutes.

You need to store the response in Azure Cache for Redis.

Which Azure Cache for Redis command should you use?

A

SET and EX

You should use the SET command with the EX argument. You can use the SET command to store a value in a key and the EX command to set its expiration in seconds in a single operation. You should run the command below to store a string value in the key “myKey” for 30 minutes:

SET myKey "some-value" EX 1800

You should not use the FCALL command. This command is used to invoke a function. Functions are loaded to the server with the FUNCTION LOAD command.

You should not use the EXPIRE command. You can use this command to expire an existing key stored on Azure Cache for Redis. You cannot use this command to set an expiration on data types such as strings, hashes, and lists.

You should not use the EXISTS command. You can use this command to check if a key exists in Azure Cache for Redis, without returning its value.

How well did you know this?
1
Not at all
2
3
4
5
Perfectly
12
Q

You configure the maxmemory-policy directive of Azure Cache for Redis for your new web app.

You need to ensure that when the memory limit is reached, the Azure Cache for Redis instance evicts the least recently used (LRU) keys first. The LRU keys should be among the keys with an expire set.

What eviction policy should you use for the maxmemory-policy directive?

A

volatile-lru

You should use the volatile-Iru eviction policy. When the memory limit is reached, this policy dictates that the Azure cache for Redis instance should make space for the new data by removing the LRU keys, but only from the set of keys that have their expiry values defined.

You should not use the allkeys-Iru eviction policy. With this policy, Azure Cache for Redis tries to remove the LRU keys first. However, it does not consider whether or not the keys have an expire set.

You should not use the allkeys-random eviction policy. With this policy, Azure Cache for Redis evicts keys randomly.

You should not use the noeviction policy. With this policy, no keys are evicted and the Azure cache for Redis instance will return an error when the memory limit is reached.

How well did you know this?
1
Not at all
2
3
4
5
Perfectly
13
Q

Your company is using Azure CDN to efficiently deliver web content to a geographically distributed group of users.

You are creating three separate Azure CDN profiles. You need to select an Azure CDN product for each profile in order to provide the required capabilities, as listed in the answer area.

You must ensure that the selected Azure CDN product remains supported in 2023 and beyond, without an imminent need to migrate to a different Azure CDN product due to product retirement.

Which Azure CDN product should you use for each capability? To answer, select the appropriate options from the drop-down menus.

Choose the correct options
Capability

Asset pre-loading

Real-time alerts for bandwidth utilization

Brotli compression encoding

A
  • Premium or Standard Verizon
  • Premium Verizon
  • Standard Microsoft

You should select Premium or Standard Verizon to provide asset pre-loading. The asset pre-loading feature proactively loads assets into the edge servers, rather than reactively loading them there after the first request. This provides a higher-performance customer experience. Both the Verizon Standard and Verizon Premium services provide this capability, and it is not provided by the Standard Microsoft or the Standard Akamai products.

You should select the Premium Verizon product to provide real-time alerts for bandwidth utilization. The real-time alerts capability provides instant notification of a selectable set of metrics, thus streamlining the CDN administration process. This is an advanced capability that is exclusive to the Premium Verizon product.

You should select the Standard Microsoft product to use Brotli compression encoding. This encoding was originally developed by Google. It provides a number of benefits over the standard GZIP encoding. Only the Standard Microsoft product currently supports this capability.

The scenario requirement of ensuring supportability of the Azure CDN product in 2023 and beyond is important to consider in the context of the Standard Akamai product, seeing as it is being retired on October 31, 2023. You can therefore automatically exclude it as the correct answer for all scenarios in this question.

How well did you know this?
1
Not at all
2
3
4
5
Perfectly
14
Q

You are developing an ASP.NET Core application that is configured with Application Insights instrumentation to track custom events and page views.

You need to support the marketing team with trend analytics about application usage.

Which Application Insights usage analysis features should you use? To answer, drag the appropriate feature to each requirement. Each feature may be used once, more than once, or not at all.

Drag and drop the answers
Requirement
Determine how many users were impacted by a marketing campaign website page.

Determine how a product page load time affects product sales.
Determine which events most influence users to return to your website.

A

Users
Impact
Retention

You should use users analytics to determine how many users were impacted by a marketing campaign website page. You can use users analytics to determine how many people used your application and how many users visited the campaign page. Users are counted by using anonymous IDs that are stored in browser cookies.

You should use impact analytics to determine how a product page load time affects product sales. Impact analytics determine how load times and other properties influence conversion rates, like clicking the purchase button, for your website. Conversion rates are calculated using a statistical technique named the Pearson correlation coefficient.

You should use retention analytics to determine which events most influence users to return to your website. You can use retention analytics to determine how many users return to your app, and how often they perform particular tasks, like visiting a sales campaign or the homepage.

You should not use funnels analytics. You can use funnels analytics to determine the dropout rate in a user journey until they perform a specific action, like purchasing a product. For example, $100 \%$ of your users visit the website homepage, but only $10 \%$ visit a specific product page, and fewer than than $2 \%$ click the purchase button and complete the purchase. You can focus and measure actions that reduce dropout between these pages.

How well did you know this?
1
Not at all
2
3
4
5
Perfectly
15
Q

You have the following code:

IDatabase database = ConnectionMultiplexer.Connect(connectionString).GetDatabase();
var result = database.Execute("PING").ToString();

What happens when this code is run?

A

It verifies a connection to an Azure Cache for Redis

This verifies a conn to an Azure Cache for Redis. When you execute a PING command, the value of the result is PONG if the conn is valid.

This does not determine if an Azure VM allows ICMP conns. The IDatabase interface reps a conn to an Azure Cache for Redis.

How well did you know this?
1
Not at all
2
3
4
5
Perfectly