A distributed graph database engine that stores users' graph-like data with a supported query language.
View Demo · Report Bug · Request Feature
Nowadays, in our data-driven world, various industries and domains are recognizing the immense value of graph databases. Social Networks, Recommendation Systems, and Bio-informatics are examples of such domains that could benefit from using a graph database to store and process their intricate and interconnected data. Unlike traditional SQL(tabular) databases, graph databases provide flexible semantics that aligns with busi- ness models in addition to eliminating the unnecessary overhead associated with SQL databases when querying complex and interconnected data. In addition, the increasing amount of data needed to be stored requires graph database systems to be distributed across multiple server
GraphoPlex consists of a client (an interactive shell in Python) and a cluster (multiple servers that run the same code and were implemented in Java). The client could be connected to any server in the cluster through an HTTP connection to send user queries. Inter-cluster communication is done through gRPC.
- Python 3.6 or higher
- Java 17 or higher
- Maven 3.6.3 or higher
- Docker
- Redis
- Clone the repository
git clone https://github.com/ShimaaBetah/GraphoPlex.git && cd GraphoPlex
- Build the Server
cd graph_db && mvn install
- Run the Server (this will only run 1 server on default 8080 port)
mvn spring-boot:run
- Run the client
python3 client.py
-
Start writing commands
see section 3.2.2 in the thesis for more details about the supported commands.
The previous steps will only run 1 server on default 8080 port, to run a cluster of servers, you need to run the following commands.
-
Setup app properties
open the file
graph_db/src/main/resources/application.properties
and change the following propertiesserver.numOfServers= ${number of servers you want in the cluster} grpc.servers.ports= ${grpc ports of the servers in the cluster separated by comma} grpc.servers.hosts= ${ip address of the servers in the cluster separated by comma}
-
Build the server code
cd graph_db && mvn install
-
Build Docker Image
docker build -t graphdb-server .
-
Run Docker Container
docker run --network="host" -e SERVER_ID=${server_id} -e REDIS_PORT=${redis_port} -e SERVER_PORT=${http_port} -e GRPC_SERVER_PORT=${grpc_port} graphdb-server
this should be done for each server replacing all environment variables by actual values for each server in the cluster. Note that if
server.numOfServers
inapplication.properties
isn
then SERVER_ID should be between0
andn-1
.Also GRPC_SERVER_PORT should be the element with index of (SERVER_ID) in the array of
grpc.servers.ports
in theapplication.properties
file . -
Run the client
python3 client.py
make sure that the
url
in client.py is belongs to one of the servers in the cluster -
Start writing commands as before
The project is NOT in active development. However, the following ideas are things that would be looked up next:
- Parallel implementation for Dijkstra and DFS
- Result Set visualization
- Partitioning Strategy Enhancement
- Result Set Visualization
- Authentication and support for multiple users
Contributions are what make the open source community such an amazing place to learn, inspire, and create. Any contributions you make are greatly appreciated.
If you have a suggestion that would make this better, please fork the repo and create a pull request. You can also simply open an issue with the tag "enhancement". Don't forget to give the project a star! Thanks again!
- Fork the Project
- Create your Feature Branch (
git checkout -b feature/AmazingFeature
) - Commit your Changes (
git commit -m 'Add some AmazingFeature'
) - Push to the Branch (
git push origin feature/AmazingFeature
) - Open a Pull Request
Distributed under the GNU General Public License v3.0. See LICENSE.txt
for more information.
Elshimaa Betah - shimaabetah1911@gmail.com