Commit Graph

260 Commits

Author SHA1 Message Date
Teon Banek
777b6a8101 Store paths to glog include and library in CMakeLists
Reviewers: buda, mferencevic

Reviewed By: mferencevic

Subscribers: pullbot

Differential Revision: https://phabricator.memgraph.io/D615
2017-08-16 11:32:52 +02:00
Mislav Bradac
599e5651af Make debug_assert noop on NDEBUG
Reviewers: mferencevic

Reviewed By: mferencevic

Subscribers: mferencevic, pullbot

Differential Revision: https://phabricator.memgraph.io/D634
2017-08-04 15:05:26 +02:00
Matej Ferencevic
a11c9885ad Merged experimental repo.
Summary:
Fixed distributed init.
Add CMakeLists to build experimentall/distribuedClosing unused Channels, work in progress.
Make System the owner of Reactor.
This entails changing shared_ptr -> unique_ptr and some pointers to references.
Merged experimental repository into memgraph.
Moved experimental repo to experimental directory.
Removed obsolete experimental files.
Added comments.
Merge branch 'master' of https://phabricator.memgraph.io/source/experimental
Subscription service unsubscribe.
Add Close method on EventStream.
Add placeholder for the configuration class.
Remove comments.
Merge branch 'master' of https://phabricator.memgraph.io/source/experimental
Clean-up parameters for EventQueue.
Merge branch 'master' of https://phabricator.memgraph.io/source/experimental
Add Channel::serialize method implementation.
Merge.
Add docs on event stream.
Clang-format merge conflicts.
First implementations of serialize methods.
Add hostname, port, and names as methods in Channel base class.
Add reactor name and name methods to LocalChannel.
Add reactor name to LocalChannel.
Add name to LocalChannel.
Add serialization service.
Serialize_test removed.
Merge branch 'master' of https://phabricator.memgraph.io/source/experimental
Move Message to the end of communications files.
Full example of serialization with cereal.
Fix constructor calls.
Merge branch 'master' of https://phabricator.memgraph.io/source/experimental
Avoid using `FindChannel` in the transaction code.
Merge branch 'master' of https://phabricator.memgraph.io/source/experimental
Init script creates libs folder.
Merge branch 'master' of https://phabricator.memgraph.io/source/experimental
Add System pointer to Network.
serialized_test binary is removed from the repo.
Merge branch 'master' of https://phabricator.memgraph.io/source/experimental
Cereal basic example.
Merge branch 'master' of https://phabricator.memgraph.io/source/experimental
Callbacks finished.
Always open the main channel by default.
Fixed callbacks, wrong number of emplace arguments.
Callbacks WIP.
Raise connector mutex to reactor level.
Add argument to LockedPush.
Fix data race in connector closing.
Merge branch 'master' of https://phabricator.memgraph.io/source/experimental
Add functional header.
Fixed to make the changes work.
Merge branch 'master' of https://phabricator.memgraph.io/source/experimental
Merge branch 'master' of https://phabricator.memgraph.io/source/experimental
Refactored connectors into Reactors
Use shared pointer for the mutex.
Rename to Open and Close in implementation file.
Rename Create to Open and Destroy to Close.
Merge branch 'master' of https://phabricator.memgraph.io/source/experimental
Adding callback to Reactors; work in progress
Add stubs for asynchronous channel resolution.
Add stubs for the networking service.
Replace reactor pointers with shared ptrs, disable System assignment.
Forbid assignment.
Replace raw channel pointers with shared pointers.
Replace raw event stream pointer with shared pointer.
Rename default stream name.
Use recursive mutex in System.
Main uses Spawn method. All files are formatted.
Move thread local to a cpp file.
Work in progress on Spawn method.
Merge branch 'master' of https://phabricator.memgraph.io/source/experimental
Kill out graph.hpp to make it compile
Add Spawn method prototype.
Fix return type.
Merge branch 'master' of https://phabricator.memgraph.io/source/experimental
Add method used to create nameless channels.
Add format script.
Introduce the Reactor base class.
Merge branch 'master' of https://phabricator.memgraph.io/source/experimental
Add compile script.
added comments about class terminology
Spinner rewrite (graph data structures and algo)
Organize Spinner code
Create working version
Improves Spinner implementation and testing
Spinner fix
.arcconfig
Merge branch 'master' of https://phabricator.memgraph.io/source/experimental
Add graph
Spinner work
Spinner added
Merge branch 'master' of https://phabricator.memgraph.io/source/experimental
Add communication
.clang-format + ycm config.
Init. Distributed hackaton.
Implementation of lock-free list from Petar Sirkovic.
pro compiler
Merge branch 'master' of https://phabricator.memgraph.io/source/experimental
Implement Match
Add test data.
Insert quotes before and after props and labels
Multiple node declarations, along with edges.
After merge.
Node property creations work now.
Bug fix in visitor
After merge.
Implement node creation with labels.
Implement boolean operators
Tidy up ImplementedVistor.
Implement expression6 (addition)
Implement basic type visitor functions
Cypher Visitor Implementation class created.
Fix style.
Fix template synrax in main.cpp
Merge remote-tracking branch 'origin/master'
Add pretty_print
Update main and BaseVisitor to present return value.
Headers included. Temporary fix.
Antlr4 module reintroduced.
Updateao git config.
Fix trailing space.
CMake 2.8 fix rerolled, 3.1 minimum version req.
Fix for Cmake version 2.8 compatibility.
Build works.
Tidy src folder. Include generated files for antlr.
Included antlr generated files.
Changed directory structure.
Cmake: include subdirectory.
GenerateRuntime, partial.
Add GenerateParser target to cmake.
Remove main.cpp
Merge remote-tracking branch 'origin/master'
Add requirements
Main file added. Run the lexer and parser with this.
Add antlr_generated to baby_compiler
Experimental memory_tracker and opencypher tck tests

Reviewers: mislav.bradac

Reviewed By: mislav.bradac

Subscribers: pullbot

Differential Revision: https://phabricator.memgraph.io/D627
2017-08-03 12:48:19 +02:00
Mislav Bradac
515bc35911 Add dependency to memgraph_link_target
Reviewers: mferencevic

Reviewed By: mferencevic

Differential Revision: https://phabricator.memgraph.io/D604
2017-07-29 22:23:50 +02:00
Mislav Bradac
ddbb63a601 More apollo harness integration
Reviewers: mferencevic

Reviewed By: mferencevic

Subscribers: pullbot

Differential Revision: https://phabricator.memgraph.io/D603
2017-07-29 21:58:10 +02:00
Mislav Bradac
32ed2d7ab8 Remove unnecessary integratino tests
Reviewers: buda

Reviewed By: buda

Subscribers: pullbot

Differential Revision: https://phabricator.memgraph.io/D566
2017-07-18 15:52:37 +02:00
Mislav Bradac
6068a95a0e Move dbms to database
Summary:
There was only two files in dbms directory so I moved them to database
directory.

Reviewers: buda

Reviewed By: buda

Subscribers: pullbot

Differential Revision: https://phabricator.memgraph.io/D540
2017-07-12 12:44:11 +02:00
Mislav Bradac
d14accad07 Migrate harness to memgraph
Reviewers: buda

Reviewed By: buda

Subscribers: pullbot

Differential Revision: https://phabricator.memgraph.io/D532
2017-07-10 19:07:32 +02:00
Mislav Bradac
99fffc23f7 Change FILE COPY to configure_file COPYONLY
Summary:
FILE COPY copies files only in configuration stage, configure_file
copies files in make stage if file has changed.

Reviewers: buda, teon.banek

Reviewed By: teon.banek

Subscribers: pullbot

Differential Revision: https://phabricator.memgraph.io/D531
2017-07-10 16:26:30 +02:00
Mislav Bradac
cbe6648eb8 Migrate command line args to gflgs in tests
Summary: Some other minor cleanups

Reviewers: buda

Reviewed By: buda

Subscribers: pullbot

Differential Revision: https://phabricator.memgraph.io/D523
2017-07-06 13:54:12 +02:00
matej.gradicek
818ac3b731 Added rapidcheck
Reviewers: buda, teon.banek

Reviewed By: buda, teon.banek

Subscribers: lion, pullbot

Differential Revision: https://phabricator.memgraph.io/D509
2017-06-30 16:26:21 +02:00
Teon Banek
20769404d8 Cleanup includes in CMakeLists
Summary:
Don't include `${CMAKE_BINARY_DIR}/include` since it is not needed and
would only slow down compilation.

Also removed `include_directories` for `fmt`, since it is built using
`add_subdirectory`. (The `add_subdirectory` also does the include.)

Use `add_custom_target` for calling `recursive_include` instead of
`custom command`. This allows specifying that `recursive_include`
depends on `plan_template_cpp`.

Reviewers: mislav.bradac, buda

Reviewed By: mislav.bradac, buda

Subscribers: pullbot

Differential Revision: https://phabricator.memgraph.io/D511
2017-06-27 11:55:13 +02:00
Dominik Gleich
e2f3aba332 Use GLogger instead of broken memgraph Logger.
Summary:
http://rpg.ifi.uzh.ch/docs/glog.html

Second phase before tests complete.

Delete logging test.

Finish relase loging.

Reviewers: mislav.bradac, teon.banek, buda

Reviewed By: teon.banek

Subscribers: buda, pullbot

Differential Revision: https://phabricator.memgraph.io/D500
2017-06-21 15:33:24 +02:00
Teon Banek
bed62c4f8b Setup building with glog library
Summary:
To use the library in code, do the following.

  * Include glog, `include "glog/logging.h"`
  * Initialize logging from a main entry point,
    `google::InitGoogleLogging(argv[0]);`
  * Log anywhere from your code, `LOG(INFO) << "Hello world from glog";`

For advanced use, refer to glog's documentation.

Reviewers: mislav.bradac, florijan, dgleich, buda

Reviewed By: mislav.bradac, buda

Subscribers: pullbot

Differential Revision: https://phabricator.memgraph.io/D492
2017-06-20 09:38:57 +02:00
Mislav Bradac
6403599a5d Generate plan_compiler_flags only if needed
Reviewers: teon.banek, buda

Reviewed By: teon.banek

Subscribers: pullbot

Differential Revision: https://phabricator.memgraph.io/D485
2017-06-16 15:58:32 +02:00
Marko Budiselic
9ed4102897 Release preparation.
Summary: Alpha config fix. Docker volume support.

Reviewers: teon.banek, dgleich

Reviewed By: teon.banek, dgleich

Subscribers: pullbot, buda

Differential Revision: https://phabricator.memgraph.io/D484
2017-06-16 15:16:11 +02:00
Teon Banek
d0016ab98c Add simple logging to a file
Reviewers: buda

Reviewed By: buda

Subscribers: pullbot

Differential Revision: https://phabricator.memgraph.io/D476
2017-06-16 10:19:37 +02:00
Mislav Bradac
67b859cf13 Add AST cache
Reviewers: buda, teon.banek, florijan

Reviewed By: buda

Subscribers: pullbot

Differential Revision: https://phabricator.memgraph.io/D468
2017-06-14 18:59:31 +02:00
Mislav Bradac
c56eb4310e Remember token positions for literals
Summary: Remove yaml

Reviewers: buda

Reviewed By: buda

Subscribers: pullbot

Differential Revision: https://phabricator.memgraph.io/D466
2017-06-13 17:11:27 +02:00
Mislav Bradac
f7d540829a Add deep clone to Ast
Summary: Prepare your aspergillums for blessing this magnificent diff.

Reviewers: buda, teon.banek, florijan

Reviewed By: teon.banek

Subscribers: lion, pullbot

Differential Revision: https://phabricator.memgraph.io/D458
2017-06-13 12:22:25 +02:00
florijan
afbb940a05 GC bugfixes, MVCC and transaction refactoring
Summary:
- GC changed to evaluate old records w.r.t. the oldest transaction's id AND snapshot, as opposed to only id
- MVCC hints exp+aborted race condition prevented
- minor MVCC refactors and cleanups
- minor Transaction refactors and cleanups

Reviewers: buda, dgleich

Reviewed By: buda, dgleich

Subscribers: dtomicevic, pullbot

Differential Revision: https://phabricator.memgraph.io/D434
2017-06-12 10:46:12 +02:00
Teon Banek
2a7a117720 Remove some unused stuff from CMakeLists
Reviewers: buda

Reviewed By: buda

Subscribers: pullbot

Differential Revision: https://phabricator.memgraph.io/D443
2017-06-08 16:30:21 +02:00
Teon Banek
04a5bdeb82 Remove unused config source code files
Reviewers: dgleich, buda

Reviewed By: buda

Subscribers: pullbot

Differential Revision: https://phabricator.memgraph.io/D442
2017-06-08 16:10:55 +02:00
Teon Banek
7091be1891 Don't pass MEMGRAPH_ALL_LIBS to all cmake targets
Summary:
CMake is smart enough to transitively detect dependencies and link them
appropriately. Therefore, it is enough that we put all libraries that
memgraph uses to the dependency list of memgraph_lib and memgraph_pic
targets.

Patch the fmt library for C++14 and higher

fmt library would detect that C++11 is supported and then put the
compiler flag. This flag was set so it overrides parent project compiler
flags. This override from fmt would prevent us from using C++14
features. New version (3.1) of fmt resolves this issue, but it hasn't
been released yet. Therefore, this commit updates the script which
clones fmt to use the released 3.0.1 version and apply the fix on that.

Reviewers: dgleich, buda

Reviewed By: buda

Subscribers: pullbot

Differential Revision: https://phabricator.memgraph.io/D441
2017-06-08 14:14:01 +02:00
Mislav Bradac
fea9031605 Refactor stripper
Summary: Fix tests

Reviewers: buda, florijan, teon.banek

Reviewed By: buda

Subscribers: pullbot

Differential Revision: https://phabricator.memgraph.io/D435
2017-06-07 18:47:09 +02:00
Dominik Gleich
65507da9eb Load configs from flagfiles.
Summary: Migrate configto gflags.

Reviewers: buda

Reviewed By: buda

Subscribers: pullbot

Differential Revision: https://phabricator.memgraph.io/D433
2017-06-07 15:38:17 +02:00
Dominik Gleich
ebdee4e509 Skiplist garbage collector rework.
Summary:
Drawing:
https://drive.google.com/open?id=0B-W7PQZqMD9hcG04b0lKaGZGOWM

Reviewers: mislav.bradac, buda, florijan

Reviewed By: buda

Subscribers: pullbot

Differential Revision: https://phabricator.memgraph.io/D395
2017-06-07 10:47:02 +02:00
matej.gradicek
15b57e2d52 Implemented recovery and tests.
Summary: Implemented durability recovery and tesats.

Reviewers: mislav.bradac, dgleich, buda

Reviewed By: mislav.bradac, dgleich, buda

Subscribers: dtomicevic, mferencevic, pullbot

Differential Revision: https://phabricator.memgraph.io/D374
2017-06-06 15:12:34 +00:00
Teon Banek
666f8e1a93 Add tuning debug builds for debugger
Summary:
A new variable has been added to CMakeLists -- `PREFERRED_DEBUGGER`.
Here, you can specify which debugger you are using, so that the compiler
produces tuned debug builds for that debugger. Currently only 'gdb' and
'lldb' are supported, since we  use 'gcc' and 'clang' compilers.
Unsupported combination of `PREFERRED_DEBUGGER` and used compiler is
displayed as a warning, and the build uses default debug flags.

Reviewers: florijan, mislav.bradac, dgleich, buda

Reviewed By: buda

Subscribers: pullbot

Differential Revision: https://phabricator.memgraph.io/D426
2017-06-06 09:31:35 +02:00
florijan
509d5db67a Query - plan - cost estimator basic. REPL mods
Reviewers: teon.banek, buda, mislav.bradac

Reviewed By: teon.banek, buda

Subscribers: pullbot, teon.banek

Differential Revision: https://phabricator.memgraph.io/D399
2017-06-02 12:44:17 +02:00
Teon Banek
f0422c0e11 Generate multiple plans depending on starting node
Summary:
Permute query parts.

Permute matching only by selecting the starting node.

Flip the expansion when expanding from the other node.

Split planner into rule_based_planner and variable_start_planner

Use symbol hash when collecting expansion nodes

Multiple node atoms may point to the same symbol, and we could generate
multiple starting positions per atom which are the same. Using symbol
hash and equality prevents generating those redundant plans.

Correctly permute optional and merge matchings

Test VariableStartPlanner

Reviewers: florijan, mislav.bradac, buda, lion

Reviewed By: florijan, buda

Subscribers: pullbot

Differential Revision: https://phabricator.memgraph.io/D417
2017-06-01 16:38:21 +02:00
Dominik Gleich
a2d3577f0f Add google flags in preparation for deleting old logger.
Summary: Implement gflags and add optional port.

Reviewers: buda, teon.banek

Reviewed By: buda

Subscribers: pullbot

Differential Revision: https://phabricator.memgraph.io/D391
2017-05-25 09:45:48 +02:00
matej.gradicek
e791e9b660 Summary:Added files for snapshot durability
Summary:
File buffer added

Implemented little more of snapshoter.

Resolved conflicts

More stuff implemented of snapshot durability.

More things in snapshoter.

Refactored, added comments

Merge branch 'dev' into durability_snapshot

Merge branch 'dev' into durability_snapshot

Resolved bug in scheduler, snapshoter is running in grpah_db.

Reviewers: mferencevic, buda, dgleich, mislav.bradac

Reviewed By: mferencevic, buda, dgleich, mislav.bradac

Subscribers: pullbot

Differential Revision: https://phabricator.memgraph.io/D232
2017-05-17 08:42:00 +00:00
Mislav Bradac
78af8c8339 Add variable with all memgraph dependent libraries
Reviewers: teon.banek, buda

Reviewed By: buda

Subscribers: pullbot

Differential Revision: https://phabricator.memgraph.io/D324
2017-04-27 18:40:34 +02:00
Mislav Bradac
5434e79ea6 Merge string utils to one file
Reviewers: buda

Reviewed By: buda

Subscribers: pullbot

Differential Revision: https://phabricator.memgraph.io/D281
2017-04-18 17:39:58 +02:00
Matej Ferencevic
f05fcd91c3 Refactored bolt session to use new decoder.
Summary:
Bolt buffer is now a template.

Communication worker now has a new interface.

Fixed network tests to use new interface.

Fixed bolt tests to use new interface.

Added more functions to bolt decoder.

Reviewers: dgleich, buda

Reviewed By: buda

Subscribers: pullbot

Differential Revision: https://phabricator.memgraph.io/D256
2017-04-15 16:35:09 +02:00
Teon Banek
3b27b20992 Reorganize query directory tree
Summary:
Move query/frontend/interpret to query/interpret.
Split interpret.hpp to frame.hpp and eval.hpp.
Move query/frontend/logical to query/plan.
Nest namespace frontend::opencypher inside query.

Reviewers: florijan, mislav.bradac, buda

Reviewed By: florijan

Subscribers: pullbot

Differential Revision: https://phabricator.memgraph.io/D272
2017-04-13 11:28:11 +02:00
Mislav Bradac
36129cdcae Implement simple function conversion
Reviewers: buda

Reviewed By: buda

Subscribers: florijan, teon.banek

Differential Revision: https://phabricator.memgraph.io/D264
2017-04-11 19:14:08 +02:00
Teon Banek
804d0b09b9 Move typed_value to query top level and namespace it
Summary:
Upgraded old uses of TypedValue.
Also, implemented operator<< for EdgeAccessor and VertexAccessor.

Reviewers: buda, florijan, mislav.bradac, mferencevic

Reviewed By: florijan

Subscribers: pullbot

Differential Revision: https://phabricator.memgraph.io/D251
2017-04-11 08:50:46 +02:00
florijan
d3692d439c Query::Plan::Operator - split into hpp and cpp
Reviewers: teon.banek

Reviewed By: teon.banek

Subscribers: pullbot

Differential Revision: https://phabricator.memgraph.io/D204
2017-03-30 13:48:16 +02:00
Teon Banek
35668d5b9f Make GNU Readline dependency optional
Reviewers: florijan, buda

Reviewed By: buda

Subscribers: pullbot

Differential Revision: https://phabricator.memgraph.io/D171
2017-03-24 12:42:45 +01:00
Teon Banek
c2c34336c3 Split symbol_generator.hpp to .cpp
Reviewers: florijan, mislav.bradac

Reviewed By: florijan

Subscribers: pullbot

Differential Revision: https://phabricator.memgraph.io/D172
2017-03-24 12:07:42 +01:00
Marko Budiselic
66d56820ac Cleanup of poc/. Only CMakeLists is left because it is reasonable to have a proof of concept folder.
Summary: Cleanup of poc/.

Reviewers: dgleich, mislav.bradac

Reviewed By: mislav.bradac

Subscribers: pullbot, buda

Differential Revision: https://phabricator.memgraph.io/D166
2017-03-23 18:10:37 +01:00
florijan
f304dfef28 Query Console implemented
Summary: buda, teon.banek, mislav.bradac

Reviewers: mislav.bradac, buda, teon.banek

Reviewed By: buda

Subscribers: pullbot

Differential Revision: https://phabricator.memgraph.io/D163
2017-03-23 15:51:25 +01:00
Marko Budiselic
3b42cd2579 Everything is merged (communication + query engine) but we have to fix the PULL_ALL issue. 2017-03-22 17:57:06 +01:00
florijan
b236694fd2 Query - entry.hpp renamed to interpreter.hpp, Engine renamed to Interpreter
Summary: Query - interpreter console hack

Reviewers: buda, teon.banek, mislav.bradac

Reviewed By: buda

Subscribers: pullbot

Differential Revision: https://phabricator.memgraph.io/D157
2017-03-22 16:39:00 +01:00
Matej Ferencevic
3bf0bd40a7 Initial version of new bolt encoder.
Reviewers: dgleich, buda

Reviewed By: buda

Subscribers: pullbot

Differential Revision: https://phabricator.memgraph.io/D104
2017-03-22 16:13:47 +01:00
Teon Banek
bed9324da9 Use SYSTEM when including various library directories
Reviewers: buda

Reviewed By: buda

Subscribers: pullbot

Differential Revision: https://phabricator.memgraph.io/D144
2017-03-17 17:33:05 +01:00
Teon Banek
baa644e9b7 Support creating NodeFilter and CreateOp logical operators
Reviewers: mislav.bradac, buda, florijan

Subscribers: pullbot

Differential Revision: https://phabricator.memgraph.io/D133
2017-03-16 10:06:01 +01:00
Teon Banek
c638955758 Remove ast.cpp from CMakeLists.txt 2017-03-13 16:06:37 +01:00
Marko Budiselic
3e0b12f646 Merge branch 'compiler_prototype' into dev 2017-03-13 13:35:23 +01:00
Mislav Bradac
026e0e6fbd Implement ast generation by cypher visitor 2017-03-11 23:22:38 +01:00
Teon Banek
fbf70de089 Add type checker which fills symbols for Ident 2017-03-11 18:04:48 +01:00
Teon Banek
ef764e0367 Add ProduceCursor and Evaluate to expression 2017-03-11 14:39:13 +01:00
Teon Banek
333861e7e9 Generate flags for PlanCompiler via cmake
Summary:
Add join function to functions.cmake

This is a convenience function which will join a list of values by
replacing ';' with the given separator.

cmake: Add fetching compile flags in gcc format

This is a utility function which takes all target compilation flags that
can be passed to gcc or clang.

Generate flags for PlanCompiler via cmake

Cmake will now collect all compiler options and definitions which are
then stored in a generated `query/plan_compiler.hpp`. The generated file
is not tracked by git and is stored inside cmake's build directory. The
file is fast to generate and may change often depending on the build
type.

Additionally, link and include directories are also generated as
absolute paths. In the future, we may want to support relative paths so
that copying/installing the build dir creates runnable binaries.

Add -Wall flag for all build types

Lowercase #pragma once in tests for network_common

It seems 'once' may be case sensitive, since clang outputs a warning for
it that the pragma is unknown.

Reviewers: buda

Reviewed By: buda

Subscribers: pullbot

Differential Revision: https://phabricator.memgraph.io/D107
2017-03-10 18:21:31 +01:00
Teon Banek
9dada557a3 Add coverage option to cmake
Summary:
Coverage is by default set to OFF, but the new option can be used for convenient
toggle when building.

Reviewers: buda

Reviewed By: buda

Subscribers: pullbot

Differential Revision: https://phabricator.memgraph.io/D109
2017-03-10 18:05:15 +01:00
Dominik Gleich
09dbe2e722 Include stderr so logger output can be surpressed during tests.
Reviewers: buda

Reviewed By: buda

Subscribers: pullbot

Differential Revision: https://phabricator.memgraph.io/D102
2017-03-09 10:09:58 +01:00
florijan
971e006d13 Query stripping now uses a parse tree and differentiates between int literals in a range expression (not stripped) and outside of a range (stripped).
Summary: See above

Reviewers: buda, mislav.bradac

Reviewed By: mislav.bradac

Subscribers: pullbot

Differential Revision: https://phabricator.memgraph.io/D98
2017-03-08 14:19:55 +01:00
Teon Banek
47ed127086 Generate openCypher parser sources if missing
Summary:
Makes cmake aware that parser source files are generated, so that it can
know how to set the dependencies for the underlying build tool. When the
files do not exist, invoking e.g. `make` will also run antlr to generate
them. Files will be regenerated only if their dependency changed
(Cypher.g4 file in this case).

Reviewers: buda, florijan

Reviewed By: buda

Subscribers: pullbot

Differential Revision: https://phabricator.memgraph.io/D94
2017-03-08 09:31:21 +01:00
Marko Budiselic
b834cdc94a memgraph coverage (lcov setup in progress...)
Summary: first version of coverage (will be polished)

Reviewers: dgleich, mferencevic, florijan, teon.banek

Reviewed By: dgleich

Subscribers: pullbot, buda

Differential Revision: https://phabricator.memgraph.io/D76
2017-03-07 18:27:03 +01:00
Dominik Gleich
8e1a897b7a Fix query integration test because of config. Fix hardcoded queries not working because of include bug.
Summary:
#1 Hardcoded query integration test was failling because the .so files couldn't be linked, because of wrong compiled directory path (missing config flag).
#2 Hardcoded query not working in production because typed_value changed so some includes didn't work.

Reviewers: florijan, buda

Reviewed By: buda

Subscribers: pullbot

Differential Revision: https://phabricator.memgraph.io/D90
2017-03-07 12:37:30 +01:00
Teon Banek
e94969000a Block in-source builds and add clean_all target
Summary:
Add detecting and blocking in-source builds

A simple cmake function, which detects if the source and build dir are
one and the same. This unfortunately does not catch the case when the
build dir is inside the source dir, since we actually want to support
that. For example, creating a 'build' directory inside the project
source directory should be allowed.

Add a clean_all custom target in cmake

This target will clean all the files inside the build directory. It
should be used with care!

A new cmake module is created, since invoking cmake -E remove_directory
will delete the directory and we want to keep it. This way, we also
avoid using platform specific shell command, i.e `rm -rf` and we can
make clean_all smarter in the future.

Untrack build/.gitignore from git

Reviewers: buda

Reviewed By: buda

Subscribers: pullbot

Differential Revision: https://phabricator.memgraph.io/D92
2017-03-07 10:00:47 +01:00
Dominik Gleich
57f1b40d8d Refactor transaction inside db_accessor. Also introduce advance_command.
Summary:
Modification to MVCC - CHECK!

Refactor transaction_read

Add automatic commit/abort functionality to graph_db_accessor.

Fix failing test in graph_db_accessor.

Reviewers: buda, dtomicevic, florijan

Reviewed By: buda, florijan

Subscribers: pullbot

Differential Revision: https://phabricator.memgraph.io/D87
2017-03-07 09:42:04 +01:00
Matej Ferencevic
813a3b9eed Started network refactorization.
Summary:
Moved server and worker from bolt to communication. Started
templatization.

Started removal of Bolt class.

Removed unnecessary files from network.

Converted states to template functions.

Bolt::Session is now a template.

Merge remote-tracking branch 'origin/dev' into mg_refactor_network

Merged bolt_serializer.cpp into hpp.

Removed obsolete include.

Initial version of bolt session unit test.

Uncommented leftover log commands.

Reimplemented io::Socket.

Added client-stress.sh script.

Reviewers: dgleich, buda

Reviewed By: dgleich, buda

Subscribers: pullbot, mferencevic, buda

Differential Revision: https://phabricator.memgraph.io/D64
2017-03-06 13:52:34 +01:00
florijan
2aeef25881 Traversal namespace specialization added for real DB primitives
Summary: database/GraphDbAccessor and storage/...Accessor now returns iterators over lazily created Accessors (filtered on visibility). Dependecies and forward declarations reorganized to support new code

Reviewers: buda, teon.banek

Reviewed By: buda

Subscribers: pullbot

Differential Revision: https://phabricator.memgraph.io/D83
2017-03-03 14:01:01 +01:00
Mislav Bradac
ccdffa1d7e Refactor TypedValue to PropertyValue
Summary:
Rename TypedValue to PropertyValue.
Move original TypedValue to query/backend/cpp.
Fix undefined behaviours and memory leaks in PropertyValue.
Add list type to PropertyValue.
Operators and appropriate tests will be revised in following commits.

Fix bugs in TypedValue

Fix bugs in typed value

Reviewers: buda, florijan

Reviewed By: buda

Subscribers: pullbot

Differential Revision: https://phabricator.memgraph.io/D77
2017-03-01 12:31:47 +01:00
Marko Budiselic
082465ff15 For each hardcoded query plan there is a build target -> that will improve Memgraph's testability + update of release script (release/alpha.sh)
Summary: For each hardcoded query plan there is a build target -> that will improve Memgraph's testability + update of release script (release/alpha.sh)

Reviewers: florijan, mislav.bradac, mferencevic, dgleich

Reviewed By: dgleich

Subscribers: pullbot, buda

Differential Revision: https://phabricator.memgraph.io/D75
2017-02-28 19:00:59 +01:00
Marko Budiselic
a32b2831e5 copy hardcoded queries
Summary: copy hardcoded queries

Reviewers: dgleich, mislav.bradac, florijan, mferencevic

Reviewed By: dgleich

Subscribers: buda

Differential Revision: https://phabricator.memgraph.io/D74
2017-02-27 18:26:51 +01:00
Dominik Gleich
82414b9111 Fix naming of asserts.runtime_assert & assert -> debug_assert
Summary:
Merge branch 'dev' into rename_assert

Fix new files.

Remove cassert.

Reviewers: buda

Reviewed By: buda

Subscribers: pullbot

Differential Revision: https://phabricator.memgraph.io/D66
2017-02-24 11:41:55 +01:00
Mislav Bradac
ca90f813ad Start implementing compiler structures
Summary:
Merge remote-tracking branch 'origin/dev' into mg_compiler_structs

Merge remote-tracking branch 'origin/dev' into mg_compiler_structs

Implement compiler structures and tests

Reviewers: florijan, buda

Reviewed By: buda

Subscribers: pullbot, florijan, buda

Differential Revision: https://phabricator.memgraph.io/D61
2017-02-23 18:12:24 +01:00
Dominik Gleich
c8ef12910d Add Ccache.
Summary:
Adding ccache option improves each additional build time by a big factor.
Example of performance, modification to a header file:
src/io/network/socket.hpp

without ccache:
	real    0m26.950s
	user    1m18.636s
	sys     0m6.160s
with ccache:
	real    0m10.644s
	user    0m30.616s
	sys     0m4.548s

Reviewers: buda

Reviewed By: buda

Subscribers: pullbot

Differential Revision: https://phabricator.memgraph.io/D63
2017-02-23 16:53:04 +01:00
Marko Budiselic
ede318c2dd Memgraph gmock support has been added
Summary: Memgraph gmock support has been added

Reviewers: mislav.bradac

Reviewed By: mislav.bradac

Subscribers: buda

Differential Revision: https://phabricator.memgraph.io/D59
2017-02-22 16:38:23 +01:00
Marko Budiselic
d1842571d6 Cpp17 support has been added
Summary: Cpp17 support has been added

Reviewers: mferencevic, dgleich, mislav.bradac, florijan

Reviewed By: mislav.bradac

Subscribers: pullbot, buda

Differential Revision: https://phabricator.memgraph.io/D57
2017-02-22 14:28:37 +01:00
Marko Budiselic
4583d8bde3 antlropencypher + youcompleteme update
Summary: antlropencypher + youcompleteme update

Test Plan: manual

Reviewers: mislav.bradac

Reviewed By: mislav.bradac

Subscribers: pullbot, mislav.bradac, buda

Differential Revision: https://phabricator.memgraph.io/D52
2017-02-20 14:06:25 +01:00
florijan
68f57fa47d CMakeLists cleanup w.r.t. Antlr linking. Removed the unused typed_value_store.cpp
Summary: See above.

Test Plan: Building tested.

Reviewers: buda

Reviewed By: buda

Subscribers: pullbot, buda

Differential Revision: https://phabricator.memgraph.io/D50
2017-02-20 09:43:58 +01:00
Marko Budiselic
fb90394499 A better configuration of cmake & clion 2017-02-20 01:25:57 +01:00
Marko Budiselic
2a046bba78 all unit tests are gtests 2017-02-19 23:47:09 +01:00
Marko Budiselic
3642fb1312 examples folder has been removed; src/test folder has been removed; the existing tests were moved to tests folder; StacktraceException has been introduced; query_plan_templated has been moved to query folder; hazard pointers have been deleted because they are not used any more 2017-02-18 18:03:48 +01:00
Marko Budiselic
e7f5bd4c21 antlr integration, *.hpp and *.cpp inside src dir, cleanup
Summary: antlr integration, *.hpp and *.cpp inside src dir, cleanup

Test Plan: manual

Reviewers: mislav.bradac, dgleich, florijan

Reviewed By: florijan

Subscribers: pullbot, buda

Differential Revision: https://phabricator.memgraph.io/D49
2017-02-17 16:20:31 +01:00
florijan
55f1912910 Properties refactoring: STABLE STATE. Memgraph compiles. Properties are out. Tests are in progress. 2017-02-16 15:47:55 +01:00
florijan
70a8b93b0b Major properties system and database accessor refactor: first stable state (compiles). 2017-02-15 14:10:16 +01:00
florijan
9e09186d30 Properties refactor in progress. Dev merge (query execution landed). UNSTABLE STATE 2017-02-14 10:17:03 +01:00
Marko Budiselic
0fcda94162 Hardcoded query infrastructure - first concrete version - USEFUL FOR: POCs & pilots
Summary: Hardcoded query infrastructure - first concrete version - USEFUL FOR: POCs & pilots

Test Plan: manual + jenkins

Reviewers: sale, florijan

Reviewed By: florijan

Subscribers: pullbot, buda

Differential Revision: https://phabricator.memgraph.io/D45
2017-02-14 09:40:31 +01:00
Florijan Stamenkovic
b38704391c Typed-value migration in progress. UNSTABLE STATE 2017-02-06 12:40:55 +01:00
Florijan Stamenkovic
b374ae1dbb storage and database major refactor in progress, also switching from properties to typed-value system. a lot of overdesigned functionalities cut down, new implementations just started. VERY UNSTABLE STATE 2017-02-04 09:01:56 +01:00
Florijan Stamenkovic
10c7514c8a storage/model - added typed_value system and tests. Modified utils slightly (backward compatible).
Summary: Added TypedValue system.

Test Plan: ???

Reviewers: sale, buda

Reviewed By: buda

Subscribers: pullbot, florijan, buda, sale

Differential Revision: https://phabricator.memgraph.io/D46
2017-02-02 15:48:16 +01:00
Florijan Stamenkovic
b329225322 storage/model - added typed_value system and tests. Modified utils slightly (backward compatible).
Summary: Added TypedValue system.

Test Plan: ???

Reviewers: sale, buda

Subscribers: florijan, buda, sale

Differential Revision: https://phabricator.memgraph.io/D46
2017-02-01 14:05:08 +01:00
Marko Budiselic
057af7ac14 Much more serious implementation of FSWatcher
Summary: Much more serious implementation of FSWatcher

Test Plan: ctest -R fswatcher

Reviewers: dtomicevic, sale

Subscribers: buda

Differential Revision: https://phabricator.memgraph.io/D33
2017-01-08 01:07:12 +01:00
Marko Budiselic
948694fd27 tests data bug fix - too many copies of tests/data 2016-12-18 10:16:07 +01:00
Marko Budiselic
f4455daeb2 CMake refactor done - added single test granularity. Fixes T190, T194 2016-12-17 21:00:32 +01:00
Marko Budiselic
d158333335 Added memgraph prefix. Fixes T160
Summary: Added memgraph prefix. Fixes T160

Test Plan: manual

Reviewers: sale

Subscribers: sale, buda

Maniphest Tasks: T160

Differential Revision: https://memgraph.phacility.com/D18
2016-12-16 14:05:29 +01:00
Marko Budiselic
0a0e5e93da src/demo was removed, src/examples and src/benchmarks were moved to the top level 2016-12-04 10:20:14 +01:00
Marko Budiselic
aedcb1c244 Linter setup. Fixes T154
Summary: Linter setup. Fixes T154

Test Plan: manual

Reviewers: sale

Subscribers: buda, sale

Maniphest Tasks: T154

Differential Revision: https://memgraph.phacility.com/D13
2016-12-02 13:49:07 +01:00
Marko Budiselic
21788d003a Dressipi CRUD queries are dummy implemented; Fixes T99 and T131
Summary: Dressipi CRUD queries are dummy implemented; Fixes T99 and T131

Test Plan: manual

Reviewers: sale

Subscribers: buda, sale

Maniphest Tasks: T131, T99

Differential Revision: https://memgraph.phacility.com/D9
2016-11-29 04:08:49 +01:00
Marko Budiselic
e1e345ccbb google benchmark support 2016-11-18 17:35:29 +01:00
Marko Budiselic
afc0a4a176 better architecture for hardcoded test queries (still has to be polished) 2016-11-17 15:46:36 +01:00
Marko Budiselic
8362b64e9f DRESSIPI FIRST PILOT RELEASE (release script update) 2016-11-04 12:05:35 +01:00
Marko Budiselic
d45121a1a2 scenario 000001 pass, dressipi scenario 1 - 3 more queries have to be implemented 2016-11-02 16:05:02 +01:00
Marko Budiselic
6cce530b6c barrier ifdefs (TODO: barrier should be removed) 2016-10-13 15:42:19 +02:00
Marko Budiselic
f5cf9c72d2 skiplist benchmark 2016-10-04 15:09:21 +02:00
Marko Budiselic
34c8adbcb9 small changes in POC's main functions 2016-09-25 19:01:46 +01:00
Marko Budiselic
a0438392df dressipi hard coded query 2016-09-25 12:51:58 +01:00
Kruno Tomola Fabro
2a59ed8906 Minor refactorings:
Importes now use logger.

Refactored order of constrution of objects in Db.

Moved index creation/removing from Db to Indexes.

Completed Garbage class.
Cleaner now calls garbage.clean() for databases.

Renamed List to ConcurrentList which better names it.
2016-09-12 20:13:04 +01:00
Kruno Tomola Fabro
443d0e0098 Changed TransactionId to TransactionRead. 2016-09-09 20:56:53 +01:00
Kruno Tomola Fabro
cf497dd522 Extracted from snapshoter => snapshot_engine. 2016-09-09 18:48:15 +01:00
Kruno Tomola Fabro
911eeff1d9 Snapshot store and load works. 2016-09-09 16:14:20 +01:00
Kruno Tomola Fabro
4443cb8b7b Finished creating part of snapshot. 2016-09-08 13:25:52 +01:00
Kruno Tomola Fabro
cfc807cc03 Merge branch 'T87' of https://phabricator.tomicevic.com/diffusion/MG/memgraph into property 2016-09-05 15:56:57 +01:00
Kruno Tomola Fabro
5d235b51f3 tmp commit
tmp commit

tmp commit v2

Finished reimplementation of propertys.
They now can be placed in a holder with different source of type information.

Tmp commit
2016-09-05 10:02:48 +01:00
Marko Budiselic
8e5dbd4703 config is better now (yaml-cpp) + web::Client + web::Logger 2016-09-05 01:39:30 +01:00
Marko Budiselic
0f7be340fa Merge branch 'dev' of https://phabricator.tomicevic.com/diffusion/MG/memgraph into dev 2016-08-30 06:16:30 +01:00
Kruno Tomola Fabro
027dce0d9a Commint which extracts iterator_base methods to hpp. 2016-08-30 06:16:04 +01:00
Marko Budiselic
5dcba58d2b Merge branch 'dev' of https://phabricator.tomicevic.com/diffusion/MG/memgraph into dev 2016-08-30 05:34:16 +01:00
Marko Budiselic
32ca896425 merge with dev 2016-08-30 05:34:08 +01:00
Kruno Tomola Fabro
ff07babeba Commmit for buda. 2016-08-30 05:29:30 +01:00
Marko Budiselic
be820ce915 tmp commit, work in progress, relationship create 2016-08-30 01:01:03 +01:00
Kruno Tomola Fabro
b2ce3d58a4 Added cleaner.
Added multithreading to dbms.
Skiplist now supports emplace insert.
2016-08-30 00:45:07 +01:00
Marko Budiselic
12880ba990 work in progress engine <-> barrier integration 2016-08-29 01:01:42 +01:00
Kruno Tomola Fabro
6a4e2d8d64 Final barrier commit. 2016-08-28 21:10:13 +01:00
Kruno Tomola Fabro
e908d6588b Tidied up barrier files.
MEMGRAPH has linked/definistion errors during compile.
2016-08-28 20:46:30 +01:00
Kruno Tomola Fabro
8ace2927c9 poc/profile.cpp works over barrier.hpp 2016-08-28 19:36:52 +01:00
Kruno Tomola Fabro
77a3298d1e tmp 2016-08-28 15:47:13 +01:00
Kruno Tomola Fabro
9304c2945b Merge branch 'index' into dev 2016-08-25 15:37:53 +01:00
Kruno Tomola Fabro
8a89f6601d EdgeType indexes added.
Implemented untested UniqueOrderedIndex.

Introduced TypeGroupEdge/Vertex into database.

Added Index capabilityes to PropertyFamily.
Added method for adding index.
Added method for removing index.
2016-08-25 15:29:45 +01:00
Kruno Tomola Fabro
23c9ae2026 Fixed benchmark bug in profile. 2016-08-25 11:39:25 +01:00
Kruno Tomola Fabro
85dbf1bd86 Extracted import tool for csv to file with CSVImporter.
Astar now uses csv import tool.
2016-08-23 10:58:55 +01:00
Kruno Tomola Fabro
fbd9ca8420 First version of CSVImport tool.
Query and import works.

Properties now use unordered_map.
Reduced memory footprint of properties by more than half.
2016-08-22 19:03:45 +01:00
Kruno Tomola Fabro
eba7fd8be4 Fixed Query compiler to use new interface. 2016-08-19 18:40:04 +01:00
Marko Budiselic
e5f161974f merged T70 2016-08-19 11:29:15 +01:00
Marko Budiselic
427a7bbe4b merged interface branch 2016-08-19 11:28:10 +01:00
Marko Budiselic
e22cb3aee4 review fixes + T70 2016-08-19 01:28:37 +01:00
Marko Budiselic
9bb0b8983d LOG error fixed + BOLT queries + Fixes T70 2016-08-18 17:48:13 +01:00
Kruno Tomola Fabro
5a42e15c4a Alpha version of label indexes.
Squashed messages from 9 commits:

9.
Properties now uses PropertyFamily and contained classes.
Fetching,seting,clearing properties can be done with PropertyFamilyKey or PropertyTypeKey.
Hierarchy of newly added clases is:
Vertices -n-> PropertyFamily {name: String} <-1-n-> PropertyType {type: Property::Flags}
Edges -n-> PropertyFamily {name: String} <-1-n-> PropertyType {type: Property::Flags}

PropertyFamilyKey -> PropertyType
PropertyTypeKey -> PropertyType

PropertyType t0,t1;
let t0!=t1 be true
let t0.family==t1.family be true

then next is true
PropertyTypeKey{&t0}!=PropertyTypeKey{&t1}
PropertyFamilyKey{&t0}==PropertyFamilyKey{&t1}
PropertyFamilyKey{&t0}==PropertyTypeKey{&t1}
PropertyTypeKey{&t0}==PropertyFamilyKey{&t1}

8.
Intermedate commit.
Noticed that integration queries throw SEGFAULT.

7.
Defined interface for indexes.
Fixed three memory leaks.
Fixed integration_queries test which now passes.

6.
Commit which return Xorshift128plus to valid shape.

5.
Tmp commit.

4.
Label Index is compiling.

3.
tmp

2.
Vertex::Accessor now updates Label index.

1.
Applied changes for code review.
2016-08-18 15:34:36 +01:00
Marko Budiselic
e1cca548ba alpha release script + bolt serialization works (nodes and edges) 2016-08-15 15:10:30 +01:00
Kruno Tomola Fabro
df0bf6fa5f Database interface refactor.
DbAccessor:
 -Guarantees that access to Vertex and Edge is possible only through
 Vertex::Accessor and Edge::Accessor.
 -Guarantees that changing Vertex and Edge is possible only using
 Vertex::Accessor returned by vertex_insert() method and
 Edge::Accessor returned by edge_insert() method.
 -Offers CRUD for Vertex and Edge except iterating over all edges.

Squashed commit messages:

First step in database accessor refactoring done.
It's compiling.
All tests with exception of integration_querys pass

Tests now initialize logging facilities.

Refactored accessors.
RecordAccessor now has 3 states.
From,To,Out,In in there respecive Accessors return unfilled RecordAccessor.
Added iterator classes into utils/itearator/.
2016-08-15 00:09:58 +01:00
Marko Budiselic
a9419b559d Small fixes not done yet, first the whole DB interface has to be finished 2016-08-14 13:45:47 +01:00
Kruno Tomola Fabro
1849514159 First step in database accessor refactoring done.
It's compiling.
All tests with exception of integration_querys pass
2016-08-12 23:01:39 +01:00
Marko Budiselic
93b174afd7 First integration almost done. BOLT still doesn't work as expected, problem is only serialization order. 2016-08-11 04:47:30 +01:00
Marko Budiselic
869da8dcda All files for the Release are now isolated 2016-08-10 09:39:02 +01:00
Marko Budiselic
84e69bb1d3 fmt wrapper + proof of concept folder 2016-08-08 09:32:34 +01:00
Marko Budiselic
d04cf101b4 Cypher CRUD support is becomes bigger and bigger. Implemented: create relationship, match relationship and update relationship 2016-07-31 18:58:12 +01:00
Marko Budiselic
c8440b4671 tests/manual/query_engine.cpp work in compiler in progress 2016-07-11 02:39:33 +01:00
Marko Budiselic
84db4b6657 cypher parser update 2016-07-09 19:05:02 +01:00
Marko Budiselic
b538fb041c first integration test (basic set of queries is tested) 2016-07-07 01:58:26 +01:00
Marko Budiselic
a8a1ce9f0a edge type store 2016-07-06 17:37:05 +01:00
Marko Budiselic
2b1fc70695 some header files are splitted (WORK IN PROGRESS) 2016-07-05 13:20:33 +01:00
Marko Budiselic
b94cae12d1 some new header + source files (vertices, vertex_accessor, properties), first version of Index works, skiplist<T> + concurrent_set + concurrent_map (still has to be finished) 2016-07-05 04:01:22 +01:00
Marko Budiselic
18e7394d9e basic queries are manually implemented inside src/query_engine/main_queries 2016-07-03 01:02:42 +01:00
Marko Budiselic
5110cde698 query engine code, labels (unfinished), TODO: query engine module system 2016-07-01 22:05:03 +01:00
Marko Budiselic
1d1242af50 query_engine executable file 2016-06-26 23:43:28 +01:00