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

Fix sse for notifications behind nginx reverse proxy #1650

Merged
merged 2 commits into from May 10, 2021

Conversation

sdorra
Copy link
Member

@sdorra sdorra commented May 7, 2021

Proposed changes

Fixes SSE Events for notifications if SCM-Manager is running behind an Nginx reverse proxy. The notifications do not work behind Nginx, because Nginx buffers the response. This change will add the X-Accel-Buffering: no response header to notification subscribe endpoint. The X-Accel-Buffering: no header tells nginx to stop buffering for this endpoint.

Your checklist for this pull request

Contributor:

  • PR is well described and the description can be used as a commit message on squash
  • Related issues linked to PR if existing and labels set
  • Target branch is not master (in most cases develop should bet the target of choice)
  • Code does not conflict with target branch
  • New code is covered with unit tests
  • Changelog entry file created in gradle/changelog or CHANGELOG.md is updated for plugins

Reviewer:

  • The clean code principles are respected (CleanCode)
  • All new code/logic is implemented on the right spot / "Should this be done here?"
  • UI changes fits into the layout
  • The UI views / components are responsive (mobile views)
  • Correct translations are available

Checklist for branch merge request (not required for forks)

@sdorra sdorra added the bug Something isn't working label May 7, 2021
Copy link
Member

@pfeuffer pfeuffer left a comment

Choose a reason for hiding this comment

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

Just change the one test method.

@pfeuffer pfeuffer merged commit 9e45d82 into develop May 10, 2021
@pfeuffer pfeuffer deleted the bugfix/sse_behind_rp branch May 10, 2021 06:57
@sonarcloud
Copy link

sonarcloud bot commented May 10, 2021

Kudos, SonarCloud Quality Gate passed!

Bug A 0 Bugs
Vulnerability A 0 Vulnerabilities
Security Hotspot A 0 Security Hotspots
Code Smell A 0 Code Smells

95.5% 95.5% Coverage
0.0% 0.0% Duplication

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
bug Something isn't working
Projects
None yet
Development

Successfully merging this pull request may close these issues.

None yet

2 participants