Skip to content

Commit 51553dd

Browse files
authored
AMQ-9718 Removed collections which are never queried (#1444)
1 parent 273d8fb commit 51553dd

File tree

3 files changed

+0
-16
lines changed

3 files changed

+0
-16
lines changed

activemq-broker/src/test/java/org/apache/activemq/store/PListTestSupport.java

Lines changed: 0 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -128,11 +128,9 @@ private PListEntry getFirst(PList plist) throws IOException {
128128
}
129129

130130
protected void doTestRemove(final int COUNT) throws IOException {
131-
Map<String, ByteSequence> map = new LinkedHashMap<String, ByteSequence>();
132131
for (int i = 0; i < COUNT; i++) {
133132
String test = new String("test" + i);
134133
ByteSequence bs = new ByteSequence(test.getBytes());
135-
map.put(test, bs);
136134
plist.addLast(test, bs);
137135
}
138136
assertEquals(plist.size(), COUNT);

activemq-console/src/main/java/org/apache/activemq/console/command/BrowseCommand.java

Lines changed: 0 additions & 7 deletions
Original file line numberDiff line numberDiff line change
@@ -75,7 +75,6 @@ public class BrowseCommand extends AbstractJmxCommand {
7575
};
7676

7777
private final List<String> queryAddObjects = new ArrayList<String>(10);
78-
private final List<String> querySubObjects = new ArrayList<String>(10);
7978
private final Set<String> groupViews = new HashSet<String>(10);
8079
private final Set queryViews = new HashSet(10);
8180

@@ -144,12 +143,6 @@ protected void handleOption(String token, List<String> tokens) throws Exception
144143
// option
145144
if (tokens.isEmpty() || ((String)tokens.get(0)).startsWith("-")) {
146145
context.printException(new IllegalArgumentException("Message selector not specified"));
147-
return;
148-
}
149-
150-
StringTokenizer queryTokens = new StringTokenizer((String)tokens.remove(0), COMMAND_OPTION_DELIMETER);
151-
while (queryTokens.hasMoreTokens()) {
152-
querySubObjects.add(queryTokens.nextToken());
153146
}
154147

155148
} else if (token.startsWith("--view")) {

activemq-console/src/main/java/org/apache/activemq/console/command/PurgeCommand.java

Lines changed: 0 additions & 7 deletions
Original file line numberDiff line numberDiff line change
@@ -60,7 +60,6 @@ public class PurgeCommand extends AbstractJmxCommand {
6060
};
6161

6262
private final List<String> queryAddObjects = new ArrayList<String>(10);
63-
private final List<String> querySubObjects = new ArrayList<String>(10);
6463
private boolean resetStatistics;
6564

6665
@Override
@@ -175,12 +174,6 @@ protected void handleOption(String token, List<String> tokens) throws Exception
175174
// option
176175
if (tokens.isEmpty() || tokens.get(0).startsWith("-")) {
177176
context.printException(new IllegalArgumentException("Message selector not specified"));
178-
return;
179-
}
180-
181-
StringTokenizer queryTokens = new StringTokenizer(tokens.remove(0), COMMAND_OPTION_DELIMETER);
182-
while (queryTokens.hasMoreTokens()) {
183-
querySubObjects.add(queryTokens.nextToken());
184177
}
185178
} else if (token.startsWith("--reset")) {
186179
resetStatistics = true;

0 commit comments

Comments
 (0)