You are viewing a plain text version of this content. The canonical link for it is here.
Posted to commits@jmeter.apache.org by fs...@apache.org on 2019/08/20 19:18:10 UTC
[jmeter] branch master updated (fdccd01 -> 2ab436b)
This is an automated email from the ASF dual-hosted git repository.
fschumacher pushed a change to branch master
in repository https://gitbox.apache.org/repos/asf/jmeter.git.
from fdccd01 Spec for CompareAssertion
new 8b53d21 Hide the constructor as this is a singleton
new 2ab436b No need to create an Object-array
The 2 revisions listed above as "new" are entirely new to this
repository and will be described in separate emails. The revisions
listed as "add" were already present in the repository and have only
been added to this reference.
Summary of changes:
.../main/java/org/apache/jmeter/samplers/SampleSenderFactory.java | 6 +++++-
1 file changed, 5 insertions(+), 1 deletion(-)
[jmeter] 02/02: No need to create an Object-array
Posted by fs...@apache.org.
This is an automated email from the ASF dual-hosted git repository.
fschumacher pushed a commit to branch master
in repository https://gitbox.apache.org/repos/asf/jmeter.git
commit 2ab436b8de009093fe5dd3932f32fd1b152786d5
Author: Felix Schumacher <fe...@internetallee.de>
AuthorDate: Tue Aug 20 21:12:18 2019 +0200
No need to create an Object-array
New java versions have varargs, so use them.
---
.../src/main/java/org/apache/jmeter/samplers/SampleSenderFactory.java | 2 +-
1 file changed, 1 insertion(+), 1 deletion(-)
diff --git a/src/core/src/main/java/org/apache/jmeter/samplers/SampleSenderFactory.java b/src/core/src/main/java/org/apache/jmeter/samplers/SampleSenderFactory.java
index 3a0f726..ef41194 100644
--- a/src/core/src/main/java/org/apache/jmeter/samplers/SampleSenderFactory.java
+++ b/src/core/src/main/java/org/apache/jmeter/samplers/SampleSenderFactory.java
@@ -76,7 +76,7 @@ public class SampleSenderFactory {
try {
Class<?> clazz = Class.forName(type);
Constructor<?> cons = clazz.getConstructor(RemoteSampleListener.class);
- s = (SampleSender) cons.newInstance(new Object[]{listener});
+ s = (SampleSender) cons.newInstance(listener);
} catch (Exception e) {
// houston we have a problem !!
log.error(
[jmeter] 01/02: Hide the constructor as this is a singleton
Posted by fs...@apache.org.
This is an automated email from the ASF dual-hosted git repository.
fschumacher pushed a commit to branch master
in repository https://gitbox.apache.org/repos/asf/jmeter.git
commit 8b53d21007d5fb253ddee0b3cd6f1b17d0c8533e
Author: Felix Schumacher <fe...@internetallee.de>
AuthorDate: Tue Aug 20 21:09:28 2019 +0200
Hide the constructor as this is a singleton
---
.../src/main/java/org/apache/jmeter/samplers/SampleSenderFactory.java | 4 ++++
1 file changed, 4 insertions(+)
diff --git a/src/core/src/main/java/org/apache/jmeter/samplers/SampleSenderFactory.java b/src/core/src/main/java/org/apache/jmeter/samplers/SampleSenderFactory.java
index 5a59b32..3a0f726 100644
--- a/src/core/src/main/java/org/apache/jmeter/samplers/SampleSenderFactory.java
+++ b/src/core/src/main/java/org/apache/jmeter/samplers/SampleSenderFactory.java
@@ -38,6 +38,10 @@ public class SampleSenderFactory {
private static final String MODE_DISKSTORE = "DiskStore"; // $NON-NLS-1$
private static final String MODE_STRIPPED_DISKSTORE = "StrippedDiskStore"; // $NON-NLS-1$
+ private SampleSenderFactory() {
+ // this is a singleton, so don't let anyone instantiate us
+ }
+
/**
* Checks for the JMeter property mode and returns the required class.
*