Examples of dateHistogram()


Examples of org.graylog2.restclient.models.UniversalSearch.dateHistogram()

            filter = "streams:" + streamId;
        }

        try {
            UniversalSearch search = searchFactory.queryWithRangeAndFilter(q, timerange, filter);
            DateHistogramResult histogram = search.dateHistogram(interval);
            List<Map<String, Long>> results = formatHistogramResults(histogram, maxDataPoints, relative == 0);

            Map<String, Object> result = Maps.newHashMap();
            AbsoluteRange boundaries = histogram.getHistogramBoundaries();
            result.put("time", histogram.getTookMs());
View Full Code Here

Examples of org.graylog2.restclient.models.UniversalSearch.dateHistogram()

            // histogram resolution (strangely aka interval)
            if (interval == null || interval.isEmpty() || !SearchTools.isAllowedDateHistogramInterval(interval)) {
                interval = determineHistogramResolution(searchResult);
            }
            histogramResult = search.dateHistogram(interval);
            formattedHistogramResults = formatHistogramResults(histogramResult.getResults(), displayWidth);
        } catch (IOException e) {
            return status(504, views.html.errors.error.render(ApiClient.ERROR_MSG_IO, e, request()));
        } catch (APIException e) {
            String message = "There was a problem with your search. We expected HTTP 200, but got a HTTP " + e.getHttpCode() + ".";
View Full Code Here
TOP
Copyright © 2018 www.massapi.com. All rights reserved.
All source code are property of their respective owners. Java is a trademark of Sun Microsystems, Inc and owned by ORACLE Inc. Contact coftware#gmail.com.