Commit Graph
15 Commits
Author SHA1 Message Date
Ryan Derr a396d60232 fix(db): Update migration 102 sql file to correct name including .up (#6295) 2025-12-09 10:07:29 -06:00
Ryan DerrandLouis Ruch bd4dd9808a Conflicting Error Code Bump (#6002)
* Bump up the error code for InvalidListToken such that it does not conflict with the error code Paused

* chore: reorder the errors and give 136 to InvalidListToken over Pausedx

* chore(errors): Add missing tests and err info

---------

Co-authored-by: Louis Ruch <louisruch@gmail.com>
2025-08-28 12:30:41 -05:00
Ryan DerrandBharath Gajjala 4d3cb76c28 Cassandra Connect Support (#5952)
* Init cassandra

* Init cassandra

* Initial Cassandra Command Support For cqlsh

* Add Make Gen

* adding cassandra test

* Cleanup cassandra docker setup

* Adding container wait

* Container restart

* Minor Fix

* Cleanup docker and test

* Adding final tests

* Removing comment

* Fixing cleanup (uncomment)

* Removing bad yaml

* Cleanup

* Cleanup

* Adressing PR review comments

* Adding test support

* fix spacing

* Adding changelog

* docs

* docs

* adding cassandra page

* nav

* Versbose commenting

* cleanup naming of file

* updating helper func to return errors

* doc change

* Removed an incorrect comment and now passing the config by reference.

* Comment cleanup

* Fix option warning in cassandra connect command (#5951)

* Add healthcheck to caller function as it's resposible for container health

* Resolve Comments

* Update Log Typo

---------

Co-authored-by: Bharath Gajjala <120367134+bgajjala8@users.noreply.github.com>
2025-07-30 16:21:11 -05:00
Ryan Derr 67d55f3743 ICU-17341 Update UpdateControllerStatus to handle empty string descriptions. When reading from the server_controller database, NULL descriptions are cast to empty strings. To prevent violating the wt_description_too_short constraint in the wt_description domain, ensure that empty string descriptions are converted to nil before being passed. (#5894) 2025-07-02 13:45:26 -05:00
Ryan Derr 7040374b6f Postgres 15 -> 16 Migration Update (#5825)
* ICU-17235 fix(sql): add explicit casting to resolve Postgres 16 domain constraint changes

This migration updates the `wt_alias` and `wt_target_alias` domains to include explicit `::text` casting in their constraints. Postgres 16 enforces stricter domain checks, requiring explicit casts to ensure compatibility. These changes address upgrade issues by aligning the constraints with the stricter evaluation rules.

* Add Comment To Old Constraints
2025-06-13 08:27:38 -05:00
Ryan Derr cf35dce3fa Remove Duplicate Error Check That's Unreachable And Is Not Tested Against (#5799) 2025-05-27 12:30:53 -05:00
Ryan Derr 093226a057 ListResolvableAliasesPermissions Hotfix (#5673)
* ICU-16921 Fix ListResolvableAliasesPermissions where function skips some permission building when all children scope is provided, this currently results in skipping subsequent direct grants. Also, update listResolvableAliasesRepo to return early with no data when splitting permissions yields no relevant permissions.

* Remove conditional split permission check for listResolvableAliasesRefresh and listRemovedResolvableAliasIds as condition is never reachable. Additionally remove unecessary grants being given to list targets as part of TestACL_ListResolvableAliasesPermissions.

* Remove additonal 'type=target;actions=list' grants as part of TestACL_ListResolvableAliasesPermissions

* Update Switch Statement Too Factor For Edge Case With Children Granted With Role Scope Global

* Resolve comment to refactor error return in listResolvableAliases to instead return no data and document why and when this can occur.

* Add unit tests to cover case where provided permissions to ListResolvableAliases service contains no grant scopes where targets can reside.
2025-05-02 13:12:32 -05:00
Ryan Derr 25bb217a7a Database Init Flags Refactor (#5668)
* ICU-16920 Refactor Boundary Database Init Flags for Improved Dependency Handling

This commit refactors the database initialization flags to prevent early exits and ensure explicit handling of flag dependencies. If one flag relies on resources skipped by another, the dependent flag will also be skipped.

Key Changes:
- Introduced a `InitFlags` struct to organize existing flags and establish a clear pattern for adding future flags.
- Added receiver functions on the `InitFlags` struct to determine whether a flag should be skipped based on provided options or dependencies.
- Refactored the `Run()` method to avoid early returns when a flag skips resource creation. Instead, a log message is provided to indicate the skipped option, and the process continues with resource creation.

* Resolve Comments
2025-04-27 13:16:02 -05:00
Ryan Derr 6d9f97d6c8 ICU-16457 Split Liveness Query In Two (#5628)
* Fix #5602: Ensure controller status update triggers update_time

Rework and fix the logic of #5602 query split. Initial implementation failed to update controller status within `server_controller` as `w.Update` did not trigger `update_time` if `address` or `description` were not updated. Now using `w.Exec` with `updateController` query to always set `update_time` to `now()`.

Additional Notes:
- Updated `repository_controller` tests to verify `update_time` updates even when controller values don't change.
- Added `cleanupFunc` to test cases to remove inserted controllers after each test.
- Verified via `boundary dev` that `worker.upstreamDialerFunc` errors are not present.

Refs: 6c0b3a8a1c

* Resolve Comments
2025-03-26 14:54:02 -05:00
Ryan Derr 4cc5c07214 Migrate Controller Repo Usage From Store To Server (#5609)
* Create Server Domain Package For Controller

* Resolve Comments
2025-03-18 12:30:38 -05:00
Ryan Derr 6c0b3a8a1c Controller Liveliness Query Split (#5602)
* Initial Update Controller Call And Sample Test

* Update Controller Start Logic To Upsert

* Chore Make Gen

* Lowercase User For GCP Instance Label

* Resolve Comments
2025-03-17 14:04:40 -05:00
Ryan Derr 6d8615045e Lowercase GH Handle When Defining User Label For GCP (#5605) 2025-03-17 13:25:55 -05:00
Ryan Derr dc51dfba92 Update Tags For CRT (#5296) 2024-12-03 12:06:19 -06:00
Ryan Derr de141e34a9 Worker Connection Failure Add Controller Target (#5109)
* ICU-11692 Add Upstream Controller Addrs When Throwing Controller Connection Failure

* Reference Consistant Load Variable For Client Connection
2024-09-30 11:51:55 -07:00
Ryan Derr 913e6d755f ICU-11661 Add scope name in options slice for authorized-sessions (#5108) 2024-09-13 15:09:38 -05:00