https://github.com/darkleaf/pg-nosql
https://github.com/darkleaf/pg-nosql
Last synced: 7 months ago
JSON representation
- Host: GitHub
- URL: https://github.com/darkleaf/pg-nosql
- Owner: darkleaf
- Archived: true
- Created: 2016-01-29T11:09:11.000Z (about 10 years ago)
- Default Branch: master
- Last Pushed: 2016-01-29T13:10:28.000Z (about 10 years ago)
- Last Synced: 2025-03-21T15:23:53.966Z (11 months ago)
- Size: 1000 Bytes
- Stars: 0
- Watchers: 2
- Forks: 0
- Open Issues: 0
-
Metadata Files:
- Readme: README.md
Awesome Lists containing this project
README
# pg-nosql
Основа - http://jsonapi.org/format/
```
#Базовая табличка
id: int
data: jsonb
mixins: array[string]
type: strign??
#Доступные функции
upsert???
find_TYPE
find_MIXIN
wrap_TYPE(row): json
getId
удалять ничего нельзя
#Схема data
{
id: int,
type: string,
attributes: {},
relationships: {},
meta: {}
}
mixin: {
validate(data),
beforeUpsert(data, diff), #добавить блокировки
upsert(data, diff),
filter(obj): req_builder
reduce(obj, row): obj # добавляет в итоговый объект необозимые данные
}
#вопросы
1. full_text highlight
2. counter_cache
```