-
Notifications
You must be signed in to change notification settings - Fork 185
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
paho: expand test coverage #3720 #3721
Conversation
691ae7b
to
6343bfc
Compare
InputStream in = Thread.currentThread().getContextClassLoader().getResourceAsStream(keystore); | ||
|
||
try { |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
InputStream in = Thread.currentThread().getContextClassLoader().getResourceAsStream(keystore); | |
try { | |
try (InputStream in = Thread.currentThread().getContextClassLoader().getResourceAsStream(keystore)) { |
It would be nice if we could close the InputStream
integration-tests/paho/src/main/java/org/apache/camel/quarkus/component/paho/PahoResource.java
Show resolved
Hide resolved
InputStream in = Thread.currentThread().getContextClassLoader().getResourceAsStream(keystore); | ||
|
||
try { | ||
Files.copy(in, Paths.get(keystore), StandardCopyOption.REPLACE_EXISTING); |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Woudn't this copy the file to the given module's root directory, where somebody could inadvertently add it to git? Maybe under tmp or target could be better?
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
yeah, I agree and prefer to create a tmp file. Thanks @ppalaga !
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
@aldettinger it could be useful to create a |
No description provided.