diff --git a/src/main/java/com/conveyal/analysis/components/LocalBackendComponents.java b/src/main/java/com/conveyal/analysis/components/LocalBackendComponents.java index f567d7021..4de8e3098 100644 --- a/src/main/java/com/conveyal/analysis/components/LocalBackendComponents.java +++ b/src/main/java/com/conveyal/analysis/components/LocalBackendComponents.java @@ -34,7 +34,7 @@ public LocalBackendComponents () { authentication = new LocalAuthentication(); // TODO add nested LocalWorkerComponents here, to reuse some components, and pass it into the LocalWorkerLauncher? workerLauncher = new LocalWorkerLauncher(config, fileStorage, gtfsCache, osmCache); - broker = new Broker(config, eventBus, workerLauncher, fileStorage); + broker = new Broker(config, fileStorage, eventBus, workerLauncher); censusExtractor = new SeamlessCensusGridExtractor(config); // Instantiate the HttpControllers last, when all the components except the HttpApi are already created. List httpControllers = standardHttpControllers(); diff --git a/src/main/java/com/conveyal/analysis/components/broker/Broker.java b/src/main/java/com/conveyal/analysis/components/broker/Broker.java index a60a1a496..7abe1e5f4 100644 --- a/src/main/java/com/conveyal/analysis/components/broker/Broker.java +++ b/src/main/java/com/conveyal/analysis/components/broker/Broker.java @@ -90,6 +90,8 @@ public interface Config { private Config config; // Component Dependencies + // Result assemblers return files that need to be permanently stored. + private final FileStorage fileStorage; private final EventBus eventBus; private final WorkerLauncher workerLauncher; @@ -140,11 +142,6 @@ public interface Config { */ private static Map resultAssemblers = new HashMap<>(); - /** - * Result assemblers return files that need to be permanently stored. - */ - private final FileStorage fileStorage; - /** * keep track of which graphs we have launched workers on and how long ago we launched them, so * that we don't re-request workers which have been requested. @@ -152,11 +149,11 @@ public interface Config { public TObjectLongMap recentlyRequestedWorkers = TCollections.synchronizedMap(new TObjectLongHashMap<>()); - public Broker (Config config, EventBus eventBus, WorkerLauncher workerLauncher, FileStorage fileStorage) { + public Broker (Config config, FileStorage fileStorage, EventBus eventBus, WorkerLauncher workerLauncher) { this.config = config; + this.fileStorage = fileStorage; this.eventBus = eventBus; this.workerLauncher = workerLauncher; - this.fileStorage = fileStorage; } /** diff --git a/src/main/java/com/conveyal/analysis/results/CsvResultWriter.java b/src/main/java/com/conveyal/analysis/results/CsvResultWriter.java index 4b7925e75..153e4187c 100644 --- a/src/main/java/com/conveyal/analysis/results/CsvResultWriter.java +++ b/src/main/java/com/conveyal/analysis/results/CsvResultWriter.java @@ -56,7 +56,7 @@ public abstract class CsvResultWriter implements RegionalResultWriter { * Construct a writer to record incoming results in a CSV file, with header row consisting of * "origin", "destination", and the supplied indicator. */ - public CsvResultWriter (RegionalTask task) { + CsvResultWriter (RegionalTask task) { checkArgument(task.originPointSet != null, "CsvResultWriters require FreeFormPointSet origins."); String[] columns = columnHeaders(); csvWriter = getBufferedCsvWriter(columns);