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

Use uploadDir path from VertxServerSettings instead of internal Vertx default value + fix deprecations & unused imports #3120

Merged
merged 3 commits into from
Aug 18, 2023

Conversation

Grryum
Copy link
Contributor

@Grryum Grryum commented Aug 17, 2023

This pull request aims to improve codebase by utilizing the uploadDir path from the VertxServerSettings configuration instead of relying on the internal Vertx default value.
Before this fix there was an issue where Vertx created unnecessary upload directories with default name (file-uploads) for every request, even without endpoints with file input type:
https://github.com/vert-x3/vertx-web/blob/master/vertx-web/src/main/java/io/vertx/ext/web/handler/impl/BodyHandlerImpl.java#L234

The main cause is that BodyHandler by default is created with ability to handle file uploads and default upload dir:
https://github.com/vert-x3/vertx-web/blob/master/vertx-web/src/main/java/io/vertx/ext/web/handler/impl/BodyHandlerImpl.java#L60
https://github.com/softwaremill/tapir/blob/master/server/vertx-server/src/main/scala/sttp/tapir/server/vertx/handlers/package.scala#L12

@Grryum Grryum changed the title Use uploadDir path from VertxServerSettings instead of internal Vertx default value. Use uploadDir path from VertxServerSettings instead of internal Vertx default value + fix deprecations & unused imports. Aug 17, 2023
@Grryum Grryum changed the title Use uploadDir path from VertxServerSettings instead of internal Vertx default value + fix deprecations & unused imports. Use uploadDir path from VertxServerSettings instead of internal Vertx default value + fix deprecations & unused imports Aug 17, 2023
@adamw adamw merged commit bafb26e into softwaremill:master Aug 18, 2023
@adamw
Copy link
Member

adamw commented Aug 18, 2023

Thanks!

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

Successfully merging this pull request may close these issues.

2 participants