ocean icon indicating copy to clipboard operation
ocean copied to clipboard

[Integration][Azure DevOps] Use Service ID As Identifier in Default Mapping

Open emekanwaoma opened this issue 1 week ago • 2 comments

User description

Description

What -

  • Switched the identifier mapping for the Azure DevOps service blueprint to use the native .id in integrations/azure-devops/.port/resources/port-app-config.yaml.

Why -

  • The previous string-composed identifier (from project and service names) was subject to normalization (case/whitespace) and potential collisions. Using the native id ensures uniqueness and stability across resyncs and live events.

How -

  • Replaced the jq expression that built the identifier from names with .id.

Type of change

Please leave one option from the following and delete the rest:

  • [x] Non-breaking change (fix of existing functionality that will not change current behavior)

All tests should be run against the port production environment(using a testing org).

Core testing checklist

  • [x] Integration able to create all default resources from scratch
  • [x] Resync finishes successfully
  • [x] Resync able to create entities
  • [x] Resync able to update entities
  • [x] Resync able to detect and delete entities
  • [x] Scheduled resync able to abort existing resync and start a new one
  • [x] Tested with at least 2 integrations from scratch
  • [x] Tested with Kafka and Polling event listeners
  • [x] Tested deletion of entities that don't pass the selector

Integration testing checklist

  • [x] Integration able to create all default resources from scratch
  • [x] Completed a full resync from a freshly installed integration and it completed successfully
  • [x] Resync able to create entities
  • [x] Resync able to update entities
  • [x] Resync able to detect and delete entities
  • [x] Resync finishes successfully
  • [x] If new resource kind is added or updated in the integration, add example raw data, mapping and expected result to the examples folder in the integration directory.
  • [x] If resource kind is updated, run the integration with the example data and check if the expected result is achieved
  • [x] If new resource kind is added or updated, validate that live-events for that resource are working as expected
  • [ ] Docs PR link here

Preflight checklist

  • [ ] Handled rate limiting
  • [ ] Handled pagination
  • [ ] Implemented the code in async
  • [ ] Support Multi account

Screenshots

Include screenshots from your environment showing how the resources of the integration will look.

API Documentation

Provide links to the API documentation used for this integration.


PR Type

Enhancement


Description

  • Replace composite identifier with native .id in Azure DevOps repository mapping

  • Ensures stable, unique identifiers across resync and live events

  • Eliminates normalization issues from case/whitespace handling

  • Bump version to 0.4.33 with changelog entry


Diagram Walkthrough

flowchart LR
  A["Composite identifier<br/>project+service names"] -->|normalization issues| B["Instability & collisions"]
  C["Native .id field"] -->|stable & unique| D["Reliable entity mapping"]
  A -.->|replaced with| C

File Walkthrough

Relevant files
Enhancement
port-app-config.yaml
Replace composite identifier with native ID                           

integrations/azure-devops/.port/resources/port-app-config.yaml

  • Changed repository kind identifier from composite jq expression to
    native .id field
  • Removed complex string normalization logic that downcased and removed
    special characters
  • Simplifies mapping while ensuring uniqueness and stability
+1/-2     
Documentation
CHANGELOG.md
Add changelog entry for version 0.4.33                                     

integrations/azure-devops/CHANGELOG.md

  • Added version 0.4.33 release notes
  • Documented improvement: using .id as identifier for repository kind
  • Explained benefits: stable keys and avoiding normalization issues
+8/-0     
Configuration changes
pyproject.toml
Update version to 0.4.33                                                                 

integrations/azure-devops/pyproject.toml

  • Bumped version from 0.4.32 to 0.4.33
+1/-1     

emekanwaoma avatar Nov 19 '25 14:11 emekanwaoma