Skip to content

README: Add migration guidance for breaking changes in v3.0.114 (pageIndex + CancellationToken) #4

Description

@davidnmbond

Problem

When upgrading from Cisco.Api 3.0.104 to 3.0.114, several API interface methods have breaking changes:

  1. Added required pageIndex parameter to methods that previously didn't require one:

    • IEox.GetBySoftwareReleaseStringAsync(IEnumerable<string>) now requires int pageIndex (default: 1)
    • IEox.GetBySerialNumberAsync(string) now requires int pageIndex (default: 1)
    • ISoftwareSuggestion.GetByProductIdsAsync(IEnumerable<string>) now requires int pageIndex (default: 1)
  2. Added required alias parameter to:

    • ISecurityAdvisory.GetAdvisoriesByOsTypeAndVersion(string type, string version) now requires string alias (default: "")
  3. All obsolete overloads without CancellationToken are now errors (Obsolete(..., true)), requiring callers to pass a CancellationToken:

    • ISerialNumberToInfo.GetCoverageStatusBySerialNumbersAsync
    • ISerialNumberToInfo.GetCoverageSummaryBySerialNumbersAsync
    • IProductInfo.GetBySerialNumbersAsync
    • ISecurityAdvisory.GetOsVersionDataByType
    • ISecurityAdvisory.GetAdvisoriesByCveName
    • ISecurityAdvisory.GetAdvisoriesByProduct

Suggestion

Add a migration section to README.md (similar to what Uk.Parliament does) showing before/after examples for each breaking change. For example:

## Migration from 3.0.x to 3.0.114

### pageIndex parameter
Methods on `IEox` and `ISoftwareSuggestion` now require an explicit `pageIndex` parameter. Pass `1` for single-page requests:

```csharp
// Before
var result = await client.Eox.GetBySerialNumberAsync(serial);

// After
var result = await client.Eox.GetBySerialNumberAsync(serial, 1, cancellationToken);

CancellationToken now required

All overloads without CancellationToken are removed. Add cancellationToken (or default) as the last argument.


This would have saved significant time when upgrading MagicSuite from 3.0.104 to 3.0.114.

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Fields

    No fields configured for issues without a type.

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions