libdinemic
API for scalable applications based on P2P networks and cryptography

Distributed database

All data is stored across whole cluster - every update made by app launched with Dinemic is immediately shared with all other nodes

Cryptographic auth system

No additional, centralized auth system is needed. Libdinemic gives all tools necessary to authenticate your apps across clusters.

Every object in database has its own cryptographic keys - this makes every change securly authenticated by advanced cryptography algorithms.

Event driven applications

Don't wait for events - just define your own actions for database updates.

This approach makes easy way to create applications and services across multiple cluster nodes. Together with cryptographic API it makes great way to use libdinemic as communication channel

Keep it simple!

...because there are microservices, ha proxies, redundant networks, containers and many more. But what if you just want to create scalable application without taking care about infrastructure?

 

libdinemic is easy to use library for creating clusters of applications. It provides access to distributed database, security, cryptography and many more!

Libdinemic bases on blockchain technology, together with asymmetric cryptography and event driven development paradigm. With this library you can build scallable, distributed applications, without any centralized point of infrastructure. Libdinemic is designed in fully decentralized and redundant architecture, to create software defined redundancy at application level, but without sophistication level known from Etereum or Blockchain.


github.com

With simple ORM provided by libdinemic you can store any data in distributed database. Each node creates its own copy of this database, which is continuously updated by all nodes

Split brain after network failure? Databases will be synchronized as soon as it is possible. All nodes in separated partition will go on with synchronization until networking is back.

All branches of DB versions are available. After rejoin all nodes could decide about shape of its local database. This approach makes easier management of resources in cluster

#include <libdinemic/dmodel.h>

DModel person("Person", store, sync, vector<string>());

person.set("first_name", "John");
person.set("last_name", "Travolta");
person.set("date_of_birth", "1970-01-01 01:01");
...
cout << person.get("last_name") << endl;

You can define triggers to be executed on any change in database - field, object or data model.

Every change in database is propagated as update across whole cluster. Every incomming to your application update could trigger your unique action. This mechanism could be used to drive your application or as communication channel between many applications.

Libdinemic gives assurance about the genuineness of each update. Triggering mechanism gives information about each change - the order in chain, digital signature and detached state. You can check all those properties in flags of each action.

#include <libdinemic/daction.h>

...

class MyListener: public DAction {
    void on_update(DModel *parent,
                   const DActionFlags &flags,
                   DHeaders &headers,
                   const string &key,
                   const string &old_value,
                   const string &new_value) {
        if (flags.is_verified()) {
            cout << "Yes! This person updated info!" << endl;
            // Do something...
        } else {
            cout << "Nope, false alarm" << endl;
        }
    }
};

MyListener listener;

sync->add_on_create_listener("Person:*", &listener);
No need for additional communication channel

Each application using libdinemic could inherit basic application class, to create application skeleton.

This is easy, intuitive class defining all necessary actions related to your new application. With DApp you will be able to define all tasks related to first setup of your application, each launch and finally, deregistration from cluster.

#include <neon/dapp.h>
...

class MyApp : public DApp
{
    ...

public:
    MyApp(int argc, char **argv);
    void create();
    void launch();
    void remove();
};
#include <myapp.h>

int main(int argc, char **argv) {
    MyApp app(argc, argv);
    app.exec();
    return 0;
}