外观
lib-proj 库参考
原文: https://finproducts.atlassian.net/wiki/spaces/JIDD3/pages/34793226355/FIN+5.3.1+lib-proj 中文整理基于 FIN 5.3.1
导读: 项目管理模块
以下为 API 参考,保留英文以便对照源码;目录已列出(英文标题便于检索);概述已尽量中译。
目录(导读)
- lib
- meta
- tags
- funcs
- views
- def
- folioBackup()
- folioBackupCleanup(dateOrAge)
- folioBackupDelete(ts)
- folioBackups()
- folioEmptyTrash()
- projRebuild(opts: {})
概述(中译)
项目管理模块
API 正文(英文)
tags
| readRouteStatus | Project cluster route status for reads |
| routeStatus | Project cluster route status |
funcs
| folioBackup | Asynchronously kick off a new backup for current project |
| folioBackupCleanup | Delete all backups older than the given duration or date |
| folioBackupDelete | Delete a backup file by its timestamp |
| folioBackups | List all the backups for the current project |
| folioEmptyTrash | Delete all the records marked with trash tag |
| projRebuild | Rebuild the current project in-place |
views
| projs | View and manage the projects visible to the current node |
def
func:folioBackup
folioBackup()
Asynchronously kick off a new backup for current project. Requires admin permission. See Proj.backup To run a snapshot a background job use jobFolioBackup(). Return a future to track completion of the backup. The future's result value is subject to change.
meta
| admin | ✓ |
| confirm | |
| def | func:folioBackup |
| disKey | ui::backup |
| is | func |
| lib | lib:proj |
| name | folioBackup |
supertypes
| feature | Feature namespace of definitions formatted as feature:name |
| func | Axon function |
def
func:folioBackupCleanup
folioBackupCleanup(dateOrAge)
Delete all backups older than the given duration or date. Requires admin permission.
Examples:
folioBackupCleanup(15day) // delete all backups older than 15 days
folioBackupCleanup(2017-11-15) // delete all backups before given datemeta
| admin | ✓ |
| def | func:folioBackupCleanup |
| is | func |
| lib | lib:proj |
| name | folioBackupCleanup |
supertypes
| feature | Feature namespace of definitions formatted as feature:name |
| func | Axon function |
def
func:folioBackupDelete
folioBackupDelete(ts)
Delete a backup file by its timestamp. Return true if backup found and deleted or false otherwise. Requires admin permission.
meta
| admin | ✓ |
| confirm | |
| def | func:folioBackupDelete |
| disKey | ui::delete |
| is | func |
| lib | lib:proj |
| multi | ✓ |
| name | folioBackupDelete |
| select | ✓ |
supertypes
| feature | Feature namespace of definitions formatted as feature:name |
| func | Axon function |
def
func:folioBackups
folioBackups()
List all the backups for the current project:
- ts: timestamp of backup
- size: size in bytes of backup
meta
| admin | ✓ |
| def | func:folioBackups |
| is | func |
| lib | lib:proj |
| name | folioBackups |
supertypes
| feature | Feature namespace of definitions formatted as feature:name |
| func | Axon function |
def
func:folioEmptyTrash
folioEmptyTrash()
Delete all the records marked with trash tag. See Proj.emptyTrash
meta
| admin | ✓ |
| def | func:folioEmptyTrash |
| is | func |
| lib | lib:proj |
| name | folioEmptyTrash |
supertypes
| feature | Feature namespace of definitions formatted as feature:name |
| func | Axon function |
def
func:projRebuild
projRebuild(opts: {})
Rebuild the current project in-place. This operation will shutdown the project, then rebuild it by copying all recs and re-writing all history. It supports the following options:
- hisPageSize: (Duration) - the hisPageSize to use when re-writing the history. If not specified, the current hisPageSize is used.
Returns a Future that will be completed when the rebuild is finished. This operation could take a long time for large databases.
meta
| def | func:projRebuild |
| is | func |
| lib | lib:proj |
| name | projRebuild |
| su | ✓ |
supertypes
| feature | Feature namespace of definitions formatted as feature:name |
| func | Axon function |
def
readRouteStatus
Project cluster route status for reads
meta
| def | readRouteStatus |
| enum | See below |
| is | routeStatus |
| lib | lib:proj |
| transient | ✓ |
enum
| ok | All is okay |
| fault | Configuration problem |
| down | Communication or network problem |
supertypes
| val | Data value type |
| scalar | Scalar is an atomic value kind |
| str | Unicode string of characters |
| routeStatus | Project cluster route status |
def
routeStatus
Project cluster route status
meta
| def | routeStatus |
| enum | See below |
| is | str |
| lib | lib:proj |
| transient | ✓ |
enum
| ok | All is okay |
| fault | Configuration problem |
| down | Communication or network problem |
supertypes
| val | Data value type |
| scalar | Scalar is an atomic value kind |
| str | Unicode string of characters |
subtypes
| readRouteStatus | Project cluster route status for reads |
def
view:projs
View and manage the projects visible to the current node
meta
| appName | host |
| def | view:projs |
| disKey | ui::projs |
| icon | view |
| is | view |
| lib | lib:proj |
| order | 100 |
| su | ✓ |
supertypes
| feature | Feature namespace of definitions formatted as feature:name |
| view | Fresco UI view |
src
view: {inherit:"table"}
new: {action:"projNew"}
demogen: {disKey:"ui::demogen" action:"uiMisc::ProjDemogen.open" }
rename: {action:"projRename"}
delete: {action:"projDelete"}
details: {action:"projDetails"}
backup: {action:"projBackup"}
replicate: {action:"projReplicate"}
data: {expr:"projs()"}