Coder Social home page Coder Social logo

p6's Introduction

JANTIMATOR: Join Analysis of iNequality esTIMATOR

This is a project about creating better cardinality estimates for Join Queries with inequality predicates. Todays systems are not geared towards giving good cardinality estimates for these queries, which is something this project aims to do something about.

ezgif-2-c037fe5652

The program itself consists of a WPF interface written in C#. The program is capable of taking a set of queries in a json format, see what a given database system would estimate the cardinality of said query and then give a new estimate from our estimator. This program itself uses MySQL and PostgeSQL to run queries on.

Datasets

For this project, 10 syntetic datasets and 3 real datasets was used. The syntetic datasets have the same table setup (See mysql table definitions and postgres table definitions for details) and the data is:

  • RandomNumberBlocks
    • Consisting of 4 tables with random values in them (See inserts for details)
  • ConstantNumberBlocks
  • ClumpedNumberBlocks_Difficult
  • ClumpedNumberBlocks_Possible
  • LinearNumberBlocks

In addition to this, there are Large verisons of them, with 5 times more rows in each table.

The real datasets are:

Setup

You need to setup the two database systems (or alternatively disable one them in the experiments.json file). The current tests are setup to use default users for PostgreSQL and MySQL.

MySQL: Username: root password password

PostgrSQL: Username: postgre password password

These can be changed in the secrets file (See the readme for more info).

Views

The program consist of 3 main views, the main view, the Sentinel Viewer and the Cache Viewer. The main view is the one shown when the program starts. This has options to turn on/off sentinels and a run button. If you press said button the program will start running through all the experiments defined in the experiments.json file (See the readme for more info)

Sentinel Viewer

Result sentinels are there to make sure that the database systems get the same result between runs. This is an additional safety check, to make sure the results are actually correct. See ResultsSentinel for more info.

Cache Viewer

This program makes use of caches to reduce execution times for tests. The Actual Cardinalities are saved to a cache file during runtime (and is loaded automatically on next launch). What is saved in these caches can be seen in the Cache Viewer, consisting of a MD5 hash of the data as well as the data itself.

Subviews

There are also two subviews, that can be used to debug or get a better understanding of what happens during the bounding and estimation process. One subview is for seeing how Milestones got generated, while the other is for each of the query file runs you can see how the bounding and estimation was set. These views are buttons under each testrunner that is displayed when the tests starts running.

Flow

A general flowchart of how the tests are run can be seen below. This is for each connector. flow

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    ๐Ÿ–– Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. ๐Ÿ“Š๐Ÿ“ˆ๐ŸŽ‰

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google โค๏ธ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.