Commit Graph
100 Commits
Author SHA1 Message Date
andi 708a85c28c add daterangepicker
We are now adding the daterangepicker without Angular. This is a little
bit dirty, because we have to load jquery, moment and daterangepicker
manually via script tags, but it works without major hassle.
2019-10-11 17:47:34 +02:00
andi e61f415880 add date range field
It is (again) surprisingly hard to find a decent date+time-range
picker that works with Angular. Daterangepicker, which I used with
my VueJS application does not work with Angular. I can't get the
angularized version
https://github.com/fragaria/angular-daterangepicker) to work either.
And and a native Angular date picker
(https://github.com/GNURub/ngx-daterangepicker) doesn't work either.
2019-10-11 17:29:14 +02:00
andi 020c3b6c39 make the drop down for "combine with" dynamic 2019-10-11 09:54:26 +02:00
andi ca8ee7d8f7 add component for y-axis range 2019-10-10 16:54:02 +02:00
andi 9cf9bf4673 add more plot type icons and disable not (yet) implemented plot types 2019-10-10 15:36:52 +02:00
andi 7ca7b80255 create icons for plot types 2019-10-10 12:00:41 +02:00
andi 69968b7682 ignore hs_err_pid files 2019-10-09 19:03:13 +02:00
andi 2787b42c31 adding a few filters (no doing anything yet) 2019-10-09 19:02:34 +02:00
andi 1afcc7cf38 add left/right panel to visualization page 2019-10-09 16:47:19 +02:00
andi 8b42476b72 add pages for uploading and help 2019-10-09 16:11:05 +02:00
andi e547b67105 add icons from https://uxwing.com/ (MIT License) 2019-10-09 16:10:40 +02:00
andi 65b37e9c67 initial commit of the new UI based on Angular
At this point it is still the example Angular application.
2019-10-08 18:18:24 +02:00
andi c128bdd532 my ideas on how to proceed
I need to clean up the UI and make it easier extendible.
2019-10-08 17:10:13 +02:00
andi 57ad6a1cee update SpringBoot to 2.1.9
Also remove direct dependencies to log4j-api and log4j-core where
possible. log4j-slf4j-impl is enough in many cases.
2019-10-04 20:15:09 +02:00
andi d895eba47c remove duplicate values when rendering
Rendering plots with millions of values is expensive. Before this fix
we wrote all values into CSV files. The CSV files were then read by
Gnuplot that did the rendering. But in an image with n×m pixes there
can only be nm different values. In most realistic scenarios we will
have many values that will be drawn to the same pixels. So we are
wasting time yb first generation the CSV for too many values and then
by parsing that CSV again.
Fixed by using a sparse 2D array to de-duplicate many values before
they get written to the CSV. The additional time we spend de-duplicating
is often smaller than the time saved when writing the CSV, so that the
total CSV writing is about as 'fast' as before (sometimes a little
faster, sometimes a little slower). But the time Gnuplot needs for
rendering drastically reduces. The factor depends on the data, of
course. We have seen factor 50 for realistic examples. Making a 15s
job run in 300ms.
2019-09-29 18:57:57 +02:00
andi d40a7a71c8 update 3rd-party libs 2019-09-29 11:10:05 +02:00
andi 242c83e590 extract constants for gnuplot margins in px 2019-09-08 08:34:14 +02:00
andi 162ef1626c reduce memory usage for computation of cumulative distribution
Before: To compute the cumulative distribution we added every duration
into a LongList. This requires O(n) memory, where n is the number of
values.

Now: We store the durations + the number of occurrences in a
LongLongHashMap. This has the potential to reduce the memory
requirements if durations occur multiple times. There are a lot of
durations with 0, 1, 2 milliseconds. In the worst case every duration
is different. In that case the memory usage doubled with this solution.

Future: We are currently storing durations with milli seconds precision.
We don't have to do that. We cannot draw 100 million different values
on the y-axis in an images with only 1000px.
2019-09-07 18:31:18 +02:00
andi 0e9e2cd53a remove dependency to Guava 2019-09-01 15:44:36 +02:00
andi 8579974051 performance improvement
Queries like "firstname=John and lastname=???" were slightly
inefficient.
They fetched all firstnames, filtered to those that matched the prefix
(e.g. John or Jonathan is this example) and then iterated over all those
values and return the lastnames.
Fixed by having two implementations. One for the case that only a few
of the values in fieldA match and one for the case that many match.
2019-08-31 19:30:54 +02:00
andi d8a114dbaf handle globlike patterns in in-expressions 2019-08-31 17:34:17 +02:00
andi f8e859fb6d cleanup and javadoc 2019-08-31 16:52:13 +02:00
andi 0eee012798 allow 'not' for negation in addition to '!' 2019-08-31 08:30:13 +02:00
andi 4161cd7f98 only field prefixes returned instead of full values
When using autocomplete to return field values I
missed, that autocomplete had the feature that cut
values at dots. So instead of returning full field
values only the prefix up to the first dot was
returned.
Fixed by making the cut-at-dot feature optional.
2019-08-27 20:37:07 +02:00
andi a174ec21ad increase contrast between scatter and cumulative distribution 2019-08-26 20:38:57 +02:00
andi 79c28f2f9e hide tics in gallery view 2019-08-25 18:56:08 +02:00
andi 2f35978184 fetch available values for gallery via autocomplete method
We had a method that returned the values of a field
with respect to a query. That method was inefficient,
because it executed the query, fetched all Docs
and collected the values.
The autocomplete method we introduced a while back
can answer the same question but much more efficiently.
2019-08-25 18:52:05 +02:00
andi 4f61d91c79 draw tic for max value on y-axis only if it makes sense 2019-08-25 15:40:20 +02:00
andi a905c608aa increase maximal allowed duration for 'parallel requests' plot 2019-08-25 10:47:23 +02:00
andi da97a13ed8 add new ranges for date picker 2019-08-25 10:40:05 +02:00
andi 2cd0d71dde fix compile error in Eclipse
Eclipse marked this as an error. A Gradle build had
no issue.
2019-08-25 10:26:39 +02:00
andi 5b57417f75 make the tics on the y-axis easier readable
People are having trouble to understand durations like
100000 or 2.7E+6 milliseconds. Therefore we are
hanging the labels on the y-axis to include the unit
in the tic's label. We also use multiples of seconds,
minutes, hours and days instead of multiples of 10.
2019-08-25 10:25:47 +02:00
andi 4e9b556ea9 update third-party libs 2019-08-24 19:59:06 +02:00
andi 3a7688d1ae remember next eviction time and skip eviction 2019-08-24 19:39:59 +02:00
andi 6eaf4e10fc add maxSize parameter to HotEntryCache 2019-08-24 19:24:20 +02:00
andi 00c20dae6b use long instead of Instant for time
Working with longs is faster and requires less
cache. The space in L123 caches is precious.
2019-08-19 18:58:24 +02:00
andi feda901f6d remove event types
We only have removal events. The additional complexity
of having a generic interface for many different event
types does not pay off.
2019-08-18 20:30:25 +02:00
andi 4d9ea6d2a8 switch back to my own HotEntryCache implementation
Guava's cache does not evict elements reliably by
time. Configure a cache to have a lifetime of n
seconds, then you cannot expect that an element is
actually evicted after n seconds with Guava.
2019-08-18 20:14:14 +02:00
andi 427d7818bf update gradle and commons-collections 2019-08-01 18:54:52 +02:00
andi 574a9c9cc4 update jquery to 3.4.1 2019-07-04 19:12:54 +02:00
andi a8d77562c9 update daterangepicker to 3.0.5 2019-07-04 19:11:00 +02:00
andi 2cb81e5acd make it possible to ignore columns using the csv ingestor 2019-07-04 09:51:33 +02:00
andi 3a39f66e22 update 3rd party libs 2019-07-04 09:06:06 +02:00
andi 58f988f378 update gradle to 5.5 2019-07-04 09:01:39 +02:00
andi 4f57a29c3b increase cache of stringified longs
This should improve the csv generation a little bit.
2019-05-25 17:55:14 +02:00
andi 1be57dce0c update spring and jackson 2019-05-25 17:53:54 +02:00
andi 2eb2a69c17 rename 'percentile' plots to 'cumulative distribution' 2019-05-12 14:30:16 +02:00
andi 1f144846db update 3rd party libs and gradle 2019-04-28 14:40:43 +02:00
andi 9fb1a136c8 cache last used date prefix
The 99.9999% use case is to ingest data
from the same month.
2019-04-22 09:51:44 +02:00
andi dfe9579726 use DateTimeRange.max() instead of arbitrary relative range 2019-04-20 20:36:26 +02:00
andi d82b33c60e update js libraries 2019-04-20 20:31:51 +02:00
andi 7277670b8b update 3rd party libs 2019-04-20 20:19:24 +02:00
andi 9525ee22a0 add access restrictions for a few unwelcome classes 2019-04-20 20:12:45 +02:00
andi 56085061ed do not return anything if the field/value does not exist
The computation of proposals is done by searching for values in a
combined index. If one of the values didn't exist, then the algorithm
returned all values. Fixed by checking that we query only existing
field/values from the combined index.
2019-04-20 19:48:51 +02:00
andi dbe0e02517 rename cluster to partition
We are not clustering the indices, we
are partitioning them.
2019-04-14 10:10:16 +02:00
andi 2a1885a77f cluster the indices 2019-03-31 09:01:55 +02:00
andi 95f2f26966 handle IOExceptions earlier 2019-03-17 11:13:46 +01:00
andi 5d0ceb112e add clustering for DiskStore 2019-03-17 10:53:02 +01:00
andi b5e2d0a217 introduce clustering for query completion indices 2019-03-16 10:19:28 +01:00
andi fb9f8592ac make ClusteredPersistentMap easier to use 2019-02-24 19:20:44 +01:00
andi 59aea1a15f introduce index clustering (part 1)
In order to prevent files from getting too big and
make it easier to implement retention policies, we
are splitting all files into chunks. Each chunk
contains the data for a time interval (1 month per
default).
This first changeset introduces the ClusteredPersistentMap
that implements this for PersistentMap. It is used
for a couple (not all) of indices.
2019-02-24 16:50:57 +01:00
andi 372a073b6d PdbWriter is no longer in the API of DataStore 2019-02-16 16:24:14 +01:00
andi 92a47d9b56 remove TagsToFile
Remove one layer of abstraction by moving the code into the DataStore.
2019-02-16 16:06:46 +01:00
andi 117ef4ea34 use guava's cache as implementation for the HotEntryCache
My own implementation was faster, but was not able to
implement a size limitation.
2019-02-16 10:23:52 +01:00
andi 7b00eede86 refactoring: extract EncoderDecoders from DataStore 2019-02-16 09:16:15 +01:00
andi cbcb7714bb split BSFile into a TimeSeries and a LongStream file
BSFile was used to store two types of data. This makes
the API complex. I split the API into two files with
easier and more clear APIs. Interestingly the API of
BSFile is still rather complex and has to consider both
use cases.
2019-02-10 09:59:16 +01:00
andi fd55ea0866 update vuejs to 2.6.4
Added the version to moment.min.js
2019-02-09 15:39:28 +01:00
andi 93dea402a5 remove obsolete class 2019-02-09 15:25:39 +01:00
andi 27b83234cc group proposal as if they were hierarchical
We interpret dots ('.') as hierarchy delimiter in.
That way we can reduce the number of proposed values
and show only those for the next level.
2019-02-09 15:21:35 +01:00
andi 493971bcf3 values used in queries were added to the keys.csv
Due to a mistake in Tag which added all strings used
by Tag into the String dictionary, the dictionary
did contain all values that were used in queries.
2019-02-09 08:28:23 +01:00
andi ea5884a5e6 move creation of PdbWriter to the DataStore 2019-02-07 18:06:41 +01:00
andi 668d73c926 introduced a new custom file format used for backup and ingestion
The new file format reduces repetition, is easy to parse,
easy to generate in any language and is human readable.
2019-02-03 15:44:35 +01:00
andi 1d8ca0e21c fetch org.lucares artifacts only from repo.lucares.de 2019-02-02 17:51:20 +01:00
andi c0fffbf676 update third party libs
gradle to 5.1.1
spring-boot to 2.1.2.RELEASE
antlr to 4.7.2
jackson to 2.9.8
2019-02-02 17:33:21 +01:00
andi 2e48061793 add LRU cache to PersistentMap
This should speed up fetching and inserting of values
that are used often.
2019-02-02 17:26:25 +01:00
andi d4d1685f9f replace stdout with logger 2019-02-02 16:49:21 +01:00
andi 151e9363e1 remove obsolete classes 2019-02-02 16:45:34 +01:00
andi 76e5d441de rewrite query completion
The old implementation searched for all possible values and then
executed each query to see what matches.
The new implementation uses several indices to find only
the matching values.
2019-02-02 15:35:56 +01:00
andi 72e9a9ebe3 prepare more efficient query completion
adding an index that answers the question
given a query "a=b and c=", what are possible values
for c.
2019-01-13 10:22:17 +01:00
andi 5197063ae3 the union of many small lists is expensive
The reason seems to be the number of memory allocations. In order
to create the union of 100 lists we have 99 memory allocations.
The first needs the space for the first two lists, the second the
space for the first three lists, and so on.

We can reduce the number of allocations drastically (in many
cases to one) by leveraging the fact that many of the lists
were already sorted, non-overlapping and increasing, so that
we can simply concatenate them.
2019-01-05 08:52:56 +01:00
andi 3dca7483de utility that generates a csv with many different tags 2019-01-05 08:33:57 +01:00
andi f2d16b6758 make CacheKey comparable
The CacheKey is used as a key in a HashMap. Lookup can
be faster if the CacheKey is comparable when there are
hash collisions.
In this case I was not able to measure any effect. I am
keeping the comparables nonetheless, because the can
only have a positive effect.
2019-01-01 08:47:48 +01:00
andi 4cde10a9f2 read csv using input stream instead of reader
We are now reading the CSV input without transforming
the data into strings. This reduces the amount of bytes
that have to be converted and copied.
We also made Tag smaller. It no longer stores pointers
to strings, instead it stored integers obtained by
compressing the strings (see StringCompressor). This
reduces memory usage and it speeds up hashcode and
equals, which speeds up access to the writer cache.

Performance gain is almost 100%:
- 330k entries/s -> 670k entries/s, top speed measured over a second
- 62s -> 32s, to ingest 16 million entries
2019-01-01 08:31:28 +01:00
andi 0487c30582 use List instead of TreeMap for intToString mapping
UniqueStringIntegerPairs stores mappings of integers
0-n to strings and vice versa. Mapping integers to
strings does not need a TreeMap, it can be done with
a List.
Makes insertions 3 times (when using the in-memory
variant that does not write to disk) and 7 times faster
for int to string mapping.
2018-12-22 10:07:19 +01:00
andi e537e94d39 HotEntryCache will update Instants only once per second
Calling Instant.now() several hundred thousand times per
second can be expensive. In my measurements >10% of the
time spend when loading new data was spend calling
Instant.now().
Fixed this by storing an Instant as static member and
updating it periodically in a separate thread.
2018-12-21 19:16:55 +01:00
andi d95a71e32e batch entries between TcpIngestor and PerformanceDB
One bottleneck was the blocking queue used to transport entries
from the listener thread to the ingestor thread.
Reduced the bottleneck by batching entries.
Interestingly the batch size of 100 was better than batch size
of 1000 and better than 10.
2018-12-21 13:11:35 +01:00
andi 73ad27ab96 remove lastAccessMap
In the last commit I added a lastAccessMap to the HotEntryCache.
This map made it much more efficient to evict entries. But it
also made and put and get operation much more expensive. Overall
that change lead to a 65% decrease in ingestion performance of
the PerformanceDB.
Fixed by removing the map again. Eviction has to look at all
elements again.
2018-12-21 10:28:34 +01:00
andi afba3b6f77 elements not evicted if new elements are added 2018-12-20 16:13:55 +01:00
andi d52bfa0916 remove obsolete class RadixConverter 2018-12-17 19:11:33 +01:00
andi 3a4101bbf9 increase the buffer between ingestion and insertion thread
I was finally able to show that there is a tiny but measureable
effect of this buffer. I think it was not visible before,
because the parsing was too slow. But now, that I replaced the
date parser, the ingestion thread is twice as fast as the
insertion thread. Therefore the buffer makes more sense.
2018-12-17 19:07:55 +01:00
andi d37508b7a1 Pattern.split is faster than StringUtils.splitPreserveAll
Document the fact, so that I do not have to repeat the same
test a third time.
2018-12-17 19:05:34 +01:00
andi 40f4506e13 use FastISODateParser.parseAsEpochMilli
Compared to FastISODateParser.parse, which returns an
OffsetDateTime object, parseAsEpochMilli returns the
epoch time millis. The performance improvement for
date parsing alone is roughly 100% (8m dates/s to
18m dates/s).
Insertion speed improved from 13-14s for 1.6m entries
to 11.5-12.5s.
2018-12-16 19:24:47 +01:00
andi 23f800a441 add date parsing method that returns epochMillis instead of date object 2018-12-16 15:38:26 +01:00
andi 20c555c30a update 3rd party libs and gradle 2018-12-07 14:06:59 +01:00
andi 253bbabd19 cleanup
remove debug output
2018-11-25 07:49:23 +00:00
andi a86a473b4a use unix line breaks 2018-11-25 07:49:04 +00:00
andi 37207d67ab use utf-8 as resource encoding 2018-11-25 07:29:29 +00:00
andi 593752470c cleanup 2018-11-25 07:46:58 +01:00
andi 5404253bc6 use TreeMap in PersistentMapDiskNode instead of list 2018-11-24 15:57:05 +01:00
andi d67e452a91 cache disk blocks in an LRU cache
Improves read access by factor 4 for small trees.
2018-11-24 15:07:37 +01:00