https://github.com/sinri/koladb
Simple Information Storage Service.
https://github.com/sinri/koladb
Last synced: 8 months ago
JSON representation
Simple Information Storage Service.
- Host: GitHub
- URL: https://github.com/sinri/koladb
- Owner: sinri
- License: gpl-3.0
- Created: 2018-06-16T09:47:56.000Z (almost 8 years ago)
- Default Branch: master
- Last Pushed: 2018-06-19T12:12:38.000Z (almost 8 years ago)
- Last Synced: 2025-10-13T19:39:23.626Z (8 months ago)
- Language: PHP
- Size: 67.4 KB
- Stars: 0
- Watchers: 1
- Forks: 0
- Open Issues: 0
-
Metadata Files:
- Readme: README.md
- License: LICENSE
Awesome Lists containing this project
README
# KolaDB


Simple Information Storage Service.
https://sinri.github.io/KolaDB/index.html
> composer require sinri/kola-db
## Structure
A simple three level object storage structure and simple key-value properties within objects.
```
Cluster::DIR {
Collection::DIR {
Object::JSON_FILE {
field1:value1,
field2:value2
}
}
}
```
## Action
Action grammar is used to communicate with the server to do certain action.
### Action for Drop
```json
{
"action":"drop",
"cluster":"CLUSTER_NAME",
"collection":"COLLECTION_NAME",
"object":"OBJECT_NAME"
}
```
Fields `collection` and `object` are optional.
### Action for Edit
```json
{
"action":"edit",
"cluster":"CLUSTER_NAME",
"collection":"COLLECTION_NAME",
"object":"OBJECT_NAME",
"data":{
"KEY":"VALUE"
}
}
```
### Action for Rename
```json
{
"action":"rename",
"cluster":"CLUSTER_NAME",
"collection":"COLLECTION_NAME",
"object":"OBJECT_NAME",
"change":"NEW_NAME"
}
```
Fields `collection` and `object` are optional.
### Action for Query
```json
{
"action":"query",
"cluster":"CLUSTER_NAME",
"collection":"COLLECTION_NAME",
"query":[
{
"method":"EQUAL",
"field":"FIELD_NAME",
"reference":"REFERENCE"
},
{
"method":"AND",
"queries":[
{
"method":"EQUAL",
"field":"FIELD_NAME",
"reference":"REFERENCE"
},
{
"method":"EQUAL",
"field":"FIELD_NAME",
"reference":"REFERENCE"
}
]
}
]
}
```
### Action for List
```json
{
"action":"list",
"cluster":"CLUSTER_NAME",
"collection":"COLLECTION_NAME"
}
```
Field `collection` is optional.