Skip to content

Comments

Update federation error documentation#1956

Merged
pcapriotti merged 6 commits intodevelopfrom
pcapriotti/federation-error-docs
Dec 8, 2021
Merged

Update federation error documentation#1956
pcapriotti merged 6 commits intodevelopfrom
pcapriotti/federation-error-docs

Conversation

@pcapriotti
Copy link
Contributor

@pcapriotti pcapriotti commented Dec 2, 2021

This is about making sure that the documentation of federation errors in the public API is up to date with respect to the changes introduced in #1930.

Tracked by https://wearezeta.atlassian.net/browse/FS-262.

Checklist

  • The PR Title explains the impact of the change.
  • The PR description provides context as to why the change should occur and what the code contributes to that effect. This could also be a link to a JIRA ticket or a Github issue, if there is one.
  • changelog.d contains the following bits of information (details):
    • A file with the changelog entry in one or more suitable sub-sections. The sub-sections are marked by directories inside changelog.d.

@pcapriotti pcapriotti marked this pull request as draft December 2, 2021 09:53
@pcapriotti pcapriotti force-pushed the pcapriotti/federation-error-docs branch 2 times, most recently from 15a9329 to ded7730 Compare December 2, 2021 10:58
@pcapriotti pcapriotti marked this pull request as ready for review December 2, 2021 14:47
@pcapriotti pcapriotti force-pushed the pcapriotti/federation-error-docs branch from 16bcfb8 to 0fe676c Compare December 3, 2021 09:17
The markdown file is converted to a haskell module by a custom
`Setup.hs`.
The federation-denied error is client-visible, since it may be due to
errors in the original request. This makes the error propagate to the
client with status code 400.
Also change some error labels and status codes to make them more consistent.

The authentication error category has been merged with the remote
federation error category, and all errors of the same category now have
similar status codes.
@pcapriotti pcapriotti force-pushed the pcapriotti/federation-error-docs branch from 0fe676c to c6088e8 Compare December 7, 2021 12:53
@pcapriotti pcapriotti requested a review from smatting December 7, 2021 12:55
@pcapriotti pcapriotti merged commit eebfc3b into develop Dec 8, 2021
@pcapriotti pcapriotti deleted the pcapriotti/federation-error-docs branch December 8, 2021 09:25
pcapriotti added a commit that referenced this pull request Dec 9, 2021
* Fix expected status for federation-not-implemented

Co-authored-by: Matthias Fischmann <mf@zerobuzz.net>
@sysvinit sysvinit mentioned this pull request Dec 10, 2021
pcapriotti added a commit that referenced this pull request May 2, 2022
Since we are using file-embed-lzma to embed swagger definitions in the
executable (and servant-swagger itself is using it to embed the swagger
frontend), there is no point in maintaining a second way to embed static
files into the executable.

Therefore, this commit removes the mechanism for loading the swagger
description at compile time via a custom `Setup.hs`, introduced in
#1956, and simply embeds it
using `embedText` from `file-embed-lzma`.
pcapriotti added a commit that referenced this pull request May 9, 2022
Since we are using file-embed-lzma to embed swagger definitions in the
executable (and servant-swagger itself is using it to embed the swagger
frontend), there is no point in maintaining a second way to embed static
files into the executable.

Therefore, this commit removes the mechanism for loading the swagger
description at compile time via a custom `Setup.hs`, introduced in
#1956, and simply embeds it
using `embedText` from `file-embed-lzma`.
pcapriotti added a commit that referenced this pull request May 9, 2022
* New stab at an API versioning policy

* Add some client examples

* Add header in version middleware

* Add current swagger descriptions for v0 and v1

* Add Servant combinators for versioning

* Remove deprecated Brig endpoints in latest version

* Extract general version utilities

* WIP: federation api versioning

* Set up versioning and negotiation for fed API

* Fix federator unit tests

* fixup! New stab at an API versioning policy

* Add API fetch test in federator

* Implement remote api-version as a normal RPC

* Add API version fetch test

* Get rid of api-version special cases in federator

* Simplify brig federation client definitions

* Fix integration test

* Fix API versioning tests

* Start galley V2 API

* Explain client versioning approach in docs

* Start cargohold V2 API

* Serve old swagger versions

* Replace brig custom setup with file-embed-lzma

Since we are using file-embed-lzma to embed swagger definitions in the
executable (and servant-swagger itself is using it to embed the swagger
frontend), there is no point in maintaining a second way to embed static
files into the executable.

Therefore, this commit removes the mechanism for loading the swagger
description at compile time via a custom `Setup.hs`, introduced in
#1956, and simply embeds it
using `embedText` from `file-embed-lzma`.

* Add API version federation endpoint test

* Always run version negotiation on Brig

* Update and reformat old swaggers

* Add CHANGELOG entry

* Fix integration test assertion

* Add development field to public API version info

* Fix typo in CHANGELOG entry

Co-authored-by: fisx <mf@zerobuzz.net>

* Small clarification in api versioning docs

Co-authored-by: fisx <mf@zerobuzz.net>

* Grammar

Co-authored-by: fisx <mf@zerobuzz.net>

* Note about clients ignoring development versions

* Do not advertise development versions by default

Also add an option to enable development versions.

* Add more CHANGELOG entries

Co-authored-by: fisx <mf@zerobuzz.net>
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants