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

Mono<Void> returns 200 even when code is set to 204 #438

Closed
CezaryBD opened this issue May 10, 2024 · 2 comments
Closed

Mono<Void> returns 200 even when code is set to 204 #438

CezaryBD opened this issue May 10, 2024 · 2 comments
Assignees

Comments

@CezaryBD
Copy link

Expected Behavior

Should preserve code instead of rewriting it.

Actual Behaviour

Rewrites status code to 200.

Steps To Reproduce

See reproducible example in the repository

Environment Information

  • macOS 14.4.1
  • Corretto 17.0.11

Example Application

https://github.com/CezaryBD/micronaut-reactor-mono-void-bug-01

Version

4.4.2

@sdelamo
Copy link
Contributor

sdelamo commented Aug 16, 2024

@dstepanov can you check this?

@sdelamo
Copy link
Contributor

sdelamo commented Feb 3, 2025

I think your test is incorrect @CezaryBD you the following code:

@Controller
public class SimpleController {
	@Inject
	SimpleClient simpleClient;

	@Get("/simple-void")
	public Mono<Void> getSimpleVoid() {
		return simpleClient.getSimpleVoid();
	}
}
@Client("http://localhost:6969")
public interface SimpleClient {
	@Get("/simple-void")
    Mono<Void> getSimpleVoid();
}

it is expected that the controller responds 200. Even if the client receives a 204.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
No open projects
Status: Done
Development

No branches or pull requests

3 participants