Skip to content

Conversation

@svkrieger
Copy link
Contributor

@svkrieger svkrieger commented May 21, 2025

Summary

We want to remove the cloud_controller_container_networking_info link from CAPI release and the usage of internal_route_vip_range in Cloud Controller.
cf-networking release is still consuming the link, which is why we need to remove it from here first.
I built a dev release for cf-networking with the changes in this PR, as well as a dev release of capi including the below mentioned changes (+removed the link completely) and deployed it to a BBL environment. CATS were green.

Please check whether it can be removed from your POV. Also please check whether I got all references.

Here is the initial issue: cloudfoundry/cloud_controller_ng#3712

And those PRs will remove it from CAPI release and CC:
cloudfoundry/cloud_controller_ng#3761
cloudfoundry/capi-release#419

Backward Compatibility

Breaking Change? Yes/No
I suppose no if it is dead code.

@klapkov
Copy link

klapkov commented Jun 26, 2025

@ameowlia Any worries from your side regarding backward compatibility here ?

Copy link
Member

@ameowlia ameowlia left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

In general, it looks good to me, and I am so happy that you are cleaning this up.

But it fails template tests. I ran them like this..

DB=postgres ./scripts/create-docker-container.bash

# inside the docker container
cd repo
./scripts/docker/tests-templates.bash
While loading ./spec/garden-cni/garden_cni_spec.rb a `raise SyntaxError` occurred, RSpec will now quit.                                                                                                                                                                       Failure/Error: __send__(method, file)                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                       SyntaxError:                                                                                                                                                                                                                                                                    --> /repo/spec/garden-cni/garden_cni_spec.rb                                                                                                                                                                                                                                  Unmatched `end', missing keyword (`do', `def`, `if`, etc.) ?                                                                                                                                                                                                                      6  module Bosh::Template::Test                                                                                                                                                                                                                                                7    describe 'garden-cni job template rendering' do                                                                                                                                                                                                                      >   8      let(:release_path) {File.join(File.dirname(__FILE__), '../..')}
  >   9      let(:release) {ReleaseDir.new(release_path)}
  >  10      let(:job) {release.job('garden-cni')}                                                                                                                                                                                                                              >  11      end
    147    end
    148  end
  /repo/spec/garden-cni/garden_cni_spec.rb:148: syntax error, unexpected `end' (SyntaxError)
# /opt/rubies/ruby-3.2.2/lib/ruby/gems/3.2.0/gems/rspec-core-3.13.2/lib/rspec/core/configuration.rb:2144:in `load'
# /opt/rubies/ruby-3.2.2/lib/ruby/gems/3.2.0/gems/rspec-core-3.13.2/lib/rspec/core/configuration.rb:2144:in `load_file_handling_errors'
# /opt/rubies/ruby-3.2.2/lib/ruby/gems/3.2.0/gems/rspec-core-3.13.2/lib/rspec/core/configuration.rb:1643:in `block in load_spec_files'
# /opt/rubies/ruby-3.2.2/lib/ruby/gems/3.2.0/gems/rspec-core-3.13.2/lib/rspec/core/configuration.rb:1641:in `each'
# /opt/rubies/ruby-3.2.2/lib/ruby/gems/3.2.0/gems/rspec-core-3.13.2/lib/rspec/core/configuration.rb:1641:in `load_spec_files'
# /opt/rubies/ruby-3.2.2/lib/ruby/gems/3.2.0/gems/rspec-core-3.13.2/lib/rspec/core/runner.rb:102:in `setup'
# /opt/rubies/ruby-3.2.2/lib/ruby/gems/3.2.0/gems/rspec-core-3.13.2/lib/rspec/core/runner.rb:86:in `run'
# /opt/rubies/ruby-3.2.2/lib/ruby/gems/3.2.0/gems/rspec-core-3.13.2/lib/rspec/core/runner.rb:71:in `run'
# /opt/rubies/ruby-3.2.2/lib/ruby/gems/3.2.0/gems/rspec-core-3.13.2/lib/rspec/core/runner.rb:45:in `invoke'
# /opt/rubies/ruby-3.2.2/lib/ruby/gems/3.2.0/gems/rspec-core-3.13.2/exe/rspec:4:in `<top (required)>'
# /opt/rubies/ruby-3.2.2/bin/rspec:25:in `load'
# /opt/rubies/ruby-3.2.2/bin/rspec:25:in `<top (required)>'
# /opt/rubies/ruby-3.2.2/lib/ruby/gems/3.2.0/gems/bundler-2.5.23/lib/bundler/cli/exec.rb:58:in `load'
# /opt/rubies/ruby-3.2.2/lib/ruby/gems/3.2.0/gems/bundler-2.5.23/lib/bundler/cli/exec.rb:58:in `kernel_load'
# /opt/rubies/ruby-3.2.2/lib/ruby/gems/3.2.0/gems/bundler-2.5.23/lib/bundler/cli/exec.rb:23:in `run'
# /opt/rubies/ruby-3.2.2/lib/ruby/gems/3.2.0/gems/bundler-2.5.23/lib/bundler/cli.rb:456:in `exec'
# /opt/rubies/ruby-3.2.2/lib/ruby/gems/3.2.0/gems/bundler-2.5.23/lib/bundler/vendor/thor/lib/thor/command.rb:28:in `run'
# /opt/rubies/ruby-3.2.2/lib/ruby/gems/3.2.0/gems/bundler-2.5.23/lib/bundler/vendor/thor/lib/thor/invocation.rb:127:in `invoke_command'
# /opt/rubies/ruby-3.2.2/lib/ruby/gems/3.2.0/gems/bundler-2.5.23/lib/bundler/vendor/thor/lib/thor.rb:527:in `dispatch'
# /opt/rubies/ruby-3.2.2/lib/ruby/gems/3.2.0/gems/bundler-2.5.23/lib/bundler/cli.rb:35:in `dispatch'
# /opt/rubies/ruby-3.2.2/lib/ruby/gems/3.2.0/gems/bundler-2.5.23/lib/bundler/vendor/thor/lib/thor/base.rb:584:in `start'
# /opt/rubies/ruby-3.2.2/lib/ruby/gems/3.2.0/gems/bundler-2.5.23/lib/bundler/cli.rb:29:in `start'
# /opt/rubies/ruby-3.2.2/lib/ruby/gems/3.2.0/gems/bundler-2.5.23/exe/bundle:28:in `block in <top (required)>'
# /opt/rubies/ruby-3.2.2/lib/ruby/gems/3.2.0/gems/bundler-2.5.23/lib/bundler/friendly_errors.rb:117:in `with_friendly_errors'
# /opt/rubies/ruby-3.2.2/lib/ruby/gems/3.2.0/gems/bundler-2.5.23/exe/bundle:20:in `<top (required)>'
# /opt/rubies/ruby-3.2.2/bin/bundle:25:in `load'
# /opt/rubies/ruby-3.2.2/bin/bundle:25:in `<main>'
#
#   Showing full backtrace because every line was filtered out.
#   See docs for RSpec::Configuration#backtrace_exclusion_patterns and
#   RSpec::Configuration#backtrace_inclusion_patterns for more information.
..............................................................

Finished in 0.07194 seconds (files took 0.10355 seconds to load)
62 examples, 0 failures, 1 error occurred outside of examples

It also fails when you run the regular test script because of go vet...

Run like this..

DB=postgres ./scripts/create-docker-container.bash

# inside the docker container
cd repo
./scripts/docker/test.bash

Result

Verifying: verify_go_version_match_bosh_release repo
Verifying: verify_gofmt repo/src/code.cloudfoundry.org/bosh-dns-adapter
Verifying: verify_govet repo/src/code.cloudfoundry.org/bosh-dns-adapter
# code.cloudfoundry.org/bosh-dns-adapter/config_test
# [code.cloudfoundry.org/bosh-dns-adapter/config_test]
vet: config/config_test.go:4:2: "net" imported and not used

The requirement to run these scripts is covered in CONTRIBUTING.md.

@ameowlia
Copy link
Member

ameowlia commented Jul 9, 2025

Please post in the #wg-app-runtime-platform slack channel when you have made the fixes and are ready for another review.

@svkrieger svkrieger force-pushed the remove-usage-of-cloud_controller-container-netorking-info branch from 92489a7 to f804e37 Compare July 17, 2025 12:36
@svkrieger
Copy link
Contributor Author

Ah I removed the small things I've overseen and now ./scripts/test-in-docker.bash went through without errors. I would encourage you to check it carefully though, as I cannot judge the semantics.

@github-project-automation github-project-automation bot moved this from Inbox to Pending Merge | Prioritized in Application Runtime Platform Working Group Jul 17, 2025
@ameowlia ameowlia merged commit a66a577 into cloudfoundry:develop Jul 17, 2025
7 checks passed
@github-project-automation github-project-automation bot moved this from Pending Merge | Prioritized to Done in Application Runtime Platform Working Group Jul 17, 2025
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Projects

Development

Successfully merging this pull request may close these issues.

3 participants