Hacktoberfest 2026: the issues maintainers tagged for October, open and beginner-friendly. Browse Hacktoberfest issues

[BUG]ProductLink ID conflict during Publish after upgrading from v4 to v7

Open
#852 2 comments 0 reactions 0 assignees View on GitHub

Nobody has claimed this yet.

Assessment

Difficulty
4/5
Estimated time
3-5 days
Newbie friendliness
45/100
Issue type
Bug
Clarity
Mostly clear
Activity status
Quiet
Tech stack
azure, csharp
Domain
api, devops

Research direction

Start by reproducing the migration with the v7 Extractor and Publisher using the two-environment ProductLink setup described in the issue. Inspect the generated configuration for the captured productLink ID and compare the Publisher's handling of that link with the existing target link; done means deployment succeeds when the environments use different internal IDs.

Written by the indexing model from the issue text.

Description

Release version

APIM v7.0.0

Describe the bug

We are currently migrating our APIM DevOps process from v4 (specifically version [Insert Exact Version]) to v7.

In our existing environment (deployed originally using v4), we have several Groups linked to Products. In the v4 repository structure, these links were handled without explicit IDs in the configuration files.

When using the v7 Extractor on our Development environment, the tool now captures the productLink ID and stores it in the repository.

When we run the v7 Publisher to deploy these changes to higher environments (Test/Prod), the deployment fails.

The error indicates that a productLink already exists on the target environment but has a different Resource ID than the one captured from Dev and stored in the repo.

In v4: The extracted files did not contain a specific productLink ID. Deployment worked seamlessly across environments as it likely matched by name/relation rather than a specific GUID.

In v7: The productLink ID is hardcoded in the extracted JSON/YAML. If the target environment already has that link established with a different ID, the Publisher fails.

Is this change in behavior (hardcoding the productLink ID during extraction) an intended feature or a bug?

Is there a recommended workflow to resolve this conflict during a migration? Should these IDs be tokenized, or is there a way to make the Publisher ignore the ID and match by Product/Group name instead?

Expected behavior

The Publisher should be able to synchronize Product-to-Group links across different environments regardless of the internal Resource ID (GUID).

Since these links represent a relationship between two named entities (a specific Product and a specific Group), the tool should ideally match them by name/reference or update the existing link.

Upgrading from v4 to v7 should not break existing CI/CD pipelines for resources that were previously deployed without explicit IDs.

Actual behavior

The v7 Extractor captures a specific, hardcoded ID for the productLink resource, when the Publisher attempts to deploy this to a target environment where the link already exists (but was created with a different internal ID), the deployment fails with a conflict error.

Reproduction Steps
  1. Environment Setup: Have two APIM instances (Dev and Prod). Link a Group to a Product in both environments
  2. Extraction: Use the v7 Extractor on the Dev environment.
    *the generated configuration file now contains a specific GUID/ID for the productLink.
  3. Deployment: Run the v7 Publisher using the extracted files from step 2, targeting the Prod environment.
  4. Failure: The Publisher fails during the productLink deployment phase because the link already exists in Prod with a different ID than the one captured from Dev.
Dominant language
C#
Stars
448
Forks
247
PR merge metrics
No merged PRs in 30d

Contributor guide

Open the contributing guide

First steps

  1. Read the whole issue, then the project's contributing guide.
  2. Comment on the issue to say you are picking it up — it saves two people doing the same work.
  3. Fork the repository and make your change on a branch.
  4. Open a pull request that references the issue number.

More from Azure/apiops

All issues in Azure/apiops

Similar issues

More C# issues

Get new issues in your inbox

A short digest of beginner-friendly GitHub issues.