You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Copy file name to clipboardExpand all lines: README.md
+1-1Lines changed: 1 addition & 1 deletion
Display the source diff
Display the rich diff
Original file line number
Diff line number
Diff line change
@@ -191,7 +191,7 @@ sam deploy --parameter-overrides SyncUserFields=phoneNumbers,addresses,enterpris
191
191
## ⚠️ Limitations
192
192
193
193
***Group Limit**: The AWS SSO SCIM API has a limit of 50 groups per request. Please support the feature request on the [AWS Support site](https://repost.aws/questions/QUqqnVkIo_SYyF_SlX5LcUjg/aws-sso-scim-api-pagination-for-methods) to help get this limit increased.
194
-
***Throttling**: With a large number of users and groups, you may encounter a `ThrottlingException` from the AWS SSO SCIM API. This project uses a [retryable HTTP client](https://github.com/p2p-b2b/httpretrier) to mitigate this, but it's still a possibility.
194
+
***Throttling**: With a large number of users and groups, you may encounter a `ThrottlingException` from the AWS SSO SCIM API. This project uses the [httpx](https://github.com/slashdevops/httpx) library with automatic retry and jitter backoff to mitigate this, but it's still a possibility.
195
195
***User Status**: The Google Workspace API doesn't differentiate between normal and guest users except for their status. This project only syncs `ACTIVE` users.
Copy file name to clipboardExpand all lines: docs/Whats-New.md
+36Lines changed: 36 additions & 0 deletions
Display the source diff
Display the rich diff
Original file line number
Diff line number
Diff line change
@@ -2,6 +2,42 @@
2
2
3
3
This document tracks notable changes, new features, and bug fixes across releases.
4
4
5
+
## v0.40.1
6
+
7
+
### Improved HTTP Retry Library
8
+
9
+
Replaced the `httpretrier` library with [httpx](https://github.com/slashdevops/httpx), a zero-dependency HTTP client with built-in retry support.
10
+
11
+
**Why:** The previous library did not properly handle HTTP `429 Too Many Requests` responses, which caused issues with AWS SSO SCIM API throttling under high load.
12
+
13
+
**What changed:**
14
+
15
+
* The `httpx` library automatically retries on `429` and `5xx` responses with configurable backoff strategies.
16
+
* AWS SCIM API calls now use **jitter backoff** instead of simple exponential backoff, reducing the chance of thundering herd effects during rate limiting.
17
+
* Google Workspace API calls use **exponential backoff** for reliable retries.
18
+
* The `httpx` library has zero external dependencies and integrates with Go's `slog` logging.
19
+
20
+
### AWS SCIM Client Improvements (`pkg/aws`)
21
+
22
+
Several code quality improvements and bug fixes in the AWS SCIM client:
23
+
24
+
***Bug fix:**`CreateOrGetUser` used `reflect.DeepEqual` to compare a `*CreateUserRequest` with a `*GetUserResponse` — different types, so the comparison always returned `false`, causing unnecessary PUT updates on every 409 conflict. Replaced with a typed `usersEqual` function that compares only sync-relevant attributes.
25
+
***Removed `pkg/errors` dependency:** Replaced with stdlib `errors` and `fmt` packages. Sentinel errors now use `errors.New` instead of `errors.Errorf`.
26
+
***Go 1.26 `errors.AsType`:** Migrated all `errors.As` calls to the generic `errors.AsType[T]` for compile-time type safety and better performance.
27
+
***Fixed `String()` methods:**`User.String()` and `Group.String()` no longer call `os.Exit(1)` on marshal failure. They return a safe fallback string instead.
28
+
***Eliminated double JSON decode:**`GetUserByUserName` and `GetGroupByDisplayName` no longer marshal a resource to JSON and re-parse it. They use direct type conversion instead.
29
+
***Fixed decode error fallback:**`CreateGroup` and `CreateOrGetGroup` no longer attempt to read an already-consumed response body on decode failure.
30
+
***Removed redundant context set:**`do()` no longer calls `req.WithContext(ctx)` since the request is already created with `http.NewRequestWithContext`.
31
+
***Simplified type conversions:**`CreateOrGetUser` and `CreateOrGetGroup` use type conversions instead of manual field-by-field struct copies.
32
+
33
+
### Go 1.26 Modernization
34
+
35
+
Applied Go 1.26 best practices across the codebase:
36
+
37
+
***Removed `github.com/pkg/errors` dependency:** Replaced all `errors.Wrap` and `errors.Errorf` with stdlib `fmt.Errorf` (with `%w`) and `errors.New` in `internal/setup`, `internal/repository`, and `pkg/aws`.
38
+
***`errors.AsType[T]`:** Migrated `errors.As` calls to the generic `errors.AsType[T]` in `internal/core/sync.go` for type safety and performance.
39
+
***Fixed `os.Exit` in `Hash()`:**`internal/model.Hash()` no longer calls `os.Exit(1)` on nil input or encoding failure. It panics instead (appropriate for programming errors, recoverable, produces stack trace).
0 commit comments