Conflict once creating elastic job agent

Conflict once creating elastic job agent

I explained about elastic job agent earlier and how we use that to create SQL Job in Azure, I experienced new issue related to creating elastic job agent recently, once the user tried to create this after a minute he got “Conflict” error message and could not find more details.

Here is what I reproduced it in my lab.

In Operation details also there was not details to find what is the root cause.

 
{"code":"DeploymentFailed","message":"At least one resource deployment operation failed. Please list deployment operations for details. Please see https://aka.ms/arm-deployment-operations for usage details.","details":[{"code":"InternalServerError","message":"An unexpected error occured while processing the request. Tracking ID: '01ca9c4d-xxx-45fa-xxxx-bbbbbbbb'"}]}.

If you also have same issue, the reason behind this could be server less database if you also use it.

Microsoft does not support elastic job agent on auto paused enabled databases at this time. This is because the elastic job agent works by polling the provided jobs DB to fetch any new job definition information and to update job status. Therefore, the database would never actually go serverless. Please provision the job agent on a DB that does not have auto paused enabled!

If you’re interested you see the referral link and some Known limitations for elastic jobs.

The solution for the user was move to provisioned tier, Azure Functions may be alternative in some cases.