cortoproject / corto

A hierarchical object store for connecting realtime machine data with web applications, historians & more
https://www.corto.io
MIT License
87 stars 14 forks source link

Recursive ("select all") queries interrogating mount with invalid limit #632

Closed hendrenja closed 6 years ago

hendrenja commented 6 years ago

While recursively interrogating the kentucky/... path, the Limit is set to 1. So only kentucky/nicholasville/weather is returned.

Object Store:

california                          // LIMIT = 0 OFFSET = 0
california/san diego                // LIMIT = 0 OFFSET = 0        
california/san diego/weather        // LIMIT = 0 OFFSET = 0
kentucky                            // LIMIT = 1 OFFSET = 0
kentucky/lexington                  // NOT QUERIED
kentucky/lexington/weather          // NOT QUERIED
kentucky/nicholasville              // LIMIT = 1 OFFSET = 0
kentucky/nicholasville/weather      // LIMIT = 1 OFFSET = 0
texas                               // LIMIT = 0 OFFSET = 0
texas/houston                       // LIMIT = 0 OFFSET = 0
texas/houston/weather               // LIMIT = 0 OFFSET = 0
corto_select("//")
    .from("/weather")
    .type(corto_fullpath(NULL, (corto_type)test_Weather_o))
    .iter(&it)
hendrenja commented 6 years ago

@SanderMertens I have reproduced the issue using the filestore mount, which you are more familiar with (also substantially less complex than influxDB). https://github.com/hendrenja/driver-mnt-filestore/tree/type_query_limit_bug

I added a print statement to filestore_mount_onQuery to show the invalid limits as the mount begins recursively interrogating the filestore mount.

Set the storeDir in type/etc/everywhere/filestore.json to a valid directory on your machine.

Compile and run type app.

SanderMertens commented 6 years ago

Fixed in: https://github.com/cortoproject/corto/commit/648896f64ef2fc2b62da04dcf4ec415a5debb783