Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Subparty forsvinner fra party-response #1226

Closed
seanes opened this issue Oct 4, 2024 · 5 comments
Closed

Subparty forsvinner fra party-response #1226

seanes opened this issue Oct 4, 2024 · 5 comments
Assignees
Labels
bug Something isn't working

Comments

@seanes
Copy link

seanes commented Oct 4, 2024

Symptomer

Subparty urn:altinn:organization:identifier-no:910519794 for bruker "forsvinner" fra responsen til parties-query. Etter stale time på ca 5 minutter, dukker sub party opp igjen, kun ved én fetch, deretter forsvinner det igjen. Har kun opplevd én gang å få subparty i liste over konsekutive fetches (torsdag i 1605-tiden)

Funn

Innlogget bruker 07117000413 EDEL REISERSEN

Opprettet dialog med id 019256a5-38ea-7095-9664-543168df9796

{
  searchDialogs(input: {
    party: ["urn:altinn:organization:identifier-no:910519794"]
  }) {
    items {
      id
      party
    }
  }
}

returnerer tom liste, mens f.eks.

{
  dialogById(dialogId: "019256a5-38ea-7095-9664-543168df9796") {
    dialog {
      party
      content {
        title { value { languageCode value}}
      }
      id  
    }
  }
}

returnerer dialog.

@seanes seanes added the bug Something isn't working label Oct 4, 2024
@oskogstad oskogstad self-assigned this Oct 4, 2024
@coderabbitai coderabbitai bot mentioned this issue Nov 12, 2024
oskogstad added a commit that referenced this issue Nov 22, 2024
<!--- Provide a general summary of your changes in the Title above -->

## Description

<!--- Describe your changes in detail -->

## Related Issue(s)

- #1226 

## Verification

- [ ] **Your** code builds clean without any errors or warnings
- [ ] Manual testing done (required)
- [ ] Relevant automated test added (if you find this hard, leave it and
we'll help out)

## Documentation

- [ ] Documentation is updated (either in `docs`-directory, Altinnpedia
or a separate linked PR in
[altinn-studio-docs.](https://github.com/Altinn/altinn-studio-docs), if
applicable)


<!-- This is an auto-generated comment: release notes by coderabbit.ai
-->
## Summary by CodeRabbit

- **New Features**
- Introduced new fields in the `AuthorizedParty` and
`AuthorizedSubParty` types to enhance user representation and
relationships.
- Added a new type `AuthorizedSubParty` to support nested party
structures.

- **Bug Fixes**
- Improved the `GetAuthorizedParties` method to return a more complex
structure, including nested sub-party information.

- **Refactor**
- Updated class structure and inheritance for `AuthorizedParty` and
`AuthorizedSubParty` to facilitate better organization and
relationships.
<!-- end of auto-generated comment: release notes by coderabbit.ai -->
oskogstad added a commit that referenced this issue Nov 22, 2024
<!--- Provide a general summary of your changes in the Title above -->

## Description

<!--- Describe your changes in detail -->

## Related Issue(s)

- #1226 

## Verification

- [ ] **Your** code builds clean without any errors or warnings
- [ ] Manual testing done (required)
- [ ] Relevant automated test added (if you find this hard, leave it and
we'll help out)

## Documentation

- [ ] Documentation is updated (either in `docs`-directory, Altinnpedia
or a separate linked PR in
[altinn-studio-docs.](https://github.com/Altinn/altinn-studio-docs), if
applicable)


<!-- This is an auto-generated comment: release notes by coderabbit.ai
-->

## Summary by CodeRabbit

- **Bug Fixes**
- Resolved issues with the caching mechanism for retrieving authorized
parties, now using direct requests to improve reliability.
- **Improvements**
- Enhanced clarity in the claims retrieval process for authorized
resources.
- Maintained robust error handling to ensure integrity in the
authorization process.

<!-- end of auto-generated comment: release notes by coderabbit.ai -->
@knuhau knuhau self-assigned this Nov 25, 2024
oskogstad added a commit that referenced this issue Nov 26, 2024
<!--- Provide a general summary of your changes in the Title above -->

## Description

<!--- Describe your changes in detail -->

## Related Issue(s)

- #1226 

## Verification

- [ ] **Your** code builds clean without any errors or warnings
- [ ] Manual testing done (required)
- [ ] Relevant automated test added (if you find this hard, leave it and
we'll help out)

## Documentation

- [ ] Documentation is updated (either in `docs`-directory, Altinnpedia
or a separate linked PR in
[altinn-studio-docs.](https://github.com/Altinn/altinn-studio-docs), if
applicable)
oskogstad added a commit that referenced this issue Nov 26, 2024
<!--- Provide a general summary of your changes in the Title above -->

## Description

<!--- Describe your changes in detail -->

## Related Issue(s)

- #1226

## Verification

- [ ] **Your** code builds clean without any errors or warnings
- [ ] Manual testing done (required)
- [ ] Relevant automated test added (if you find this hard, leave it and
we'll help out)

## Documentation

- [ ] Documentation is updated (either in `docs`-directory, Altinnpedia
or a separate linked PR in
[altinn-studio-docs.](https://github.com/Altinn/altinn-studio-docs), if
applicable)
oskogstad added a commit that referenced this issue Nov 26, 2024
<!--- Provide a general summary of your changes in the Title above -->

## Description

<!--- Describe your changes in detail -->

## Related Issue(s)

- #1226

## Verification

- [ ] **Your** code builds clean without any errors or warnings
- [ ] Manual testing done (required)
- [ ] Relevant automated test added (if you find this hard, leave it and
we'll help out)

## Documentation

- [ ] Documentation is updated (either in `docs`-directory, Altinnpedia
or a separate linked PR in
[altinn-studio-docs.](https://github.com/Altinn/altinn-studio-docs), if
applicable)


<!-- This is an auto-generated comment: release notes by coderabbit.ai
-->

## Summary by CodeRabbit

- **Bug Fixes**
- Removed unnecessary logging and reflection in cache handling,
simplifying error management.
- Temporarily disabled setting of sub-parties in the party flattening
logic for ongoing development.

- **Chores**
- Removed the "Serilog" logging configuration from the app settings,
streamlining the configuration file.

<!-- end of auto-generated comment: release notes by coderabbit.ai -->
oskogstad added a commit that referenced this issue Dec 2, 2024
<!--- Provide a general summary of your changes in the Title above -->

## Description

<!--- Describe your changes in detail -->
Enables
[AutoClone](ZiggyCreatures/FusionCache#279)
feature in FusionCache
## Related Issue(s)

- #1226 

## Verification

- [x] **Your** code builds clean without any errors or warnings
- [x] Manual testing done (required)
- [ ] Relevant automated test added (if you find this hard, leave it and
we'll help out)

## Documentation

- [ ] Documentation is updated (either in `docs`-directory, Altinnpedia
or a separate linked PR in
[altinn-studio-docs.](https://github.com/Altinn/altinn-studio-docs), if
applicable)


<!-- This is an auto-generated comment: release notes by coderabbit.ai
-->

## Summary by CodeRabbit

- **New Features**
- Introduced a new property, `EnableAutoClone`, in the caching
configuration to enhance cache management.
- **Bug Fixes**
- Activated the assignment of an empty list to the `SubParties`
property, ensuring no sub-parties are included in the authorized parties
result.
- **Style**
- Minor formatting adjustments made for improved readability in the
caching configuration.

<!-- end of auto-generated comment: release notes by coderabbit.ai -->
@LeifHelstad
Copy link

LeifHelstad commented Dec 2, 2024

Test:
Usikker på om dette gjør noe fra eller til som bevis. Kallet returnerer i det minste et sub-party.
Planen for test er at en "noe" sendt til sub-party ikke skal forsvinne.

image

@oskogstad
Copy link
Collaborator

@LeifHelstad Ah, glemte å oppdatere saken her med hvordan reprodusere.

100% repro var:

  1. Kall authorized parties med en bruker (webapi eller gql), du får tilbake sub-parties

  2. Gjør et søk med samme bruker mot samme presentasjonslag (webapi/gql)

  3. Kall samme authorized parties igjen med samme bruker, sub-parties mangler, og mangler i ~15min etter at steg 2 ble gjort

Kunne hende at du kun fikk feil annenhvert kall om du gjentok steg 3. Kom an på om det var flere replicas av containerene kjørende.

@LeifHelstad
Copy link

Test:

Velger bruker Ask Uglesett 12907499179 som har en del parties og sub-parties som bør vises:
"party": "urn:altinn:person:identifier-no:12907499179",
"name": "ASK UGLESETT",
"party": "urn:altinn:organization:identifier-no:213294342",
"name": "LATTERMILD ORIENTAL TIGER AS",
"party": "urn:altinn:organization:identifier-no:215421902",
"name": "LATTERMILD ORIENTAL TIGER AS",
"party": "urn:altinn:organization:identifier-no:313549461",
"name": "ORDENTLIG VIRTUELL TIGER AS",
"party": "urn:altinn:organization:identifier-no:311615696",
"name": "DYPSINDIG FUNKSJONELL FJELLREV",
"party": "urn:altinn:organization:identifier-no:311615688",
"name": "UPRESIS KONSENTRISK FJELLREV",
"party": "urn:altinn:organization:identifier-no:313776816",
"name": "PLUTSELIG NYBAKT TIGER AS",
"party": "urn:altinn:organization:identifier-no:315073693",
"name": "PLUTSELIG NYBAKT TIGER AS",
"party": "urn:altinn:organization:identifier-no:312409216",
"name": "STYRBAR UTTRYKKSFULL TIGER AS",
"party": "urn:altinn:organization:identifier-no:314518748",
"name": "STYRBAR UTTRYKKSFULL TIGER AS",

Kjører testen via arbeidsflate, som jeg da oppfyller kravet om at alle kall i 1. 2 og 3 gjøres av samme bruker i samme API.

Observerer;
Steg 1:

  • Alle navn fra både både party og sub-party i listen fremkommer
  • I de tilfeller sub-party har samme navn som sitt party fremkommer navnet kun en gang i menyen.

Oppretter en dialog så jeg har noe å lage søk på som gir treff i steg 2
"01939b61-8b48-778b-8132-b94bc5f05484"

Steg 2:
1 treff i innboks

Venter fra 10:53

@LeifHelstad
Copy link

LeifHelstad commented Dec 6, 2024

Etter vent så fremkommer alle aktører som før.
Også etter en refresh av siden (etter det pnuktet over).
Innså så at søket fortsatt sto aktivt og ble usikker på om det påvirker 2.

Gjør derfor en ny 2 nå, men kysser så ut søkekriterier før jeg starter ventetiden (11:48).

@LeifHelstad
Copy link

Også etter denne varianten fremkommer alle aktører som før. Får ikke gjenskapt beskrevet problem via arbeidsflate og anser testen som Passed.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
bug Something isn't working
Projects
Development

No branches or pull requests

5 participants