Skip to content

Deprecated Syslog Binding URL API removal#3527

Merged
philippthun merged 1 commit intocloudfoundry:mainfrom
chombium:syslog-api-cleanup
Mar 6, 2026
Merged

Deprecated Syslog Binding URL API removal#3527
philippthun merged 1 commit intocloudfoundry:mainfrom
chombium:syslog-api-cleanup

Conversation

@chombium
Copy link
Copy Markdown
Contributor

@chombium chombium commented Nov 29, 2023

Code clean up after the deprecation of the /v4 API for the Syslog Binding URL.

With the introduction of mTLS for Syslog Drains we have changed the internal structure of the bindings. In order to enable updating without downtime of the cloud controller, the syslog binding cache and the syslog agent, we have introduced two endpoints for reading the syslog binding in the old and new format. This PR cleans up the code of the legacy syslog binding API endpoint.

Thanks for contributing to cloud_controller_ng. To speed up the process of reviewing your pull request please provide us with:

  • A short explanation of the proposed change:

  • An explanation of the use cases your change solves

  • Links to any other associated PRs

  • I have reviewed the contributing guide

  • I have viewed, signed, and submitted the Contributor License Agreement

  • I have made this pull request to the main branch

  • I have run all the unit tests using bundle exec rake

  • I have run CF Acceptance Tests

I have done extensive manual testing on a full fledged Cloud Foundry deployment.

@cloudfoundry/wg-app-runtime-platform-logging-and-metrics-approvers can someone please take a look at this? I've also cleaned up the usage of the old URL in the Syslog Binding Cache and the Syslog Agent in the following PR.

Copy link
Copy Markdown
Member

@mkocher mkocher left a comment

Choose a reason for hiding this comment

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

Nice to get some old code deleted. We looked into this and think this will be a safe change to make in our environments.

let!(:binding_with_drain1) { ServiceBinding.make(syslog_drain_url: 'fish,finger', app: app_obj, service_instance: instance1) }
let!(:binding_with_drain2) { ServiceBinding.make(syslog_drain_url: 'foobar', app: app_obj, service_instance: instance2) }

describe 'GET /internal/v4/syslog_drain_urls' do
Copy link
Copy Markdown
Member

Choose a reason for hiding this comment

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

It seems like this PR removed the test coverage for the shared hostname_from_app_name method. It would be good to add the test cases to the v5 specs.

@mkocher
Copy link
Copy Markdown
Member

mkocher commented Dec 4, 2023

We took another look and found one internal consumer of this internal API. We're going to work on moving it to v5 to not hold up this cleanup.

@chombium
Copy link
Copy Markdown
Contributor Author

Hi @mkocher, I've updated all the tests which were included in the v4 API to work with v5 API, so that we have all of the tests which we had before.

When I only run the whole RSpec.describe SyslogDrainUrlsInternalController all the tests are successful, but when I run bundle exec rake some of the tests fail and the PR validation fails. I will have to check what's going on :-/

@chombium
Copy link
Copy Markdown
Contributor Author

I've added few more examples for the test by mistake. Now I've cleaned up the spec and everything should be fine now.

@chombium chombium requested a review from mkocher January 18, 2024 14:57
@chombium
Copy link
Copy Markdown
Contributor Author

@ctlong, @mkocher As we have merge the api cleanup in the loggregator-agent-release, now we should take a look and merge this PR as well. I have just rebased the state with the latest ccng main branch, everything is ready for merging.

@ctlong
Copy link
Copy Markdown
Member

ctlong commented Jan 18, 2024

@chombium we'd like to hold off on merging this PR for a little while (~1-2 months). It turns out that we have an internal agent that uses the old v4 endpoint that we need to migrate to the v5 endpoint.

Thanks for your diligence in cleaning up this cruft!

@chombium
Copy link
Copy Markdown
Contributor Author

chombium commented Jan 18, 2024

@ctlong thanks for the clarification. I thought that as its counterpart in Loggregator agent release was merged, we can merge this as well. We're not in a hurry, take your time to do the needful.

@fhambrec
Copy link
Copy Markdown
Contributor

Hi @ctlong, I assume @philippthun added the blocked label as you were still working on patching the internal agent to the /v5 endpoint. Is this done in the meantime/can we merge the PR? @chombium I guess we should revisit this PR to resolve the conflicts that have come up in the past months.

@ctlong
Copy link
Copy Markdown
Member

ctlong commented Oct 28, 2024

Yes, I believe we're unblocked now. Please feel free to proceed with this PR, and thanks for waiting!

@chombium chombium force-pushed the syslog-api-cleanup branch 2 times, most recently from c3113ff to c7b1bf7 Compare November 3, 2025 10:59
@chombium chombium force-pushed the syslog-api-cleanup branch 2 times, most recently from 0d196c8 to d80daf0 Compare January 16, 2026 10:07
- Code cleanup after the deprecation of the `/v4` API for the Syslog
Binding URL.
- Adaptation of of v4 tests for v5

fix tests and migrate v4 tests to v5
@chombium
Copy link
Copy Markdown
Contributor Author

Hi @mkocher, Hi @ctlong I hope you are both doing well. As you are the people with who I've discussed this change, I would kindly ask you to take a look at the PR and review it.

@philippthun Can you please change the label from blocked to needs review

@sethboyles
Copy link
Copy Markdown
Member

@philippthun @johha This is OK to merge from our perspective. I'd just like to double check with you all before I do since it is removing an endpoint.

@chombium
Copy link
Copy Markdown
Contributor Author

chombium commented Mar 5, 2026

Hi @sethboyles, we've migrated the endpoint from v4 to v5 long time ago, but Broadcom had some systems still using the v4 and we had to wait so they migrate.

@philippthun philippthun merged commit 80ce779 into cloudfoundry:main Mar 6, 2026
19 of 24 checks passed
ari-wg-gitbot added a commit to cloudfoundry/capi-release that referenced this pull request Mar 6, 2026
Changes in cloud_controller_ng:

- Deprecated Syslog Binding URL API removal
    PR: cloudfoundry/cloud_controller_ng#3527
    Author: Jovan Kostovski <jovan.kostovski@sap.com>
@chombium
Copy link
Copy Markdown
Contributor Author

chombium commented Mar 6, 2026

Thanks for the help @sethboyles and @philippthun.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Projects

None yet

Development

Successfully merging this pull request may close these issues.

6 participants