Skip to content
Snippets Groups Projects
Commit 62c3c086 authored by Vojtech Moravec's avatar Vojtech Moravec
Browse files

Prepare Server for compression.

Server can now answer URL with ?p=init_qcmp. Server will send codebook
stored in ICacheFile as a data stream.
parent 846e48f9
No related branches found
No related tags found
No related merge requests found
...@@ -78,55 +78,6 @@ public class BigDataServer { ...@@ -78,55 +78,6 @@ public class BigDataServer {
new CompressionOptions()); new CompressionOptions());
} }
public static void main(final String[] args) throws Exception {
System.setProperty("org.eclipse.jetty.util.log.class", "org.eclipse.jetty.util.log.StdErrLog");
final Parameters params = processOptions(args, getDefaultParameters());
if (params == null)
return;
final String thumbnailsDirectoryName = getThumbnailDirectoryPath(params);
// Threadpool for multiple connections
final Server server = new Server(new QueuedThreadPool(200, 8));
// ServerConnector configuration
final ServerConnector connector = new ServerConnector(server);
connector.setHost(params.getHostname());
connector.setPort(params.getPort());
LOG.info("Set connectors: " + connector);
server.setConnectors(new Connector[]{connector});
final String baseURL = "http://" + server.getURI().getHost() + ":" + params.getPort();
// Handler initialization
final HandlerCollection handlers = new HandlerCollection();
final ContextHandlerCollection datasetHandlers = createHandlers(baseURL, params, thumbnailsDirectoryName);
handlers.addHandler(datasetHandlers);
handlers.addHandler(new JsonDatasetListHandler(server, datasetHandlers));
Handler handler = handlers;
if (params.enableManagerContext()) {
// Add Statistics bean to the connector
final ConnectorStatistics connectorStats = new ConnectorStatistics();
connector.addBean(connectorStats);
// create StatisticsHandler wrapper and ManagerHandler
final StatisticsHandler statHandler = new StatisticsHandler();
handlers.addHandler(new ManagerHandler(baseURL, server, connectorStats, statHandler, datasetHandlers, thumbnailsDirectoryName));
statHandler.setHandler(handlers);
handler = statHandler;
}
LOG.info("Set handler: " + handler);
server.setHandler(handler);
LOG.info("Server Base URL: " + baseURL);
LOG.info("BigDataServer starting");
server.start();
server.join();
}
/** /**
* Server parameters: hostname, port, datasets. * Server parameters: hostname, port, datasets.
*/ */
...@@ -186,7 +137,6 @@ public class BigDataServer { ...@@ -186,7 +137,6 @@ public class BigDataServer {
public CompressionOptions getCompressionParams() { public CompressionOptions getCompressionParams() {
return compressionParam; return compressionParam;
} }
} }
...@@ -203,6 +153,7 @@ public class BigDataServer { ...@@ -203,6 +153,7 @@ public class BigDataServer {
"dataset should be made accessible and XML is the path to the XML file of the dataset.\n" + "dataset should be made accessible and XML is the path to the XML file of the dataset.\n" +
"If -qcmp option is specified, these options are enabled:\u001b[35m-sq,-vq,-b,-cbc\u001b[0m\n"; "If -qcmp option is specified, these options are enabled:\u001b[35m-sq,-vq,-b,-cbc\u001b[0m\n";
options.addOption(OptionBuilder options.addOption(OptionBuilder
.withDescription("Hostname of the server.\n(default: " + defaultParameters.getHostname() + ")") .withDescription("Hostname of the server.\n(default: " + defaultParameters.getHostname() + ")")
.hasArg() .hasArg()
...@@ -243,13 +194,10 @@ public class BigDataServer { ...@@ -243,13 +194,10 @@ public class BigDataServer {
.create(ENABLE_COMPRESSION), ++optionOrder)); .create(ENABLE_COMPRESSION), ++optionOrder));
OptionGroup qcmpOptionGroup = new OptionGroup(); options.addOption(new OptionWithOrder(CliConstants.createCBCMethod(), ++optionOrder));
qcmpOptionGroup.setRequired(false); options.addOption(new OptionWithOrder(CliConstants.createSQOption(), ++optionOrder));
qcmpOptionGroup.addOption(new OptionWithOrder(CliConstants.createCBCMethod(), ++optionOrder)); options.addOption(new OptionWithOrder(CliConstants.createVQOption(), ++optionOrder));
qcmpOptionGroup.addOption(new OptionWithOrder(CliConstants.createSQOption(), ++optionOrder)); options.addOption(new OptionWithOrder(CliConstants.createBitsOption(), ++optionOrder));
qcmpOptionGroup.addOption(new OptionWithOrder(CliConstants.createVQOption(), ++optionOrder));
qcmpOptionGroup.addOption(new OptionWithOrder(CliConstants.createBitsOption(), ++optionOrder));
options.addOptionGroup(qcmpOptionGroup);
if (Constants.ENABLE_EXPERIMENTAL_FEATURES) { if (Constants.ENABLE_EXPERIMENTAL_FEATURES) {
...@@ -309,15 +257,20 @@ public class BigDataServer { ...@@ -309,15 +257,20 @@ public class BigDataServer {
compressionReport.append("Quantization type: "); compressionReport.append("Quantization type: ");
switch (compressionOptions.getQuantizationType()) { switch (compressionOptions.getQuantizationType()) {
case Scalar: case Scalar:
compressionReport.append("Scalar\n"); compressionReport.append("Scalar");
break; break;
case Vector1D: case Vector1D:
compressionReport.append(String.format("Vector1D %s\n", compressionOptions.getQuantizationVector().toString())); compressionReport.append("Vector1D");
break; break;
case Vector2D: case Vector2D:
compressionReport.append(String.format("Vector2D %s\n", compressionOptions.getQuantizationVector().toString())); compressionReport.append("Vector2D");
break;
case Vector3D:
compressionReport.append("Vector3D");
break; break;
} }
compressionReport.append(compressionOptions.getQuantizationVector().toString());
compressionReport.append('\n');
compressionReport.append("Bits per codebook index: ").append(compressionOptions.getBitsPerCodebookIndex()).append('\n'); compressionReport.append("Bits per codebook index: ").append(compressionOptions.getBitsPerCodebookIndex()).append('\n');
compressionReport.append("Codebook cache folder: ").append(compressionOptions.getCodebookCacheFolder()).append('\n'); compressionReport.append("Codebook cache folder: ").append(compressionOptions.getCodebookCacheFolder()).append('\n');
compressionReport.append("\u001b[0m"); compressionReport.append("\u001b[0m");
...@@ -461,4 +414,53 @@ public class BigDataServer { ...@@ -461,4 +414,53 @@ public class BigDataServer {
return handlers; return handlers;
} }
public static void main(final String[] args) throws Exception {
System.setProperty("org.eclipse.jetty.util.log.class", "org.eclipse.jetty.util.log.StdErrLog");
final Parameters params = processOptions(args, getDefaultParameters());
if (params == null)
return;
final String thumbnailsDirectoryName = getThumbnailDirectoryPath(params);
// Threadpool for multiple connections
final Server server = new Server(new QueuedThreadPool(200, 8));
// ServerConnector configuration
final ServerConnector connector = new ServerConnector(server);
connector.setHost(params.getHostname());
connector.setPort(params.getPort());
LOG.info("Set connectors: " + connector);
server.setConnectors(new Connector[]{connector});
final String baseURL = "http://" + server.getURI().getHost() + ":" + params.getPort();
// Handler initialization
final HandlerCollection handlers = new HandlerCollection();
final ContextHandlerCollection datasetHandlers = createHandlers(baseURL, params, thumbnailsDirectoryName);
handlers.addHandler(datasetHandlers);
handlers.addHandler(new JsonDatasetListHandler(server, datasetHandlers));
Handler handler = handlers;
if (params.enableManagerContext()) {
// Add Statistics bean to the connector
final ConnectorStatistics connectorStats = new ConnectorStatistics();
connector.addBean(connectorStats);
// create StatisticsHandler wrapper and ManagerHandler
final StatisticsHandler statHandler = new StatisticsHandler();
handlers.addHandler(new ManagerHandler(baseURL, server, connectorStats, statHandler, datasetHandlers, thumbnailsDirectoryName));
statHandler.setHandler(handlers);
handler = statHandler;
}
LOG.info("Set handler: " + handler);
server.setHandler(handler);
LOG.info("Server Base URL: " + baseURL);
LOG.info("BigDataServer starting");
server.start();
server.join();
}
} }
package bdv.server; package bdv.server;
import java.awt.image.BufferedImage; import azgracompress.cache.ICacheFile;
import java.io.*; import azgracompress.cache.QuantizationCacheManager;
import java.nio.ByteBuffer; import azgracompress.compression.CompressionOptions;
import java.nio.file.Files; import azgracompress.compression.IImageCompressor;
import java.nio.file.Path; import azgracompress.compression.ImageCompressor;
import java.nio.file.Paths; import azgracompress.data.V3;
import azgracompress.data.V3i;
import javax.imageio.ImageIO; import azgracompress.io.FileInputData;
import javax.servlet.http.HttpServletRequest; import azgracompress.io.FlatBufferInputData;
import javax.servlet.http.HttpServletResponse; import azgracompress.io.InputData;
import azgracompress.quantization.vector.VQCodebook;
import compression.U16;
import compression.data.Chunk3D;
import compression.data.ChunkIO;
import compression.data.V3i;
import compression.data.V3l;
import compression.quantization.scalar.ScalarQuantizer;
import compression.utilities.Utils;
import org.eclipse.jetty.server.Request;
import org.eclipse.jetty.server.handler.ContextHandler;
import org.eclipse.jetty.util.log.Log;
import org.jdom2.Document;
import org.jdom2.JDOMException;
import org.jdom2.input.SAXBuilder;
import org.jdom2.output.Format;
import org.jdom2.output.XMLOutputter;
import com.google.gson.GsonBuilder;
import bdv.BigDataViewer; import bdv.BigDataViewer;
import bdv.cache.CacheHints; import bdv.cache.CacheHints;
import bdv.cache.LoadingStrategy; import bdv.cache.LoadingStrategy;
...@@ -45,9 +27,27 @@ import bdv.spimdata.SequenceDescriptionMinimal; ...@@ -45,9 +27,27 @@ import bdv.spimdata.SequenceDescriptionMinimal;
import bdv.spimdata.SpimDataMinimal; import bdv.spimdata.SpimDataMinimal;
import bdv.spimdata.XmlIoSpimDataMinimal; import bdv.spimdata.XmlIoSpimDataMinimal;
import bdv.util.ThumbnailGenerator; import bdv.util.ThumbnailGenerator;
import com.google.gson.GsonBuilder;
import mpicbg.spim.data.SpimDataException; import mpicbg.spim.data.SpimDataException;
import net.imglib2.img.basictypeaccess.volatiles.array.VolatileShortArray; import net.imglib2.img.basictypeaccess.volatiles.array.VolatileShortArray;
import net.imglib2.realtransform.AffineTransform3D; import net.imglib2.realtransform.AffineTransform3D;
import org.eclipse.jetty.server.Request;
import org.eclipse.jetty.server.handler.ContextHandler;
import org.eclipse.jetty.util.log.Log;
import org.jdom2.Document;
import org.jdom2.JDOMException;
import org.jdom2.input.SAXBuilder;
import org.jdom2.output.Format;
import org.jdom2.output.XMLOutputter;
import javax.imageio.ImageIO;
import javax.servlet.http.HttpServletRequest;
import javax.servlet.http.HttpServletResponse;
import java.awt.image.BufferedImage;
import java.io.*;
import java.nio.file.Files;
import java.nio.file.Path;
import java.nio.file.Paths;
public class CellHandler extends ContextHandler { public class CellHandler extends ContextHandler {
private long transferedDataSize = 0; private long transferedDataSize = 0;
...@@ -96,18 +96,21 @@ public class CellHandler extends ContextHandler { ...@@ -96,18 +96,21 @@ public class CellHandler extends ContextHandler {
* Full path to thumbnail png. * Full path to thumbnail png.
*/ */
private final String thumbnailFilename; private final String thumbnailFilename;
final CustomCompressionParameters compressionParams;
private ScalarQuantizer quantizer; /**
* Compression stuff.
*/
private final CompressionOptions compressionParams;
private ICacheFile compressionCacheFile = null;
private ImageCompressor compressor = null;
public CellHandler(final String baseUrl, final String xmlFilename, final String datasetName, final String thumbnailsDirectory, public CellHandler(final String baseUrl, final String xmlFilename, final String datasetName, final String thumbnailsDirectory,
final CustomCompressionParameters compressionParams, final CompressionOptions compressionParams) throws SpimDataException, IOException {
final ScalarQuantizer quantizer) throws SpimDataException, IOException {
final XmlIoSpimDataMinimal io = new XmlIoSpimDataMinimal(); final XmlIoSpimDataMinimal io = new XmlIoSpimDataMinimal();
final SpimDataMinimal spimData = io.load(xmlFilename); final SpimDataMinimal spimData = io.load(xmlFilename);
final SequenceDescriptionMinimal seq = spimData.getSequenceDescription(); final SequenceDescriptionMinimal seq = spimData.getSequenceDescription();
final Hdf5ImageLoader imgLoader = (Hdf5ImageLoader) seq.getImgLoader(); final Hdf5ImageLoader imgLoader = (Hdf5ImageLoader) seq.getImgLoader();
this.quantizer = quantizer;
this.compressionParams = compressionParams; this.compressionParams = compressionParams;
cache = imgLoader.getCacheControl(); cache = imgLoader.getCacheControl();
...@@ -124,10 +127,33 @@ public class CellHandler extends ContextHandler { ...@@ -124,10 +127,33 @@ public class CellHandler extends ContextHandler {
metadataJson = buildMetadataJsonString(imgLoader, seq); metadataJson = buildMetadataJsonString(imgLoader, seq);
settingsXmlString = buildSettingsXML(baseFilename); settingsXmlString = buildSettingsXML(baseFilename);
thumbnailFilename = createThumbnail(spimData, baseFilename, datasetName, thumbnailsDirectory); thumbnailFilename = createThumbnail(spimData, baseFilename, datasetName, thumbnailsDirectory);
initializeCompression();
}
private void initializeCompression() {
if (compressionParams == null)
return;
this.compressionParams.setInputDataInfo(new FileInputData(this.baseFilename));
compressor = new ImageCompressor(compressionParams);
QuantizationCacheManager qcm = new QuantizationCacheManager(compressionParams.getCodebookCacheFolder());
this.compressionCacheFile = qcm.loadCacheFile(compressionParams);
if (compressionCacheFile != null) {
LOG.info("CellHandler loaded codebook cache file. '" + compressionCacheFile.toString() + "'");
System.out.println("\u001b[33mCellHandler::initializeCompression() loaded codebook cache file. '" +
compressionCacheFile.toString() + "'\u001b[0m");
}
} }
@Override @Override
public void doHandle(final String target, final Request baseRequest, final HttpServletRequest request, final HttpServletResponse response) throws IOException { public void doHandle(final String target,
final Request baseRequest,
final HttpServletRequest request,
final HttpServletResponse response) throws IOException {
if (target.equals("/settings")) { if (target.equals("/settings")) {
if (settingsXmlString != null) if (settingsXmlString != null)
respondWithString(baseRequest, response, "application/xml", settingsXmlString); respondWithString(baseRequest, response, "application/xml", settingsXmlString);
...@@ -159,109 +185,63 @@ public class CellHandler extends ContextHandler { ...@@ -159,109 +185,63 @@ public class CellHandler extends ContextHandler {
Integer.parseInt(parts[5]), Integer.parseInt(parts[5]),
Integer.parseInt(parts[6]), Integer.parseInt(parts[6]),
Integer.parseInt(parts[7])}; Integer.parseInt(parts[7])};
final long[] cellMin = new long[]{ final long[] cellMin = new long[]{
Long.parseLong(parts[8]), Long.parseLong(parts[8]),
Long.parseLong(parts[9]), Long.parseLong(parts[9]),
Long.parseLong(parts[10])}; Long.parseLong(parts[10])};
if (cell == null) { if (cell == null) {
cell = cache.getLoadingVolatileCache().get(key, cacheHints, new VolatileCellLoader<>(loader, timepoint, setup, level, cellDims, cellMin)); cell = cache.getLoadingVolatileCache().get(key,
cacheHints,
new VolatileCellLoader<>(loader,
timepoint,
setup,
level,
cellDims,
cellMin));
} }
@SuppressWarnings("unchecked") @SuppressWarnings("unchecked")
short[] data = ((VolatileCell<VolatileShortArray>) cell).getData().getCurrentStorageArray(); short[] data = ((VolatileCell<VolatileShortArray>) cell).getData().getCurrentStorageArray();
final OutputStream responseStream = response.getOutputStream();
// // Stupidity just testing chunking if (compressor == null || true) {
// { final byte[] buf = new byte[2 * data.length];
// Chunk3D dataBox = new Chunk3D(new V3i(cellDims[0], cellDims[1], cellDims[2]), for (int i = 0, j = 0; i < data.length; i++) {
// new V3l(cellMin[0], cellMin[1], cellMin[1]), data); final short s = data[i];
// Chunk3D[] chunks = dataBox.divideIntoChunks(new V3i(3)); buf[j++] = (byte) ((s >> 8) & 0xff);
// dataBox.zeroData(); buf[j++] = (byte) (s & 0xff);
// dataBox.reconstructFromChunks(chunks);
// data = dataBox.getDataAsShort();
// }
if (compressionParams.shouldCompressData()) {
assert (quantizer != null) : "Compressor wasn't created";
data = quantizer.quantize(data);
} else if (compressionParams.renderDifference()) {
final int diffThreshold = compressionParams.getDiffThreshold();
assert (quantizer != null) : "Compressor wasn't created";
short[] compressedData = quantizer.quantize(data);
int maxError = Integer.MIN_VALUE;
for (int i = 0; i < data.length; i++) {
final int diff = Math.abs(compressedData[i] - data[i]);
maxError = Math.max(maxError, diff);
// NOTE(Moravec): We know that we are not producing non-existing values.
// There was no data but now there is.
// if (data[i] == 0 && compressedData[i] != 0) {
// data[i] = (short) 0xffff;
// ++nonExistingDataCount;
// } else {
// data[i] = (short) 0x0;
// }
// if (compressedData[i] > data[i]) {
// data[i] = compressedData[i];
// } else {
// data[i] = 0;
// }
// if (diff > diffThreshold) {
// data[i] = (short) diff;
// } else {
// data[i] = 0;
// }
// NOTE(Moravec): Squared error
final short squaredError = (short) Math.floor(Math.pow(compressedData[i] - data[i], 2));
data[i] = squaredError;
}
if (maxError > 0) {
System.out.println("Max error: " + maxError);
} }
response.setContentLength(buf.length);
responseStream.write(buf);
} else {
// TODO(Moravec): Implement.
} }
responseStream.close();
final byte[] buf = new byte[2 * data.length]; response.setContentType("application/octet-stream");
for (int i = 0, j = 0; i < data.length; i++) { response.setStatus(HttpServletResponse.SC_OK);
final short s = data[i]; baseRequest.setHandled(true);
buf[j++] = (byte) ((s >> 8) & 0xff);
buf[j++] = (byte) (s & 0xff);
}
if (compressionParams.shouldDumpRequestData()) { } else if (parts[0].equals("init")) {
// Normal data dump respondWithString(baseRequest, response, "application/json", metadataJson);
/* } else if (parts[0].equals("init_qcmp")) {
FileOutputStream dumpStream = new FileOutputStream(compressionParams.getDumpFile(), true); if (compressor == null) {
dumpStream.write(buf); respondWithString(baseRequest, response,
dumpStream.flush(); "text/plain", "QCMP Compression wasn't enabled on BigDataViewer server.",
dumpStream.close(); HttpServletResponse.SC_BAD_REQUEST);
*/ return;
// Dumping HDF5 3D chunks
ChunkIO.saveChunks(cellDims, cellMin, buf, compressionParams.getDumpFile());
} }
transferedDataSize += buf.length; try (DataOutputStream dos = new DataOutputStream(response.getOutputStream())) {
compressionCacheFile.writeToStream(dos);
// LOG.info(String.format("I:%d;T:%d;S:%d;L:%d Total transfered data: [%d KB] [%d MB]", }
// index, timepoint, setup, level,
// (transferedDataSize / 1000), ((transferedDataSize / 1000) / 1000)));
response.setContentType("application/octet-stream"); response.setContentType("application/octet-stream");
response.setContentLength(buf.length);
response.setStatus(HttpServletResponse.SC_OK); response.setStatus(HttpServletResponse.SC_OK);
baseRequest.setHandled(true); baseRequest.setHandled(true);
final OutputStream os = response.getOutputStream();
os.write(buf);
os.close();
} else if (parts[0].
equals("init")) {
respondWithString(baseRequest, response, "application/json", metadataJson);
} }
} }
private void provideThumbnail(final Request baseRequest, final HttpServletResponse response) throws IOException { private void provideThumbnail(final Request baseRequest, final HttpServletResponse response) throws IOException {
...@@ -314,7 +294,9 @@ public class CellHandler extends ContextHandler { ...@@ -314,7 +294,9 @@ public class CellHandler extends ContextHandler {
* Create a modified dataset XML by replacing the ImageLoader with an * Create a modified dataset XML by replacing the ImageLoader with an
* {@link RemoteImageLoader} pointing to the data we are serving. * {@link RemoteImageLoader} pointing to the data we are serving.
*/ */
private static String buildRemoteDatasetXML(final XmlIoSpimDataMinimal io, final SpimDataMinimal spimData, final String baseUrl) throws IOException, SpimDataException { private static String buildRemoteDatasetXML(final XmlIoSpimDataMinimal io,
final SpimDataMinimal spimData,
final String baseUrl) throws IOException, SpimDataException {
final SpimDataMinimal s = new SpimDataMinimal(spimData, new RemoteImageLoader(baseUrl, false)); final SpimDataMinimal s = new SpimDataMinimal(spimData, new RemoteImageLoader(baseUrl, false));
final Document doc = new Document(io.toXml(s, s.getBasePath())); final Document doc = new Document(io.toXml(s, s.getBasePath()));
final XMLOutputter xout = new XMLOutputter(Format.getPrettyFormat()); final XMLOutputter xout = new XMLOutputter(Format.getPrettyFormat());
...@@ -350,12 +332,18 @@ public class CellHandler extends ContextHandler { ...@@ -350,12 +332,18 @@ public class CellHandler extends ContextHandler {
/** /**
* Create PNG thumbnail file named "{@code <baseFilename>.png}". * Create PNG thumbnail file named "{@code <baseFilename>.png}".
*/ */
private static String createThumbnail(final SpimDataMinimal spimData, final String baseFilename, final String datasetName, final String thumbnailsDirectory) { private static String createThumbnail(final SpimDataMinimal spimData,
final String baseFilename,
final String datasetName,
final String thumbnailsDirectory) {
final String thumbnailFileName = thumbnailsDirectory + "/" + datasetName + ".png"; final String thumbnailFileName = thumbnailsDirectory + "/" + datasetName + ".png";
final File thumbnailFile = new File(thumbnailFileName); final File thumbnailFile = new File(thumbnailFileName);
if (!thumbnailFile.isFile()) // do not recreate thumbnail if it already exists if (!thumbnailFile.isFile()) // do not recreate thumbnail if it already exists
{ {
final BufferedImage bi = ThumbnailGenerator.makeThumbnail(spimData, baseFilename, Constants.THUMBNAIL_WIDTH, Constants.THUMBNAIL_HEIGHT); final BufferedImage bi = ThumbnailGenerator.makeThumbnail(spimData,
baseFilename,
Constants.THUMBNAIL_WIDTH,
Constants.THUMBNAIL_HEIGHT);
try { try {
ImageIO.write(bi, "png", thumbnailFile); ImageIO.write(bi, "png", thumbnailFile);
} catch (final IOException e) { } catch (final IOException e) {
...@@ -369,10 +357,24 @@ public class CellHandler extends ContextHandler { ...@@ -369,10 +357,24 @@ public class CellHandler extends ContextHandler {
/** /**
* Handle request by sending a UTF-8 string. * Handle request by sending a UTF-8 string.
*/ */
private static void respondWithString(final Request baseRequest, final HttpServletResponse response, final String contentType, final String string) throws IOException { private static void respondWithString(final Request baseRequest,
final HttpServletResponse response,
final String contentType,
final String string) throws IOException {
respondWithString(baseRequest, response, contentType, string, HttpServletResponse.SC_OK);
}
/**
* Handle request by sending a UTF-8 string.
*/
private static void respondWithString(final Request baseRequest,
final HttpServletResponse response,
final String contentType,
final String string,
final int httpStatus) throws IOException {
response.setContentType(contentType); response.setContentType(contentType);
response.setCharacterEncoding("UTF-8"); response.setCharacterEncoding("UTF-8");
response.setStatus(HttpServletResponse.SC_OK); response.setStatus(httpStatus);
baseRequest.setHandled(true); baseRequest.setHandled(true);
final PrintWriter ow = response.getWriter(); final PrintWriter ow = response.getWriter();
......
...@@ -157,8 +157,7 @@ public class ManagerHandler extends ContextHandler { ...@@ -157,8 +157,7 @@ public class ManagerHandler extends ContextHandler {
CellHandler ctx = null; CellHandler ctx = null;
try { try {
LOG.warn("We are creating CellHandler without compression params!"); LOG.warn("We are creating CellHandler without compression params!");
ctx = new CellHandler(baseURL + context + "/", fileLocation, datasetName, thumbnailsDirectoryName, ctx = new CellHandler(baseURL + context + "/", fileLocation, datasetName, thumbnailsDirectoryName, null);
null, null);
} catch (final SpimDataException e) { } catch (final SpimDataException e) {
LOG.warn("Failed to create a CellHandler", e); LOG.warn("Failed to create a CellHandler", e);
e.printStackTrace(); e.printStackTrace();
......
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Please register or to comment