Azure Marketplace: Update apiVersion for "Microsoft.Resources/deployments" resource

David Olsson 111 Reputation points
2021-03-23T19:36:59.427+00:00

Trying to publish an Azure Application to the Azure Marketplace. The solutions template is working but it is failing a best practices test when I attempt to make it live (Go Live button in the Partner Center portal).

The best practice failure:
`##[error] Api versions must be the latest or under 2 years old (730 days) - API version 2018-05-01 of Microsoft.Resources/deployments is 1057 days old

So I updated the apiVersion for the resource in question and attempted to upload it via the Partner Center portal and I get this error message:
Package acceptance validation error: AzureAppTrackingIdFound The uploaded package has an additional resource in the mainTemplate.json. The resource - "name": "pid-xxxxxxxx-xxxx-xxxx-xxxx-xxxxxxxxxxxxxxxx" should not be present. Error code: PAC-AzureAppTrackingIdFound

Strange error since I'm only changing the apiVersion.

When I remove that resource from maintemplate.json I do not see the error in Partner Center. However, the package still fails the same best practice test since it seems there is no way to update the apiVersion for that resource.

Does anybody have experience with this? I'm certain I'm doing something wrong but I don't see where.

I've also created a support case via the Partner Center for this but hoping somebody can point me in the right direction.

Thanks,

David Olsson

Not Monitored
Not Monitored
Tag not monitored by Microsoft.
36,250 questions
{count} vote

Accepted answer
  1. David Olsson 111 Reputation points
    2021-03-29T19:10:06.56+00:00

    @Jason Johndrow

    It is "solved" but I'm not sure what I did or if this was even caused by me.

    I opened a ticket in the Partner Center, waited 2 days for a response, tested this again before I had a scheduled meeting with MS support and it worked. Worked meaning I submitted the solutions template via Partner Center and saw the changes reflected in the pull request.

    Before I opened the ticket I tried many different iterations of the "Microsoft.Resources/deployments" resource section. This had no immediate impact and I noticed that many of my submissions never showed up in the pull request (https://solutiontemplates.visualstudio.com/marketplacesolutions/_git/). Also, this seems like a moving target right now given this note I found in the doc (https://learn.microsoft.com/en-us/azure/marketplace/azure-partner-customer-usage-attribution):

    "For existing Azure apps, a one-time migration began in March 2021 to update the tracking IDs in each plan's technical configuration. Usage from past deployments of those offers will remain tracked in Microsoft systems.

    As you update your offers, you no longer need to add the Microsoft.Resources/deployments resource type in your main template file."

    Eventually this updated and I now submit the solutions template without the "Microsoft.Resources/deployments" resource in mainTemplate.json. I believe the Partner Center adds this section as I now see this in repo (https://solutiontemplates.visualstudio.com/marketplacesolutions/_git/):
    " {
    "name": "pid-xxxxxxxx-xxxx-xxxx-xxxx-xxxxxxxxxxxx-partnercenter",
    "type": "Microsoft.Resources/deployments",
    "apiVersion": "2020-10-01",
    "properties": {
    "mode": "Incremental",
    "template": {
    "$schema": "https://schema.management.azure.com/schemas/2019-04-01/deploymentTemplate.json#",
    "contentVersion": "1.0.0.0",
    "resources": []
    }
    }
    },"

    Hope this helps and hope this post is not deleted as it's off topic for these forums.

    2 people found this answer helpful.
    0 comments No comments

0 additional answers

Sort by: Most helpful