QuestionQ195
VerifiedDevelop Azure compute solutionsHOTSPOT
You are developing an online game in which players vote for their preferred photo that illustrates a word. The game is built with Azure Functions and uses durable entities to track vote counts.
The voting window is 30 seconds, and you must minimize latency.
You need to implement the Azure Function for voting.
How should you complete the code?
Select
[FunctionName("Vote")] public static async Task<HttpResponseMessage> Run( [HttpTrigger("POST", Route = "pic/{id}")] HttpRequestMessage req, c, string id) { var eid = new EntityId("pic", id); await c.(eid, "vote"); return req.CreateResponse(HttpStatusCode.OK); }
Community Discussion