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

Fixes for several string formats, they are based on static analysis. #6306

Open
wants to merge 8 commits into
base: master
Choose a base branch
from
Original file line number Diff line number Diff line change
Expand Up @@ -268,7 +268,7 @@ protected void computeFromPostBody(HTTPSamplerBase sampler,
HTTPFileArg [] files = {new HTTPFileArg(out.getPath(),"",contentType)};
sampler.setHTTPFiles(files);
} catch (IOException e) {
log.warn("Could not create binary file: {}", e);
log.warn("Could not create binary file", e);
dk2k marked this conversation as resolved.
Show resolved Hide resolved
}
} else {
// Just put the whole postbody as the value of a parameter
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -121,9 +121,9 @@ private void initClass() {
javaClass = Class.forName(name, false, Thread.currentThread().getContextClassLoader());
Method method = javaClass.getMethod("teardownTest", JavaSamplerContext.class);
isToBeRegistered = !method.getDeclaringClass().equals(AbstractJavaSamplerClient.class);
log.info("Created class: {}. Uses tearDownTest: ", name, isToBeRegistered);
log.info("Created class: {}. Uses tearDownTest: {}", name, isToBeRegistered);
} catch (Exception e) {
log.error("{}\tException initialising: ", whoAmI(), name, e);
log.error("{}\tException initialising: {}", whoAmI(), name, e);
Copy link
Contributor

Choose a reason for hiding this comment

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

While the text in the message looks like it is missing a placeholder, I would refrain from adding it here. Adding a placeholder will loose the stacktrace, which could be helpful identifying the root cause.

Copy link
Contributor Author

Choose a reason for hiding this comment

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

I restored this placeholder

}

}
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -504,7 +504,7 @@ private void closeSocket(String socketKey) {
try {
con.close();
} catch (IOException e) {
log.warn("Error closing socket {}", e); //$NON-NLS-1$
log.warn("Error closing socket", e); //$NON-NLS-1$
dk2k marked this conversation as resolved.
Show resolved Hide resolved
}
}
}
Expand Down
Loading