Skip to content

[TNZ-71257][ai-assisted=yes] remove nats-v1 ref#93

Merged
kart2bc merged 1 commit intodevelopfrom
nats-v1-remove
Mar 10, 2026
Merged

[TNZ-71257][ai-assisted=yes] remove nats-v1 ref#93
kart2bc merged 1 commit intodevelopfrom
nats-v1-remove

Conversation

@kart2bc
Copy link
Copy Markdown
Contributor

@kart2bc kart2bc commented Mar 4, 2026

[ai-assisted=yes]

Summary

We used to run nats v1 (package name: gnatsd). We wanted to update to nats v2 (package name: nats-server). However, nats v1 and nats v2 cannot communicate with each other. This means that if we updated them the "normal" bosh way, there would be nats split brains while the nats VMs were rolling. Split brains are bad.

So instead we built a custom nats-v2-migrate. It would wait until the bosh deploy had finished rolling the nats vms and then it would update all of the nats servers to use nats v2 all at once.

In order for the migration to work the nats v1 and nats v2 binaries must be present on all of the nats vms.

At this point, now all customers should have upgrades to nats v2 and it is safe to rip out nats v1 and the migrator.

test results:

ci updates: cloudfoundry/wg-app-platform-runtime-ci#120

~/workspace/nats-release |nats-v1-remove ✔| 
$ ./scripts/create-docker-container.bash 
-it
Using default tag: latest
latest: Pulling from cloudfoundry/tas-runtime-build
Digest: sha256:2ab3eba1e6a4fa447205e0f523623d7bab0f0d77e327f6ceaa63e9743a65fb82
Status: Image is up to date for cloudfoundry/tas-runtime-build:latest
docker.io/cloudfoundry/tas-runtime-build:latest
nats-release-docker-container
root@e3dc8d20c825:/# ./repo/scripts/docker/lint.bash
Running ./ci/nats-release/linters/sync-package-specs.bash for-nats-release with-exit-on-error=true
Running ./ci/shared/linters/sync-submodule-config.bash for-nats-release with-exit-on-error=true
No submodule for this repo, intentionally left blank
Running ./ci/shared/linters/match-golang-os-package-versions.bash for-nats-release with-exit-on-error=true
root@e3dc8d20c825:/# ./repo/scripts/docker/   
lint.bash             test.bash             tests-templates.bash  
root@e3dc8d20c825:/# ./repo/scripts/docker/tests-templates.bash 
Don't run Bundler as root. Installing your bundle as root will break this application for all non-root users on this machine.
Bundler 4.0.7 is running, but your lockfile was generated with 2.4.19. Installing Bundler 2.4.19 and restarting using that version.
Fetching gem metadata from https://rubygems.org/.
Fetching bundler 2.4.19
Installing bundler 2.4.19
Don't run Bundler as root. Installing your bundle as root will break this application for all non-root users on this machine.
Fetching gem metadata from https://rubygems.org/...........
Fetching ast 2.4.2
Fetching semi_semantic 1.2.0
Installing semi_semantic 1.2.0
Installing ast 2.4.2
Fetching diff-lcs 1.5.0
Fetching language_server-protocol 3.17.0.3
Installing diff-lcs 1.5.0
Installing language_server-protocol 3.17.0.3
Fetching parallel 1.23.0
Installing parallel 1.23.0
Fetching racc 1.7.1
Installing racc 1.7.1 with native extensions
Fetching rainbow 3.1.1
Installing rainbow 3.1.1
Fetching regexp_parser 2.8.2
Installing regexp_parser 2.8.2
Fetching rexml 3.2.6
Installing rexml 3.2.6
Fetching rspec-support 3.12.1
Installing rspec-support 3.12.1
Fetching ruby-progressbar 1.13.0
Installing ruby-progressbar 1.13.0
Fetching unicode-display_width 2.5.0
Installing unicode-display_width 2.5.0
Fetching bosh-template 2.4.0
Installing bosh-template 2.4.0
Fetching rspec-core 3.12.2
Installing rspec-core 3.12.2
Fetching rspec-expectations 3.12.3
Installing rspec-expectations 3.12.3
Fetching rspec-mocks 3.12.6
Installing rspec-mocks 3.12.6
Fetching rspec 3.12.0
Installing rspec 3.12.0
Fetching parser 3.2.2.4
Installing parser 3.2.2.4
Fetching rubocop-ast 1.29.0
Installing rubocop-ast 1.29.0
Fetching rubocop 1.57.1
Installing rubocop 1.57.1
Bundle complete! 3 Gemfile dependencies, 23 gems now installed.
Use `bundle info [gemname]` to see where a bundled gem is installed.
...........Bad 'nats.mem_limit.alert' setting: 100 potatoes. Format is: <number> B|KB|MB|GB|%
.Bad 'nats.mem_limit.alert' setting: mashed potatoes. Format is: <number> B|KB|MB|GB|%
.Bad 'nats.mem_limit.restart' setting: 100 potatoes. Format is: <number> B|KB|MB|GB|%
.Bad 'nats.mem_limit.restart' setting: mashed potatoes. Format is: <number> B|KB|MB|GB|%
................

Finished in 0.09344 seconds (files took 0.12089 seconds to load)
30 examples, 0 failures

Backward Compatibility

Breaking Change? No

@kart2bc kart2bc force-pushed the nats-v1-remove branch 4 times, most recently from b220c51 to d86a2e5 Compare March 9, 2026 17:56
@kart2bc kart2bc marked this pull request as ready for review March 9, 2026 17:57
@kart2bc kart2bc requested a review from a team as a code owner March 9, 2026 17:57
@maxmoehl
Copy link
Copy Markdown
Member

Could you please write a PR description explaining your change and select whether it's a breaking change or not? Thanks!

@github-project-automation github-project-automation Bot moved this from Inbox to Pending Merge | Prioritized in Application Runtime Platform Working Group Mar 10, 2026
@kart2bc kart2bc merged commit a63a311 into develop Mar 10, 2026
2 checks passed
@kart2bc kart2bc deleted the nats-v1-remove branch March 10, 2026 15:35
@github-project-automation github-project-automation Bot moved this from Pending Merge | Prioritized to Done in Application Runtime Platform Working Group Mar 10, 2026
@kart2bc kart2bc mentioned this pull request Mar 10, 2026
1 task
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

Development

Successfully merging this pull request may close these issues.

3 participants