= Kyoto Cabinet based graph = Kyoto Cabinet is a fast, lightweight storage DBRM. This graph is created on top of this data storage engine. This kind of graph consists of a minimal implementation in C, while the rest of the graph remained in Erlang. ''Note that Kyoto Cabinet based graph can only be used under Linux or under OS X.'' == Using the Kyoto Cabinet based graph == Linux / OS X: {{{ $: bin/referl -db kcmini }}} {{{ #!comment Windows: {{{ c:\> bin\referl -db kcmini }}} }}} It is important to know that if the database is not closed properly, it will be corrupted. For this reason it is recommended to make backups of the database after loading the source code: {{{ erl> ri:backup("My first backup"). {ok,"backup.1"} }}} Other backup related functions: {{{ erl> ri:ls_backups(). ["backup.1"] erl> ri:backup_info(1). Informations about 'backup.1': Commit-log: My first backup Time of creation: 2012-10-01 11:02:37 ok erl> ri:restore(1). ok }}} Deleting all backups: {{{ erl> ri:clean(). ok erl> ri:ls_backups(). [] }}} == Default Parameters == With starting the database as written above, it will use some default parameters for setting up Kyoto Cabinet. == Tuning the database == It is also possible to customize the kyoto cabinet storage. For this, use the following command to start the tool: {{{ $: bin/referl -dbmod refdb_kyotomini -dbargs "[{dbtype, 'DbType'}, {param1, Val1}, ...]" }}} For the name and possible value of the parameters, please refer to the kyoto cabinet documentation at [http://fallabs.com/kyotocabinet/api/kclangc_8h.html#a464237fa818e4b70b15526a898b5c5f5 Kyoto Cabinet / kclangc.h / kcdbopen()]. == Good to know == It is possible to create multiple graphs within the same tool instance {{{ erl> ri:ls_graphs(). [default] erl> ri:create_graph(my_graph). [default,my_graph] erl> ri:actual_graph(). default erl> ri:load_graph(my_graph). ok erl> ri:ri:actual_graph(). my_graph erl> ri:load_graph(default). ok erl> ri:delete_graph(my_graph). ok erl> ri:ls_graphs(). [default] }}}