Skip to Content.
Sympa Menu

perfsonar-dev - perfsonar: r4593 - trunk/ps-mdm-flowsub-mp/src/main/java/org/perfsonar/service/measurementPoint/flowsubscription

Subject: perfsonar development work

List archive

perfsonar: r4593 - trunk/ps-mdm-flowsub-mp/src/main/java/org/perfsonar/service/measurementPoint/flowsubscription


Chronological Thread 
  • From:
  • To:
  • Subject: perfsonar: r4593 - trunk/ps-mdm-flowsub-mp/src/main/java/org/perfsonar/service/measurementPoint/flowsubscription
  • Date: Tue, 7 Oct 2008 03:29:35 -0400

Author: michael.bischoff
Date: 2008-10-07 03:29:34 -0400 (Tue, 07 Oct 2008)
New Revision: 4593

Modified:

trunk/ps-mdm-flowsub-mp/src/main/java/org/perfsonar/service/measurementPoint/flowsubscription/NfReplayControll.java
Log:
Improved error message when an unknown exporter/router is encountered.

Modified:
trunk/ps-mdm-flowsub-mp/src/main/java/org/perfsonar/service/measurementPoint/flowsubscription/NfReplayControll.java
===================================================================
---
trunk/ps-mdm-flowsub-mp/src/main/java/org/perfsonar/service/measurementPoint/flowsubscription/NfReplayControll.java
2008-10-07 07:02:10 UTC (rev 4592)
+++
trunk/ps-mdm-flowsub-mp/src/main/java/org/perfsonar/service/measurementPoint/flowsubscription/NfReplayControll.java
2008-10-07 07:29:34 UTC (rev 4593)
@@ -6,6 +6,7 @@
import java.io.IOException;
import java.util.ArrayList;
import java.util.Arrays;
+import java.util.Collection;
import java.util.List;
import java.util.Set;
import java.util.TreeSet;
@@ -99,7 +100,7 @@
protected File getRouterDirectory(String routerName) throws
PerfSONARException {
File directory = new
File(nfcapTargetDirectory,routerName + "/");
if(!directory.exists() && !directory.mkdir()) {
- throw new
PerfSONARException("","Could not create a router directory");
+ throw new
PerfSONARException("error.ma.configuration","Could not create a router
directory("+directory+")");
}
return directory;
}
@@ -374,7 +375,7 @@
}
for(String routerName : subscription.getRouters()) {
if(exportingRouterMap.get(routerName)==null) {
- throw new PerfSONARException("Unkown router
encountered");
+ throw new
PerfSONARException("error.ma.fetching","Unknown exporter
encountered("+routerName+") known exporters: " +
toString(exportingRouterMap.keySet()));
}
}
tunnel.setListener(new Listener() {
@@ -392,6 +393,15 @@
}
}

+ private String toString(Collection<?> collection) {
+ StringBuilder builder = new StringBuilder();
+ for(Object item : collection) {
+ builder.append(item);
+ builder.append(" ");
+ }
+ return builder.toString();
+ }
+
public void destroy() {
relayer.shutdownNow();
exporters.shutdownNow();



  • perfsonar: r4593 - trunk/ps-mdm-flowsub-mp/src/main/java/org/perfsonar/service/measurementPoint/flowsubscription, svnlog, 10/07/2008

Archive powered by MHonArc 2.6.16.

Top of Page