Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

config.dsn does not respect port #1699

Closed
laurafeier opened this issue Jan 26, 2022 · 3 comments · Fixed by #1702
Closed

config.dsn does not respect port #1699

laurafeier opened this issue Jan 26, 2022 · 3 comments · Fixed by #1702
Assignees
Milestone

Comments

@laurafeier
Copy link

Issue Description

Custom port is not respected by default transport.
I assume the problem is in the http transport class

server = URI(@dsn.server)
use_ssl = server.scheme == "https"
port = use_ssl ? 443 : 80

This probably need to be changed in

server = URI(@dsn.server)
use_ssl = server.scheme == "https"
port = server.port

Reproduction Steps

Use custom dsn with custom port.

Expected Behavior

Connection should respect custom port. Instead it is enforced to 80.

Actual Behavior

ERROR -- sentry: exception happened in background worker: Failed to open TCP connection to 75.81.74.93:80 (Connection refused - connect(2) for "75.81.74.93" port 80)

Ruby Version

3.0.2p107

SDK Version

5.0.1

Integration and Its Version

rails 6.1.4.4

Sentry Config

config.dsn = 'http://xxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxx@75.81.74.93:9000/1'
@st0012 st0012 added this to the 5.1.0 milestone Jan 26, 2022
@st0012
Copy link
Collaborator

st0012 commented Jan 26, 2022

@laurafeier Yeah it's a bug and thanks for reporting it 👍

@Bertg
Copy link

Bertg commented Jan 31, 2022

@st0012 Any idea on when this fix will be released?

@st0012
Copy link
Collaborator

st0012 commented Jan 31, 2022

It should go out later today 🙂

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

Successfully merging a pull request may close this issue.

3 participants