Add support for RabbitMQ streams
Nobody has claimed this yet.
Assessment
- Difficulty
- 4/5
- Estimated time
- 3-5 days
- Newbie friendliness
- 45/100
Research direction
Start by locating the RabbitMQ service-binding parser and its tests, then trace how the credentials.protocols map is converted into Spring properties. Done means rabbitmq-stream values populate the stream host, port, username, password, and virtual-host instead of localhost or null, with coverage for the supplied VCAP_SERVICES shape.
Written by the indexing model from the issue text.
Description
Is your feature request related to a problem? Please describe.
Spring properties for RabbitMQ stream protocol are not being populated and an error is raised with connection failing to localhost. Adding some custom beans and debugging info, this is what the properties that are being set look like (all properties prefixed with spring.rabbitmq.):
host: q-s0.rabbitmq-server.<some-domain>.service-instance-756e8a51-f5be-4e39-9aef-511a958b4d1e.bosh
port: null
username: be35bc61-2b67-47d4-b53a-45f9bc2d63bf
password: ***SET***
virtualHost: 756e8a51-f5be-4e39-9aef-511a958b4d1e
stream.host: localhost
stream.port: 5552
stream.username: null
stream.password: null
stream.virtual-host: null
This is how the VCAP_SERVICES property looks like (notice rabbitmq-stream is under a protocols map)
{
"p.rabbitmq": [
{
"binding_guid": "be35bc61-2b67-47d4-b53a-45f9bc2d63bf",
"binding_name": null,
"credentials": {
"dashboard_url": "https://dashboard-url",
"hostname": "q-s0.rabbitmq-server.<some-domain>.service-instance-756e8a51-f5be-4e39-9aef-511a958b4d1e.bosh",
"hostnames": [
"q-s0.rabbitmq-server.some-domain.service-instance-756e8a51-f5be-4e39-9aef-511a958b4d1e.bosh"
],
"http_api_uri": "https://be35bc61-2b67-47d4-b53a-45f9bc2d63bf:dAZmAYu8xuMb5qahvmD2bDGI@rmq-756e8a51-f5be-4e39-9aef-511a958b4d1e.<sys-domain>/api/",
"http_api_uris": [
"https://be35bc61-2b67-47d4-b53a-45f9bc2d63bf:dAZmAYu8xuMb5qahvmD2bDGI@rmq-756e8a51-f5be-4e39-9aef-511a958b4d1e.<sys-domain>/api/"
],
"password": "dAZmAYu8xuMb5qahvmD2bDGI",
"protocols": {
"amqp": {
"host": "q-s0.rabbitmq-server.<some-domain>.service-instance-756e8a51-f5be-4e39-9aef-511a958b4d1e.bosh",
"hosts": [
"q-s0.rabbitmq-server.<some-domain>.service-instance-756e8a51-f5be-4e39-9aef-511a958b4d1e.bosh"
],
"password": "dAZmAYu8xuMb5qahvmD2bDGI",
"port": 5672,
"ssl": false,
"uri": "amqp://be35bc61-2b67-47d4-b53a-45f9bc2d63bf:[email protected].<some-domain>.service-instance-756e8a51-f5be-4e39-9aef-511a958b4d1e.bosh/756e8a51-f5be-4e39-9aef-511a958b4d1e",
"uris": [
"amqp://be35bc61-2b67-47d4-b53a-45f9bc2d63bf:[email protected].<some-domain>.service-instance-756e8a51-f5be-4e39-9aef-511a958b4d1e.bosh/756e8a51-f5be-4e39-9aef-511a958b4d1e"
],
"username": "be35bc61-2b67-47d4-b53a-45f9bc2d63bf",
"vhost": "756e8a51-f5be-4e39-9aef-511a958b4d1e"
},
"rabbitmq-stream": {
"host": "q-s0.rabbitmq-server.<some-domain>.service-instance-756e8a51-f5be-4e39-9aef-511a958b4d1e.bosh",
"hosts": [
"q-s0.rabbitmq-server.<some-domain>.service-instance-756e8a51-f5be-4e39-9aef-511a958b4d1e.bosh"
],
"password": "dAZmAYu8xuMb5qahvmD2bDGI",
"port": 5552,
"ssl": false,
"uri": "rabbitmq-stream://be35bc61-2b67-47d4-b53a-45f9bc2d63bf:[email protected].<some-domain>.service-instance-756e8a51-f5be-4e39-9aef-511a958b4d1e.bosh:5552/756e8a51-f5be-4e39-9aef-511a958b4d1e",
"uris": [
"rabbitmq-stream://be35bc61-2b67-47d4-b53a-45f9bc2d63bf:[email protected].<some-domain>.service-instance-756e8a51-f5be-4e39-9aef-511a958b4d1e.bosh:5552/756e8a51-f5be-4e39-9aef-511a958b4d1e"
],
"username": "be35bc61-2b67-47d4-b53a-45f9bc2d63bf",
"vhost": "756e8a51-f5be-4e39-9aef-511a958b4d1e"
}
},
"ssl": false,
"uri": "amqp://be35bc61-2b67-47d4-b53a-45f9bc2d63bf:[email protected].<some-domain>.service-instance-756e8a51-f5be-4e39-9aef-511a958b4d1e.bosh/756e8a51-f5be-4e39-9aef-511a958b4d1e",
"uris": [
"amqp://be35bc61-2b67-47d4-b53a-45f9bc2d63bf:[email protected].<some-domain>.service-instance-756e8a51-f5be-4e39-9aef-511a958b4d1e.bosh/756e8a51-f5be-4e39-9aef-511a958b4d1e"
],
"username": "be35bc61-2b67-47d4-b53a-45f9bc2d63bf",
"vhost": "756e8a51-f5be-4e39-9aef-511a958b4d1e"
},
"instance_guid": "756e8a51-f5be-4e39-9aef-511a958b4d1e",
"instance_name": "audit-events",
"label": "p.rabbitmq",
"name": "audit-events",
"plan": "on-demand-plan",
"provider": null,
"syslog_drain_url": null,
"tags": [
"rabbitmq"
],
"volume_mounts": []
}
]
}
```
### Describe the solution you'd like
I'd like the right properties to be filled in when the stream plugin is enabled in rabbit so autowiring sucessfully sets up the boot beans.
### Describe alternatives you've considered
_No response_
### Additional context
_No response_
- Dominant language
- Java
- Stars
- 97
- Forks
- 64
- Avg merge
- 6h 36m
- Merged PRs (30d)
- 6
Getting set up
First steps
- Read the whole issue, then the project's contributing guide.
- Comment on the issue to say you are picking it up — it saves two people doing the same work.
- Fork the repository and make your change on a branch.
- Open a pull request that references the issue number.
More from pivotal-cf/java-cfenv
-
enhancement
Difficulty 3/5 1-2 days Newbie friendliness 48/100
pivotal-cf/java-cfenv#296 · 3 reactions ·
-
bug
Difficulty 4/5 3-5 days Newbie friendliness 35/100
pivotal-cf/java-cfenv#292 ·
-
Difficulty 4/5 3-5 days Newbie friendliness 25/100
pivotal-cf/java-cfenv#255 · 2 comments ·
-
bug
Difficulty 3/5 1-2 days Newbie friendliness 35/100
pivotal-cf/java-cfenv#249 · 2 comments ·
-
enhancement
Difficulty 5/5 Over a week Newbie friendliness 35/100
pivotal-cf/java-cfenv#171 · 1 comment ·
All issues in pivotal-cf/java-cfenv
Similar issues
-
Difficulty 2/5 1-3 hours Newbie friendliness 88/100
checkstyle/checkstyle#21755 · 1 comment ·
Maintainers usually reply within 1 day
-
Difficulty 2/5 1-3 hours Newbie friendliness 84/100
Maintainers usually reply within 1 day
-
agentic-workflows
Difficulty 2/5 1-3 hours Newbie friendliness 68/100
github/copilot-sdk#2782 ·
Maintainers usually reply within 1 day
-
documentation Good for newcomer quick win
Difficulty 2/5 1-3 hours Newbie friendliness 68/100
CodeForPhilly/benefit-decision-toolkit#519 ·
Maintainers usually reply within 1 day
-
area-deployment triage:bot-seen triage:needs-human
Difficulty 2/5 1-3 hours Newbie friendliness 68/100
microsoft/aspire#20533 · 1 comment ·
Maintainers usually reply within 1 day