Exam-Answer

Home / Microsoft / AZ-300 / Question 82

Prev Question
Next Question

Question 82

You are using the WebJobs SDK to create an Azure WebJob. You write the following code (line numbers are included for reference only):

01 static void Main(string[] args)

02 {

03 var config = new JobHostConfiguration();

04 var host = new JobHost(config);

05

06 }

You need to complete the code at line 05 so that the WebJob can be manually triggered.

Which code should you add at line 05?

Answers



A B C D

Advertisement

Explanation

You should call host.RunAndBlock. This method starts the WebJob and blocks the current thread so that it can keep running.

You should not call host.Start. This method starts the WebJob, but it does not block the current thread. This causes it to stop as soon as the Main method returns.

You should not call host.Call. This method allows you to have the WebJob call an external method.

References

Comments

Load more
Prev Question
Next Question