diff --git a/docs-2.0/1.introduction/1.what-is-nebula-graph.md b/docs-2.0/1.introduction/1.what-is-nebula-graph.md index e9fd4024f9..e664f77401 100644 --- a/docs-2.0/1.introduction/1.what-is-nebula-graph.md +++ b/docs-2.0/1.introduction/1.what-is-nebula-graph.md @@ -30,7 +30,7 @@ Nebula Graph 采用 shared-nothing 架构,支持在不停止数据库服务的 ### 易开发 -Nebula Graph 提供 Java、Python、C++和 Go 等流行编程语言的客户端,更多客户端仍在开发中。详情请参见 [Nebula Graph clients](../14.client/1.nebula-client.md)。 +Nebula Graph 提供 Java、Python、C++ 和 Go 等流行编程语言的客户端,更多客户端仍在开发中。详情请参见 [Nebula Graph clients](../14.client/1.nebula-client.md)。 ### 高可靠访问控制 diff --git a/docs-2.0/1.introduction/2.1.path.md b/docs-2.0/1.introduction/2.1.path.md index a222bf8cc4..f1b808f002 100644 --- a/docs-2.0/1.introduction/2.1.path.md +++ b/docs-2.0/1.introduction/2.1.path.md @@ -50,6 +50,6 @@ 用户也可以观看视频了解路径的相关概念。 -[Nebula Algorithm](https://www.bilibili.com/video/BV1Uf4y1t72L)(03 分 09 秒) +[Path](https://www.bilibili.com/video/BV1Uf4y1t72L)(03 分 09 秒) diff --git a/docs-2.0/1.introduction/2.data-model.md b/docs-2.0/1.introduction/2.data-model.md index 2318359cac..f016e925aa 100644 --- a/docs-2.0/1.introduction/2.data-model.md +++ b/docs-2.0/1.introduction/2.data-model.md @@ -27,9 +27,15 @@ Nebula Graph 数据模型使用 6 种基本的数据模型: - 两点之间可以有多条边。 - 边是有方向的,不存在无向边。 - - 四元组 `<起点 VID、Edge type、边排序值 (Rank)、终点 VID>` 用于唯一标识一条边。边没有 EID。 + - 四元组 `<起点 VID、Edge type、边排序值 (rank)、终点 VID>` 用于唯一标识一条边。边没有 EID。 - 一条边有且仅有一个 Edge type。 - - 一条边有且仅有一个 rank。其为 int64,默认为 0。 + - 一条边有且仅有一个 rank,类型为 int64,默认值为 0。 + + !!! 关于 rank + + rank 可以用来区分 Edge type、起始点、目的点都相同的边。该值完全由用户自己指定。 + 读取时必须自行取得全部的 rank 值后排序过滤和拼接。 + 不支持诸如 `next(), pre(), head(), tail(), max(), min(), lessThan(), moreThan()` 等函数功能,也不能通过创建索引加速访问或者条件过滤。 - 标签(Tag) diff --git a/docs-2.0/1.introduction/3.nebula-graph-architecture/4.storage-service.md b/docs-2.0/1.introduction/3.nebula-graph-architecture/4.storage-service.md index 06f7faed24..8793fae60f 100644 --- a/docs-2.0/1.introduction/3.nebula-graph-architecture/4.storage-service.md +++ b/docs-2.0/1.introduction/3.nebula-graph-architecture/4.storage-service.md @@ -26,7 +26,7 @@ Storage 服务是由 nebula-storaged 进程提供的,用户可以根据场景 - Storage interface 层 - Storage 服务的最上层,定义了一系列和图相关的 API。API 请求会在这一层被翻译成一组针对[分片](#数据分片)的 KV 操作,例如: + Storage 服务的最上层,定义了一系列和图相关的 API。API 请求会在这一层被翻译成一组针对[分片](#_4)的 KV 操作,例如: - `getNeighbors`:查询一批点的出边或者入边,返回边以及对应的属性,并且支持条件过滤。 @@ -70,6 +70,7 @@ Nebula Graph 使用自行开发的 KVStore,而不是其他开源 KVStore,原 - 支持多个图空间,不同图空间相互隔离,每个图空间可以设置自己的分片数和副本数。 + ### 属性说明 Nebula Graph 使用强类型 Schema。 @@ -122,6 +123,7 @@ Nebula Graph 使用强类型 Schema。 ![data partitioning](https://www-cdn.nebula-graph.com.cn/nebula-blog/DataModel02.png) + ### 分片算法 分片策略采用**静态 Hash **的方式,即对点 VID 进行取模操作,同一个点的所有 Tag、出边和入边信息都会存储到同一个分片,这种方式极大地提升了查询效率。 @@ -266,6 +268,7 @@ Storage 服务基于 Raft 协议实现的分布式架构,与 HDFS 的分布式 总而言之,Storage 服务更加轻量级,精简了一些功能,架构没有 HDFS 复杂,可以有效提高小块存储的读写性能。 + diff --git a/docs-2.0/1.introduction/3.vid.md b/docs-2.0/1.introduction/3.vid.md index 0e3934455a..ce159b2ae2 100644 --- a/docs-2.0/1.introduction/3.vid.md +++ b/docs-2.0/1.introduction/3.vid.md @@ -22,7 +22,7 @@ ## VID 使用建议 -- Nebula Graph 1.x 只支持 VID 类型为`INT64`,2.x 支持`INT64`和`FIXED_STRING()`。在`CREATE SPACE`中通过参数`vid_type`可以指定 VID 类型。 +- Nebula Graph 1.x 只支持 VID 类型为`INT64`,从 2.x 开始支持`INT64`和`FIXED_STRING()`。在`CREATE SPACE`中通过参数`vid_type`可以指定 VID 类型。 - 可以使用`id()`函数,指定或引用该点的 VID; diff --git a/docs-2.0/14.client/1.nebula-client.md b/docs-2.0/14.client/1.nebula-client.md index ced474b359..9e7fee2f93 100644 --- a/docs-2.0/14.client/1.nebula-client.md +++ b/docs-2.0/14.client/1.nebula-client.md @@ -14,4 +14,4 @@ Nebula Graph 提供多种类型客户端,便于用户连接、管理 Nebula Gr !!! note - 除 Nebula Java 之外,其他客户端暂不支持线程安全(thread-safe)。 + 客户端暂不支持线程安全(thread-safe)。 diff --git a/docs-2.0/14.client/3.nebula-cpp-client.md b/docs-2.0/14.client/3.nebula-cpp-client.md index 651b112b2e..dacaeb3350 100644 --- a/docs-2.0/14.client/3.nebula-cpp-client.md +++ b/docs-2.0/14.client/3.nebula-cpp-client.md @@ -13,8 +13,9 @@ |Nebula Graph 版本|Nebula CPP 版本| |:---|:---| |{{ nebula.release }}|{{cpp.release}}| -|2.0.1|2.0.0| -|2.0.0|2.0.0| +|2.6.x|2.5.0| +|2.5.x|2.5.0| +|2.0.x|2.0.0| ## 安装 Nebula CPP @@ -23,7 +24,7 @@ - (推荐)如果需要安装指定版本的 Nebula CPP,请使用选项`--branch`指定分支。例如安装 v{{ cpp.release }}发布版本,请执行如下命令: ```bash - $ git clone --branch v{{ cpp.release }} https://github.com/vesoft-inc/nebula-cpp.git + $ git clone --branch {{cpp.branch}} https://github.com/vesoft-inc/nebula-cpp.git ``` - 如果需要安装日常开发版本,请执行如下命令下载`master`分支的源码: @@ -82,7 +83,7 @@ 将 CPP 文件编译为可执行文件即可。接下来以`SessionExample.cpp`为例,介绍如何操作。 -1. 使用[示例代码](https://github.com/vesoft-inc/nebula-cpp/blob/master/examples/SessionExample.cpp)创建`SessionExample.cpp`文件。 +1. 使用[示例代码](https://github.com/vesoft-inc/nebula-cpp/blob/{{cpp.branch}}/examples/SessionExample.cpp)创建`SessionExample.cpp`文件。 2. 编译文件,命令如下: @@ -102,22 +103,5 @@ ### 核心代码 -详细示例请参见 [SessionExample](https://github.com/vesoft-inc/nebula-cpp/blob/master/examples/SessionExample.cpp)。 - -```C++ -nebula::init(&argc, &argv); -auto address = "192.168.xx.1:9669"; -nebula::ConnectionPool pool; -pool.init({address}, nebula::Config{}); -auto session = pool.getSession("root", "nebula"); - -auto result = session.execute("SHOW HOSTS"); -std::cout << *result.data; - -std::atomic_bool complete{false}; -session.asyncExecute("SHOW HOSTS", [&complete](nebula::ExecutionResponse&& cbResult) { - std::cout << *cbResult.data; - complete.store(true); -}); -session.release(); -``` +详细示例请参见 [SessionExample](https://github.com/vesoft-inc/nebula-cpp/blob/{{cpp.branch}}/examples/SessionExample.cpp)。 + diff --git a/docs-2.0/14.client/4.nebula-java-client.md b/docs-2.0/14.client/4.nebula-java-client.md index 580e516c92..0b48c20728 100644 --- a/docs-2.0/14.client/4.nebula-java-client.md +++ b/docs-2.0/14.client/4.nebula-java-client.md @@ -11,8 +11,8 @@ |Nebula Graph 版本|Nebula Java 版本| |:---|:---| |{{ nebula.release }}|{{java.release}}| -|2.0.1|2.0.0| -|2.0.0|2.0.0| +|2.6.x|2.6.1| +|2.0.x|2.0.0| |2.0.0-rc1|2.0.0-rc1| ## 下载 Nebula Java @@ -20,7 +20,7 @@ - (推荐)如果需要使用指定版本的 Nebula Java,请使用选项`--branch`指定分支。例如使用 v{{ java.release }}发布版本,请执行如下命令: ```bash - $ git clone --branch v{{ java.release }} https://github.com/vesoft-inc/nebula-java.git + $ git clone --branch {{java.branch}} https://github.com/vesoft-inc/nebula-java.git ``` - 如果需要安装日常开发版本,请执行如下命令下载`master`分支的源码: @@ -39,13 +39,13 @@ !!! note - `2.0.0-SNAPSHOT`为日常研发版本,可能存在未知问题,建议使用 release 版本号替换`2.0.0-SNAPSHOT`。 + `3.0.0-SNAPSHOT`为日常研发版本,可能存在未知问题,建议使用 release 版本号替换`3.0.0-SNAPSHOT`。 ```bash com.vesoft client - 2.0.0-SNAPSHOT + 3.0.0-SNAPSHOT ``` @@ -64,49 +64,5 @@ ### 核心代码 -详细示例请参见 [GraphClientExample](https://github.com/vesoft-inc/nebula-java/blob/master/examples/src/main/java/com/vesoft/nebula/examples/GraphClientExample.java)。 - -```java -NebulaPool pool = new NebulaPool(); -Session session = null; -try { - NebulaPoolConfig nebulaPoolConfig = new NebulaPoolConfig(); - nebulaPoolConfig.setMaxConnSize(100); - List addresses = Arrays.asList(new HostAddress("192.168.xx.1", 9669), - new HostAddress("192.168.xx.2", 9670)); - pool.init(addresses, nebulaPoolConfig); - session = pool.getSession("root", "nebula", false); - - //create space - String space = "test"; - String createSpace = "CREATE SPACE IF NOT EXISTS " + space + " (partition_num=15, replica_factor=1, vid_type=fixed_string(30)); "; - ResultSet resp = session.execute(createSpace); - - //create schema - String createSchema = "USE " + space + "; CREATE TAG IF NOT EXISTS person(name string, age int);" - + "CREATE EDGE IF NOT EXISTS like(likeness double)"; - ResultSet resp = session.execute(createSchema); - - //insert vertex - String insertVertexes = "INSERT VERTEX person(name, age) VALUES " + "'Bob':('Bob', 10), " - + "'Lily':('Lily', 9), " + "'Tom':('Tom', 10), " + "'Jerry':('Jerry', 13), " - + "'John':('John', 11);"; - ResultSet resp = session.execute(insertVertexes); - - // inert edge - String insertEdges = "INSERT EDGE like(likeness) VALUES " + "'Bob'->'Lily':(80.0), " - + "'Bob'->'Tom':(70.0), " + "'Lily'->'Jerry':(84.0), " + "'Tom'->'Jerry':(68.3), " - + "'Bob'->'John':(97.2);"; - ResultSet resp = session.execute(insertEdges); - - // query - String query = "GO FROM \"Bob\" OVER like " + "YIELD properties($$).name, properties($$).age, properties(edge).likeness"; - ResultSet resp = session.execute(query); - printResult(resp); -}finally { - if (session != null) { - session.release(); - } - pool.close(); -} -``` +详细示例请参见 [GraphClientExample](https://github.com/vesoft-inc/nebula-java/blob/{{java.branch}}/examples/src/main/java/com/vesoft/nebula/examples/GraphClientExample.java)。 + diff --git a/docs-2.0/14.client/5.nebula-python-client.md b/docs-2.0/14.client/5.nebula-python-client.md index 264484a393..39cafeb3ff 100644 --- a/docs-2.0/14.client/5.nebula-python-client.md +++ b/docs-2.0/14.client/5.nebula-python-client.md @@ -4,15 +4,15 @@ ## 前提条件 -已安装 Python,版本为 3.5 及以上。 +已安装 Python,版本为 3.6 及以上。 ## 版本对照表 |Nebula Graph 版本|Nebula Python 版本| |:---|:---| |{{ nebula.release }}|{{python.release}}| -|2.0.1|2.0.0| -|2.0.0|2.0.0| +|2.6.x|2.6.0| +|2.0.x|2.0.0| |2.0.0-rc1|2.0.0rc1| ## 安装 Nebula Python @@ -20,7 +20,7 @@ ### pip 安装 ```bash -$ pip install nebula2-python== +$ pip install nebula3-python== ``` ### 克隆源码安装 @@ -30,7 +30,7 @@ $ pip install nebula2-python== - (推荐)如果需要安装指定版本的 Nebula Python,请使用选项`--branch`指定分支。例如安装 v{{ python.release }}发布版本,请执行如下命令: ```bash - $ git clone --branch v{{ python.release }} https://github.com/vesoft-inc/nebula-python.git + $ git clone --branch {{python.branch}} https://github.com/vesoft-inc/nebula-python.git ``` - 如果需要安装日常开发版本,请执行如下命令下载`master`分支的源码: @@ -53,66 +53,5 @@ $ pip install nebula2-python== ## 核心代码 -详细示例请参见 [Example](https://github.com/vesoft-inc/nebula-python/tree/master/example)。 +详细示例请参见 [Example](https://github.com/vesoft-inc/nebula-python/tree/{{python.branch}}/example)。 -### 连接 Graph 服务 - -```python -# 定义配置 -config = Config() -config.max_connection_pool_size = 10 -# 初始化连接池 -connection_pool = ConnectionPool() -# 如果给定的服务器正常,则返回 true,否则返回 false。 -ok = connection_pool.init([('192.168.xx.1', 9669)], config) - -# 方法 1:控制连接自行释放。 -# 从连接池中获取会话 -session = connection_pool.get_session('root', 'nebula') - -# 选择图空间 -session.execute('USE basketballplayer') - -# 执行查看 TAG 命令 -result = session.execute('SHOW TAGS') -print(result) - -# 释放会话 -session.release() - -# 方法 2:使用 session_context,会话将被自动释放。 -with connection_pool.session_context('root', 'nebula') as session: - session.execute('USE basketballplayer;') - result = session.execute('SHOW TAGS;') - print(result) - -# 关闭连接池 -connection_pool.close() -``` - -### 连接 Storage 服务 - -```python -# 设置所有 Meta 服务地址 -meta_cache = MetaCache([('192.168.xx.1', 9559), - ('192.168.xx.2', 9559), - ('192.168.xx.3', 9559)], - 50000) -graph_storage_client = GraphStorageClient(meta_cache) - -resp = graph_storage_client.scan_vertex( - space_name='ScanSpace', - tag_name='person') -while resp.has_next(): - result = resp.next() - for vertex_data in result: - print(vertex_data) - -resp = graph_storage_client.scan_edge( - space_name='ScanSpace', - edge_name='friend') -while resp.has_next(): - result = resp.next() - for edge_data in result: - print(edge_data) -``` \ No newline at end of file diff --git a/docs-2.0/14.client/6.nebula-go-client.md b/docs-2.0/14.client/6.nebula-go-client.md index 2da1e6c6d5..802f7417ad 100644 --- a/docs-2.0/14.client/6.nebula-go-client.md +++ b/docs-2.0/14.client/6.nebula-go-client.md @@ -11,15 +11,15 @@ |Nebula Graph 版本|Nebula Go 版本| |:---|:---| |{{ nebula.release }}|{{go.release}}| -|2.0.1|2.0.0-GA| -|2.0.0|2.0.0-GA| +|2.6.x|2.6.0| +|2.0.x|2.0.0-GA| ## 下载 Nebula Go - (推荐)如果需要下载指定版本的 Nebula Go,请使用选项`--branch`指定分支。例如安装 v{{ go.release }}发布版本,请执行如下命令: ```bash - $ git clone --branch v{{ go.release }} https://github.com/vesoft-inc/nebula-go.git + $ git clone --branch {{go.branch}} https://github.com/vesoft-inc/nebula-go.git ``` - 如果需要安装日常开发版本,请执行如下命令下载`master`分支的源码: @@ -36,43 +36,9 @@ $ go get -u -v github.com/vesoft-inc/nebula-go@ ``` -`tag`:指定分支。例如`master`或`v{{ go.release }}`。 +`tag`:指定分支。例如`master`或`{{go.branch}}`。 ## 核心代码 -详细示例请参见 [graph_client_basic_example](https://github.com/vesoft-inc/nebula-go/blob/master/basic_example/graph_client_basic_example.go) 和 [graph_client_goroutines_example](https://github.com/vesoft-inc/nebula-go/blob/master/gorountines_example/graph_client_goroutines_example.go)。 +详细示例请参见 [graph_client_basic_example](https://github.com/vesoft-inc/nebula-go/blob/{{go.branch}}/basic_example/graph_client_basic_example.go) 和 [graph_client_goroutines_example](https://github.com/vesoft-inc/nebula-go/blob/{{go.branch}}/gorountines_example/graph_client_goroutines_example.go)。 -```bash -const ( - address = "192.168.xx.1" - port = 9669 - username = "root" - password = "nebula" -) - -func main() { - hostAddress := nebula.HostAddress{Host: address, Port: port} - hostList := []nebula.HostAddress{hostAddress} - testPoolConfig := nebula.GetDefaultConf() - pool, err := nebula.NewConnectionPool(hostList, testPoolConfig, log) - defer pool.Close() - session, err := pool.GetSession(username, password) - defer session.Release() - - checkResultSet := func(prefix string, res *nebula.ResultSet) { - if !res.IsSucceed() { - log.Fatal(fmt.Sprintf("%s, ErrorCode: %v, ErrorMsg: %s", prefix, res.GetErrorCode(), res.GetErrorMsg())) - } - } - { - createSchema := "CREATE SPACE IF NOT EXISTS basic_example_space(vid_type=FIXED_STRING(20)); " + - "USE basic_example_space;" + - "CREATE TAG IF NOT EXISTS person(name string, age int);" + - "CREATE EDGE IF NOT EXISTS like(likeness double)" - resultSet, err := session.Execute(createSchema) - checkResultSet(createSchema, resultSet) - } - fmt.Print("\n") - log.Info("Nebula Go Client Basic Example Finished") -} -``` diff --git a/docs-2.0/15.contribution/how-to-contribute.md b/docs-2.0/15.contribution/how-to-contribute.md index d294da3b46..0753e625d6 100644 --- a/docs-2.0/15.contribution/how-to-contribute.md +++ b/docs-2.0/15.contribution/how-to-contribute.md @@ -28,11 +28,11 @@ Nebula Graph 文档以 Markdown 语言编写。单击文档标题右侧的铅笔 ### Step 1:通过 GitHub fork 仓库 -Nebula Graph 项目有很多[仓库](https://github.com/vesoft-inc),以 [nebula-graph 仓库](https://github.com/vesoft-inc/nebula)为例: +Nebula Graph 项目有很多[仓库](https://github.com/vesoft-inc),以 [nebula 仓库](https://github.com/vesoft-inc/nebula)为例: 1. 访问 [github.com/vesoft-inc/nebula](https://github.com/vesoft-inc/nebula)。 -2. 在右上角单击按钮`Fork`,然后单击用户名,即可 fork 出 nebula-graph 仓库。 +2. 在右上角单击按钮`Fork`,然后单击用户名,即可 fork 出 nebula 仓库。 ### Step 2:将分支克隆到本地 @@ -54,8 +54,8 @@ Nebula Graph 项目有很多[仓库](https://github.com/vesoft-inc),以 [nebul ```bash mkdir -p $working_dir cd $working_dir - git clone https://github.com/$user/nebula-graph.git - # 或:git clone git@github.com:$user/nebula-graph.git + git clone https://github.com/$user/nebula.git + # 或:git clone git@github.com:$user/nebula.git cd $working_dir/nebula git remote add upstream https://github.com/vesoft-inc/nebula.git @@ -66,8 +66,8 @@ Nebula Graph 项目有很多[仓库](https://github.com/vesoft-inc),以 [nebul # 确认远程分支有效。 # 正确的格式为: - # origin git@github.com:$(user)/nebula-graph.git (fetch) - # origin git@github.com:$(user)/nebula-graph.git (push) + # origin git@github.com:$(user)/nebula.git (fetch) + # origin git@github.com:$(user)/nebula.git (push) # upstream https://github.com/vesoft-inc/nebula (fetch) # upstream no_push (push) git remote -v @@ -80,14 +80,14 @@ Nebula Graph 项目有很多[仓库](https://github.com/vesoft-inc),以 [nebul hook 将检查 commit,包括格式、构建、文档生成等。 ```bash - cd $working_dir/nebula-graph/.git/hooks - ln -s $working_dir/nebula-graph/.linters/cpp/hooks/pre-commit.sh . + cd $working_dir/nebula/.git/hooks + ln -s $working_dir/nebula/.linters/cpp/hooks/pre-commit.sh . ``` pre-commit hook 有时候可能无法正常执行,用户必须手动执行。 ```bash - cd $working_dir/nebula-graph/.git/hooks + cd $working_dir/nebula/.git/hooks chmod +x pre-commit ``` @@ -177,7 +177,7 @@ git push origin myfeature ### Step 8:创建 pull request -1. 访问 fork 出的仓库`https://github.com/$user/nebula-graph` (替换此处的用户名`$user`)。 +1. 访问 fork 出的仓库`https://github.com/$user/nebula` (替换此处的用户名`$user`)。 2. 单击`myfeature`分支旁的按钮`Compare & pull request`。 diff --git a/docs-2.0/2.quick-start/1.quick-start-workflow.md b/docs-2.0/2.quick-start/1.quick-start-workflow.md index f4db47ee89..882f09d8f6 100644 --- a/docs-2.0/2.quick-start/1.quick-start-workflow.md +++ b/docs-2.0/2.quick-start/1.quick-start-workflow.md @@ -28,9 +28,12 @@ ### 热点视频 + + * [Foesa 小学姐课堂——Nebula Graph 那些磨人的概念](https://www.bilibili.com/video/BV1Q5411K7Gg)(04 分 20 秒) @@ -39,19 +42,24 @@ * [Foesa 小学姐课堂——path 的三种类型](https://www.bilibili.com/video/BV1Uf4y1t72L)(03 分 09 秒) + + ### NG 辅导班 diff --git a/docs-2.0/2.quick-start/4.nebula-graph-crud.md b/docs-2.0/2.quick-start/4.nebula-graph-crud.md index e72458bfad..7d1e953162 100644 --- a/docs-2.0/2.quick-start/4.nebula-graph-crud.md +++ b/docs-2.0/2.quick-start/4.nebula-graph-crud.md @@ -27,15 +27,26 @@ ## 管理 Nebula Graph 集群的 Storage 节点 -首先将 Storage 节点加入 Nebula Graph 集群。更多管理集群命令请参见 [管理逻辑机架(Zone)](../4.deployment-and-installation/5.zone.md)。 +首先将 Storage 节点加入 Nebula Graph 集群。 + + + !!! compatibility - 从 3.0 版本开始,在配置文件中添加的 Storage 节点无法直接读写,配置文件的作用仅仅是将 Storage 节点注册至 Meta 服务中。必须使用`ADD HOSTS`命令后,才能正常读写 Storage 节点。 + 从 3.0.0 版本开始,在配置文件中添加的 Storage 节点无法直接读写,配置文件的作用仅仅是将 Storage 节点注册至 Meta 服务中。必须使用`ADD HOSTS`命令后,才能正常读写 Storage 节点。 + +```ngql +ADD HOSTS : [,: ...]; +``` + 示例: @@ -51,14 +62,13 @@ Storage 服务加入集群后,可以执行命令`SHOW HOSTS`查看机器状态 ```ngql nebula> SHOW HOSTS; -+------------------+------+----------+--------------+----------------------+------------------------+ -| Host | Port | Status | Leader count | Leader distribution | Partition distribution | -+------------------+------+----------+--------------+----------------------+------------------------+ -| "192.168.10.100" | 9779 | "ONLINE" | 0 | "No valid partition" | "No valid partition" | -| "192.168.10.101" | 9779 | "ONLINE" | 0 | "No valid partition" | "No valid partition" | -| "192.168.10.102" | 9779 | "ONLINE" | 0 | "No valid partition" | "No valid partition" | -| "Total" | | | 0 | | | -+------------------+------+----------+--------------+----------------------+------------------------+ ++------------------+------+----------+--------------+----------------------+------------------------+---------+ +| Host | Port | Status | Leader count | Leader distribution | Partition distribution | Version | ++------------------+------+----------+--------------+----------------------+------------------------+---------+ +| "192.168.10.100" | 9779 | "ONLINE" | 0 | "No valid partition" | "No valid partition" | "3.0.0" | +| "192.168.10.101" | 9779 | "ONLINE" | 0 | "No valid partition" | "No valid partition" | "3.0.0" | +| "192.168.10.102" | 9779 | "ONLINE" | 0 | "No valid partition" | "No valid partition" | "3.0.0" | ++------------------+------+----------+--------------+----------------------+------------------------+---------+ ``` 在返回结果中,查看 **Status** 列,可以看到所有 Storage 服务都在线。 @@ -93,11 +103,8 @@ nebula> SHOW HOSTS; [replica_factor = ,] vid_type = {FIXED_STRING() | INT64} ) - [ON zone_list] - [COMMENT = '']; - zone_list: - "zone_name" [,"zone_name" ...] + [COMMENT = '']; ``` 参数详情请参见 [CREATE SPACE](../3.ngql-guide/9.space-statements/1.create-space.md)。 @@ -131,14 +138,13 @@ nebula> SHOW HOSTS; ```ngql nebula> SHOW HOSTS; - +-------------+-----------+-----------+--------------+----------------------------------+------------------------+ - | Host | Port | Status | Leader count | Leader distribution | Partition distribution | - +-------------+-----------+-----------+--------------+----------------------------------+------------------------+ - | "storaged0" | 9779 | "ONLINE" | 5 | "basketballplayer:5" | "basketballplayer:5" | - | "storaged1" | 9779 | "ONLINE" | 5 | "basketballplayer:5" | "basketballplayer:5" | - | "storaged2" | 9779 | "ONLINE" | 5 | "basketballplayer:5" | "basketballplayer:5" | - | "Total" | | | 15 | "basketballplayer:15" | "basketballplayer:15" | - +-------------+-----------+-----------+--------------+----------------------------------+------------------------+ + +-------------+-----------+-----------+--------------+----------------------------------+------------------------+---------+ + | Host | Port | Status | Leader count | Leader distribution | Partition distribution | Version | + +-------------+-----------+-----------+--------------+----------------------------------+------------------------+---------+ + | "storaged0" | 9779 | "ONLINE" | 5 | "basketballplayer:5" | "basketballplayer:5" | "3.0.0" | + | "storaged1" | 9779 | "ONLINE" | 5 | "basketballplayer:5" | "basketballplayer:5" | "3.0.0" | + | "storaged2" | 9779 | "ONLINE" | 5 | "basketballplayer:5" | "basketballplayer:5" | "3.0.0" | + +-------------+-----------+-----------+--------------+----------------------------------+------------------------+---------+ ``` 如果** Leader distribution **分布不均匀,请执行命令`BALANCE LEADER`重新分配。更多信息,请参见 [Storage 负载均衡](../8.service-tuning/load-balance.md)。 @@ -165,9 +171,14 @@ nebula> SHOW HOSTS; ### nGQL 语法 ```ngql -CREATE {TAG | EDGE} { | }( -[, ...]) -[COMMENT = '']; +CREATE {TAG | EDGE} [IF NOT EXISTS] { | } + ( + [NULL | NOT NULL] [DEFAULT ] [COMMENT ''] + [{, [NULL | NOT NULL] [DEFAULT ] [COMMENT '']} ...] + ) + [TTL_DURATION = ] + [TTL_COL = ] + [COMMENT = '']; ``` 参数详情请参见 [CREATE TAG](../3.ngql-guide/10.tag-statements/1.create-tag.md) 和 [CREATE EDGE](../3.ngql-guide/11.edge-type-statements/1.create-edge.md)。 @@ -202,19 +213,33 @@ nebula> CREATE EDGE serve(start_year int, end_year int); - 插入点 ```ngql - INSERT VERTEX [IF NOT EXISTS] [ (] [, ...]) - [, ([, ...]), ...] - VALUES : ([[, ...]]); + INSERT VERTEX [IF NOT EXISTS] [tag_props, [tag_props] ...] + VALUES : ([prop_value_list]) + + tag_props: + tag_name ([prop_name_list]) + + prop_name_list: + [prop_name [, prop_name] ...] + + prop_value_list: + [prop_value [, prop_value] ...] ``` - `VID`是 Vertex ID 的缩写,`VID`在一个图空间中是唯一的。参数详情请参见 [INSERT VERTEX](../3.ngql-guide/12.vertex-statements/1.insert-vertex.md)。 + `vid`是 Vertex ID 的缩写,`vid`在一个图空间中是唯一的。参数详情请参见 [INSERT VERTEX](../3.ngql-guide/12.vertex-statements/1.insert-vertex.md)。 - 插入边 ```ngql - INSERT EDGE [IF NOT EXISTS] ([, ...]) - VALUES -> [@] : ([, ...]) - [, -> [@] : ([, ...]), ...]; + INSERT EDGE [IF NOT EXISTS] ( ) VALUES + -> [@] : ( ) + [, -> [@] : ( ), ...]; + + ::= + [ [, ] ...] + + ::= + [ [, ] ...] ``` 参数详情请参见 [INSERT EDGE](../3.ngql-guide/13.edge-statements/1.insert-edge.md)。 @@ -262,10 +287,10 @@ nebula> CREATE EDGE serve(start_year int, end_year int); ```ngql GO [[ TO] STEPS ] FROM OVER [{REVERSELY | BIDIRECT}] - [ WHERE  ] - YIELD [DISTINCT] - [{SAMPLE | LIMIT }] - [| GROUP BY {col_name | expr | position} YIELD ] + [ WHERE ] + YIELD [DISTINCT] + [{ SAMPLE | }] + [| GROUP BY { | expression> | } YIELD ] [| ORDER BY [{ASC | DESC}]] [| LIMIT [,] ]; ``` @@ -293,12 +318,15 @@ nebula> CREATE EDGE serve(start_year int, end_year int); LOOKUP ON { | } [WHERE [AND ...]] YIELD [AS ]; + + + [AS ] [, [AS ] ...]; ``` - `MATCH` ```nGQL - MATCH [] RETURN ; + MATCH [] RETURN []; ``` ### `GO`语句示例 @@ -530,7 +558,7 @@ nebula> FETCH PROP ON player "player100" YIELD properties(vertex); !!! Note - 为没有指定长度的变量属性创建索引时,需要指定索引长度。在 utf-8 编码中,一个中文字符占 3 字节,请根据变量属性长度设置合适的索引长度。例如 10 个中文字符,索引长度需要为 30。详情请参见[创建索引](../3.ngql-guide/14.native-index-statements/1.create-native-index.md#_6)。 + 为没有指定长度的变量属性创建索引时,需要指定索引长度。在 utf-8 编码中,一个中文字符占 3 字节,请根据变量属性长度设置合适的索引长度。例如 10 个中文字符,索引长度需要为 30。详情请参见[创建索引](../3.ngql-guide/14.native-index-statements/1.create-native-index.md)。 ### 基于索引的`LOOKUP`和`MATCH`示例 diff --git a/docs-2.0/2.quick-start/6.cheatsheet-for-ngql-command.md b/docs-2.0/2.quick-start/6.cheatsheet-for-ngql-command.md index fb69ffeb72..79abd821ea 100644 --- a/docs-2.0/2.quick-start/6.cheatsheet-for-ngql-command.md +++ b/docs-2.0/2.quick-start/6.cheatsheet-for-ngql-command.md @@ -84,15 +84,37 @@ * [Schema 函数](../3.ngql-guide/6.functions-and-expressions/4.schema.md) - | 函数 | 说明 | - | :----------------------------- | :------------------------------------------------------ | - | id(vertex) | 返回点 ID。数据类型和点 ID 的类型保持一致。 | - | map properties(vertex) | 返回点的所有属性。 | - |map properties(edge)) | 返回边的所有属性。| - | string type(edge) | 返回边的 Edge type。 | - | src(edge) | 返回边的起始点 ID。数据类型和点 ID 的类型保持一致。 | - | dst(edge) | 返回边的目的点 ID。数据类型和点 ID 的类型保持一致。 | - | int rank(edge) | 返回边的 Rank 值。 | + * 原生 nGQL 语句适用 + + |函数| 说明 | + |:---- | :----| + |id(vertex) | 返回点 ID。数据类型和点 ID 的类型保持一致。| + |map properties(vertex) | 返回点的所有属性。| + |map properties(edge) | 返回边的所有属性。| + |string type(edge) | 返回边的 Edge type。| + |src(edge)|返回边的起始点 ID。数据类型和点 ID 的类型保持一致。| + |dst(edge)|返回边的目的点 ID。数据类型和点 ID 的类型保持一致。| + |int rank(edge) | 返回边的 rank。| + |vertex | 返回点的信息。包括点 ID、Tag、属性和值。| + |edge | 返回边的信息。包括 Edge type、起始点 ID、目的点 ID、rank、属性和值。| + |vertices | 返回子图中的点的信息。详情参见 [GET SUBGRAPH](../3.ngql-guide/16.subgraph-and-path/1.get-subgraph.md)。| + |edges | 返回子图中的边的信息。详情参见 [GET SUBGRAPH](../3.ngql-guide/16.subgraph-and-path/1.get-subgraph.md)。| + |path | 返回路径信息。详情参见 [FIND PATH](../3.ngql-guide/16.subgraph-and-path/2.find-path.md)。| + + * openCypher 兼容语句适用 + + |函数| 说明 | + |:---- | :----| + | id() | 返回点 ID。数据类型和点 ID 的类型保持一致。| + |list tags() | 返回点的 Tag,与 labels() 作用相同。| + |list labels() | 返回点的 Tag,与 tags() 作用相同,用于兼容 openCypher 语法。| + |map properties() | 返回点或边的所有属性。| + |string type() | 返回边的 Edge type。| + |src()|返回边的起始点 ID。数据类型和点 ID 的类型保持一致。| + |dst()|返回边的目的点 ID。数据类型和点 ID 的类型保持一致。| + |vertex startNode() | 获取一条边或一条路径并返回它的起始点 ID。| + |string endNode() | 获取一条边或一条路径并返回它的目的点 ID。| + |int rank() | 返回边的 rank。| * [列表函数](../3.ngql-guide/6.functions-and-expressions/6.list.md) @@ -198,13 +220,14 @@ * [MATCH](../3.ngql-guide/7.general-query-statements/2.match.md) ``` - MATCH [] RETURN + MATCH [] RETURN []; ``` | 模式 | 示例 | 说明 | | --------------------------- | ------------------------------------------------------------ | ------------------------------------------------------------ | | 匹配点 | `(v)` | 用户可以在一对括号中使用自定义变量来表示模式中的点。例如`(v)`。 | | 匹配 Tag | `MATCH (v:player) RETURN v` | 用户可以在点的右侧用`:`表示模式中的 Tag。 | + | 匹配多 Tag | `MATCH (v:player:team) RETURN v LIMIT 10` | 用户可以用英文冒号(:)匹配多 Tag 的点。 | | 匹配点的属性 | `MATCH (v:player{name:"Tim Duncan"}) RETURN v` | 用户可以在 Tag 的右侧用`{: }`表示模式中点的属性。 | | 匹配单点 ID | `MATCH (v) WHERE id(v) == 'player101' RETURN v` | 用户可以使用点 ID 去匹配点。`id()`函数可以检索点的 ID。 | | 匹配多点 ID | `MATCH (v:player { name: 'Tim Duncan' })--(v2) WHERE id(v2) IN ["player101", "player102"] RETURN v2` | 要匹配多个点的 ID,可以用`WHERE id(v) IN [vid_list]`。 | @@ -229,6 +252,12 @@ | 检索路径中的边 | `MATCH p=(v:player{name:"Tim Duncan"})-[]->(v2) RETURN relationships(p)` | 使用`relationships()`函数检索路径中的所有边。 | | 检索路径长度 | `MATCH p=(v:player{name:"Tim Duncan">})-[*..2]->(v2) RETURN p AS Paths, length(p) AS Length` | 使用`length()`函数检索路径的长度。 | +* [OPTIONAL MATCH](../3.ngql-guide/7.general-query-statements/optional-match.md) + + | 模式 | 示例 | 说明 | + | ------------------- | ------------------------------------------------------------ | ---------------------------------------------- | + |作为MATCH语句的可选项去匹配图数据库中的模式 | `MATCH (m)-[]->(n) WHERE id(m)=="player100" OPTIONAL MATCH (n)-[]->(l) WHERE id(n)=="player125" RETURN id(m),id(n),id(l)` | 如果图数据库中没有对应的模式,对应的列返回NULL。| + * [LOOKUP](../3.ngql-guide/7.general-query-statements/5.lookup.md) ``` @@ -255,6 +284,7 @@ OVER [{REVERSELY | BIDIRECT}] [ WHERE ] YIELD [DISTINCT] + [{SAMPLE | LIMIT }] [| GROUP BY {col_name | expr | position} YIELD ] [| ORDER BY [{ASC | DESC}]] [| LIMIT [,] ] @@ -262,8 +292,8 @@ | 示例 | 说明 | | ------------------------------------------------------------ | ------------------------------------------------------- | - | `GO FROM "player102" OVER serve` | 返回 player102 所属队伍。 | - | `GO 2 STEPS FROM "player102" OVER follow` | 返回距离 player102 两跳的朋友。 | + | `GO FROM "player102" OVER serve YIELD dst(edge)` | 返回 player102 所属队伍。 | + | `GO 2 STEPS FROM "player102" OVER follow YIELD dst(edge)` | 返回距离 player102 两跳的朋友。 | | `GO FROM "player100", "player102" OVER serve WHERE properties(edge).start_year > 1995 YIELD DISTINCT properties($$).name AS team_name, properties(edge).start_year AS start_year, properties($^).name AS player_name` | 添加过滤条件。 | | `GO FROM "player100" OVER follow, serve YIELD properties(edge).degree, properties(edge).start_year` | 遍历多个 Edge type。属性没有值时,会显示`UNKNOWN_PROP`。 | | `GO FROM "player100" OVER follow REVERSELY YIELD src(edge) AS destination` | 返回 player100 入方向的邻居点。 | @@ -273,41 +303,37 @@ * [FETCH](../3.ngql-guide/7.general-query-statements/4.fetch.md) - ``` - FETCH PROP ON {[, tag_name ...] | *} - [, vid ...] - YIELD [AS ] - ``` - - | 示例 | 说明 | - | ------------------------------------------------------------ | ------------------------------------------------------------ | - | `FETCH PROP ON player "player100"` | 在`FETCH`语句中指定 Tag 获取对应点的属性值。 | - | `FETCH PROP ON player "player100" YIELD player.name AS name` | 使用`YIELD`子句指定返回的属性。 | - | `FETCH PROP ON player "player101", "player102", "player103"` | 指定多个点 ID 获取多个点的属性值,点之间用英文逗号(,)分隔。 | - | `FETCH PROP ON player, t1 "player100", "player103"` | 在`FETCH`语句中指定多个 Tag 获取属性值。Tag 之间用英文逗号(,)分隔。 | - | `FETCH PROP ON * "player100", "player106", "team200"` | 在`FETCH`语句中使用`*`获取当前图空间所有标签里,点的属性值。 | - | `FETCH PROP ON serve "player102" -> "player106" YIELD dst(edge)` | 语法:`FETCH PROP ON -> [@] [, -> ...] [YIELD ]` | - | `FETCH PROP ON serve "player100" -> "team204"` | 获取连接 player100 和 team204 的边 serve 的所有属性值。 | - | `FETCH PROP ON serve "player100" -> "team204" YIELD serve.start_year` | 使用`YIELD`子句指定返回的属性。 | - | `FETCH PROP ON serve "player100" -> "team204", "player133" -> "team202"` | 指定多个边模式 (` -> [@]`) 获取多个边的属性值。模式之间用英文逗号(,)分隔。 | - | `FETCH PROP ON serve "player100" -> "team204"@1` | 要获取 rank 不为 0 的边,请在 FETCH 语句中设置 rank。 | - | `GO FROM "player101" OVER follow YIELD follow._src AS s, follow._dst AS d | FETCH PROP ON follow $-.s -> $-.d YIELD follow.degree` | 返回从点 player101 开始的 follow 边的 degree 值。 | - | `$var = GO FROM "player101" OVER follow YIELD follow._src AS s, follow._dst AS d; FETCH PROP ON follow $var.s -> $var.d YIELD follow.degree` | 自定义变量构建查询。 | - + * 获取点的属性值 + + ``` + FETCH PROP ON {[, tag_name ...] | *} + [, vid ...] + YIELD [AS ] + ``` + + | 示例 | 说明 | + | ------------------------------------------------------------ | ------------------------------------------------------------ | + | `FETCH PROP ON player "player100" YIELD properties(vertex)` | 在`FETCH`语句中指定 Tag 获取对应点的属性值。 | + | `FETCH PROP ON player "player100" YIELD player.name AS name` | 使用`YIELD`子句指定返回的属性。 | + | `FETCH PROP ON player "player101", "player102", "player103" YIELD properties(vertex)` | 指定多个点 ID 获取多个点的属性值,点之间用英文逗号(,)分隔。 | + | `FETCH PROP ON player, t1 "player100", "player103" YIELD properties(vertex)` | 在`FETCH`语句中指定多个 Tag 获取属性值。Tag 之间用英文逗号(,)分隔。 | + | `FETCH PROP ON * "player100", "player106", "team200" YIELD properties(vertex)` | 在`FETCH`语句中使用`*`获取当前图空间所有标签里,点的属性值。 | - -* [UNWIND](../3.ngql-guide/8.clauses-and-options/unwind.md) - - ``` - UNWIND AS - ``` - - | 示例 | 说明 | - | ------------------------------------------------------------ | ------------------------------------------------------------ | - | `UNWIND [1,2,3] AS n RETURN n` | 拆分列表。 | - | `WITH [1,1,2,2,3,3] AS n UNWIND n AS r WITH DISTINCT r AS r ORDER BY r RETURN collect(r)` | 1. 拆分列表`[1,1,2,2,3,3]`。 2. 删除重复行。 3. 排序行。 4. 将行转换为列表。 | - | `MATCH p=(v:player{name:"Tim Duncan"})--(v2) WITH nodes(p) AS n UNWIND n AS r WITH DISTINCT r AS r RETURN collect(r)` | 1. 将匹配路径上的顶点输出到列表中。 2. 拆分列表。 3. 删除重复行。 4. 将行转换为列表。 | - + * 获取边的属性值 + + ``` + FETCH PROP ON -> [@] [, -> ...] + YIELD ; + ``` + + | 示例 | 说明 | + | ------------------------------------------------------------ | ------------------------------------------------------------ | + | `FETCH PROP ON serve "player100" -> "team204" YIELD properties(edge)` | 获取连接 player100 和 team204 的边 serve 的所有属性值。 | + | `FETCH PROP ON serve "player100" -> "team204" YIELD serve.start_year` | 使用`YIELD`子句指定返回的属性。 | + | `FETCH PROP ON serve "player100" -> "team204", "player133" -> "team202" YIELD properties(edge)` | 指定多个边模式 (` -> [@]`) 获取多个边的属性值。模式之间用英文逗号(,)分隔。 | + | `FETCH PROP ON serve "player100" -> "team204"@1 YIELD properties(edge)` | 要获取 rank 不为 0 的边,请在 FETCH 语句中设置 rank。 | + | `GO FROM "player101" OVER follow YIELD follow._src AS s, follow._dst AS d | FETCH PROP ON follow $-.s -> $-.d YIELD follow.degree` | 返回从点 player101 开始的 follow 边的 degree 值。 | + | `$var = GO FROM "player101" OVER follow YIELD follow._src AS s, follow._dst AS d; FETCH PROP ON follow $var.s -> $var.d YIELD follow.degree` | 自定义变量构建查询。 | * SHOW @@ -341,19 +367,21 @@ | [GROUP BY](../3.ngql-guide/8.clauses-and-options/group-by.md) | ` GROUP BY YIELD , ` | `GO FROM "player100" OVER follow BIDIRECT YIELD $$.player.name as Name | GROUP BY $-.Name YIELD $-.Name as Player, count(*) AS Name_Count` | 查找所有连接到 player100 的点,并根据他们的姓名进行分组,返回姓名的出现次数。 | | [LIMIT](../3.ngql-guide/8.clauses-and-options/limit.md) | `YIELD [| LIMIT [,] ]` | `O FROM "player100" OVER follow REVERSELY YIELD $$.player.name AS Friend, $$.player.age AS Age | ORDER BY $-.Age, $-.Friend | LIMIT 1, 3` | 从排序结果中返回第 2 行开始的 3 行数据。 | | [SKIP](../3.ngql-guide/8.clauses-and-options/limit.md) | `RETURN [SKIP ] [LIMIT ]` | `MATCH (v:player{name:"Tim Duncan"}) --> (v2) RETURN v2.player.name AS Name, v2.player.age AS Age ORDER BY Age DESC SKIP 1` | 用户可以单独使用`SKIP `设置偏移量,后面不需要添加`LIMIT `。 | +| [SAMPLE](../3.ngql-guide/8.clauses-and-options/sample.md) | ` SAMPLE ;` | `GO 3 STEPS FROM "player100" OVER * YIELD properties($$).name AS NAME, properties($$).age AS Age SAMPLE [1,2,3];` | 在结果集中均匀取样并返回指定数量的数据。 | | [ORDER BY](../3.ngql-guide/8.clauses-and-options/order-by.md) | ` ORDER BY [ASC | DESC] [, [ASC | DESC] ...]` | `FETCH PROP ON player "player100", "player101", "player102", "player103" YIELD player.age AS age, player.name AS name | ORDER BY $-.age ASC, $-.name DESC` | `ORDER BY`子句指定输出结果的排序规则。 | | [RETURN](../3.ngql-guide/8.clauses-and-options/return.md) | `RETURN {||.|.|...}` | `MATCH (v:player) RETURN v.player.name, v.player.age LIMIT 3` | 返回点的属性为`name`和`age`的前三行值。 | | [TTL](../3.ngql-guide/8.clauses-and-options/ttl-options.md) | ``CREATE TAG ( , , ...) ttl_duration= , ttl_col = `` | `CREATE TAG t2(a int, b int, c string) ttl_duration= 100, ttl_col = "a"` | 创建 Tag 并设置 TTL 选项。 | | [WHERE](../3.ngql-guide/8.clauses-and-options/where.md) | `WHERE {. {>|==|<|...} ...}` | `MATCH (v:player) WHERE v.player.name == "Tim Duncan" XOR (v.player.age < 30 AND v.player.name == "Yao Ming") OR NOT (v.player.name == "Yao Ming" OR v.player.name == "Tim Duncan") RETURN v.player.name, v.player.age` | `WHERE`子句可以根据条件过滤输出结果,通常用于`GO`和`LOOKUP`语句,`MATCH`和`WITH`语句。 | | [YIELD](../3.ngql-guide/8.clauses-and-options/yield.md) | `YIELD [DISTINCT] [AS ] [, [AS ] ...] [WHERE ];` | `GO FROM "player100" OVER follow YIELD dst(edge) AS ID | FETCH PROP ON player $-.ID YIELD player.age AS Age | YIELD AVG($-.Age) as Avg_age, count(*)as Num_friends` | 查找 player100 关注的 player,并计算他们的平均年龄。 | | [WITH](../3.ngql-guide/8.clauses-and-options/with.md) | `MATCH $expressions WITH {nodes()|labels()|...}` | `MATCH p=(v:player{name:"Tim Duncan"})--() WITH nodes(p) AS n UNWIND n AS n1 RETURN DISTINCT n1` | `WITH`子句可以获取并处理查询前半部分的结果,并将处理结果作为输入传递给查询的后半部分。 | +|[UNWIND](../3.ngql-guide/8.clauses-and-options/unwind.md)|`UNWIND AS ` |`UNWIND [1,2,3] AS n RETURN n` |拆分列表。| ## 图空间语句 | 语句 | 语法 | 示例 | 说明 | | ------------------------------------------------------------ | ------------------------------------------------------------ | ----------------------------------------------------- | ------------------------------------------------------------ | -| [CREATE SPACE](../3.ngql-guide/9.space-statements/1.create-space.md) | `CREATE SPACE [IF NOT EXISTS] ( [partition_num = ,] [replica_factor = ,] vid_type = {FIXED_STRING()| INT[64]} ) [COMMENT = '']` | `CREATE SPACE my_space_1 (vid_type=FIXED_STRING(30))` | 创建一个新的图空间。 | -| [CREATE SPACE](../3.ngql-guide/9.space-statements/1.create-space.md) | `CREATE SPACE AS ` | `CREATE SPACE my_space_4 as my_space_3` | 克隆现有图空间的 Schema | +| [CREATE SPACE](../3.ngql-guide/9.space-statements/1.create-space.md) | `CREATE SPACE [IF NOT EXISTS] ( [partition_num = ,] [replica_factor = ,] vid_type = {FIXED_STRING() | INT[64]} ) [COMMENT = '']` | `CREATE SPACE my_space_1 (vid_type=FIXED_STRING(30))` | 创建一个新的图空间。 | +| [CREATE SPACE](../3.ngql-guide/9.space-statements/1.create-space.md) | `CREATE SPACE AS ` | `CREATE SPACE my_space_4 as my_space_3` | 克隆现有图空间的 Schema。 | | [USE](../3.ngql-guide/9.space-statements/2.use-space.md) | `USE ` | `USE space1` | 指定一个图空间,或切换到另一个图空间,将其作为后续查询的工作空间。 | | [SHOW SPACES](../3.ngql-guide/9.space-statements/3.show-spaces.md) | `SHOW SPACES` | `SHOW SPACES` | 列出 Nebula Graph 示例中的所有图空间。 | | [DESCRIBE SPACE](../3.ngql-guide/9.space-statements/4.describe-space.md) | `DESC[RIBE] SPACE ` | `DESCRIBE SPACE basketballplayer` | 显示指定图空间的信息。 | @@ -367,7 +395,7 @@ | [DROP TAG](../3.ngql-guide/10.tag-statements/2.drop-tag.md) | `DROP TAG [IF EXISTS] ` | `CREATE TAG test(p1 string, p2 int)` | 删除当前工作空间内所有点上的指定 Tag。 | | [ALTER TAG](../3.ngql-guide/10.tag-statements/3.alter-tag.md) | `ALTER TAG [, alter_definition] ...] [ttl_definition [, ttl_definition] ... ] [COMMENT = '']` | `ALTER TAG t1 ADD (p3 int, p4 string)` | 修改 Tag 的结构。例如增删属性、修改数据类型,也可以为属性设置、修改 [TTL](../3.ngql-guide/8.clauses-and-options/ttl-options.md)(Time-To-Live)。 | | [SHOW TAGS](../3.ngql-guide/10.tag-statements/4.show-tags.md) | `SHOW TAGS` | `SHOW TAGS` | 显示当前图空间内的所有 Tag 名称。 | -| [DESCRIBE TAG](../3.ngql-guide/10.tag-statements/5.describe-tag.md) | `DESC[RIBE] TAG ` | `DESCRIBE TAG player` | 指定 Tag 的详细信息,例如字段名称、数据类型等。 | +| [DESCRIBE TAG](../3.ngql-guide/10.tag-statements/5.describe-tag.md) | `DESC[RIBE] TAG ` | `DESCRIBE TAG player` | 查看指定 Tag 的详细信息,例如字段名称、数据类型等。 | | [DELETE TAG](../3.ngql-guide/10.tag-statements/6.delete-tag.md) | `DELETE TAG FROM ` | `DELETE TAG test1 FROM "test"` | 删除指定点上的指定 Tag。 | ## Edge type 语句 @@ -378,13 +406,13 @@ | [DROP EDGE](../3.ngql-guide/11.edge-type-statements/2.drop-edge.md) | `DROP EDGE [IF EXISTS] ` | `DROP EDGE e1` | 删除当前工作空间内的指定 Edge type。 | | [ALTER EDGE](../3.ngql-guide/11.edge-type-statements/3.alter-edge.md) | `ALTER EDGE [, alter_definition] ...] [ttl_definition [, ttl_definition] ... ] [COMMENT = '']` | `ALTER EDGE e1 ADD (p3 int, p4 string)` | 修改 Edge type 的结构。 | | [SHOW EDGES](../3.ngql-guide/11.edge-type-statements/4.show-edges.md) | `SHOW EDGES` | `SHOW EDGES` | 显示当前图空间内的所有 Edge type 名称。 | -| [DESCRIBE EDGE](../3.ngql-guide/11.edge-type-statements/5.describe-edge.md) | `DESC[RIBE] EDGE ` | `DESCRIBE EDGE follow` | 指定 Edge type 的详细信息,例如字段名称、数据类型等。 | +| [DESCRIBE EDGE](../3.ngql-guide/11.edge-type-statements/5.describe-edge.md) | `DESC[RIBE] EDGE ` | `DESCRIBE EDGE follow` | 查看指定 Edge type 的详细信息,例如字段名称、数据类型等。 | ## 点语句 | 语句 | 语法 | 示例 | 说明 | | ------------------------------------------------------------ | ------------------------------------------------------------ | ------------------------------------------------------------ | ------------------------------------------------------------ | -| [INSERT VERTEX](../3.ngql-guide/12.vertex-statements/1.insert-vertex.md) | `INSERT VERTEX [IF NOT EXISTS] [tag_props, [tag_props] ...] VALUES VID: ([prop_value_list])
tag_props: tag_name ([prop_name_list])
prop_name_list: [prop_name [, prop_name] ...]
prop_value_list: [prop_value [, prop_value] ...] ` | `INSERT VERTEX t2 (name, age) VALUES "13":("n3", 12), "14":("n4", 8)` | 在 Nebula Graph 实例的指定图空间中插入一个或多个点。 | +| [INSERT VERTEX](../3.ngql-guide/12.vertex-statements/1.insert-vertex.md) | `INSERT VERTEX [IF NOT EXISTS] [tag_props, [tag_props] ...] VALUES : ([prop_value_list])` | `INSERT VERTEX t2 (name, age) VALUES "13":("n3", 12), "14":("n4", 8)` | 在 Nebula Graph 实例的指定图空间中插入一个或多个点。 | | [DELETE VERTEX](../3.ngql-guide/12.vertex-statements/4.delete-vertex.md) | `DELETE VERTEX [, ...]` | `DELETE VERTEX "team1"` | 删除点,以及点关联的出边和入边。 | | [UPDATE VERTEX](../3.ngql-guide/12.vertex-statements/2.update-vertex.md) | `UPDATE VERTEX ON SET [WHEN ] [YIELD ]` | `UPDATE VERTEX ON player "player101" SET age = age + 2 ` | 修改点上 Tag 的属性值。 | | [UPSERT VERTEX](../3.ngql-guide/12.vertex-statements/3.upsert-vertex.md) | `UPSERT VERTEX ON SET [WHEN ] [YIELD ]` | `UPSERT VERTEX ON player "player667" SET age = 31` | 结合`UPDATE`和`INSERT`,如果点存在,会修改点的属性值;如果点不存在,会插入新的点。 | @@ -433,8 +461,8 @@ | 类型 | 语法 | 示例 | 说明 | | ------------------------------------------------------------ | ------------------------------------------------------------ | ------------------------------------------------------------ | ------------------------------------------------------------ | -| [子图](../3.ngql-guide/16.subgraph-and-path/1.get-subgraph.md) | `GET SUBGRAPH [WITH PROP] [ STEPS] FROM {, ...} [{IN | OUT | BOTH} , ...] [YIELD [VERTICES AS ] [,EDGES AS ]] ` | `GET SUBGRAPH 1 STEPS FROM "player100" YIELD VERTICES AS nodes, EDGES AS relationships` | 指定 Edge type 的起始点可以到达的点和边的信息,返回子图信息。 | -| [路径](../3.ngql-guide/16.subgraph-and-path/2.find-path.md) | `FIND { SHORTEST | ALL | NOLOOP } PATH [WITH PROP] FROM TO
OVER [REVERSELY | BIDIRECT] [] [UPTO STEPS] [| ORDER BY $-.path] [| LIMIT ]` | `FIND SHORTEST PATH FROM "player102" TO "team204" OVER *` | 查找指定起始点和目的点之间的路径。返回的路径格式类似于`()-[:@]->( STEPS] FROM {, ...} [{IN | OUT | BOTH} , ...] YIELD [VERTICES AS ] [,EDGES AS ] ` | `GET SUBGRAPH 1 STEPS FROM "player100" YIELD VERTICES AS nodes, EDGES AS relationships` | 指定 Edge type 的起始点可以到达的点和边的信息,返回子图信息。 | +| [路径](../3.ngql-guide/16.subgraph-and-path/2.find-path.md) | `FIND { SHORTEST | ALL | NOLOOP } PATH [WITH PROP] FROM TO OVER [REVERSELY | BIDIRECT] [] [UPTO STEPS] YIELD path as [| ORDER BY $-.path] [| LIMIT ]` | `FIND SHORTEST PATH FROM "player102" TO "team204" OVER * YIELD path as p` | 查找指定起始点和目的点之间的路径。返回的路径格式类似于`()-[:@]->(` | 显示`BALANCE DATA`任务的状态。 | - | `BALANCE DATA STOP` | 停止`BALANCE DATA`任务。 | - | `BALANCE DATA REMOVE ` | 在 Nebula Graph 集群中扫描并解绑指定的 Storage 主机。 | - | `BALANCE LEADER` | 在 Nebula Graph 集群中均衡分布 leader。 | + |`BALANCE LEADER`|在当前图空间内启动任务均衡分布 leader。该命令会返回任务 ID。| + + * [作业管理](../3.ngql-guide/18.operation-and-maintenance-statements/4.job-statements.md) @@ -466,6 +495,10 @@ | `SHOW JOBS` | 列出当前图空间内所有未过期的作业。 | | `STOP JOB` | 停止当前图空间内未完成的作业。 | | `RECOVER JOB` | 重新执行当前图空间内失败的作业,并返回已恢复的作业数量。 | + * [终止查询](../3.ngql-guide/18.operation-and-maintenance-statements/6.kill-query.md) diff --git a/docs-2.0/20.appendix/0.FAQ.md b/docs-2.0/20.appendix/0.FAQ.md index 7c2fe9f291..9da119c306 100644 --- a/docs-2.0/20.appendix/0.FAQ.md +++ b/docs-2.0/20.appendix/0.FAQ.md @@ -22,25 +22,31 @@ Nebula Graph 一直在持续开发,功能或操作的行为可能会有变化 !!! compatibility "`X`版本兼容性" - Nebula Graph {{ nebula.release }} 与 历史版本 (包括 Nebula Graph 1.x 和 2.0-RC) 的数据格式、客户端通信协议均**双向不兼容**。 + Nebula Graph {{ nebula.release }} 与 历史版本 (包括 Nebula Graph 1.x 和 2.x) 的数据格式、客户端通信协议均**双向不兼容**。 数据格式升级参见[升级 Nebula Graph 历史版本至当前版本](../4.deployment-and-installation/3.upgrade-nebula-graph/upgrade-nebula-graph-to-latest.md)。 客户端与工具均需要[下载对应版本](../20.appendix/6.eco-tool-version.md)。 + -## 关于执行 +## 关于执行报错 -### 为什么 Nebula Graph 2.6.0 的返回结果每行之间没有横线分隔了? +### 如何处理错误信息 `SemanticError: Missing yield clause.` -这是 Nebula Console 2.6.0 版本的变动造成的,不是 Nebula Graph 内核的变更,不影响返回数据本身的内容。 +从 Nebula Graph 3.0.0 开始,查询语句`LOOKUP`、`GO`、`FETCH`必须用`YIELD`子句指定输出结果。详情请参见[YIELD](../3.ngql-guide/8.clauses-and-options/yield.md)。 -### 关于悬挂边 + + +### 如何处理错误信息 `To get the property of the vertex in 'v.age', should use the format 'var.tag.prop'` -Nebula Graph {{ nebula.release }} 的数据模型中,由于设计允许图中存在“悬挂边”;没有 openCypher 中的 MERGE 语句。对于悬挂边的保证完全依赖应用层面。详见 [INSERT VERTEX](../3.ngql-guide/12.vertex-statements/1.insert-vertex.md), [DELETE VERTEX](../3.ngql-guide/12.vertex-statements/4.delete-vertex.md), [INSERT EDGE](../3.ngql-guide/13.edge-statements/1.insert-edge.md), [DELETE EDGE](../3.ngql-guide/13.edge-statements/4.delete-edge.md)。 +从 3.0.0 版本开始,`pattern`支持同时匹配多个 Tag,所以返回属性时,需要额外指定 Tag 名称。即从`RETURN 变量名.属性名`改为`RETURN 变量名.Tag名.属性名`。 ### 如何处理错误信息 `[ERROR (-1005)]: Used memory hits the high watermark(0.800000) of total system memory.` @@ -51,10 +57,6 @@ Nebula Graph {{ nebula.release }} 的数据模型中,由于设计允许图中 * 清理系统内存,使其降低到阈值以下。 * [修改 Graph 配置](../5.configurations-and-logs/1.configurations/1.configurations.md)。在所有 Graph 服务器的配置文件中增加`system_memory_high_watermark_ratio`参数,为其设置一个大于`0.8`的值,例如`0.9`。 - !!! note - - 仅 Graph 服务支持`system_memory_high_watermark_ratio`,Storage 和 Meta 服务不支持该参数。 - ### 如何处理错误信息 `Storage Error E_RPC_FAILURE` 报错原因通常为 Graph 服务向 Storage 服务请求了过多的数据,导致 Storage 服务超时。请尝试以下解决方案: @@ -69,17 +71,108 @@ Nebula Graph {{ nebula.release }} 的数据模型中,由于设计允许图中 已知问题,通常需要重试 1-N 次 (N==partition 数量)。原因为 meta client 更新 leader 缓存需要 1-2 个心跳或者通过错误触发强制更新。 -### 如何处理错误信息 `SemanticError: Missing yield clause.` +### [ERROR (-1005)]: Schema not exist: xxx -从 Nebula Graph 3.0 开始,查询语句`LOOKUP`、`GO`、`FETCH`必须用`YIELD`子句指定输出结果。详情请参见[YIELD](../3.ngql-guide/8.clauses-and-options/yield.md)。 +查询时提示`Schema not exist`,请确认: -### 如何处理错误信息 `Zone not enough!` +- Schema 中是否存在该 Tag 或 Edge type。 -从 3.0 版本开始,在配置文件中添加的 Storage 节点无法直接读写,配置文件的作用仅仅是将 Storage 节点注册至 Meta 服务中。必须使用`ADD HOSTS`命令后,才能正常读写 Storage 节点。详情参见[管理逻辑机架(Zone)](../4.deployment-and-installation/5.zone.md)。 +- Tag 或 Edge type 的名称是否为关键字,如果是关键字,请使用反引号(\`)将它们括起来。详情请参见[关键字](../3.ngql-guide/1.nGQL-overview/keywords-and-reserved-words.md)。 + +### 编译 Exchange、Connectors、Algorithm 时无法下载 SNAPSHOT 包 + +现象:编译时提示`Could not find artifact com.vesoft:client:jar:xxx-SNAPSHOT`。 + +原因:本地 maven 没有配置用于下载 SNAPSHOT 的仓库。maven 中默认的 central 仓库用于存放正式发布版本,而不是开发版本(SNAPSHOT)。 + +解决方案:在 maven 的 setting.xml文件的`profiles`作用域内中增加以下配置: + +``` + + + true + + + + snapshots + https://oss.sonatype.org/content/repositories/snapshots/ + + true + + + + +``` + +### 如何处理错误信息`[ERROR (-7)]: SyntaxError: syntax error near`? + +大部分情况下,查询语句需要有`YIELD`或`RETURN`,请检查查询语句是否包含。 + + + +### 如何处理错误信息`can’t solve the start vids from the sentence` + +查询引擎需要知道从哪些 VID 开始图遍历。这些开始图遍历的 VID,或者通过用户指定,例如: + +```ngql +> GO FROM ${vids} ... +> MATCH (src) WHERE id(src) == ${vids} +# 开始图遍历的 VID 通过如上办法指定 +``` + +或者通过一个属性索引来得到,例如: + +```ngql +# CREATE TAG INDEX IF NOT EXISTS i_player ON player(name(20)); +# REBUILD TAG INDEX i_player; + +> LOOKUP ON player WHERE player.name == "abc" | ... YIELD ... +> MATCH (src) WHERE src.name == "abc" ... +# 通过点属性 name 的索引,来得到 VID +``` + +否则,就会抛出这样一个异常 `can’t solve the start vids from the sentence`。 + +### 如何处理错误信息`Wrong vertex id type: 1001` + +检查输入的 VID 类型是否是`create space`设置的`INT64`或`FIXED_STRING(N)`。详情请参见 [create space](../3.ngql-guide/9.space-statements/1.create-space.md)。 + +### 如何处理错误信息`The VID must be a 64-bit integer or a string fitting space vertex id length limit.` + +检查输入的 VID 是否超过限制长度。详情请参见 [create space](../3.ngql-guide/9.space-statements/1.create-space.md)。 + +### 如何处理错误信息 `edge conflict` 或 `vertex conflict` + +Storage 服务在毫秒级时间内多次收到插入或者更新同一点或边的请求时,可能返回该错误。请稍后重试。 + +### 如何处理错误信息 `RPC failure in MetaClient: Connection refused` + +报错原因通常为 metad 服务状态异常,或是 metad 和 graphd 服务所在机器网络不通。请尝试以下解决方案: + +- 在 metad 所在服务器查看下 metad 服务状态,如果服务状态异常,可以重新启动 metad 服务。 + +- 在报错服务器下使用`telnet meta-ip:port`查看网络状态。 + +- 检查配置文件中的端口配置,如果端口号与连接时使用的不同,改用配置文件中的端口或者修改配置。 + +### 如何处理 `nebula-graph.INFO` 中错误日志 `StorageClientBase.inl:214] Request to "x.x.x.x":9779 failed: N6apache6thrift9transport19TTransportExceptionE: Timed Out` + +报错原因可能是查询的数据量比较大,storaged 处理超时。请尝试以下解决方法: + +- 导入数据时,手动 [compaction](../8.service-tuning/compaction.md),加速读的速度。 + +- 增加 Graph 服务与 Storage 服务的 RPC 连接超时时间,在`nebula-storaged.conf`文件里面修改`--storage_client_timeout_ms`参数的值。该值的单位为毫秒(ms),默认值为 60000 毫秒。 + + + +### 如何处理 `nebula-storaged.INFO` 中错误日志 `MetaClient.cpp:65] Heartbeat failed, status:Wrong cluster!` 或者 `nebula-metad.INFO` 含有错误日志`HBProcessor.cpp:54] Reject wrong cluster host "x.x.x.x":9771!` + +报错的原因可能是用户修改了 metad 的 ip 或者端口信息,或者 storage 之前加入过其他集群。请尝试以下解决方法: + +用户到 storage 部署的机器所在的安装目录(默认安装目录为 `/usr/local/nebula`)下面将`cluster.id`文件删除,然后重启 storaged 服务。 -### 如何处理错误信息 `To get the property of the vertex in 'v.age', should use the format 'var.tag.prop'` -从 3.0 版本开始,`pattern`支持同时匹配多个 Tag,所以返回属性时,需要额外指定 Tag 名称。即从`RETURN 变量名.属性名`改为`RETURN 变量名.Tag名.属性名`。 +## 关于设计与功能 ### 返回消息中 `time spent` 的含义是什么? @@ -99,6 +192,19 @@ Got 1 rows (time spent 1235/1934 us) - 第二个数字`1934`表示从客户端角度看所花费的时间,即从客户端发送请求、接收结果,然后在屏幕上显示结果所花费的时间。 +### 为什么 Nebula Graph 的返回结果每行之间没有横线分隔了? + +这是 Nebula Console 2.6.0 版本的变动造成的,不是 Nebula Graph 内核的变更,不影响返回数据本身的内容。 + +### 关于悬挂边 + +悬挂边 (Dangling edge) 是指一条边的起点或者终点在数据库中不存在。 + +Nebula Graph {{ nebula.release }} 的数据模型中,由于设计允许图中存在“悬挂边”; +没有 openCypher 中的 MERGE 语句。 +对于悬挂边的保证完全依赖应用层面。 +详见 [INSERT VERTEX](../3.ngql-guide/12.vertex-statements/1.insert-vertex.md), [DELETE VERTEX](../3.ngql-guide/12.vertex-statements/4.delete-vertex.md), [INSERT EDGE](../3.ngql-guide/13.edge-statements/1.insert-edge.md), [DELETE EDGE](../3.ngql-guide/13.edge-statements/4.delete-edge.md)。 + ### 可以在`CREATE SPACE`时设置`replica_factor`为偶数(例如设置为 2)吗? 不要这样设置。 @@ -143,10 +249,6 @@ Storage 服务使用 Raft 协议(多数表决),为保证可用性,要求 关于路径的详细说明,请参见[维基百科](https://en.wikipedia.org/wiki/Path_(graph_theory)#Walk,_trail,_path)。 -### 如何处理错误信息`[ERROR (-7)]: SyntaxError: syntax error near`? - -大部分情况下,查询语句需要有`YIELD`或`RETURN`,请检查查询语句是否包含。 - ### 如何统计每种 Tag 有多少个点,每个 Edge type 有多少条边? 请参见 [show-stats](../3.ngql-guide/7.general-query-statements/6.show/14.show-stats.md)。 @@ -181,67 +283,6 @@ nGQL 没有该功能。 或者指定各 Tag/Edge Type,然后再自己通过 `Union` 拼装。 -### 如何处理错误信息`can’t solve the start vids from the sentence` - -查询引擎需要知道从哪些 VID 开始图遍历。这些开始图遍历的 VID,或者通过用户指定,例如: - -```ngql -> GO FROM ${vids} ... -> MATCH (src) WHERE id(src) == ${vids} -# 开始图遍历的 VID 通过如上办法指定 -``` - -或者通过一个属性索引来得到,例如: - -```ngql -# CREATE TAG INDEX IF NOT EXISTS i_player ON player(name(20)); -# REBUILD TAG INDEX i_player; - -> LOOKUP ON player WHERE player.name == "abc" | ... YIELD ... -> MATCH (src) WHERE src.name == "abc" ... -# 通过点属性 name 的索引,来得到 VID -``` - -否则,就会抛出这样一个异常 `can’t solve the start vids from the sentence`。 - -### 如何处理错误信息`Wrong vertex id type: 1001` - -检查输入的 VID 类型是否是`create space`设置的`INT64`或`FIXED_STRING(N)`。详情请参见 [create space](../3.ngql-guide/9.space-statements/1.create-space.md)。 - -### 如何处理错误信息`The VID must be a 64-bit integer or a string fitting space vertex id length limit.` - -检查输入的 VID 是否超过限制长度。详情请参见 [create space](../3.ngql-guide/9.space-statements/1.create-space.md)。 - -### 如何处理错误信息 `edge conflict` 或 `vertex conflict` - -Storage 服务在毫秒级时间内多次收到插入或者更新同一点或边的请求时,可能返回该错误。请稍后重试。 - -### 如何处理错误信息 `RPC failure in MetaClient: Connection refused` - -报错原因通常为 metad 服务状态异常,或是 metad 和 graphd 服务所在机器网络不通。请尝试以下解决方案: - -- 在 metad 所在服务器查看下 metad 服务状态,如果服务状态异常,可以重新启动 metad 服务。 - -- 在报错服务器下使用`telnet meta-ip:port`查看网络状态。 - -- 检查配置文件中的端口配置,如果端口号与连接时使用的不同,改用配置文件中的端口或者修改配置。 - -### 如何处理 `nebula-graph.INFO` 中错误日志 `StorageClientBase.inl:214] Request to "x.x.x.x":9779 failed: N6apache6thrift9transport19TTransportExceptionE: Timed Out` - -报错原因可能是查询的数据量比较大,storaged 处理超时。请尝试以下解决方法: - -- 导入数据时,手动 [compaction](../8.service-tuning/compaction.md),加速读的速度。 - -- 增加 Graph 服务与 Storage 服务的 RPC 连接超时时间,在`nebula-storaged.conf`文件里面修改`--storage_client_timeout_ms`参数的值。该值的单位为毫秒(ms),默认值为 60000 毫秒。 - - - -### 如何处理 `nebula-storaged.INFO` 中错误日志 `MetaClient.cpp:65] Heartbeat failed, status:Wrong cluster!` 或者 `nebula-metad.INFO` 含有错误日志`HBProcessor.cpp:54] Reject wrong cluster host "x.x.x.x":9771!` - -报错的原因可能是用户修改了 metad 的 ip 或者端口信息,或者 storage 之前加入过其他集群。请尝试以下解决方法: - -用户到 storage 部署的机器所在的安装目录(默认安装目录为 `/usr/local/nebula`)下面将`cluster.id`文件删除,然后重启 storaged 服务。 - ### 能不能用中文字符做标识符,比如图空间、Tag、Edge type、属性、索引的名称? 能,详情参见[关键字和保留字](../3.ngql-guide/1.nGQL-overview/keywords-and-reserved-words.md)。 @@ -261,46 +302,18 @@ nebula > MATCH (s)<-[e]-() WHERE id(s) == "given" RETURN count(e); #入度 可以使用 [Nebula Algorithm](../nebula-algorithm.md)。 -### [ERROR (-1005)]: Schema not exist: xxx - -查询时提示`Schema not exist`,请确认: - -- Schema 中是否存在该 Tag 或 Edge type。 - -- Tag 或 Edge type 的名称是否为关键字,如果是关键字,请使用反引号(\`)将它们括起来。详情请参见[关键字](../3.ngql-guide/1.nGQL-overview/keywords-and-reserved-words.md)。 - -### 编译 Exchange、Connectors、Algorithm 时无法下载 SNAPSHOT 包 - -现象:编译时提示`Could not find artifact com.vesoft:client:jar:xxx-SNAPSHOT`。 - -原因:本地 maven 没有配置用于下载 SNAPSHOT 的仓库。maven 中默认的 central 仓库用于存放正式发布版本,而不是开发版本(SNAPSHOT)。 - -解决方案:在 maven 的 setting.xml文件的`profiles`作用域内中增加以下配置: - -``` - - - true - - - - snapshots - https://oss.sonatype.org/content/repositories/snapshots/ - - true - - - - -``` - ## 关于运维 ### 日志文件过大时如何回收日志? + ### 如何查看 Nebula Graph 版本 @@ -310,7 +323,6 @@ Nebula Graph 使用 [glog](https://github.com/google/glog) 打印日志。glog ```bash $ ./nebula-graphd --version -nebula-graphd version 2.5.0, Git: c397299c, Build Time: Aug 19 2021 11:20:18 ``` - Docker Compose 部署 @@ -329,11 +341,11 @@ nebula-graphd version 2.5.0, Git: c397299c, Build Time: Aug 19 2021 11:20:18 ### 如何扩缩容 -用户可以使用 Dashboard(企业版),在可视化页面对 graphd 和 storaged 进行快速扩缩容,详情参见[集群操作-扩缩容](../nebula-dashboard-ent/4.cluster-operator/4.manage.md)。 +用户可以使用 Dashboard(企业版),在可视化页面对 graphd 进行快速扩缩容,详情参见[集群操作-扩缩容](../nebula-dashboard-ent/4.cluster-operator/4.manage.md)。 Nebula Graph {{ nebula.release }} 未提供运维命令以实现自动扩缩容,参考以下步骤: -- metad 的扩容和缩容: metad 不支持扩缩容,也不支持迁移到新机器,也不要增加新的 metad 进程。 +- metad 的扩容和缩容: metad 不支持自动扩缩容。 !!! note @@ -343,11 +355,16 @@ Nebula Graph {{ nebula.release }} 未提供运维命令以实现自动扩缩容 - graphd 的扩容: 在新机器上准备 graphd 二进制文件和配置文件,在配置文件中修改或增加已在运行的 metad 地址,启动 graphd 进程。 +- storaged 不支持扩缩容。 + + ### 修改 Host 名称后,旧的 Host 一直显示 `OFFLINE` 怎么办? diff --git a/docs-2.0/20.appendix/6.eco-tool-version.md b/docs-2.0/20.appendix/6.eco-tool-version.md index 14f2916aba..785d9a7f4f 100644 --- a/docs-2.0/20.appendix/6.eco-tool-version.md +++ b/docs-2.0/20.appendix/6.eco-tool-version.md @@ -6,7 +6,7 @@ 内核版本号命名规则为 `X.Y.Z`,表示`大版本 X`,`中版本 Y`,`小版本 Z`。关于生命周期说明: - - 企业版:一个`Y`版本的开发周期为 3 个月,其维护与支持周期为 3 年; + - 企业版:一个`Y`版本的开发周期为 6 个月,其维护与支持周期为 3 年; - 社区版:一个`Y`版本的开发周期为 3 个月,其维护与支持周期至下一个`Y`版本发布; @@ -28,7 +28,7 @@ - 默认内核及客户端都不支持降级:不可从`X.Y.Z2`降级成`X.Y.Z1`; - - 1.x 版本的生态工具完全不支持在 Nebula Graph 2.x 版本中使用。 + - 2.x 版本的生态工具完全不支持在 Nebula Graph 3.x 版本中使用。 ## Nebula Graph Studio @@ -39,132 +39,70 @@ Nebula Graph Studio(简称 Studio)是一款可以通过 Web 访问的图数 Studio 版本发布节奏独立于 Nebula Graph 内核,其命名方式也不参照内核命名规则,两者兼容对应关系如下表。 -|Nebula Graph 版本|Studio 版本(commit id)| -|:---|:---| -| {{ nebula.release }} | {{studio.release}}(3754219)| ## Nebula Dashboard(社区版) Nebula Dashboard(简称 Dashboard)是一款用于监控 Nebula Graph 集群中机器和服务状态的可视化工具。详情参见[什么是 Nebula Dashboard](../nebula-dashboard/1.what-is-dashboard.md)。 -|Nebula Graph 版本|Dashboard 版本(commit id)| -|:---|:---| -| {{ nebula.release }} | {{dashboard.release}}(a610013) | ## Nebula Dashboard(企业版) Nebula Dashboard(简称 Dashboard)是一款用于监控和管理 Nebula Graph 多集群中机器和服务状态的可视化工具,支持在可视化界面进行集群创建、集群导入、数据平衡、扩容缩容等操作。详情参见[什么是 Nebula Dashboard](../nebula-dashboard-ent/1.what-is-dashboard-ent.md)。 -|Nebula Graph 版本|Dashboard 企业版本(commit id)| -|:---|:---| -| {{ nebula.release }} | {{dashboard_ent.release}}(3474c78) | - -## Nebula Dashboard(企业版) - -Nebula Dashboard(简称Dashboard)是一款用于监控和管理Nebula Graph多集群中机器和服务状态的可视化工具,支持在可视化界面进行集群创建、集群导入、数据平衡、扩容缩容等操作。详情参见[什么是Nebula Dashboard](../nebula-dashboard-ent/1.what-is-dashboard-ent.md)。 - -|Nebula Graph版本|Dashboard企业版本(commit id)| -|:---|:---| -| {{ nebula.release }} | {{dashboard_ent.release}}(79248d9) | - ## Nebula Explorer Nebula Explorer(简称 Explorer)是一款可以通过 Web 访问的图探索可视化工具,搭配 Nebula Graph 内核使用,用于与图数据进行可视化交互。即使没有图数据操作经验,用户也可以快速成为图专家。详情参见[什么是 Nebula Explorer](../nebula-explorer/about-explorer/ex-ug-what-is-explorer.md)。 -|Nebula Graph 版本|Explorer 版本(commit id)| -|:---|:---| -| {{ nebula.release }} | {{explorer.release}}(3acdd02) | +## Nebula Stats Exporter + +[nebula-stats-exporter](https://github.com/vesoft-inc/nebula-stats-exporter)将监控数据导入Prometheus。 ## Nebula Exchange Nebula Exchange(简称 Exchange)是一款 Apache Spark™ 应用,用于在分布式环境中将集群中的数据批量迁移到 Nebula Graph 中,能支持多种不同格式的批式数据和流式数据的迁移。详情请参见[什么是 Nebula Exchange](../nebula-exchange/about-exchange/ex-ug-what-is-exchange.md)。 -|Nebula Graph 版本|Exchange 社区版版本(commit id)|Exchange 企业版版本(commit id)| -|:---|:---|:--| -| {{ nebula.release }} | {{exchange.release}}(e6d8601) |{{exchange_ent.release}}(8712390) | ## Nebula Operator Nebula Operator(简称 Operator)是用于在 Kubernetes 系统上自动化部署和运维 Nebula Graph 集群的工具。依托于 Kubernetes 扩展机制,Nebula Graph 将其运维领域的知识全面注入至 Kubernetes 系统中,让 Nebula Graph 成为真正的云原生图数据库。详情请参考[什么是 Nebula Operator](../nebula-operator/1.introduction-to-nebula-operator.md)。 -|Nebula Graph 版本|Operator 版本(commit id)| -|:---|:---| -| {{ nebula.release }} | {{operator.release}}(ba88e28) | ## Nebula Importer Nebula Importer(简称 Importer)是一款 Nebula Graph 的 CSV 文件导入工具。Importer 可以读取本地的 CSV 文件,然后导入数据至 Nebula Graph 图数据库中。详情请参见[什么是 Nebula Importer](../nebula-importer/use-importer.md)。 -|Nebula Graph 版本|[Importer](https://github.com/vesoft-inc/nebula-importer/tree/{{importer.branch}}) 版本(commit id)| -|:---|:---| -| {{ nebula.release }} | {{importer.release}}(43234f3) | - ## Nebula Spark Connector Nebula Spark Connector 是一个 Spark 连接器,提供通过 Spark 标准形式读写 Nebula Graph 数据的能力。Nebula Spark Connector 由 Reader 和 Writer 两部分组成。详情请参见[什么是 Nebula Spark Connector](../nebula-spark-connector.md)。 -|Nebula Graph 版本|Spark Connector 版本(commit id)| -|:---|:---| -| {{ nebula.release }} | {{sparkconnector.release}}(aac22e1) | - ## Nebula Flink Connector Nebula Flink Connector 是一款帮助 Flink 用户快速访问 Nebula Graph 的连接器,支持从 Nebula Graph 图数据库中读取数据,或者将其他外部数据源读取的数据写入 Nebula Graph 图数据库。详情请参见[什么是 Nebula Flink Connector](../nebula-flink-connector.md)。 -|Nebula Graph 版本|Flink Connector 版本(commit id)| -|:---|:---| -| {{ nebula.release }} | {{flinkconnector.release}}(79bd8d4) | - ## Nebula Algorithm Nebula Algorithm(简称 Algorithm)是一款基于 [GraphX](https://spark.apache.org/graphx/) 的 Spark 应用程序,通过提交 Spark 任务的形式使用完整的算法工具对 Nebula Graph 数据库中的数据执行图计算,也可以通过编程形式调用 lib 库下的算法针对 DataFrame 执行图计算。详情请参见[什么是 Nebula Algorithm](../nebula-algorithm.md)。 -|Nebula Graph 版本|Algorithm 版本(commit id)| -|:---|:---| -| {{ nebula.release }} | {{algorithm.release}}(2c61ca5) | - -## Nebula Plato +## Nebula Analytics -Nebula Plato 是一款集成了开源高性能图计算框架 Plato 的应用程序,支持利用 Plato 对 Nebula Graph 数据库中的数据执行图计算。详情请参见[什么是 Nebula Plato](../nebula-plato.md)。 - -|Nebula Graph 版本|Plato 版本(commit id)| -|:---|:---| -| {{ nebula.release }} | {{plato.release}}(d895634) | +Nebula Analytics是一款集成了开源高性能图计算框架 Plato 的应用程序,支持利用 Plato 对 Nebula Graph 数据库中的数据执行图计算。详情请参见[什么是 Nebula Analytics](../nebula-analytics.md)。 ## Nebula Console Nebula Console 是 Nebula Graph 的原生 CLI 客户端。如何使用请参见[连接 Nebula Graph](../2.quick-start/3.connect-to-nebula-graph.md)。 -|Nebula Graph 版本|Console 版本(commit id)| -|:---|:---| -| {{ nebula.release }} | {{console.release}}(0834198) | - ## Nebula Docker Compose Docker Compose 可以快速部署 Nebula Graph 集群。如何使用请参见 [Docker Compose 部署 Nebula Graph](../4.deployment-and-installation/2.compile-and-install-nebula-graph/3.deploy-nebula-graph-with-docker-compose.md)。 -|Nebula Graph 版本|Docker Compose 版本(commit id)| -|:---|:---| -| {{ nebula.release }} | {{dockercompose.release}}(a6e9d78) | - - - ## Nebula Bench [Nebula Bench](https://github.com/vesoft-inc/nebula-bench) 用于测试 Nebula Graph 的基线性能数据,使用 LDBC v0.3.3 的标准数据集。 -|Nebula Graph 版本|Nebula Bench 版本(commit id)| -|:---|:---| -| {{ nebula.release }} | {{bench.release}}(661f871) | - ## API、SDK !!! compatibility @@ -173,10 +111,11 @@ Docker Compose 可以快速部署 Nebula Graph 集群。如何使用请参见 [D |Nebula Graph 版本| 语言(commit id) | |:---| :--- | -| {{ nebula.release }}| [C++](https://github.com/vesoft-inc/nebula-cpp/tree/{{cpp.branch}})(00e2625) | -| {{ nebula.release }}| [Go](https://github.com/vesoft-inc/nebula-go/tree/{{go.branch}})(02eb246) | -| {{ nebula.release }}| [Python](https://github.com/vesoft-inc/nebula-python/tree/{{python.branch}})(f9e8b11) | -| {{ nebula.release }}| [Java](https://github.com/vesoft-inc/nebula-java/tree/{{java.branch}})(064f3a4) | +| {{ nebula.release }}| [C++](https://github.com/vesoft-inc/nebula-cpp/tree/{{cpp.branch}})| +| {{ nebula.release }}| [Go](https://github.com/vesoft-inc/nebula-go/tree/{{go.branch}})| +| {{ nebula.release }}| [Python](https://github.com/vesoft-inc/nebula-python/tree/{{python.branch}}) | +| {{ nebula.release }}| [Java](https://github.com/vesoft-inc/nebula-java/tree/{{java.branch}}) | +| {{ nebula.release }} | [HTTP](https://github.com/vesoft-inc/nebula-http-gateway) | ## 未发布 @@ -186,18 +125,8 @@ Docker Compose 可以快速部署 Nebula Graph 集群。如何使用请参见 [D - [Node.js Client](https://github.com/vesoft-inc/nebula-node) - - [HTTP Client](https://github.com/vesoft-inc/nebula-http-gateway) - - [Object Graph Mapping Library (OGM, or ORM)] Java, Python (TODO: in design) -- 监控 - - - [Promethus connector](https://github.com/vesoft-inc/nebula-stats-exporter) - - - [Graph Computing] (TODO: in coding) - - 测试 - [Chaos Test](https://github.com/vesoft-inc/nebula-chaos) - -- Backup & Restore diff --git a/docs-2.0/20.appendix/learning-path.md b/docs-2.0/20.appendix/learning-path.md index 8760ad8874..c72806b704 100644 --- a/docs-2.0/20.appendix/learning-path.md +++ b/docs-2.0/20.appendix/learning-path.md @@ -10,7 +10,7 @@ | 文档 | 视频 | | ------------------------------------------------------------ | ------------------------------------------------------------ | -| [什么是 Nebula Graph](https://docs.nebula-graph.com.cn/{{nebula.release}}/1.introduction/1.what-is-nebula-graph/) | [Nebula Graph 介绍](https://www.bilibili.com/video/BV1kf4y1v7LM)、[万亿级别的图数据库 Nebula Graph](https://www.bilibili.com/video/BV1aK4y1e7Q4?spm_id_from=333.999.0.0) 、[Nebula v2.x 讲解](https://www.bilibili.com/video/BV14U4y157zc?spm_id_from=333.999.0.0)、[吴敏博士带你了解硬核 v2.5.0](https://www.bilibili.com/video/BV14b4y1S7BS)| +| [什么是 Nebula Graph](https://docs.nebula-graph.com.cn/{{nebula.release}}/1.introduction/1.what-is-nebula-graph/) | [Nebula Graph 介绍](https://www.bilibili.com/video/BV1kf4y1v7LM)、[万亿级别的图数据库 Nebula Graph](https://www.bilibili.com/video/BV1aK4y1e7Q4?spm_id_from=333.999.0.0)| ### 1.2 图相关术语 @@ -42,8 +42,8 @@ | 文档 | 视频 | | ------------------------------------------------------------ | ------------------------------------------------------------ | | [Meta 服务](https://docs.nebula-graph.com.cn/{{nebula.release}}/1.introduction/3.nebula-graph-architecture/2.meta-service/) | - | - | [Graph 服务](https://docs.nebula-graph.com.cn/{{nebula.release}}/1.introduction/3.nebula-graph-architecture/3.graph-service/) | [Nebula Graph Query Engine](https://www.bilibili.com/video/BV1xV411n7DD) | - | [Storage 服务](https://docs.nebula-graph.com.cn/{{nebula.release}}/1.introduction/3.nebula-graph-architecture/4.storage-service/) | [Nebula Graph Storage](https://www.bilibili.com/video/BV16b4y1Q77k) | + | [Graph 服务](https://docs.nebula-graph.com.cn/{{nebula.release}}/1.introduction/3.nebula-graph-architecture/3.graph-service/) | - | + | [Storage 服务](https://docs.nebula-graph.com.cn/{{nebula.release}}/1.introduction/3.nebula-graph-architecture/4.storage-service/) | - | @@ -55,7 +55,7 @@ | ------------------------------------------------------------ | ------------------------------------------------------------ | | [使用 RPM/DEB 包](https://docs.nebula-graph.com.cn/{{nebula.release}}/4.deployment-and-installation/2.compile-and-install-nebula-graph/2.install-nebula-graph-by-rpm-or-deb/) | - | | [使用 TAR 包](https://docs.nebula-graph.com.cn/{{nebula.release}}/4.deployment-and-installation/2.compile-and-install-nebula-graph/4.install-nebula-graph-from-tar/) | - | - | [使用 Docker](https://docs.nebula-graph.com.cn/{{nebula.release}}/4.deployment-and-installation/2.compile-and-install-nebula-graph/3.deploy-nebula-graph-with-docker-compose/) | [使用 Docker Compose 部署 Nebula Graph 2.0 和 Web Studio](https://www.bilibili.com/video/BV1T54y1b7pa) | + | [使用 Docker](https://docs.nebula-graph.com.cn/{{nebula.release}}/4.deployment-and-installation/2.compile-and-install-nebula-graph/3.deploy-nebula-graph-with-docker-compose/) | - | | [使用源码](https://docs.nebula-graph.com.cn/{{nebula.release}}/4.deployment-and-installation/2.compile-and-install-nebula-graph/1.install-nebula-graph-by-compiling-the-source-code/) | [图数据库入门教程(零)通过编译源码来安装 Nebula Graph](https://www.bilibili.com/video/BV1YJ411i7Jn?spm_id_from=333.999.0.0) | |-|[如何选择部署方式?](https://www.bilibili.com/video/BV1vy4y1K7S5)| @@ -89,8 +89,7 @@ | 文档 | | ------------------------------------------------------------ | - | [升级 v2.0.x 至当前版本](https://docs.nebula-graph.com.cn/{{nebula.release}}/4.deployment-and-installation/3.upgrade-nebula-graph/upgrade-nebula-from-200-to-latest/) | - | [升级 v2.0.0-GA 以下版本至当前版本](https://docs.nebula-graph.com.cn/{{nebula.release}}/4.deployment-and-installation/3.upgrade-nebula-graph/upgrade-nebula-graph-to-latest/) | + | [升级 Nebula Graph](https://docs.nebula-graph.com.cn/{{nebula.release}}/4.deployment-and-installation/3.upgrade-nebula-graph/upgrade-nebula-graph-to-latest/) | ### 3.3 配置Nebula @@ -137,11 +136,13 @@ | ------------------------------------------------------------ | |[创建快照](https://docs.nebula-graph.com.cn/{{nebula.release}}/7.data-security/3.manage-snapshot/#_5)| + - SSL 加密 @@ -187,12 +188,12 @@ | ------------------------------------------------------------ | | [Nebula Bench](https://docs.nebula-graph.com.cn/{{nebula.release}}/nebula-bench/) | -- 集群运维 + - 图算法 | 文档 |视频| diff --git a/docs-2.0/3.ngql-guide/1.nGQL-overview/1.overview.md b/docs-2.0/3.ngql-guide/1.nGQL-overview/1.overview.md index d1efdce20e..22b9ded171 100644 --- a/docs-2.0/3.ngql-guide/1.nGQL-overview/1.overview.md +++ b/docs-2.0/3.ngql-guide/1.nGQL-overview/1.overview.md @@ -43,17 +43,26 @@ Nebula Graph 查询语言 nGQL 参照以下标准设计: | 符号 | 含义 | | ---- | ---- | | < > | 语法元素的名称。 | -| ::= | 定义元素的公式。 | +| : | 定义元素的公式。 | | [ ] | 可选元素。 | | { } | 显式的指定元素。 | | \| | 所有可选的元素。 | | ... | 可以重复多次。 | -例如创建点或边的 nGQL 语法: +例如创建点的 nGQL 语法: ```ngql -CREATE {TAG | EDGE} { | }( -[, ...]); +INSERT VERTEX [IF NOT EXISTS] [tag_props, [tag_props] ...] +VALUES : ([prop_value_list]) + +tag_props: + tag_name ([prop_name_list]) + +prop_name_list: + [prop_name [, prop_name] ...] + +prop_value_list: + [prop_value [, prop_value] ...] ``` 示例语句: diff --git a/docs-2.0/3.ngql-guide/10.tag-statements/1.create-tag.md b/docs-2.0/3.ngql-guide/10.tag-statements/1.create-tag.md index cd79ce64cd..1d1d4b45ac 100644 --- a/docs-2.0/3.ngql-guide/10.tag-statements/1.create-tag.md +++ b/docs-2.0/3.ngql-guide/10.tag-statements/1.create-tag.md @@ -31,7 +31,7 @@ CREATE TAG [IF NOT EXISTS] |参数|说明| |:---|:---| |`IF NOT EXISTS`|检测待创建的 Tag 是否存在,只有不存在时,才会创建 Tag。仅检测 Tag 的名称,不会检测具体属性。| -|``|每个图空间内的 Tag 必须是唯一的。Tag 名称设置后无法修改。Tag 名称支持 1~4 字节的 UTF-8 编码字符,包括英文字母(区分大小写)、数字、中文等,但是不包括除下划线外的特殊字符。使用特殊字符或保留关键字时,需要用反引号(\`)包围,详情参见[关键字和保留字](../../3.ngql-guide/1.nGQL-overview/keywords-and-reserved-words.md)。| +|``|每个图空间内的 Tag 必须是唯一的。Tag 名称设置后无法修改。Tag 名称以英文字母开头,支持 1~4 字节的 UTF-8 编码字符,包括英文字母(区分大小写)、数字、中文等,但是不包括除下划线外的特殊字符。使用特殊字符或保留关键字时,需要用反引号(\`)包围,详情参见[关键字和保留字](../../3.ngql-guide/1.nGQL-overview/keywords-and-reserved-words.md)。| |``|属性名称。每个 Tag 中的属性名称必须唯一。属性的命名规则与 Tag 相同。| |``|属性的数据类型,目前支持[数值](../3.data-types/1.numeric.md)、[布尔](../3.data-types/2.boolean.md)、[字符串](../3.data-types/3.string.md)以及[日期与时间](../3.data-types/4.date-and-time.md)。| |`NULL \| NOT NULL`|指定属性值是否支持为`NULL`。默认值为`NULL`。| diff --git a/docs-2.0/3.ngql-guide/10.tag-statements/2.drop-tag.md b/docs-2.0/3.ngql-guide/10.tag-statements/2.drop-tag.md index 824038b159..acc329c0c9 100644 --- a/docs-2.0/3.ngql-guide/10.tag-statements/2.drop-tag.md +++ b/docs-2.0/3.ngql-guide/10.tag-statements/2.drop-tag.md @@ -4,7 +4,7 @@ 点可以有一个或多个 Tag。 -- 如果某个点只有一个 Tag,删除这个 Tag 后,用户就**无法访问**这个点,下次 Compaction 操作时会删除该点,但点上的边仍然存在。 +- 如果某个点只有一个 Tag,删除这个 Tag 后,用户就**无法访问**这个点,下次 Compaction 操作时会删除该点,但与该点相邻的**边仍然存在**——这会造成悬挂边。 - 如果某个点有多个 Tag,删除其中一个 Tag,仍然可以访问这个点,但是**无法访问**已删除 Tag 所定义的所有属性。 diff --git a/docs-2.0/3.ngql-guide/11.edge-type-statements/1.create-edge.md b/docs-2.0/3.ngql-guide/11.edge-type-statements/1.create-edge.md index 2800e143b5..7509426f0c 100644 --- a/docs-2.0/3.ngql-guide/11.edge-type-statements/1.create-edge.md +++ b/docs-2.0/3.ngql-guide/11.edge-type-statements/1.create-edge.md @@ -31,7 +31,7 @@ CREATE EDGE [IF NOT EXISTS] |参数|说明| |:---|:---| |`IF NOT EXISTS`|检测待创建的 Edge type 是否存在,只有不存在时,才会创建 Edge type。仅检测 Edge type 的名称,不会检测具体属性。| -|``|每个图空间内的 Edge type 必须是唯一的。Edge type 名称设置后无法修改。Edge type 名称支持 1~4 字节的 UTF-8 编码字符,包括英文字母(区分大小写)、数字、中文等,但是不包括除下划线外的特殊字符。使用特殊字符或保留关键字时,需要用反引号(\`)包围,详情参见[关键字和保留字](../../3.ngql-guide/1.nGQL-overview/keywords-and-reserved-words.md)。| +|``|每个图空间内的 Edge type 必须是唯一的。Edge type 名称设置后无法修改。Edge type 名称以英文字母开头,支持 1~4 字节的 UTF-8 编码字符,包括英文字母(区分大小写)、数字、中文等,但是不包括除下划线外的特殊字符。使用特殊字符或保留关键字时,需要用反引号(\`)包围,详情参见[关键字和保留字](../../3.ngql-guide/1.nGQL-overview/keywords-and-reserved-words.md)。| |``|属性名称。每个 Edge type 中的属性名称必须唯一。属性的命名规则与 Edge type 相同。| |``|属性的数据类型,目前支持[数值](../3.data-types/1.numeric.md)、[布尔](../3.data-types/2.boolean.md)、[字符串](../3.data-types/3.string.md)以及[日期与时间](../3.data-types/4.date-and-time.md)。| |`NULL \| NOT NULL`|指定属性值是否支持为`NULL`。默认值为`NULL`。| diff --git a/docs-2.0/3.ngql-guide/12.vertex-statements/1.insert-vertex.md b/docs-2.0/3.ngql-guide/12.vertex-statements/1.insert-vertex.md index 7809a69409..76821215a5 100644 --- a/docs-2.0/3.ngql-guide/12.vertex-statements/1.insert-vertex.md +++ b/docs-2.0/3.ngql-guide/12.vertex-statements/1.insert-vertex.md @@ -119,6 +119,7 @@ nebula> LOOKUP ON person WHERE person.id == 2 YIELD id(vertex) as id; +-------+ | "200" | +-------+ +``` ---> ```ngql diff --git a/docs-2.0/3.ngql-guide/13.edge-statements/1.insert-edge.md b/docs-2.0/3.ngql-guide/13.edge-statements/1.insert-edge.md index 67888bfbbc..9448de69f5 100644 --- a/docs-2.0/3.ngql-guide/13.edge-statements/1.insert-edge.md +++ b/docs-2.0/3.ngql-guide/13.edge-statements/1.insert-edge.md @@ -33,7 +33,7 @@ INSERT EDGE [IF NOT EXISTS] ( ) VALUES - `dst_vid`:目的点 ID,表示边的终点。 -- `rank`:可选项。边的 rank 值。默认值为`0`。rank 值可以用来区分 Edge type、起始点、目的点都相同的边。 +- `rank`:可选项。边的 rank 值。默认值为`0`。 !!! compatibility "openCypher 兼容性" diff --git a/docs-2.0/3.ngql-guide/13.edge-statements/4.delete-edge.md b/docs-2.0/3.ngql-guide/13.edge-statements/4.delete-edge.md index aa3764a3d4..edae3fa8dc 100644 --- a/docs-2.0/3.ngql-guide/13.edge-statements/4.delete-edge.md +++ b/docs-2.0/3.ngql-guide/13.edge-statements/4.delete-edge.md @@ -4,15 +4,16 @@ 如果需要删除一个点的所有出边,请删除这个点。详情请参见 [DELETE VERTEX](../12.vertex-statements/4.delete-vertex.md)。 -!!! Note - - 目前还不能保证操作的原子性,如果发生故障请重试。 ## 语法 ```ngql DELETE EDGE -> [@] [, -> [@] ...] ``` +!!! caution + + 如果不指定 rank,则仅仅删除 rank 为 0 的边。需要删除所有的 rank,见如下示例。 + ## 示例 ```ngql @@ -20,9 +21,9 @@ nebula> DELETE EDGE serve "player100" -> "team204"@0; ``` ```ngql -# 结合管道符,删除符合条件的边。 +# 结合管道符,删除两点之间同类型的所有rank的边。 nebula> GO FROM "player100" OVER follow \ WHERE dst(edge) == "team204" \ YIELD src(edge) AS src, dst(edge) AS dst, rank(edge) AS rank \ - | DELETE EDGE follow $-.src->$-.dst @ $-.rank; + | DELETE EDGE follow $-.src -> $-.dst @ $-.rank; ``` diff --git a/docs-2.0/3.ngql-guide/14.native-index-statements/1.create-native-index.md b/docs-2.0/3.ngql-guide/14.native-index-statements/1.create-native-index.md index 3d51a2afca..4cbee2a429 100644 --- a/docs-2.0/3.ngql-guide/14.native-index-statements/1.create-native-index.md +++ b/docs-2.0/3.ngql-guide/14.native-index-statements/1.create-native-index.md @@ -70,7 +70,7 @@ CREATE {TAG | EDGE} INDEX [IF NOT EXISTS] ON { | `|索引名。索引名在一个图空间中必须是唯一的。推荐的命名方式为`i_tagName_propName`。索引名称支持 1~4 字节的 UTF-8 编码字符,包括英文字母(区分大小写)、数字、中文等,但是不包括除下划线外的特殊字符。使用特殊字符或保留关键字时,需要用反引号(\`)包围,详情参见[关键字和保留字](../../3.ngql-guide/1.nGQL-overview/keywords-and-reserved-words.md)。| +|``|索引名。索引名在一个图空间中必须是唯一的。推荐的命名方式为`i_tagName_propName`。索引名称以英文字母开头,支持 1~4 字节的 UTF-8 编码字符,包括英文字母(区分大小写)、数字、中文等,但是不包括除下划线外的特殊字符。使用特殊字符或保留关键字时,需要用反引号(\`)包围,详情参见[关键字和保留字](../../3.ngql-guide/1.nGQL-overview/keywords-and-reserved-words.md)。| |` \| `|指定索引关联的 Tag 或 Edge 名称。| |``|为**变长**字符串属性创建索引时,必须用`prop_name(length)`指定索引长度;为 Tag 或 Edge type 本身创建索引时,忽略``。| |`COMMENT`|索引的描述。最大为 256 字节。默认无描述。| diff --git a/docs-2.0/3.ngql-guide/14.native-index-statements/2.1.show-create-index.md b/docs-2.0/3.ngql-guide/14.native-index-statements/2.1.show-create-index.md index 24e425b594..4976ca8888 100644 --- a/docs-2.0/3.ngql-guide/14.native-index-statements/2.1.show-create-index.md +++ b/docs-2.0/3.ngql-guide/14.native-index-statements/2.1.show-create-index.md @@ -49,7 +49,3 @@ nebula> SHOW CREATE EDGE INDEX follow_index; | | )" | +-----------------+-------------------------------------------------+ ``` - -!!! Compatibility "历史版本兼容性" - - Nebula Graph 2.0.1 中, `SHOW TAG/EDGE INDEXES` 语句仅返回 `Names`。 diff --git a/docs-2.0/3.ngql-guide/14.native-index-statements/2.show-native-indexes.md b/docs-2.0/3.ngql-guide/14.native-index-statements/2.show-native-indexes.md index 51b5532a08..7d386be628 100644 --- a/docs-2.0/3.ngql-guide/14.native-index-statements/2.show-native-indexes.md +++ b/docs-2.0/3.ngql-guide/14.native-index-statements/2.show-native-indexes.md @@ -28,7 +28,3 @@ nebula> SHOW EDGE INDEXES; | "follow_index" | "follow" | [] | +----------------+----------+---------+ ``` - -!!! Compatibility "历史版本兼容性" - - Nebula Graph 2.0.1 中, `SHOW TAG/EDGE INDEXES` 语句仅返回 `Names`。 diff --git a/docs-2.0/3.ngql-guide/14.native-index-statements/4.rebuild-native-index.md b/docs-2.0/3.ngql-guide/14.native-index-statements/4.rebuild-native-index.md index 8c84071a17..fc4b65a6eb 100644 --- a/docs-2.0/3.ngql-guide/14.native-index-statements/4.rebuild-native-index.md +++ b/docs-2.0/3.ngql-guide/14.native-index-statements/4.rebuild-native-index.md @@ -55,8 +55,5 @@ nebula> SHOW JOB 31; +----------------+---------------------+------------+-------------------------+-------------------------+ ``` -Nebula Graph 创建一个任务去重建索引,因此可以根据返回的任务 ID,通过`SHOW JOB `语句查看任务状态。详情请参见 [SHOW JOB](../18.operation-and-maintenance-statements/4.job-statements/#show_job)。 +Nebula Graph 创建一个任务去重建索引,因此可以根据返回的任务 ID,通过`SHOW JOB `语句查看任务状态。详情请参见 [SHOW JOB](../18.operation-and-maintenance-statements/4.job-statements.md#show_job)。 -## 历史版本兼容性 - -在 Nebula Graph 2.0 中,不需要也不支持选项`OFFLINE`。 diff --git a/docs-2.0/3.ngql-guide/14.native-index-statements/README.md b/docs-2.0/3.ngql-guide/14.native-index-statements/README.md index 8ead9a9e9d..f228236ac2 100644 --- a/docs-2.0/3.ngql-guide/14.native-index-statements/README.md +++ b/docs-2.0/3.ngql-guide/14.native-index-statements/README.md @@ -2,6 +2,8 @@ Nebula Graph 支持两种类型索引:原生索引和全文索引。 +和一般数据库意义上的索引概念不同,Nebula Graph中的索引没有加速查询的功能,是用于定位到数据的必要前置条件。 + ## 原生索引 原生索引可以基于指定的属性查询数据,有如下特点: @@ -34,7 +36,7 @@ Nebula Graph 支持两种类型索引:原生索引和全文索引。 ## 全文索引 -全文索引用于对字符串属性进行前缀搜索、通配符搜索、正则表达式搜索和模糊搜索,有如下特点: +全文索引是基于Elastic Search来实现的,用于对字符串属性进行前缀搜索、通配符搜索、正则表达式搜索和模糊搜索,有如下特点: - 只允许创建一个属性的索引。 @@ -54,10 +56,15 @@ Nebula Graph 支持两种类型索引:原生索引和全文索引。 使用全文索引请参见[使用全文索引查询](../15.full-text-index-statements/1.search-with-text-based-index.md)。 -## NULL 值说明 +## 没有 NULL 值索引 不支持对值为 NULL 的属性创建索引。 -## 范围查询 +## 没有唯一索引 + +在 Cypher 中,可以通过 Constrains 实现属性值的唯一性限制。在 MySQL 中,可以建立唯一索引来限制某字段只有唯一值。在 nGQL 中没有属性的唯一索引(用户自行保证属性值的唯一性)。 + +## 数字、日期和时间类型的范围查询 + +原生索引还支持对数字、日期和时间类型的属性进行范围查询,不支持其他属性类型的范围查询。 -原生索引除了可以查询单个结果之外,还可以执行范围查询。当前仅支持对数字、日期和时间类型的属性进行范围查询。 diff --git a/docs-2.0/3.ngql-guide/16.subgraph-and-path/2.find-path.md b/docs-2.0/3.ngql-guide/16.subgraph-and-path/2.find-path.md index b45fc5f431..8528750568 100644 --- a/docs-2.0/3.ngql-guide/16.subgraph-and-path/2.find-path.md +++ b/docs-2.0/3.ngql-guide/16.subgraph-and-path/2.find-path.md @@ -6,7 +6,10 @@ ```ngql FIND { SHORTEST | ALL | NOLOOP } PATH [WITH PROP] FROM TO -OVER [REVERSELY | BIDIRECT] [] [UPTO STEPS] [| ORDER BY $-.path] [| LIMIT ]; +OVER [REVERSELY | BIDIRECT] +[] [UPTO STEPS] +YIELD path as +[| ORDER BY $-.path] [| LIMIT ]; ::= [vertex_id [, vertex_id] ...] @@ -44,7 +47,7 @@ OVER [REVERSELY | BIDIRECT] [] [UPTO STEPS] [ - 使用`WHERE`子句时只能过滤边属性,暂不支持过滤点属性,且不支持函数。 -- 路径的查找是单进程,会占用很多内存。 +- graphd 是单进程查询,会占用很多内存。 ## 示例 @@ -98,6 +101,6 @@ nebula> FIND NOLOOP PATH FROM "player100" TO "team204" OVER * YIELD path AS p; ### 是否支持 WHERE 子句,以实现图遍历过程中的条件过滤? -支持使用`WHERE`子句过滤,但目前只能过滤边属性,如示例中的`FIND ALL PATH FROM "player100" TO "team204" OVER * WHERE follow.degree is EMPTY or follow.degree >=0;`。 +支持使用`WHERE`子句过滤,但只能过滤边属性,不支持过滤点属性。 -暂不支持过滤点属性。 +如示例中的 `FIND ALL PATH FROM "player100" TO "team204" OVER * WHERE follow.degree is EMPTY or follow.degree >= 0;`。 diff --git a/docs-2.0/3.ngql-guide/18.operation-and-maintenance-statements/2.balance-syntax.md b/docs-2.0/3.ngql-guide/18.operation-and-maintenance-statements/2.balance-syntax.md index c995f13db2..8b19c1a982 100644 --- a/docs-2.0/3.ngql-guide/18.operation-and-maintenance-statements/2.balance-syntax.md +++ b/docs-2.0/3.ngql-guide/18.operation-and-maintenance-statements/2.balance-syntax.md @@ -4,14 +4,20 @@ !!! compatibility "历史版本兼容性" - Neubla Graph 3.0.0 新增 Zone 功能导致 Balance 命令发生变化,3.0.0 之前版本的命令不再兼容。 + 不支持`BALANCE DATA`命令。 `BALANCE`语法说明如下。 |语法|说明| |:---|:---| -|`BALANCE IN ZONE [REMOVE : [,: ...]]`|在当前图空间内每个 Zone 内部启动任务均衡分布分片。该命令会返回任务 ID。可以使用`REMOVE`选项指定需要清空的 Storage 节点,方便进行维护。| -|`BALANCE ACROSS ZONE [REMOVE "zone_name" [,"zone_name" ...]]`|在当前图空间内所有 Zone 之间启动任务均衡分布分片,保证各个 Zone 分片数量平衡。该命令会返回任务 ID。可以使用`REMOVE`选项指定需要清空的 Zone,方便进行维护。| |`BALANCE LEADER`|在当前图空间内所有 Zone 之间启动任务均衡分布 leader。该命令会返回任务 ID。| + 查看、停止、重启任务,请参见[作业管理](4.job-statements.md)。 diff --git a/docs-2.0/3.ngql-guide/18.operation-and-maintenance-statements/4.job-statements.md b/docs-2.0/3.ngql-guide/18.operation-and-maintenance-statements/4.job-statements.md index 18d12e6f40..484cccfa26 100644 --- a/docs-2.0/3.ngql-guide/18.operation-and-maintenance-statements/4.job-statements.md +++ b/docs-2.0/3.ngql-guide/18.operation-and-maintenance-statements/4.job-statements.md @@ -6,6 +6,7 @@ 所有作业管理命令都需要先选择图空间后才能执行。 + ## SUBMIT JOB COMPACT @@ -109,7 +111,7 @@ nebula> SHOW JOB 34; |:---|:---| |Job Id(TaskId)|第一行显示作业 ID,其他行显示作业相关的任务 ID。| |Command(Dest)|第一行显示执行的作业命令名称,其他行显示任务对应的 nebula-storaged 进程。| -|Status|显示作业或任务的状态。详情请参见[作业状态](#_6)。| +|Status|显示作业或任务的状态。详情请参见[作业状态](#_2)。| |Start Time|显示作业或任务开始执行的时间。| |Stop Time|显示作业或任务结束执行的时间,结束后的状态包括`FINISHED`、`FAILED`或`STOPPED`。| diff --git a/docs-2.0/3.ngql-guide/18.operation-and-maintenance-statements/6.kill-query.md b/docs-2.0/3.ngql-guide/18.operation-and-maintenance-statements/6.kill-query.md index 7e1179223a..31fb943ee4 100644 --- a/docs-2.0/3.ngql-guide/18.operation-and-maintenance-statements/6.kill-query.md +++ b/docs-2.0/3.ngql-guide/18.operation-and-maintenance-statements/6.kill-query.md @@ -2,6 +2,10 @@ `KILL QUERY`命令可以终止正在执行的查询,常用于终止慢查询。 +!!! note + + 当前任意角色权限账号都可以执行`KILL QUERY`命令。 + ## 语法 ```ngql diff --git a/docs-2.0/3.ngql-guide/3.data-types/9.type-conversion.md b/docs-2.0/3.ngql-guide/3.data-types/9.type-conversion.md index 24efce05e9..257ab2d99f 100644 --- a/docs-2.0/3.ngql-guide/3.data-types/9.type-conversion.md +++ b/docs-2.0/3.ngql-guide/3.data-types/9.type-conversion.md @@ -6,7 +6,7 @@ nGQL 1.0 使用 C 语言风格的类型转换(显示或隐式):`(type_name)expression`。例如`YIELD (int)(TRUE)`,结果为`1`。但是对于不熟悉 C 语言的用户来说,很容易出错。 -nGQL 2.0 使用 openCypher 的方式进行类型强制转换。 +从 nGQL 2.0 开始使用 openCypher 的方式进行类型强制转换。 ## 类型强制转换函数 diff --git a/docs-2.0/3.ngql-guide/4.variable-and-composite-queries/3.property-reference.md b/docs-2.0/3.ngql-guide/4.variable-and-composite-queries/3.property-reference.md index 896c39fd17..23fc1f4612 100644 --- a/docs-2.0/3.ngql-guide/4.variable-and-composite-queries/3.property-reference.md +++ b/docs-2.0/3.ngql-guide/4.variable-and-composite-queries/3.property-reference.md @@ -88,7 +88,7 @@ nebula> GO FROM "player100" OVER follow YIELD follow._src, follow._dst, follow._ !!! compatibility "历史版本兼容性" - Nebula Graph 2.6.0 起支持了新的 [Schema 函数](../6.functions-and-expressions/4.schema.md),以上示例中的语句在 2.6.0 版本中的写法如下。 + 从 Nebula Graph 2.6.0 起支持了新的 [Schema 函数](../6.functions-and-expressions/4.schema.md)。以上示例在 Nebula Graph {{ nebula.release}} 中的写法如下: ```ngql GO FROM "player100" OVER follow YIELD properties($^).name AS startName, properties($$).age AS endAge; @@ -96,4 +96,4 @@ nebula> GO FROM "player100" OVER follow YIELD follow._src, follow._dst, follow._ GO FROM "player100" OVER follow YIELD src(edge), dst(edge), type(edge), rank(edge); ``` - 在 2.6.0 版本中 Nebula Graph 依然兼容旧语法。 + Nebula Graph {{ nebula.release}} 兼容新旧语法。 diff --git a/docs-2.0/3.ngql-guide/5.operators/2.boolean.md b/docs-2.0/3.ngql-guide/5.operators/2.boolean.md index 1b6168eaf9..d56cf29645 100644 --- a/docs-2.0/3.ngql-guide/5.operators/2.boolean.md +++ b/docs-2.0/3.ngql-guide/5.operators/2.boolean.md @@ -15,4 +15,4 @@ Nebula Graph 支持的布尔符如下。 ## 历史兼容问题 -在 Nebula Graph 2.0 中,非 0 数字不能转换为布尔值。 +非 0 数字不能转换为布尔值。 diff --git a/docs-2.0/3.ngql-guide/6.functions-and-expressions/12.hash.md b/docs-2.0/3.ngql-guide/6.functions-and-expressions/12.hash.md index e0c0bafa9d..00160c7c50 100644 --- a/docs-2.0/3.ngql-guide/6.functions-and-expressions/12.hash.md +++ b/docs-2.0/3.ngql-guide/6.functions-and-expressions/12.hash.md @@ -12,7 +12,7 @@ MurmurHash2.hash64("to_be_hashed".getBytes(),"to_be_hashed".getBytes().length, 0 ## 历史版本兼容性 -nGQL 1.0 不支持字符串类型的 VID,一种常用的处理方式是用 hash 函数获取字符串的哈希值,然后将该值设置为 VID。但 nGQL 2.0 同时支持了字符串和整数类型的 VID,所以无需再使用这种方式设置 VID。 +nGQL 1.0 不支持字符串类型的 VID,一种常用的处理方式是用 hash 函数获取字符串的哈希值,然后将该值设置为 VID。但从 nGQL 2.0 开始,同时支持了字符串和整数类型的 VID,所以无需再使用这种方式设置 VID。 ## 计算数字的哈希值 diff --git a/docs-2.0/3.ngql-guide/7.general-query-statements/2.match.md b/docs-2.0/3.ngql-guide/7.general-query-statements/2.match.md index 45c58de60d..398c1fa99d 100644 --- a/docs-2.0/3.ngql-guide/7.general-query-statements/2.match.md +++ b/docs-2.0/3.ngql-guide/7.general-query-statements/2.match.md @@ -8,7 +8,9 @@ ## 语法 -与`GO`或`LOOKUP`等其他查询语句相比,`MATCH`的语法更灵活。`MATCH`语法可以概括如下: +与`GO`或`LOOKUP`等其他查询语句相比,`MATCH`的语法更灵活。`MATCH`语句采用的路径类型是[`trail`](../../1.introduction/2.1.path.md),即遍历时只有点可以重复,边不可以重复。 + +`MATCH` 语法如下: ```ngql MATCH [] RETURN []; @@ -24,21 +26,19 @@ MATCH [] RETURN []; ## 注意事项 -!!! compatibility "历史版本兼容性" - - 从 3.0.0 版本开始,`pattern`支持同时匹配多个 Tag,所以返回属性时,需要额外指定 Tag 名称。即从`RETURN 变量名.属性名`改为`RETURN 变量名.Tag.属性名`。 +除以下三种情况之外,请确保 `MATCH` 语句有**至少**一个[索引](../14.native-index-statements/1.create-native-index.md)可用。 -- `MATCH`语句中的`WHERE`子句内不支持图模式。 +- A: `MATCH`语句中`WHERE`子句使用 id() 函数指定了点的 VID,不需要创建索引即可执行。 -- `MATCH`语句采用的路径类型是`trail`,即遍历时只有点可以重复,边不可以重复。详情请参见[路径](../../1.introduction/2.1.path.md)。 +- B1: 当遍历所有点边时,例如`MATCH (v) RETURN v LIMIT N`,不需要创建索引,但必须使用`LIMIT`限制输出结果数量。 -- `MATCH`语句中`WHERE`子句使用 id() 函数指定了点的 VID,不需要创建索引即可执行。 +- B2: 当遍历指定 Tag 的点或指定 Edge Type 的边时,例如`MATCH (v:player) RETURN v LIMIT N`,不需要创建索引,但必须使用`LIMIT`限制输出结果数量。 -- 当遍历所有点边时,例如`MATCH (v) RETURN v LIMIT N`,不需要创建索引,但需要使用`LIMIT`限制输出结果数量。 +此外`MATCH`语句中的`WHERE`子句内**不支持**图模式。 -- 当遍历指定 Tag 的点或指定 Edge Type 的边时,例如`MATCH (v:player) RETURN v LIMIT N`,不需要创建索引,但需要使用`LIMIT`限制输出结果数量。 +!!! compatibility "历史版本兼容性" -- 除以上三种情况之外,请确保`MATCH`语句有至少一个索引可用。如何使用索引,请参见[创建原生索引](../14.native-index-statements/1.create-native-index.md)。 + 从 3.0.0 版本开始,为了区别不同 Tag 的属性,返回属性时必须额外指定 Tag 名称。即从`RETURN <变量名>.<属性名>`改为`RETURN <变量名>..<属性名>`。 ## 示例 @@ -541,4 +541,4 @@ nebula> MATCH (m)-[]->(n) WHERE id(m)=="player100" \ !!! Performance - Nebula Graph 中`MATCH`语句的性能和资源占用得到了优化,但对性能要求较高时,仍建议使用 `GO`, `LOOKUP`, `|` 和 `FETCH` 等来替代`MATCH`。 + Nebula Graph {{ nebula.release }} 中`MATCH`语句的性能和资源占用得到了优化.但对性能要求较高时,仍建议使用 `GO`, `LOOKUP`, `|` 和 `FETCH` 等来替代`MATCH`。 diff --git a/docs-2.0/3.ngql-guide/7.general-query-statements/3.go.md b/docs-2.0/3.ngql-guide/7.general-query-statements/3.go.md index acb1945965..388d048d9e 100644 --- a/docs-2.0/3.ngql-guide/7.general-query-statements/3.go.md +++ b/docs-2.0/3.ngql-guide/7.general-query-statements/3.go.md @@ -1,6 +1,6 @@ # GO -`GO`用指定的过滤条件遍历图,并返回结果。 +`GO`从给定起始点开始遍历图。`GO`语句采用的路径类型是[`walk`](../../1.introduction/2.1.path.md),即遍历时点和边都可以重复。 ## openCypher 兼容性 @@ -13,8 +13,8 @@ GO [[ TO] STEPS ] FROM OVER [{REVERSELY | BIDIRECT}] [ WHERE  ] YIELD [DISTINCT] -[{SAMPLE | LIMIT }] -[| GROUP BY {col_name | expr | position} YIELD ] +[{ SAMPLE | }] +[| GROUP BY { | expression> | } YIELD ] [| ORDER BY [{ASC | DESC}]] [| LIMIT [,] ]; @@ -22,7 +22,7 @@ YIELD [DISTINCT] [, ...] ::= - edge_type [, edge_type ...] + [, ...] | * ::= @@ -31,10 +31,6 @@ YIELD [DISTINCT] - ` STEPS`:指定跳数。如果没有指定跳数,默认值`N`为`1`。如果`N`为`0`,Nebula Graph 不会检索任何边。 - !!! note - - `GO`语句采用的路径类型是`walk`,即遍历时点和边可以重复。详情参见[路径](../../1.introduction/2.1.path.md)。 - - `M TO N STEPS`:遍历`M~N`跳的边。如果`M`为`0`,输出结果和`M`为`1`相同,即`GO 0 TO 2`和`GO 1 TO 2`是相同的。 - ``:用逗号分隔的点 ID 列表,或特殊的引用符`$-.id`。详情参见[管道符](../5.operators/4.pipe.md)。 @@ -53,7 +49,7 @@ YIELD [DISTINCT] - `SAMPLE `:用于在结果集中取样。详情参见 [SAMPLE](../8.clauses-and-options/sample.md)。 -- `LIMIT `:用于在遍历过程中逐步限制输出数量。详情参见 [LIMIT](../8.clauses-and-options/limit.md)。 +- ``:用于在遍历过程中逐步限制输出数量。详情参见 [LIMIT](../8.clauses-and-options/limit.md)。 - `GROUP BY`:根据指定属性的值将输出分组。详情参见 [GROUP BY](../8.clauses-and-options/group-by.md)。分组后需要再次使用`YIELD`定义需要返回的输出。 diff --git a/docs-2.0/3.ngql-guide/7.general-query-statements/5.lookup.md b/docs-2.0/3.ngql-guide/7.general-query-statements/5.lookup.md index 135cba75a5..13779202d1 100644 --- a/docs-2.0/3.ngql-guide/7.general-query-statements/5.lookup.md +++ b/docs-2.0/3.ngql-guide/7.general-query-statements/5.lookup.md @@ -18,9 +18,7 @@ - 索引会导致写性能大幅降低(降低 90%甚至更多)。请不要随意在生产环境中使用索引,除非很清楚使用索引对业务的影响。 -- 如果用`LOOKUP`语句基于指定属性查询时该属性没有索引,系统会在可用的索引中随机选择一个。 - - 例如,Tag `player` 有属性 `name` 和 `age`,Tag `player` 本身和属性 `name` 有索引,而属性 `age` 没有索引。当运行 `LOOKUP ON player WHERE player.age == 36 YIELD player.name;` 时,系统会在 Tag `player` 和属性 `name` 的索引中随机使用一个。 +- 通过Explain命令查看选择的索引。 !!! compatibility "历史版本兼容性" @@ -28,7 +26,9 @@ ## 前提条件 -请确保`LOOKUP`语句有至少一个索引可用。如果需要创建索引,但是已经有相关的点、边或属性,用户必须在创建索引后[重建索引](../14.native-index-statements/4.rebuild-native-index.md),才能使其生效。 +请确保`LOOKUP`语句有至少一个索引可用。 + +如果已经存在相关的点、边或属性,必须在新创建索引后[重建索引](../14.native-index-statements/4.rebuild-native-index.md),才能使其生效。 ## 语法 @@ -56,6 +56,7 @@ YIELD [AS ]; - 不支持运算表达式和函数表达式中嵌套 AliasProp 表达式。 - 不支持 XOR 和 NOT 运算符。 - 不支持除`STARTS WITH`之外的字符串操作。 +- 不支持图模式。 ## 检索点 diff --git a/docs-2.0/3.ngql-guide/7.general-query-statements/6.show/6.show-hosts.md b/docs-2.0/3.ngql-guide/7.general-query-statements/6.show/6.show-hosts.md index 3bfd2b05ce..fbdd474d98 100644 --- a/docs-2.0/3.ngql-guide/7.general-query-statements/6.show/6.show-hosts.md +++ b/docs-2.0/3.ngql-guide/7.general-query-statements/6.show/6.show-hosts.md @@ -9,45 +9,45 @@ SHOW HOSTS [GRAPH | STORAGE | META]; ``` !!! note - - 不添加服务名,直接使用`SHOW HOSTS`时,会显示 Storage 服务主机信息,以及 leader 总数、leader 分布和分片分布。 - - 对于使用源码安装的 Nebula Graph,执行添加了服务名的命令后,输出的信息中不显示版本信息。 + + 对于使用源码安装的 Nebula Graph,执行添加了服务名的命令后,输出的信息中不显示版本信息。 ## 示例 ```ngql nebula> SHOW HOSTS; -+-------------+-------+----------+--------------+----------------------------------+------------------------------+ -| Host | Port | Status | Leader count | Leader distribution | Partition distribution | -+-------------+-------+----------+--------------+----------------------------------+------------------------------+ -| "storaged0" | 9779 | "ONLINE" | 8 | "docs:5, basketballplayer:3" | "docs:5, basketballplayer:3" | -| "storaged1" | 9779 | "ONLINE" | 9 | "basketballplayer:4, docs:5" | "docs:5, basketballplayer:4" | -| "storaged2" | 9779 | "ONLINE" | 8 | "basketballplayer:3, docs:5" | "docs:5, basketballplayer:3" | -+-------------+-------+----------+--------------+----------------------------------+------------------------------+ ++-------------+-------+----------+--------------+----------------------------------+------------------------------+---------+ +| Host | Port | Status | Leader count | Leader distribution | Partition distribution | Version | ++-------------+-------+----------+--------------+----------------------------------+------------------------------+---------+ +| "storaged0" | 9779 | "ONLINE" | 8 | "docs:5, basketballplayer:3" | "docs:5, basketballplayer:3" | "3.0.0" | +| "storaged1" | 9779 | "ONLINE" | 9 | "basketballplayer:4, docs:5" | "docs:5, basketballplayer:4" | "3.0.0" | +| "storaged2" | 9779 | "ONLINE" | 8 | "basketballplayer:3, docs:5" | "docs:5, basketballplayer:3" | "3.0.0" | ++-------------+-------+----------+--------------+----------------------------------+------------------------------+---------+ nebula> SHOW HOSTS GRAPH; -+-----------+------+----------+---------+---------------+--------+ ++-----------+------+----------+---------+--------------+---------+ | Host | Port | Status | Role | Git Info Sha | Version | +-----------+------+----------+---------+--------------+---------+ -| "graphd" | 9669 | "ONLINE" | "GRAPH" | "3ba41bd" | "2.6.0" | -| "graphd1" | 9669 | "ONLINE" | "GRAPH" | "3ba41bd" | "2.6.0" | -| "graphd2" | 9669 | "ONLINE" | "GRAPH" | "3ba41bd" | "2.6.0" | +| "graphd" | 9669 | "ONLINE" | "GRAPH" | "3ba41bd" | "3.0.0" | +| "graphd1" | 9669 | "ONLINE" | "GRAPH" | "3ba41bd" | "3.0.0" | +| "graphd2" | 9669 | "ONLINE" | "GRAPH" | "3ba41bd" | "3.0.0" | +-----------+------+----------+---------+--------------+---------+ nebula> SHOW HOSTS STORAGE; +-------------+------+----------+-----------+--------------+---------+ | Host | Port | Status | Role | Git Info Sha | Version | +-------------+------+----------+-----------+--------------+---------+ -| "storaged0" | 9779 | "ONLINE" | "STORAGE" | "3ba41bd" | "2.6.0" | -| "storaged1" | 9779 | "ONLINE" | "STORAGE" | "3ba41bd" | "2.6.0" | -| "storaged2" | 9779 | "ONLINE" | "STORAGE" | "3ba41bd" | "2.6.0" | +| "storaged0" | 9779 | "ONLINE" | "STORAGE" | "3ba41bd" | "3.0.0" | +| "storaged1" | 9779 | "ONLINE" | "STORAGE" | "3ba41bd" | "3.0.0" | +| "storaged2" | 9779 | "ONLINE" | "STORAGE" | "3ba41bd" | "3.0.0" | +-------------+------+----------+-----------+--------------+---------+ nebula> SHOW HOSTS META; +----------+------+----------+--------+--------------+---------+ | Host | Port | Status | Role | Git Info Sha | Version | +----------+------+----------+--------+--------------+---------+ -| "metad2" | 9559 | "ONLINE" | "META" | "3ba41bd" | "2.6.0" | -| "metad0" | 9559 | "ONLINE" | "META" | "3ba41bd" | "2.6.0" | -| "metad1" | 9559 | "ONLINE" | "META" | "3ba41bd" | "2.6.0" | +| "metad2" | 9559 | "ONLINE" | "META" | "3ba41bd" | "3.0.0" | +| "metad0" | 9559 | "ONLINE" | "META" | "3ba41bd" | "3.0.0" | +| "metad1" | 9559 | "ONLINE" | "META" | "3ba41bd" | "3.0.0" | +----------+------+----------+--------+--------------+---------+ ``` diff --git a/docs-2.0/3.ngql-guide/7.general-query-statements/optional-match.md b/docs-2.0/3.ngql-guide/7.general-query-statements/optional-match.md index 0f7db7446f..c8cdd8a1ed 100644 --- a/docs-2.0/3.ngql-guide/7.general-query-statements/optional-match.md +++ b/docs-2.0/3.ngql-guide/7.general-query-statements/optional-match.md @@ -1,6 +1,6 @@ # OPTIONAL MATCH -`OPTIONAL MATCH`通常用于`MATCH`语句中,作为`MATCH`语句的可选项去匹配图数据库中的模式,如果图数据库中没有对应的模式,对应的列返回`NULL`。 +`OPTIONAL MATCH`通常与`MATCH`语句一起使用,作为`MATCH`语句的可选项去匹配命中的模式,如果没有命中对应的模式,对应的列返回`NULL`。 ## openCypher 兼容性 diff --git a/docs-2.0/3.ngql-guide/8.clauses-and-options/limit.md b/docs-2.0/3.ngql-guide/8.clauses-and-options/limit.md index 99db52cc14..d692c911d4 100644 --- a/docs-2.0/3.ngql-guide/8.clauses-and-options/limit.md +++ b/docs-2.0/3.ngql-guide/8.clauses-and-options/limit.md @@ -10,10 +10,6 @@ 在原生 nGQL 或 openCypher 方式中使用`LIMIT`时,使用`ORDER BY`子句限制输出顺序非常重要,否则会输出一个不可预知的子集。 -!!! compatibility "历史版本兼容性" - - Nebula Graph 2.6.0 中,`GO`语句支持了新的`LIMIT`语法。部分`LIMIT`相关的算子支持计算下推。 - ## 原生 nGQL 语句中的 LIMIT 在原生 nGQL 中,`LIMIT`有通用语法和`GO`语句中的专属语法。 diff --git a/docs-2.0/3.ngql-guide/8.clauses-and-options/return.md b/docs-2.0/3.ngql-guide/8.clauses-and-options/return.md index 724f470b94..28ccdebaab 100644 --- a/docs-2.0/3.ngql-guide/8.clauses-and-options/return.md +++ b/docs-2.0/3.ngql-guide/8.clauses-and-options/return.md @@ -32,7 +32,7 @@ - 在 nGQL 1.x 中,`RETURN`适用于原生 nGQL,语法为`RETURN IF IS NOT NULL`。 -- 在 nGQL 2.0 中,`RETURN`不适用于原生 nGQL。 +- 从 nGQL 2.0 开始,`RETURN`不适用于原生 nGQL。 ## Map 顺序说明 diff --git a/docs-2.0/3.ngql-guide/8.clauses-and-options/sample.md b/docs-2.0/3.ngql-guide/8.clauses-and-options/sample.md index 06f0a535db..a05fed7102 100644 --- a/docs-2.0/3.ngql-guide/8.clauses-and-options/sample.md +++ b/docs-2.0/3.ngql-guide/8.clauses-and-options/sample.md @@ -2,10 +2,6 @@ `SAMPLE`子句用于在结果集中均匀取样并返回指定数量的数据。 -!!! compatibility "历史版本兼容性" - - `SAMPLE`是 Nebula Graph 2.6.0 新增的子句。 - `SAMPLE`仅能在`GO`语句中使用,语法如下: ```ngql diff --git a/docs-2.0/3.ngql-guide/9.space-statements/1.create-space.md b/docs-2.0/3.ngql-guide/9.space-statements/1.create-space.md index dc3eebb30c..5a802d9f2d 100644 --- a/docs-2.0/3.ngql-guide/9.space-statements/1.create-space.md +++ b/docs-2.0/3.ngql-guide/9.space-statements/1.create-space.md @@ -16,23 +16,22 @@ CREATE SPACE [IF NOT EXISTS] ( [replica_factor = ,] vid_type = {FIXED_STRING() | INT[64]} ) - [ON zone_list] [COMMENT = '']; - -zone_list: - "zone_name" [,"zone_name" ...] ``` |参数|说明| |:---|:---| |`IF NOT EXISTS`|检测待创建的图空间是否存在,只有不存在时,才会创建图空间。仅检测图空间的名称,不会检测具体属性。| -|``|在 Nebula Graph 实例中唯一标识一个图空间。图空间名称支持 1~4 字节的 UTF-8 编码字符,包括英文字母(区分大小写)、数字、中文等,但是不包括除下划线外的特殊字符。使用特殊字符或保留关键字时,需要用反引号(\`)包围,详情参见[关键字和保留字](../../3.ngql-guide/1.nGQL-overview/keywords-and-reserved-words.md)。| +|``|在 Nebula Graph 实例中唯一标识一个图空间。图空间名称以英文字母开头,支持 1~4 字节的 UTF-8 编码字符,包括英文字母(区分大小写)、数字、中文等,但是不包括除下划线外的特殊字符。使用特殊字符或保留关键字时,需要用反引号(\`)包围,详情参见[关键字和保留字](../../3.ngql-guide/1.nGQL-overview/keywords-and-reserved-words.md)。| |`partition_num`|指定图空间的分片数量。建议设置为 5 倍的集群硬盘数量。例如集群中有 3 个硬盘,建议设置 15 个分片。默认值为 100。| |`replica_factor`|指定每个分片的副本数量。建议在生产环境中设置为 3,在测试环境中设置为 1。由于需要基于多数表决,副本数量必须是**奇数**。默认值为 1。| |`vid_type`|必选参数。指定点 ID 的数据类型。可选值为`FIXED_STRING()`和`INT64`。`INT`等同于`INT64`。`FIXED_STRING()`表示数据类型为字符串,最大长度为`N`,超出长度会报错;`INT64`表示数据类型为整数。| -|`zone_list`|指定图空间所属的 Zone 列表,将在这些 Zone 中创建分片和对应副本。副本数量不能超过指定 Zone 数量。不指定`zone_list`时,默认属于所有 Zone。详情请参见 [管理逻辑机架(Zone)](../../4.deployment-and-installation/5.zone.md)。| |`COMMENT`|图空间的描述。最大为 256 字节。默认无描述。| + + !!! caution 如果将副本数设置为 1,用户将无法使用 [BALANCE](../../8.service-tuning/load-balance.md) 命令为 Nebula Graph 的存储服务平衡负载或扩容。 @@ -61,7 +60,7 @@ CREATE SPACE AS ; |参数|说明| |:---|:---| -|``|目标图空间名称。该图空间必须未创建。图空间名称支持 1~4 字节的 UTF-8 编码字符,包括英文字母(区分大小写)、数字、中文等,但是不包括除下划线外的特殊字符。使用保留关键字时,需要用反引号(\`)包围,详情参见[关键字和保留字](../../3.ngql-guide/1.nGQL-overview/keywords-and-reserved-words.md)。创建时会克隆``图空间的 Schema,包括图空间本身参数(分片数量、副本数量等)、Tag、Edge type、原生索引和 Zone。| +|``|目标图空间名称。该图空间必须未创建。图空间名称以英文字母开头,支持 1~4 字节的 UTF-8 编码字符,包括英文字母(区分大小写)、数字、中文等,但是不包括除下划线外的特殊字符。使用保留关键字时,需要用反引号(\`)包围,详情参见[关键字和保留字](../../3.ngql-guide/1.nGQL-overview/keywords-and-reserved-words.md)。创建时会克隆``图空间的 Schema,包括图空间本身参数(分片数量、副本数量等)、Tag、Edge type 和 原生索引。| |``|原始图空间名称。该图空间必须已存在。| ## 示例 @@ -86,11 +85,9 @@ nebula> SHOW CREATE SPACE my_space_4; +--------------+-------------------------------------------------------------------------------------------------------------------------------------------------------------------------+ ``` -## 图空间说明 - !!! caution - 立刻尝试使用刚创建的图空间可能会失败,因为创建是异步实现的。为确保数据同步,后续操作能顺利进行,请等待 2 个心跳周期(20 秒)。如果需要修改心跳间隔,请为[所有配置文件](../../5.configurations-and-logs/1.configurations/1.configurations.md)修改参数`heartbeat_interval_secs`。但过短的心跳周期(<5 秒)可能会导致分布式系统中的机器误判对端失联。 + 立刻尝试使用刚创建的图空间可能会失败。因为创建是异步实现的。为确保数据同步,后续操作能顺利进行,请等待 2 个心跳周期(20 秒)。如果需要修改心跳间隔,请为[所有配置文件](../../5.configurations-and-logs/1.configurations/1.configurations.md)修改参数`heartbeat_interval_secs`。但过短的心跳周期(<5 秒)可能会导致分布式系统中的机器误判对端失联。 ## 检查分片分布情况 @@ -98,14 +95,13 @@ nebula> SHOW CREATE SPACE my_space_4; ```ngql nebula> SHOW HOSTS; -+-------------+------+----------+--------------+--------------------------------+--------------------------------+ -| Host | Port | Status | Leader count | Leader distribution | Partition distribution | -+-------------+------+----------+--------------+--------------------------------+--------------------------------+ -| "storaged0" | 9779 | "ONLINE" | 8 | "basketballplayer:3, test:5" | "basketballplayer:10, test:10" | -| "storaged1" | 9779 | "ONLINE" | 9 | "basketballplayer:4, test:5" | "basketballplayer:10, test:10" | -| "storaged2" | 9779 | "ONLINE" | 3 | "basketballplayer:3" | "basketballplayer:10, test:10" | -| "Total" | | | 20 | "basketballplayer:10, test:10" | "basketballplayer:30, test:30" | -+-------------+------+----------+--------------+--------------------------------+--------------------------------+ ++-------------+------+----------+--------------+--------------------------------+--------------------------------+---------+ +| Host | Port | Status | Leader count | Leader distribution | Partition distribution | Version | ++-------------+------+----------+--------------+--------------------------------+--------------------------------+---------+ +| "storaged0" | 9779 | "ONLINE" | 8 | "basketballplayer:3, test:5" | "basketballplayer:10, test:10" | "3.0.0" | +| "storaged1" | 9779 | "ONLINE" | 9 | "basketballplayer:4, test:5" | "basketballplayer:10, test:10" | "3.0.0" | +| "storaged2" | 9779 | "ONLINE" | 3 | "basketballplayer:3" | "basketballplayer:10, test:10" | "3.0.0" | ++-------------+------+----------+--------------+--------------------------------+--------------------------------+---------+ ``` 如果需要均衡负载,请执行如下命令: @@ -113,12 +109,11 @@ nebula> SHOW HOSTS; ```ngql nebula> BALANCE LEADER; nebula> SHOW HOSTS; -+-------------+------+----------+--------------+--------------------------------+--------------------------------+ -| Host | Port | Status | Leader count | Leader distribution | Partition distribution | -+-------------+------+----------+--------------+--------------------------------+--------------------------------+ -| "storaged0" | 9779 | "ONLINE" | 7 | "basketballplayer:3, test:4" | "basketballplayer:10, test:10" | -| "storaged1" | 9779 | "ONLINE" | 7 | "basketballplayer:4, test:3" | "basketballplayer:10, test:10" | -| "storaged2" | 9779 | "ONLINE" | 6 | "basketballplayer:3, test:3" | "basketballplayer:10, test:10" | -| "Total" | | | 20 | "basketballplayer:10, test:10" | "basketballplayer:30, test:30" | -+-------------+------+----------+--------------+--------------------------------+--------------------------------+ ++-------------+------+----------+--------------+--------------------------------+--------------------------------+---------+ +| Host | Port | Status | Leader count | Leader distribution | Partition distribution | Version | ++-------------+------+----------+--------------+--------------------------------+--------------------------------+---------+ +| "storaged0" | 9779 | "ONLINE" | 7 | "basketballplayer:3, test:4" | "basketballplayer:10, test:10" | "3.0.0" | +| "storaged1" | 9779 | "ONLINE" | 7 | "basketballplayer:4, test:3" | "basketballplayer:10, test:10" | "3.0.0" | +| "storaged2" | 9779 | "ONLINE" | 6 | "basketballplayer:3, test:3" | "basketballplayer:10, test:10" | "3.0.0" | ++-------------+------+----------+--------------+--------------------------------+--------------------------------+---------+ ``` diff --git a/docs-2.0/3.ngql-guide/9.space-statements/4.describe-space.md b/docs-2.0/3.ngql-guide/9.space-statements/4.describe-space.md index 0a4382e8ce..6eba9671e6 100644 --- a/docs-2.0/3.ngql-guide/9.space-statements/4.describe-space.md +++ b/docs-2.0/3.ngql-guide/9.space-statements/4.describe-space.md @@ -15,8 +15,8 @@ DESC[RIBE] SPACE ; ```ngql nebula> DESCRIBE SPACE basketballplayer; +----+--------------------+------------------+----------------+---------+------------+--------------------+-------------+-----------+---------+ -| ID | Name | Partition Number | Replica Factor | Charset | Collate | Vid Type | Atomic Edge | Group | Comment | +| ID | Name | Partition Number | Replica Factor | Charset | Collate | Vid Type | Atomic Edge | Zones | Comment | +----+--------------------+------------------+----------------+---------+------------+--------------------+-------------+-----------+---------+ | 1 | "basketballplayer" | 10 | 1 | "utf8" | "utf8_bin" | "FIXED_STRING(32)" | false | "default" | | +----+--------------------+------------------+----------------+---------+------------+--------------------+-------------+-----------+---------+ -``` \ No newline at end of file +``` diff --git a/docs-2.0/4.deployment-and-installation/1.resource-preparations.md b/docs-2.0/4.deployment-and-installation/1.resource-preparations.md index 8511b6cbf3..f57d88e837 100644 --- a/docs-2.0/4.deployment-and-installation/1.resource-preparations.md +++ b/docs-2.0/4.deployment-and-installation/1.resource-preparations.md @@ -204,7 +204,7 @@ storaged 进程的数量不会影响图空间副本的数量。 | 资源 |单位 | 计算公式 |说明| |:--- |:---|:--- |:---| | 硬盘空间 |Bytes| `点和边的总数` * `属性的平均字节大小` * 6 * 120% |由于边存在存储放大现象,所以需要`点和边的总数` * `属性的平均字节大小` * 6 的空间,详情请参见[切边与存储放大](../1.introduction/3.nebula-graph-architecture/4.storage-service.md)。| -| 内存 |Bytes| [`点和边的总数` * 15 + `RocksDB 实例数量` * (`write_buffer_size` * `max_write_buffer_number` + `块缓存大小`)] * 120% |`点和边的总数` * 15 是 [BloomFilter](https://zh.wikipedia.org/wiki/%E5%B8%83%E9%9A%86%E8%BF%87%E6%BB%A4%E5%99%A8) 需要占用的内存空间,`write_buffer_size`和`max_write_buffer_number`是 RocksDB 内存相关参数,详情请参见 [MemTable](https://github.com/facebook/rocksdb/wiki/MemTable)。块缓存大小请参见 [Memory usage in RocksDB](https://github.com/facebook/rocksdb/wiki/Memory-usage-in-RocksDB#block-cache)。| +| 内存 |Bytes| [`点和边的总数` * 16 + `RocksDB 实例数量` * (`write_buffer_size` * `max_write_buffer_number` + `块缓存大小`)] * 120% |`点和边的总数` * 16 是 [BloomFilter](https://zh.wikipedia.org/wiki/%E5%B8%83%E9%9A%86%E8%BF%87%E6%BB%A4%E5%99%A8) 需要占用的内存空间,`write_buffer_size`和`max_write_buffer_number`是 RocksDB 内存相关参数,详情请参见 [MemTable](https://github.com/facebook/rocksdb/wiki/MemTable)。块缓存大小请参见 [Memory usage in RocksDB](https://github.com/facebook/rocksdb/wiki/Memory-usage-in-RocksDB#block-cache)。| | 分区数量 |-| `集群硬盘数量` * `disk_partition_num_multiplier` |`disk_partition_num_multiplier`是取值为 2~10 的一个整数,用于衡量硬盘性能。HDD 使用 2。| - 问题 1:为什么磁盘空间和内存都要乘以 120%? diff --git a/docs-2.0/4.deployment-and-installation/2.compile-and-install-nebula-graph/1.install-nebula-graph-by-compiling-the-source-code.md b/docs-2.0/4.deployment-and-installation/2.compile-and-install-nebula-graph/1.install-nebula-graph-by-compiling-the-source-code.md index eccdbaf9c1..783b84c761 100644 --- a/docs-2.0/4.deployment-and-installation/2.compile-and-install-nebula-graph/1.install-nebula-graph-by-compiling-the-source-code.md +++ b/docs-2.0/4.deployment-and-installation/2.compile-and-install-nebula-graph/1.install-nebula-graph-by-compiling-the-source-code.md @@ -169,6 +169,6 @@ $ cmake -DCMAKE_C_COMPILER= -DCMAKE_CXX_COMPILER= SHOW HOSTS; - +-------------+------+----------+--------------+----------------------+------------------------+ - | Host | Port | Status | Leader count | Leader distribution | Partition distribution | - +-------------+------+----------+--------------+----------------------+------------------------+ - | "storaged0" | 9779 | "ONLINE" | 0 | "No valid partition" | "No valid partition" | - | "storaged1" | 9779 | "ONLINE" | 0 | "No valid partition" | "No valid partition" | - | "storaged2" | 9779 | "ONLINE" | 0 | "No valid partition" | "No valid partition" | - | "Total" | | | 0 | | | - +-------------+------+----------+--------------+----------------------+------------------------+ + +-------------+------+----------+--------------+----------------------+------------------------+---------+ + | Host | Port | Status | Leader count | Leader distribution | Partition distribution | Version | + +-------------+------+----------+--------------+----------------------+------------------------+---------+ + | "storaged0" | 9779 | "ONLINE" | 0 | "No valid partition" | "No valid partition" | "3.0.0" | + | "storaged1" | 9779 | "ONLINE" | 0 | "No valid partition" | "No valid partition" | "3.0.0" | + | "storaged2" | 9779 | "ONLINE" | 0 | "No valid partition" | "No valid partition" | "3.0.0" | + +-------------+------+----------+--------------+----------------------+------------------------+---------+ ``` 5. 执行两次`exit` 可以退出容器。 @@ -256,7 +255,7 @@ docker pull vesoft/nebula-console:{{console.branch}} ### 为什么更新 nebula-docker-compose 仓库(Nebula Graph 2.0.0-RC)后,无法通过端口`3699`连接 Nebula Graph? -在 Nebula Graph 2.0.0-RC 版本,默认端口从`3699`改为`9669`。请使用`9669`端口连接,或修改配置文件`docker-compose.yaml`内的端口。 +从 Nebula Graph 2.0.0-RC 版本开始,默认端口从`3699`改为`9669`。请使用`9669`端口连接,或修改配置文件`docker-compose.yaml`内的端口。 ### 为什么更新 nebula-docker-compose 仓库后,无法访问数据?(2021 年 01 月 04 日) @@ -266,6 +265,7 @@ docker pull vesoft/nebula-console:{{console.branch}} 2021 年 01 月 27 日修改了数据格式,无法兼容之前的数据,请执行命令`docker-compose down -v`删除所有本地数据。 + \ No newline at end of file diff --git a/docs-2.0/4.deployment-and-installation/2.compile-and-install-nebula-graph/deploy-nebula-graph-cluster.md b/docs-2.0/4.deployment-and-installation/2.compile-and-install-nebula-graph/deploy-nebula-graph-cluster.md index daba642615..15000cae18 100644 --- a/docs-2.0/4.deployment-and-installation/2.compile-and-install-nebula-graph/deploy-nebula-graph-cluster.md +++ b/docs-2.0/4.deployment-and-installation/2.compile-and-install-nebula-graph/deploy-nebula-graph-cluster.md @@ -291,14 +291,13 @@ $ ./nebula-console --addr 192.168.10.111 --port 9669 -u root -p nebula Welcome to Nebula Graph! > SHOW HOSTS; -+------------------+------+----------+--------------+----------------------+------------------------+ -| Host | Port | Status | Leader count | Leader distribution | Partition distribution | -+------------------+------+----------+--------------+----------------------+------------------------+ -| "192.168.10.111" | 9779 | "ONLINE" | 0 | "No valid partition" | "No valid partition" | -| "192.168.10.112" | 9779 | "ONLINE" | 0 | "No valid partition" | "No valid partition" | -| "192.168.10.113" | 9779 | "ONLINE" | 0 | "No valid partition" | "No valid partition" | -| "192.168.10.114" | 9779 | "ONLINE" | 0 | "No valid partition" | "No valid partition" | -| "192.168.10.115" | 9779 | "ONLINE" | 0 | "No valid partition" | "No valid partition" | -| "Total" | | | 0 | | | -+------------------+------+----------+--------------+----------------------+------------------------+ ++------------------+------+----------+--------------+----------------------+------------------------+---------+ +| Host | Port | Status | Leader count | Leader distribution | Partition distribution | Version | ++------------------+------+----------+--------------+----------------------+------------------------+---------+ +| "192.168.10.111" | 9779 | "ONLINE" | 0 | "No valid partition" | "No valid partition" | "3.0.0" | +| "192.168.10.112" | 9779 | "ONLINE" | 0 | "No valid partition" | "No valid partition" | "3.0.0" | +| "192.168.10.113" | 9779 | "ONLINE" | 0 | "No valid partition" | "No valid partition" | "3.0.0" | +| "192.168.10.114" | 9779 | "ONLINE" | 0 | "No valid partition" | "No valid partition" | "3.0.0" | +| "192.168.10.115" | 9779 | "ONLINE" | 0 | "No valid partition" | "No valid partition" | "3.0.0" | ++------------------+------+----------+--------------+----------------------+------------------------+---------+ ``` diff --git a/docs-2.0/4.deployment-and-installation/3.upgrade-nebula-graph/upgrade-nebula-graph-to-latest.md b/docs-2.0/4.deployment-and-installation/3.upgrade-nebula-graph/upgrade-nebula-graph-to-latest.md index 7c88c30126..9120e85147 100644 --- a/docs-2.0/4.deployment-and-installation/3.upgrade-nebula-graph/upgrade-nebula-graph-to-latest.md +++ b/docs-2.0/4.deployment-and-installation/3.upgrade-nebula-graph/upgrade-nebula-graph-to-latest.md @@ -1,10 +1,14 @@ -# 升级 Nebula Graph 历史版本至 v{{nebula.release}} +# 升级 Nebula Graph 2.x 至 {{nebula.release}} 版本 -Nebula Graph 历史版本指低于 Nebula Graph v2.0.0-GA 的版本,本文介绍如何升级历史版本至 v{{nebula.release}}。 +本文以 Nebula Graph 2.6.1 版本升级到 {{nebula.release}} 版本为例,介绍 Nebula Graph 2.x 版本升级到 3.x 版本的方法。 -!!! note +## 适用版本 - Nebula Graph v2.0.0-GA 或更新版本升级至 v{{nebula.release}},请参见 [Nebula Graph v2.0.x 升级至 v{{nebula.release}}](upgrade-nebula-from-200-to-latest.md)。 +本文适用于将 Nebula Graph 从 2.0.0 及之后的 2.x 版本升级到 {{nebula.release}} 版本。不适用于 2.0.0 之前的历史版本(含 1.x 版本)。如需升级历史版本,将其根据最新的 2.x 版本文档升级到最新的 2.x 版本,然后根据本文的说明升级到 3.x 版本。 + +!!! caution + + 如需从 2.0.0 之前的版本(含 1.x 版本)升级到 {{nebula.release}},还需找到 {{nebula.release}} 版本文件中`share/resources`目录下的`date_time_zonespec.csv`文件,将其复制到 Nebula Graph 安装路径下的相同目录内。也可从 [GitHub](https://github.com/vesoft-inc/nebula/blob/master/resources/date_time_zonespec.csv) 下载该文件。 ## 升级限制 @@ -12,332 +16,212 @@ Nebula Graph 历史版本指低于 Nebula Graph v2.0.0-GA 的版本,本文介 - 未提供升级脚本,需手动在每台服务器上依次执行。 -- **不支持**基于 Docker 容器(包括 Docker Swarm、Docker Compose、K8s)的升级。 +- 不支持基于 Docker 容器(包括 Docker Swarm、Docker Compose、K8s)的升级。 - 必须在原服务器上原地升级,不能修改原机器的 IP 地址、配置文件,不可更改集群拓扑。 -- 硬盘空间要求:各机器硬盘剩余空间都需要是原数据目录的**三倍**。 - -- 已知会造成数据丢失的 4 种场景,和 alter schema 以及 default value 相关,请参见 [github known issues](https://github.com/vesoft-inc/nebula-graph/issues/857)。 +- 硬盘空间要求:各机器硬盘剩余空间都需要是原数据目录的**三倍以上**。 -- 所有的客户端均需要升级,通信协议不兼容。 - -- 升级时间大约需要 30 分钟(取决于具体配置),请参见文末测试环境。 +- 已知会造成数据丢失的 4 种场景,和 alter schema 以及 default value 相关,参见 [github known issues](https://github.com/vesoft-inc/nebula-graph/issues/857)。 - 数据目录不要使用软连接切换,避免失效。 -- 升级操作需要有 sudo 权限。 - -## 前置条件说明 - -### 历史版本安装目录 - -默认情况下,历史版本安装的根目录为`/usr/local/nebula/`(下文记为 `${nebula-old}`)。默认配置文件目录为 `${nebula-old}/etc/`。 - -- `${nebula-old}/etc/nebula-storaged.conf`文件中的`--data_path`参数指定了 storaged 数据目录的位置,其默认值为`data/storage`。 - -- `${nebula-old}/etc/nebula-metad.conf`文件中的`--data_path`参数指定了 metad 数据目录位置,其默认值为`data/meta`。 - -!!! Note - - Nebula Graph 的实际安装路径可能和本文示例不同,请使用实际路径。用户也可以用 `ps -ef | grep nebula` 中的参数来找到实际使用的配置文件地址。 - -### 新版本安装目录 - -本文中新版本安装目录记为 `${nebula-new}` (例如 `/usr/local/nebula-new/`)。 - -``` -# mkdir -p ${nebula-new} -``` - -## 升级步骤 - -1. **停止所有客户端访问**。也可以通过在每台服务器上关闭 graphd 服务避免脏写。在每台服务器上运行如下命令。 - - ``` - # ${nebula-old}/scripts/nebula.service stop graphd - [INFO] Stopping nebula-graphd... - [INFO] Done - ``` - -2. 停止历史版本服务。在每台服务器上运行如下命令。 - - ``` - # ${nebula-old}/scripts/nebula.service stop all - [INFO] Stopping nebula-metad... - [INFO] Done - [INFO] Stopping nebula-graphd... - [INFO] Done - [INFO] Stopping nebula-storaged... - [INFO] Done - ``` - - 运行 `ps -ef | grep nebula` 检查所有 nebula 服务都已停止。`storaged` 进程 flush 数据可能要等待 1 分钟。 - - !!! Note - - 如果超过 20 分钟不能停止服务,**放弃本次升级**,并在论坛提交问题。 +- 部分升级操作需要有 sudo 权限。 -3. 在每台服务器上运行如下命令。 +## 升级影响 - 1. 安装新的二进制文件。 - - - 如果从 RPM/DEB 安装,从 [release page](https://github.com/vesoft-inc/nebula-graph/releases) 下载对应操作系统的安装包。 - - ``` - # sudo rpm --force -i --prefix=${nebula-new} ${nebula-package-name.rpm} # for centos/redhat - # sudo dpkg -i --instdir==${nebula-new} ${nebula-package-name.deb} # for ubuntu - ``` - - 具体步骤请参见[从 RPM/DEB 安装](../2.compile-and-install-nebula-graph/2.install-nebula-graph-by-rpm-or-deb.md)。 - - - 如果从源代码安装。具体步骤请参见[从源代码安装](../2.compile-and-install-nebula-graph/1.install-nebula-graph-by-compiling-the-source-code.md)。这里列出几个关键命令: - - - clone 源代码 +- 数据膨胀 - ``` - # git clone --branch {{nebula.branch}} https://github.com/vesoft-inc/nebula-graph.git - ``` - - - 设置 CMake - - ``` - # cmake -DCMAKE_INSTALL_PREFIX=${nebula-new} -DENABLE_TESTING=OFF -DCMAKE_BUILD_TYPE=Release .. - ``` - - 2. 拷贝配置文件。 - - ``` - # cp -rf ${nebula-old}/etc ${nebula-new}/ - ``` - -4. 在曾经运行 metad 的服务器上(通常为 3 台),拷贝 metad 数据、配置文件到新目录。 - - - 拷贝 metad 数据 + Nebula Graph 3.x 版本扩展了原有的数据格式,每个点多出一个 key,所以升级后数据会占用更大的空间。 + + 新增 key 的格式为: Type 字段(1 字节)+ Partition ID 字段(3 字节)+ VID(大小根据类型而定)。key 的 value 为空。多占用的空间可以根据点的数量和 VID 的数据类型计算。例如,数据集中有 1 亿个点,且 VID 为 INT64,则升级后这个 key 会占用 1 亿 * (1 + 3 + 8)= 12 亿字节,约等于 1.2 GB。 - 在 `${nebula-old}/etc/nebula-metad.conf` 中找到 `--data_path` 项(其默认值为 `data/meta`) +- 客户端兼容 - - 如果历史版本配置**未更改** `--data_path` 项,则可以运行如下命令,将 metad 数据拷贝到新目录。 + 升级后旧版本客户端将无法连接 Nebula Graph,需将所有客户端都升级到兼容 Nebula Graph {{nebula.release}} 的版本。 - ``` - # mkdir -p ${nebula-new}/data/meta/ - # cp -r ${nebula-old}/data/meta/* ${nebula-new}/data/meta/ - ``` +- 配置变化 - - 如果历史版本配置更改了默认的 metad 目录,请根据实际目录拷贝。 + 少数配置参数发生改变,详情参考版本发布说明和参数文档。 - - 拷贝并修改配置文件 +- 语法兼容 - - 编辑新的 metad 配置文件: + nGQL 语法有部分不兼容: - ``` - # vim ${nebula-new}/nebula-metad.conf - ``` + - 禁用`YIELD`子句返回自定义变量。 - - [可选] 增加配置项: + - `FETCH`、`GO`、`LOOKUP`、`FIND PATH`、`GET SUBGRAPH`语句中必须添加`YIELD`子句。 - `--null_type=false`: 升级后的 Schema 的属性是否要支持 [`NULL`](../../3.ngql-guide/3.data-types/5.null.md),**默认为 true**。不希望支持 NULL 的话,设置为 false。此时,升级后的 Schema 如果要增加属性(ALTER TAG/EDGE)必须指定 [default 值](../../3.ngql-guide/10.tag-statements/1.create-tag.md),否则会读不出数据。 + - MATCH 语句中获取点属性时,必须指定 Tag,例如从`return v.name`变为`return v.player.name`。 - `--string_index_limit=32`: 升级后 string 对应的[索引的长度](../../3.ngql-guide/14.native-index-statements/1.create-native-index.md),不加的话系统默认为 64。 +!!! caution - !!! Note + 可能存在其它暂未发现的影响,建议升级前详细查看版本发布说明和产品手册,并密切关注[论坛](https://discuss.nebula-graph.com.cn/)与 [GitHub](https://github.com/vesoft-inc/nebula/issues) 的最新动态。 - 请确保在每个 metad 服务器都完成了以上操作。 +## 升级准备 -5. 在每个 storaged 服务器上,修改 storaged 配置文件。 +- 根据操作系统和架构下载 Nebula Graph {{nebula.release}} 版本的 TAR 文件并解压,升级过程中需要其中的二进制文件。TAR 包下载地址参见 [Download 页面](https://nebula-graph.io/download/)。 - + [可选] 如果历史版本 storaged 数据目录 `--data_path=data/storage` 不是默认值,有更改。 + !!! note + 编译源码或者下载RPM/DEB包也可以获取新版二进制文件。 - ``` - # vim ${nebula-new}/nebula-storaged.conf - ``` - `--data_path`设置为新的 storaged 数据目录地址。 +- 根据 Storage 和 Meta 服务配置中`data_path`参数的值找到数据文件的位置,并备份数据。默认路径为`nebula/data/storage`和`nebula/data/meta`。 - + 创建新版本 storaged 数据目录。 +- 备份配置文件。 - ``` - # mkdir -p ${nebula-new}/data/storage/ - ``` +- 统计所有图空间升级前的数据量,供升级后比较。统计方法如下: - 如果`${nebula-new}/etc/nebula-storaged.conf` 中的 `--data_path` 有改动,请按实际路径创建。 + 1. 运行`SUBMIT JOB STATS`。 + 2. 运行`SHOW JOBS`并记录返回结果。 -6. 启动新版本的 metad 进程。 +## 升级步骤 - - 在每个 metad 的服务器上运行如下命令。 +1. 停止所有 Nebula Graph 服务。 - ``` - # ${nebula-new}/scripts/nebula.service start metad - [INFO] Starting nebula-metad... - [INFO] Done - ``` + ``` + /scripts/nebula.service stop all + ``` - - 检查每个 metad 进程是否正常。 + `nebula_install_path`代表 Nebula Graph 的安装目录。 - ``` - # ps -ef |grep nebula-metad - ``` + `storaged` 进程 flush 数据要等待约 1 分钟。运行命令后可继续运行`nebula.service status all`命令以确认所有服务都已停止。启动和停止服务的详细说明参见[管理服务](../manage-service.md)。 - - 检查 metad 日志`${nebula-new}/logs/` 下的 ERROR 日志。 - !!! Note - 如果服务异常:请查看目录`${nebula-new}/logs`内的 metad 相关日志,并在论坛提交问题。**放弃本次升级,在原目录正常启动 nebula 服务。** + 如果超过 20 分钟不能停止服务,放弃本次升级,在[论坛](https://discuss.nebula-graph.com.cn/)或 [GitHub](https://github.com/vesoft-inc/nebula/issues) 提问。 -7. 升级 storaged 数据格式。 +2. 在**升级准备**中解压 TAR 包的目的路径下,用此处`bin`目录中的新版二进制文件替换 Nebula Graph 安装路径下`bin`目录中的旧版二进制文件。 - 在每个 storaged 服务器运行如下命令。 + !!! note + 每台部署了 Nebula Graph 服务的机器上都要更新相应服务的二进制文件。 - ``` - # ${nebula-new}/bin/db_upgrader \ - --src_db_path= \ - --dst_db_path= \ - --upgrade_meta_server=:[,:,...] \ - --upgrade_version= \ - ``` - - 参数说明: +3. 编辑所有 Graph 服务的配置文件,修改以下参数以适应新版本的取值范围。如参数值已在规定范围内,忽略该步骤。 - - `--src_db_path`:**历史版本** storaged 的数据目录的绝对路径,多个目录用逗号分隔,不加空格。 + - 为`session_idle_timeout_secs`参数设置一个在 [1,604800] 区间的值,推荐值为 28800。 + - 为`client_idle_timeout_secs`参数设置一个在 [1,604800] 区间的值,推荐值为 28800。 - - `--dst_db_path`:**新版本** storaged 的数据目录的绝对路径,多个目录用逗号分隔。逗号分隔的目录必须和`--src_db_path`中一一对应。 + 这些参数在 2.x 版本中的默认值不在新版本的取值范围内,如不修改会升级失败。详细参数说明参见[Graph 服务配置](../../5.configurations-and-logs/1.configurations/3.graph-config.md)。 - - `--upgrade_meta_server` :步骤 6 中启动的所有新 metad 的地址。 +4. 启动所有 Meta 服务。 - - `--upgrade_version`:如果历史版本为 v1.2.x,则填写 1;如果历史版本为 v2.0.0-RC,则填写 2。不可填写其他数字。 - - !!! danger + ``` + /scripts/nebula-metad.service start + ``` - 请勿颠倒`--src_db_path`和`--dst_db_path`的顺序,否则会升级失败且破坏历史版本的数据。 + 启动后,Meta 服务选举 leader。该过程耗时数秒。 - 例如,从 v1.2.x 升级: + 启动后可以任意启动一个 Graph 服务节点,使用 Nebula Graph 连接该节点并运行[`SHOW HOSTS meta`](../../3.ngql-guide/7.general-query-statements/6.show/6.show-hosts.md)和[`SHOW META LEADER`](../../3.ngql-guide/7.general-query-statements/6.show/19.show-meta-leader.md),如果能够正常返回 Meta 节点的状态,则 Meta 服务启动成功。 - ``` - # /usr/local/nebula_new/bin/db_upgrader \ - --src_db_path=/usr/local/nebula/data/storage/data1/,/usr/local/nebula/data/storage/data2/ \ - --dst_db_path=/usr/local/nebula_new/data/storage/data1/,/usr/local/nebula_new/data/storage/data2/\ - --upgrade_meta_server=192.168.*.14:45500,192.168.*.15:45500,192.168.*.16:45500 \ - --upgrade_version=1 - ``` + !!! note + 如果启动异常,放弃本次升级,并在[论坛](https://discuss.nebula-graph.com.cn/)或 [GitHub](https://github.com/vesoft-inc/nebula/issues) 提问。 - 从 v2.0.0-RC 升级: +5. 使用`bin`目录下的新版 db_upgrader 文件升级数据格式。 - ``` - # /usr/local/nebula_new/bin/db_upgrader \ - --src_db_path=/usr/local/nebula/data/storage/ \ - --dst_db_path=/usr/local/nebula_new/data/storage/ \ - --upgrade_meta_server=192.168.*.14:9559,192.168.*.15:9559,192.168.*.16:9559 \ - --upgrade_version=2 - ``` + !!! caution + 本步骤会备份 Storage 服务中保存的数据,但为防止备份失败,升级数据格式前,务必按照本文**升级准备**部分的说明备份数据。 - !!! Note - - - 如果工具抛出异常请在论坛提交问题。**放弃本次升级,关闭所有已经启动的 metad,在原目录正常启动 nebula 服务。** - - 请确保在每个 storaged 服务器都完成了以上操作。 + 命令语法: -8. 在每个 storaged 服务器启动新版本的 storaged 服务。 + ``` + /bin/db_upgrader \ + --src_db_path= \ + --dst_db_path= \ + --upgrade_meta_server=:[, : ...] \ + --upgrade_version=2:3 + ``` - ``` - # ${nebula-new}/scripts/nebula.service start storaged - # ${nebula-new}/scripts/nebula.service status storaged - ``` + - `old_storage_data_path`代表数据的存储路径,由 Storage 服务配置文件中的`data_path`参数定义。 + - `data_backup_path`代表自定义的数据备份路径。 + - `meta_server_ip`和`port`分别代表 Meta 服务各节点的 IP 地址和端口号。 + - `2:3`代表从 Nebula Graph 2.x 版本升级到 3.x 版本。 - !!! Note + 本文示例: - 如果有 storaged 未正常启动,请将日志`${nebula-new}/logs/`在论坛提交问题。**放弃本次升级,关闭所有已经启动的 metad 和 storaged,在原目录正常启动 nebula 服务。** + ``` + /bin/db_upgrader \ + --src_db_path=/usr/local/nebula/data/storage \ + --dst_db_path=/home/vesoft/nebula/data-backup \ + --upgrade_meta_server=192.168.8.132:9559 \ + --upgrade_version=2:3 + ``` -9. 在每个 graphd 服务器启动新版本的 graphd 服务。 + !!! note + 如果出现异常,放弃本次升级,并在[论坛](https://discuss.nebula-graph.com.cn/)或 [GitHub](https://github.com/vesoft-inc/nebula/issues) 提问。 - ``` - # ${nebula-new}/scripts/nebula.service start graphd - # ${nebula-new}/scripts/nebula.service status graphd - ``` - !!! Note - - 如果有 graphd 未正常启动,请将日志`${nebula-new}/logs/`在论坛提交问题。**放弃本次升级,关闭所有已经启动的 metad,storaged,graphd. 在原目录正常启动 nebula 服务。** - -10. 使用[新版本 Nebula Console](https://github.com/vesoft-inc/nebula-console) 连接新的 Nebula Graph,验证服务是否可用、数据是否正常。命令行参数,如 graphd 的 IP、端口都不变。 - - ```ngql - nebula> SHOW HOSTS; - nebula> SHOW SPACES; - nebula> USE - nebula> SHOW PARTS; - nebula> SUBMIT JOB STATS; - nebula> SHOW STATS; - ``` +6. 启动所有 Graph 和 Storage 服务。 - !!! Note - - 历史版本 Nebula Console 可能会有兼容性问题。 + !!! note + 如果启动异常,放弃本次升级,并在[论坛](https://discuss.nebula-graph.com.cn/)或 [GitHub](https://github.com/vesoft-inc/nebula/issues) 提问。 -11. 升级其他客户端。 +7. 连接新版 Nebula Graph,验证服务是否可用、数据是否正常。连接方法参见[连接服务](../connect-to-nebula-graph.md)。 - 所有的客户端都必须升级到支持 Nebula Graph v{{nebula.release}} 的版本。包括但不限于 [Python](https://github.com/vesoft-inc/nebula-python)、[Java](https://github.com/vesoft-inc/nebula-java)、[go](https://github.com/vesoft-inc/nebula-go)、[C++](https://github.com/vesoft-inc/nebula-cpp)、[Flink-connector](https://github.com/vesoft-inc/nebula-flink-connector)、[Algorithm](https://github.com/vesoft-inc/nebula-algorithm)、[Exchange](https://github.com/vesoft-inc/nebula-exchange)、[Spark-connector](https://github.com/vesoft-inc/nebula-spark-connector)、[Nebula Bench](https://github.com/vesoft-inc/nebula-bench)。请找到各 repo 对应的 branch。 + 目前尚无有效方式判断升级是否完全成功,可用于测试的参考命令如下: - !!! Note + ```ngql + nebula> SHOW HOSTS; + nebula> SHOW HOSTS storage; + nebula> SHOW SPACES; + nebula> USE + nebula> SHOW PARTS; + nebula> SUBMIT JOB STATS; + nebula> SHOW STATS; + nebula> MATCH (v) RETURN v LIMIT 5; + ``` - 不兼容历史版本的通信协议。需重新源代码编译或者下载二进制包。 - - 运维提醒:升级后的数据目录为`${nebula-new}/`。如有硬盘容量监控、日志、ELK 等,请做相应改动。 + 也可根据 {{nebula.release}} 版本的新功能测试,新功能列表参见[发布说明](../../20.appendix/releasenote.md)。 ## 升级失败回滚 -如果升级失败,请停止新版本的所有服务,启动历史版本的所有服务。 - -所有周边客户端也切换为**历史版本**。 +如果升级失败,停止新版本的所有服务,从备份中恢复配置文件和二进制文件,启动历史版本的服务。 -## 附 1:升级测试环境 +所有周边客户端也切换为旧版。 -本文测试升级的环境如下: - -- 机器配置:32 核 CPU、62 GB 内存、SSD +## FAQ -- 数据规模:Nebula Graph 1.2 版本 LDBC 测试数据 100 GB(1 个图空间、24 个分片、data 目录 92 GB) +Q:升级过程中是否可以通过客户端写入数据? -- 并发参数:`--max_concurrent=5`、`--max_concurrent_parts=24`、`--write_batch_num=100` +A:不可以。升级过程中需要停止所有服务。 -升级共耗时** 21 分钟**(其中 compaction 耗时 13 分钟)。工具并发参数说明如下: +Q:如果某台机器只有 Graph 服务,没有 Storage 服务,如何升级? -|参数名称|默认值| -|:---|:---| -|`--max_concurrent`|5| -|`--max_concurrent_parts`|10| -|`--write_batch_num`|100| +A:只需要升级 Graph 服务对应的二进制文件和配置文件。 -## 附 2:Nebula Graph v2.0.0 代码地址和 commit id +Q:操作报错 `Permission denied`。 -| 地址 | commit id | -|:---|:---| -| [graphd](https://github.com/vesoft-inc/nebula-graph/releases/tag/v2.0.0) | 91639db | -| [storaged 和 metad](https://github.com/vesoft-inc/nebula-storage/tree/v2.0.0) | 761f22b | -| [common](https://github.com/vesoft-inc/nebula-common/tree/v2.0.0) | b2512aa | +A:部分命令需要有 sudo 权限。 -## FAQ + -A:不可以。这个过程中写入的数据状态是未定义的。 +Q:是否有工具或者办法验证新旧版本数据是否一致? -Q:除了 v1.2.x 和 v2.0.0-RC 外,其他版本是否支持升级? +A:没有。如果只是检查数据量,可以在升级完成后再次运行`SUBMIT JOB STATS`和`SHOW STATS`统计数据量,并与升级之前做对比。 -A:未验证过。理论上 v1.0.0 - v1.2.0 都可以采用 v1.2.x 的升级版本。 v2.0.0-RC 之前的日常研发版本(nightly)无升级方案。 +Q: Storage `OFFLINE`并且`Leader count`是`0`怎么处理? -Q:如果某台机器只有 graphd 服务,没有 storaged 服务,如何升级? +A:运行以下命令手动添加 Storage 主机: -A:只需要升级 graphd 对应的 binary (或者 RPM 包)。 +```ngql +ADD HOSTS :[, : ...]; +``` -Q:操作报错 `Permission denied`。 +例如: -A:部分命令需要有 sudo 权限。 +``` +ADD HOSTS 192.168.10.100:9779, 192.168.10.101:9779, 192.168.10.102:9779; +``` -Q:是否有 gflags 发生改变? +如果有多个 Meta 服务节点,手动`ADD HOSTS`之后,部分 Storage 节点需等待数个心跳(`heartbeat_interval_secs`)的时间才能正常连接到集群。 -A: 目前已知的 gflags 改变整理在 [github issues](https://github.com/vesoft-inc/nebula/issues/2501)。 +如果添加 Storage 主机后问题仍然存在,在[论坛](https://discuss.nebula-graph.com.cn/)或 [GitHub](https://github.com/vesoft-inc/nebula/issues) 提问。 -Q:删除数据重新安装,和升级有何不同? +Q:为什么升级后用`SHOW JOBS`查询到的 Job 的 ID 与升级前一样,但 Job 名称等信息不同了? -A:v2.x 的默认配置(包括端口)与 v1.x 不同。升级方案沿用老的配置,删除重新安装沿用新的配置。 +A: Nebula Graph 2.5.0 版本调整了 Job 的定义,详情参见 [Pull request](https://github.com/vesoft-inc/nebula-common/pull/562/files)。如果是从 2.5.0 之前的版本升级,会出现该问题。 -Q:是否有工具或者办法验证新旧版本数据是否一致? +Q: 有哪些语法不兼容 ? -A:没有。 +A: 参见[Release Note](../../20.appendix/releasenote.md) Incompatibility 部分。 diff --git a/docs-2.0/4.deployment-and-installation/5.zone.md b/docs-2.0/4.deployment-and-installation/5.zone.md index c46bdde36c..00ea10785b 100644 --- a/docs-2.0/4.deployment-and-installation/5.zone.md +++ b/docs-2.0/4.deployment-and-installation/5.zone.md @@ -6,7 +6,7 @@ Nebula Graph 提供 Zone 功能,可以管理集群中的 Storage 节点,实 !!! compatibility - 从 3.0 版本开始,在配置文件中添加的 Storage 节点无法直接读写,配置文件的作用仅仅是将 Storage 节点注册至 Meta 服务中。必须使用`ADD HOSTS`命令后,才能正常读写 Storage 节点。 + 从 3.0.0 版本开始,在配置文件中添加的 Storage 节点无法直接读写,配置文件的作用仅仅是将 Storage 节点注册至 Meta 服务中。必须使用`ADD HOSTS`命令后,才能正常读写 Storage 节点。 用户可以将 Storage 节点加入某个 Zone 中,创建图空间时指定 Zone,就会在 Zone 内的 Storage 节点上创建及存储图空间。分片及其副本会均匀存储在各个 Zone 中。如下图所示。 @@ -53,9 +53,11 @@ nebula> SHOW ZONES; 将 Storage 节点加入已创建的 Zone。 + ```ngql ADD HOSTS : [,: ...] INTO ZONE ""; @@ -118,9 +120,11 @@ DROP ZONE ""; 合并时将检查所有图空间分片的分布情况,防止同一个分片的不同副本因为合并导致分布在同一个 Zone 中。 + ```ngql MERGE ZONE "" [,"" ...] INTO ""; @@ -136,9 +140,11 @@ MERGE ZONE "default_zone_192.168.10.100_9779","default_zone_192.168.10.101_9779" 将一个 Zone 中的所有 Storage 节点分离至多个新建 Zone。 + ```ngql DIVIDE ZONE "" INTO ""(:) [""(:) ...]; diff --git a/docs-2.0/4.deployment-and-installation/6.deploy-text-based-index/1.text-based-index-restrictions.md b/docs-2.0/4.deployment-and-installation/6.deploy-text-based-index/1.text-based-index-restrictions.md index e30e1cb9fd..9c6d1a8556 100644 --- a/docs-2.0/4.deployment-and-installation/6.deploy-text-based-index/1.text-based-index-restrictions.md +++ b/docs-2.0/4.deployment-and-installation/6.deploy-text-based-index/1.text-based-index-restrictions.md @@ -4,7 +4,7 @@ 本文介绍全文索引的限制,请在使用全文索引前仔细阅读。 -目前为止,全文索引有如下限制: +全文索引有如下 16 条限制: - 全文索引当前仅支持`LOOKUP`语句。 @@ -22,7 +22,7 @@ - 全文索引不支持搜索属性值为`NULL`的属性。 -- 不支持修改 Elasticsearch 索引。 +- 不支持修改 Elastic Search 中的索引,只能删除重建。 - 不支持管道符。 diff --git a/docs-2.0/4.deployment-and-installation/deploy-license.md b/docs-2.0/4.deployment-and-installation/deploy-license.md index e2f3d75714..4c5d463e5c 100644 --- a/docs-2.0/4.deployment-and-installation/deploy-license.md +++ b/docs-2.0/4.deployment-and-installation/deploy-license.md @@ -69,3 +69,7 @@ License 文件包含生效时间、过期时间等信息。说明如下。 !!! note 周边工具的 License 文件上传位置,请参见[具体周边工具](../20.appendix/6.eco-tool-version.md)的说明文档。 + +## 下一步 + +[启动 Nebula Graph](manage-service.md) diff --git a/docs-2.0/4.deployment-and-installation/manage-storage-host.md b/docs-2.0/4.deployment-and-installation/manage-storage-host.md new file mode 100644 index 0000000000..fcfa1e0929 --- /dev/null +++ b/docs-2.0/4.deployment-and-installation/manage-storage-host.md @@ -0,0 +1,23 @@ +# 管理 Storage 主机 + +从 3.0.0 版本开始,在配置文件中添加的 Storage 主机无法直接读写,配置文件的作用仅仅是将 Storage 主机注册至 Meta 服务中。必须使用`ADD HOSTS`命令后,才能正常读写 Storage 主机。 + +## 增加 Storage 主机 + +向集群中增加 Storage 主机。 + +```ngql +ADD HOSTS : [,: ...]; +``` + +## 删除 Storage 主机 + +从集群中删除 Storage 主机。 + +!!! note + + 无法直接删除正在使用的 Storage 主机,需要先删除关联的图空间,才能删除 Storage 主机。 + +```ngql +DROP HOSTS : [,: ...]; +``` diff --git a/docs-2.0/5.configurations-and-logs/1.configurations/1.configurations.md b/docs-2.0/5.configurations-and-logs/1.configurations/1.configurations.md index f4ed2bb190..5fa675d1ca 100644 --- a/docs-2.0/5.configurations-and-logs/1.configurations/1.configurations.md +++ b/docs-2.0/5.configurations-and-logs/1.configurations/1.configurations.md @@ -42,8 +42,11 @@ $ /usr/local/nebula/bin/nebula-storaged --help 使用`curl`命令获取运行中的配置项的值,即 Nebula Graph 的运行配置。 + 例如: @@ -89,6 +92,8 @@ Nebula Graph 为每个服务都提供了两份初始配置文件`. 对于使用 Docker Compose 创建的集群,集群的配置文件的默认路径为`/nebula-docker-compose/docker-compose.yaml`。配置文件中的`command`下面的参数为各服务的启动参数。 + diff --git a/docs-2.0/5.configurations-and-logs/1.configurations/2.meta-config.md b/docs-2.0/5.configurations-and-logs/1.configurations/2.meta-config.md index dcfdd6b5c5..d23bcafdd7 100644 --- a/docs-2.0/5.configurations-and-logs/1.configurations/2.meta-config.md +++ b/docs-2.0/5.configurations-and-logs/1.configurations/2.meta-config.md @@ -24,6 +24,7 @@ Meta 服务提供了两份初始配置文件`nebula-metad.conf.default`和`nebul | `daemonize` | `true` | 是否启动守护进程。 | | `pid_file` | `pids/nebula-metad.pid` | 记录进程 ID 的文件。 | | `timezone_name` | - | 指定 Nebula Graph 的时区。初始配置文件中未设置该参数,如需使用请手动添加。系统默认值为`UTC+00:00:00`。格式请参见 [Specifying the Time Zone with TZ](https://www.gnu.org/software/libc/manual/html_node/TZ-Variable.html "Click to view the timezone-related content in the GNU C Library manual")。例如,东八区的设置方式为`--timezone_name=UTC+08:00`。 | +|`license_path`|`share/resources/nebula.license`|企业版 License 路径。企业版需要用户[设置 License](../../4.deployment-and-installation/deploy-license.md) 才可以正常启动并使用企业版功能。仅企业版 Nebula Graph 需要设置本参数,其他周边工具如何设置 License,请参见相应周边工具的部署文档。| !!! Note @@ -42,6 +43,7 @@ Meta 服务提供了两份初始配置文件`nebula-metad.conf.default`和`nebul |`stdout_log_file` |`metad-stdout.log` | 标准输出日志文件名称。 | |`stderr_log_file` |`metad-stderr.log` | 标准错误日志文件名称。 | |`stderrthreshold` | `2` | 要复制到标准错误中的最小日志级别(`minloglevel`)。 | +| `timestamp_in_logfile_name` | `true` | 日志文件名称中是否包含时间戳。`true`表示包含,`false`表示不包含。 | ## networking 配置 diff --git a/docs-2.0/5.configurations-and-logs/1.configurations/3.graph-config.md b/docs-2.0/5.configurations-and-logs/1.configurations/3.graph-config.md index d9978d65f6..55a1bb8c82 100644 --- a/docs-2.0/5.configurations-and-logs/1.configurations/3.graph-config.md +++ b/docs-2.0/5.configurations-and-logs/1.configurations/3.graph-config.md @@ -44,6 +44,7 @@ Graph 服务提供了两份初始配置文件`nebula-graphd.conf.default`和`neb |`stdout_log_file` |`graphd-stdout.log` | 标准输出日志文件名称。 | |`stderr_log_file` |`graphd-stderr.log` | 标准错误日志文件名称。 | |`stderrthreshold` | `2` | 要复制到标准错误中的最小日志级别(`minloglevel`)。 | +| `timestamp_in_logfile_name` | `true` | 日志文件名称中是否包含时间戳。`true`表示包含,`false`表示不包含。 | ## query 配置 diff --git a/docs-2.0/5.configurations-and-logs/1.configurations/4.storage-config.md b/docs-2.0/5.configurations-and-logs/1.configurations/4.storage-config.md index 65092b71cd..1e21b57472 100644 --- a/docs-2.0/5.configurations-and-logs/1.configurations/4.storage-config.md +++ b/docs-2.0/5.configurations-and-logs/1.configurations/4.storage-config.md @@ -47,6 +47,7 @@ Storage 服务提供了两份初始配置文件`nebula-storaged.conf.default`和 |`stdout_log_file` |`storaged-stdout.log` | 标准输出日志文件名称。 | |`stderr_log_file` |`storaged-stderr.log` | 标准错误日志文件名称。 | |`stderrthreshold` | `2` | 要复制到标准错误中的最小日志级别(`minloglevel`)。 | +| `timestamp_in_logfile_name` | `true` | 日志文件名称中是否包含时间戳。`true`表示包含,`false`表示不包含。 | ## networking 配置 diff --git a/docs-2.0/7.data-security/1.authentication/3.role-list.md b/docs-2.0/7.data-security/1.authentication/3.role-list.md index 7a40151744..8dcbd3ea43 100644 --- a/docs-2.0/7.data-security/1.authentication/3.role-list.md +++ b/docs-2.0/7.data-security/1.authentication/3.role-list.md @@ -57,7 +57,6 @@ Nebula Graph 内置了多种角色,说明如下: |权限|God |Admin|DBA|User|Guest|相关语句| |:---|:---|:---|:---|:---|:---|:---| |Read space|Y|Y|Y|Y|Y|`USE`、`DESCRIBE SPACE`| - |Write space|Y|||||`CREATE SPACE`、`DROP SPACE`、`CREATE SNAPSHOT`、`DROP SNAPSHOT`、`BALANCE DATA`、`BALANCE DATA STOP`、`BALANCE DATA REMOVE`、`BALANCE LEADER`、`ADMIN`、`CONFIG`、`INGEST`、`DOWNLOAD`、`BUILD TAG INDEX`、`BUILD EDGE INDEX`| |Read schema|Y|Y|Y|Y|Y|`DESCRIBE TAG`、`DESCRIBE EDGE`、`DESCRIBE TAG INDEX`、`DESCRIBE EDGE INDEX`| |Write schema|Y|Y|Y|||`CREATE TAG`、`ALTER TAG`、`CREATE EDGE`、`ALTER EDGE`、`DROP TAG`、`DELETE TAG`、`DROP EDGE`、`CREATE TAG INDEX`、`CREATE EDGE INDEX`、`DROP TAG INDEX`、`DROP EDGE INDEX`| |Write user|Y|||||`CREATE USER`、`DROP USER`、`ALTER USER`| @@ -66,6 +65,10 @@ Nebula Graph 内置了多种角色,说明如下: |Write data|Y|Y|Y|Y||`INSERT VERTEX`、`UPDATE VERTEX`、`INSERT EDGE`、`UPDATE EDGE`、`DELETE VERTEX`、`DELETE EDGES`、`DELETE TAG`| |Show operations|Y|Y|Y|Y|Y|`SHOW`、`CHANGE PASSWORD`| |Job|Y|Y|Y|Y||`SUBMIT JOB COMPACT`、`SUBMIT JOB FLUSH`、`SUBMIT JOB STATS`、`STOP JOB`、`RECOVER JOB`| + |Write space|Y|||||`CREATE SPACE`、`DROP SPACE`、`CREATE SNAPSHOT`、`DROP SNAPSHOT`、`BALANCE`、`ADMIN`、`CONFIG`、`INGEST`、`DOWNLOAD`、`BUILD TAG INDEX`、`BUILD EDGE INDEX`| + !!! caution diff --git a/docs-2.0/7.data-security/2.backup-restore/3.br-backup-data.md b/docs-2.0/7.data-security/2.backup-restore/3.br-backup-data.md deleted file mode 100644 index 6bad9f2e07..0000000000 --- a/docs-2.0/7.data-security/2.backup-restore/3.br-backup-data.md +++ /dev/null @@ -1,58 +0,0 @@ -# 使用 BR 备份数据 - -BR 编译成功后,可以备份整个图空间的数据,本文介绍如何使用 BR 备份数据。 - -## 准备工作 - -- BR 编译完成。如何编译 BR,请参见[编译 BR](2.compile-br.md)。 - -- 确认 Nebula Graph 服务正在运行中。 - -- BR 可以免密登录服务器,即在 BR 机器上的账号可以通过 SSH 免密登录到 Meta 服务器和 Storage 服务器。详情请参见 [SSH tunnels with keys](http://alexander.holbreich.org/ssh-tunnel-without-password/)。 - -- 如果使用 Alibaba Cloud OSS 或 Amazon S3 保存备份文件,请确保 Meta 服务器、Storage 服务器和 BR 机器都已安装相应的客户端。详情请参见 [Alibaba Cloud ossutil 文档](https://www.alibabacloud.com/help/zh/doc-detail/120075.htm#concept-303829) 和 [Amazon S3 CLI 文档](https://docs.amazonaws.cn/cli/latest/userguide/cli-services-s3.html)。 - - !!! Note - - 请创建软链接方便使用 ossutil 命令。命令为`ln -s // /usr/local/bin/ossutil`,根据实际路径和系统替换内容。 - -- 如果在本地保存备份文件,需要在 Meta 服务器、Storage 服务器和 BR 机器上创建绝对路径相同的目录,并记录绝对路径,同时需要保证账号对该目录有写权限。 - - !!! Note - - 在生产环境中,我们建议用户将 NFS (Network File System)存储设备挂载到 Meta 服务器、Storage 服务器和 BR 机器上进行本地备份,或者使用 Alibaba Cloud OSS、Amazon S3 进行远程备份。否则当需要通过本地文件恢复数据时,必须手动将这些备份文件移动到指定目录,会导致数据冗余和某些问题。更多信息,请参见[使用 BR 恢复数据](4.br-restore-data.md)。 - -## 操作步骤 - -运行以下命令对整个集群进行全量备份操作。 - -!!! Note - - 确保本地存储备份文件的路径存在。 - -```bash -$ ./bin/br backup full --meta --storage --user --verbose -``` - -例如运行以下命令对 meta 服务的地址为`192.168.*.*:9559`,用户名为`test`的整个集群进行全量备份操作,并将备份文件保存到本地的 `/home/test/backup`。 - -```bash - $ ./bin/br backup full --meta "192.168.*.*:9559" --storage "local:///home/test/backup" --user "test" --verbose - ``` - -以下列出命令的相关参数。 - -| 参数 | 是否必需 | 默认值 | 说明 | 数据类型 | -| --- | --- | --- | --- | --- | -| --concurrent | 否 | 5 | 针对阿里云 OSS 最大并发数。 | int | -| --connection | 否 | 5 | 最大 ssh 连接数。 | int | -| --extra_args | 否 | 无 | 备份存储工具(OSS/HDFS/S3)用于备份的参数。 | string | -| --log | 否 | "br.log" | 日志路径。 | string | -| --meta | 是| 无 | meta 服务的地址和端口号。 | string | -| --stroage | 是 | 无 | BR 备份数据存储位置,格式为:\://\
Schema:可选值为 `local` 和 `hdfs`。
PATH:存储位置的路径。 | string | -| --user | 是 | 无 | 登录到 meta/storage 服务所在主机的用户名。 | string | -| --verbose | 否 | 无 | 显示的详细信息。 | - | - -## 下一步 - -备份文件生成后,可以使用 BR 将备份文件的数据恢复到 Nebula Graph 中。具体操作,请参见[使用 BR 恢复数据](4.br-restore-data.md)。 diff --git a/docs-2.0/7.data-security/2.backup-restore/4.br-restore-data.md b/docs-2.0/7.data-security/2.backup-restore/4.br-restore-data.md deleted file mode 100644 index b4cf197353..0000000000 --- a/docs-2.0/7.data-security/2.backup-restore/4.br-restore-data.md +++ /dev/null @@ -1,79 +0,0 @@ -# 使用 BR 恢复数据 - -如果使用 BR 备份了 Nebula Graph 的数据,可以通过备份文件进行数据恢复。本文介绍如何通过备份文件恢复数据。 - -!!! caution - - 恢复执行成功后,目标集群上已有的数据会被删除,然后替换为备份文件中的数据。建议提前备份目标集群上的数据。 - -!!! caution - - 数据恢复需要离线进行。 - -## 准备工作 - -- BR 编译完成。如何编译 BR,请参见[编译 BR](2.compile-br.md)。 - -- 确认没有应用程序连接到待恢复数据的 Nebula Graph 集群。 - -- 确认集群的拓扑结构一致,即原集群和目标集群的主机数量一致。 - -- BR 可以免密登录服务器,即在 BR 机器上的账号可以通过 SSH 免密登录到 Meta 服务器和 Storage 服务器。详情请参见 [SSH tunnels with keys](http://alexander.holbreich.org/ssh-tunnel-without-password/)。 - - !!! caution - - 该账号必须有 Nebula Graph 安装目录的写权限,meta/storage 服务的数据目录(--data_path)的写权限。 - -- 执行恢复操作时需使用 `root` 用户。 - -- 如果使用 Alibaba Cloud OSS 或 Amazon S3 保存备份文件,请确保 Meta 服务器、Storage 服务器和 BR 机器都已安装相应的客户端。详情请参见 [Alibaba Cloud ossutil 文档](https://www.alibabacloud.com/help/zh/doc-detail/120075.htm#concept-303829) 和 [Amazon S3 CLI 文档](https://docs.amazonaws.cn/cli/latest/userguide/cli-services-s3.html)。 - - !!! caution - - 请创建软链接方便使用 ossutil 命令。命令为`ln -s // /usr/local/bin/ossutil`,根据实际路径和系统替换内容。 - -## 操作步骤 - -1. 用户可以使用以下命令列出现有备份信息: - - ```bash - $ ./bin/br show --storage - ``` - 例如,可以使用以下命令列出在本地 `/home/test/backup` 路径中的备份的信息。 - ```bash - $ ./bin/br show --storage "local:///home/test/backup" - +----------------------------+---------------------+------------------+-------------+---------------+ - | NAME | CREATE TIME | SPACES | FULL BACKUP | SPECIFY SPACE | - +----------------------------+---------------------+------------------+-------------+---------------+ - | BACKUP_2021_07_29_06_51_09 | 2021-07-29 06:51:09 | basketballplayer | true | true | - | BACKUP_2021_07_29_07_55_08 | 2021-07-29 07:55:09 | basketballplayer | true | true | - +----------------------------+---------------------+------------------+-------------+---------------+ - ``` - -2. 用户可以使用以下命令恢复数据: - ``` - [root]# ./bin/br restore full --meta --storage --name --user - ``` - - 例如,可以使用以下命令,将本地 `/home/foesa/backup` 路径中的数据恢复到地址为`192.168.*.*:9559`,meta/storage 服务所在主机的用户名为`root`的集群: - - ``` - [root]# ./bin/br restore full --meta "192.168.*.*:9559" --storage "local:///home/test/backup" --name "BACKUP_2021_07_29_07_55_08" --user "root" - ``` - - 如果返回如下信息,表示数据已经恢复成功。 - ```bash - restore successed - ``` - - 以下列出命令的相关参数。 - - | 参数 | 是否必需 | 默认值 | 说明 | 数据类型 | - | --- | --- | --- | --- | --- | - | --concurrent | 否 | 5 | 针对阿里云 OSS 最大并发数。 | int | - | --extra_args | 否 | 无 | 备份存储工具(OSS/HDFS/S3)用于备份的参数。 | string | - | -h,-help | 否 | 无 | 查看帮助。 | - | - | --meta | 是 | 无 | meta 服务的地址和端口号。 | string | - | --name | 是 | 无 | 备份名字。 | string | - | --storage | 是 | 无 | BR 备份数据存储路径。 | string | - | --user | 是 | 无 | 登录到 meta/storage 服务所在主机的用户名。 | string | diff --git a/docs-2.0/8.service-tuning/2.graph-modeling.md b/docs-2.0/8.service-tuning/2.graph-modeling.md index 0d0951654c..7474c39998 100644 --- a/docs-2.0/8.service-tuning/2.graph-modeling.md +++ b/docs-2.0/8.service-tuning/2.graph-modeling.md @@ -110,7 +110,7 @@ nebula> MATCH (v1:player)-[e:temp]->() return collect(e.tmp); 在某些场景下,图需要同时带有时序信息,以描述整个图的结构随着时间变化的情况 [^twitter]。 -Nebula Graph {{ nebula.release }} 的边可以使用 Rank 字段存放时间信息 (int64),但是点上没有字段可以存放时间信息(存放在属性会被新写入覆盖)。一个折中的办法是在点上设计自己指向自己的自环,并将时间信息放置在自环上。但 Rank 字段目前缺少 `next(), pre(), head(), tail(), max(), min(), lessThan(), moreThan()` 等语法功能(也不能创建索引加速),需要取得全部的 Rank 然后应用程序自己拼接。 +Nebula Graph {{ nebula.release }} 的边可以使用 Rank 字段存放时间信息 (int64),但是点上没有字段可以存放时间信息(存放在属性会被新写入覆盖)。一个折中的办法是在点上设计自己指向自己的自环,并将时间信息放置在自环的 Rank 上。 ![image](sequence.png) diff --git a/docs-2.0/8.service-tuning/3.system-design.md b/docs-2.0/8.service-tuning/3.system-design.md index 72a97ac933..a140e96269 100644 --- a/docs-2.0/8.service-tuning/3.system-design.md +++ b/docs-2.0/8.service-tuning/3.system-design.md @@ -5,13 +5,16 @@ - Nebula Graph {{ nebula.release }} 更擅长处理(互联网式的)有大量并发的小请求。也即:虽然全图很大(万亿点边),但是每个请求要访问到的子图本身并不大(几百万个点边)——单个请求时延不大;但这类请求的并发数量特别多——QPS 大。 - 但对于一些交互分析型的场景,并发请求的数量不多,而每个请求要访问的子图本身特别大(亿以上)。为降低时延,可以在应用程序中将一个大的请求,拆分为多个小请求,并发发送给多个 graphd。这样可以降低单个大请求的时延,降低单个 graphd 的内存占用。另外,也可以使用[图计算功能 Nebula Algorithm](../nebula-algorithm.md)。 - + ## 数据传输与优化 - 读写平衡。Nebula Graph 适合读写平衡性的在线场景,也即 OLTP 型的的“并发的发生写入与读取”;而非数仓 OLAP 型的“一次写入多次读取”。 diff --git a/docs-2.0/8.service-tuning/compaction.md b/docs-2.0/8.service-tuning/compaction.md index 8dc48f62e2..f16debb683 100644 --- a/docs-2.0/8.service-tuning/compaction.md +++ b/docs-2.0/8.service-tuning/compaction.md @@ -118,9 +118,10 @@ Level Files Size Score Read(GB) Rn(GB) Rnp1(GB) Write(GB) Wnew(GB) Mov ### 全量`Compaction`操作会耗费多长时间? -如果已经设置读写速率限制,例如`rate_limit`限制为 20MB/S 时,用户可以通过 `硬盘使用量/rate_limit` 预估需要耗费的时间。如果没有设置读写速率限制,根据经验,速率大约为 50MB/S。 +如果已经设置读写速率限制,例如`rocksdb_rate_limit`限制为 20MB/S 时,用户可以通过 `硬盘使用量/rocksdb_rate_limit` 预估需要耗费的时间。 +如果没有设置读写速率限制,根据经验,速率大约为 50MB/S。 -### 可以动态调整`rate_limit`吗? +### 可以动态调整`rocksdb_rate_limit`吗? 不可以。 diff --git a/docs-2.0/8.service-tuning/load-balance.md b/docs-2.0/8.service-tuning/load-balance.md index 3952c399d4..d84dbb8ad9 100644 --- a/docs-2.0/8.service-tuning/load-balance.md +++ b/docs-2.0/8.service-tuning/load-balance.md @@ -2,6 +2,11 @@ 用户可以使用`BALANCE`语句平衡分片和 Raft leader 的分布,或者清空某些 Storage 服务器方便进行维护。详情请参见 [BALANCE](../3.ngql-guide/18.operation-and-maintenance-statements/2.balance-syntax.md)。 +!!! compatibility "历史版本兼容性" + + 不支持`BALANCE DATA`命令。 + + ## 均衡 leader 分布 @@ -141,17 +145,16 @@ nebula> BALANCE LEADER; ```ngql nebula> SHOW HOSTS; -+------------------+------+----------+--------------+-----------------------------------+------------------------+ -| Host | Port | Status | Leader count | Leader distribution | Partition distribution | -+------------------+------+----------+--------------+-----------------------------------+------------------------+ -| "192.168.10.100" | 9779 | "ONLINE" | 4 | "basketballplayer:3" | "basketballplayer:8" | -| "192.168.10.101" | 9779 | "ONLINE" | 8 | "basketballplayer:3" | "basketballplayer:8" | -| "192.168.10.102" | 9779 | "ONLINE" | 3 | "basketballplayer:3" | "basketballplayer:8" | -| "192.168.10.103" | 9779 | "ONLINE" | 0 | "basketballplayer:2" | "basketballplayer:7" | -| "192.168.10.104" | 9779 | "ONLINE" | 0 | "basketballplayer:2" | "basketballplayer:7" | -| "192.168.10.105" | 9779 | "ONLINE" | 0 | "basketballplayer:2" | "basketballplayer:7" | -| "Total" | | | 15 | "basketballplayer:15" | "basketballplayer:45" | -+------------------+------+----------+--------------+-----------------------------------+------------------------+ ++------------------+------+----------+--------------+-----------------------------------+------------------------+---------+ +| Host | Port | Status | Leader count | Leader distribution | Partition distribution | Version | ++------------------+------+----------+--------------+-----------------------------------+------------------------+---------+ +| "192.168.10.100" | 9779 | "ONLINE" | 4 | "basketballplayer:3" | "basketballplayer:8" | "3.0.0" | +| "192.168.10.101" | 9779 | "ONLINE" | 8 | "basketballplayer:3" | "basketballplayer:8" | "3.0.0" | +| "192.168.10.102" | 9779 | "ONLINE" | 3 | "basketballplayer:3" | "basketballplayer:8" | "3.0.0" | +| "192.168.10.103" | 9779 | "ONLINE" | 0 | "basketballplayer:2" | "basketballplayer:7" | "3.0.0" | +| "192.168.10.104" | 9779 | "ONLINE" | 0 | "basketballplayer:2" | "basketballplayer:7" | "3.0.0" | +| "192.168.10.105" | 9779 | "ONLINE" | 0 | "basketballplayer:2" | "basketballplayer:7" | "3.0.0" | ++------------------+------+----------+--------------+-----------------------------------+------------------------+---------+ ``` !!! caution diff --git a/docs-2.0/README.md b/docs-2.0/README.md index 53e9a84a1c..841d5692aa 100644 --- a/docs-2.0/README.md +++ b/docs-2.0/README.md @@ -15,6 +15,7 @@ Nebula Graph 是一款开源的、分布式的、易扩展的原生图数据库 * [简介](1.introduction/1.what-is-nebula-graph.md) * [快速开始](2.quick-start/1.quick-start-workflow.md) * [配置要求](4.deployment-and-installation/1.resource-preparations.md) +* [nGQL 命令汇总](2.quick-start/6.cheatsheet-for-ngql-command.md) * [FAQ](20.appendix/0.FAQ.md) * [生态工具](20.appendix/6.eco-tool-version.md) diff --git a/docs-2.0/nebula-algorithm.md b/docs-2.0/nebula-algorithm.md index 98919848ba..3ebc0c2d18 100644 --- a/docs-2.0/nebula-algorithm.md +++ b/docs-2.0/nebula-algorithm.md @@ -2,6 +2,20 @@ [Nebula Algorithm](https://github.com/vesoft-inc/nebula-algorithm) (简称 Algorithm)是一款基于 [GraphX](https://spark.apache.org/graphx/) 的 Spark 应用程序,通过提交 Spark 任务的形式使用完整的算法工具对 Nebula Graph 数据库中的数据执行图计算,也可以通过编程形式调用 lib 库下的算法针对 DataFrame 执行图计算。 +## 版本兼容性 + +Nebula Algorithm 版本和 Nebula Graph 内核的版本对应关系如下。 + +|Algorithm client 版本|Nebula Graph 版本| +|:---|:---| +|3.0-SNAPSHOT | nightly | +|{{algorithm.release}}| {{nebula.release}} | +| 2.6.x | 2.6.x | +| 2.5.0 | 2.5.0、2.5.1 | +| 2.1.0 | 2.0.0、2.0.1 | + + + ## 前提条件 在使用 Algorithm 之前,用户需要确认以下信息: @@ -22,6 +36,27 @@ - 图计算会输出点的数据集,算法结果会以DataFrame形式作为点的属性存储。用户可以根据业务需求,自行对算法结果做进一步操作,例如统计、筛选。 +- 如果将算法结果写入到 Nebula Graph 中,请确保对应图空间中的 Tag 有对应算法结果名称的属性。各项算法对应的属性如下。 + + | 算法 | 属性名称 |属性数据类型| + |:------------------------:|:-----------------------:|:-----------:| + | pagerank | pagerank |double/string| + | louvain | louvain | int/string | + | kcore | kcore | int/string | + | labelpropagation | lpa | int/string | + | connectedcomponent | cc | int/string | + |stronglyconnectedcomponent| scc | int/string | + | betweenness | betweenness |double/string| + | shortestpath | shortestpath | string | + | degreestatic |degree,inDegree,outDegree| int/string | + | trianglecount | trianglecount | int/string | + | clusteringcoefficient | clustercoefficient |double/string| + | closeness | closeness |double/string| + | hanp | hanp | int/string | + | bfs | bfs | string | + | jaccard | jaccard | string | + | node2vec | node2vec | string | + ## 支持算法 Nebula Algorithm 支持的图计算算法如下。 @@ -32,14 +67,19 @@ Nebula Algorithm 支持的图计算算法如下。 | Louvain | 社区发现 | 社团挖掘、层次化聚类| | KCore | K 核 |社区发现、金融风控| | LabelPropagation | 标签传播 |资讯传播、广告推荐、社区发现| + | Hanp |标签传播进阶版|社区发现、推荐 | | ConnectedComponent | 联通分量 |社区发现、孤岛发现| |StronglyConnectedComponent| 强联通分量 |社区发现| | ShortestPath | 最短路径 |路径规划、网络规划| | TriangleCount | 三角形计数 |网络结构分析| | GraphTriangleCount | 全图三角形计数 |网络结构及紧密程度分析| | BetweennessCentrality | 介数中心性 |关键节点挖掘,节点影响力计算| + | Closeness | 接近中心性 |关键节点挖掘、节点影响力计算| | DegreeStatic | 度统计 |图结构分析| | ClusteringCoefficient | 聚集系数 |推荐、电信诈骗分析| + | Jaccard | 杰卡德相似度计算| 相似度计算、推荐| + | BFS | 广度优先遍历| 层序遍历、最短路径规划| + | Node2Vec | - | 图分类 | ## 实现方法 @@ -75,11 +115,11 @@ Nebula Algorithm 实现图计算的流程如下: $ mvn clean package -Dgpg.skip -Dmaven.javadoc.skip=true -Dmaven.test.skip=true ``` -编译完成后,在目录`nebula-algorithm/target`下生成类似文件`nebula-algorithm-{{algorithm.release}}.jar`。 +编译完成后,在目录`nebula-algorithm/target`下生成类似文件`nebula-algorithm-3.x.x.jar`。 ### Maven 远程仓库下载 -[下载地址](https://repo1.maven.org/maven2/com/vesoft/nebula-algorithm/{{algorithm.release}}/) +[下载地址](https://repo1.maven.org/maven2/com/vesoft/nebula-algorithm/) ## 使用方法 @@ -207,15 +247,16 @@ Nebula Algorithm 实现图计算的流程如下: } algorithm: { - # 需要执行的算法,可选值为:pagerank、louvain、connectedcomponent、 - # labelpropagation、shortestpaths、degreestatic、kcore、 - # stronglyconnectedcomponent、trianglecount、betweenness + # 需要执行的算法,可选值为: + # pagerank、louvain、connectedcomponent、labelpropagation、shortestpaths、 + # degreestatic、kcore、stronglyconnectedcomponent、trianglecount、 + # betweenness、graphtriangleCount。 executeAlgo: pagerank # PageRank 参数 pagerank: { maxIter: 10 - resetProb: 0.15 # 默认为 0.15 + resetProb: 0.15 } # Louvain 参数 @@ -225,38 +266,9 @@ Nebula Algorithm 实现图计算的流程如下: tol: 0.5 } - # ConnectedComponent/StronglyConnectedComponent 参数 - connectedcomponent: { - maxIter: 20 - } + # ... - # LabelPropagation 参数 - labelpropagation: { - maxIter: 20 - } - - # ShortestPath 参数 - shortestpaths: { - # several vertices to compute the shortest path to all vertices. - landmarks: "1" - } - - # DegreeStatic 参数 - degreestatic: {} - - # KCore 参数 - kcore:{ - maxIter:10 - degree:1 - } - - # TriangleCount 参数 - trianglecount:{} - - # BetweennessCentrality 参数 - betweenness:{ - maxIter:5 - } + } } ``` @@ -269,7 +281,7 @@ Nebula Algorithm 实现图计算的流程如下: 示例: ```bash - ${SPARK_HOME}/bin/spark-submit --master "local" --class com.vesoft.nebula.algorithm.Main /root/nebula-algorithm/target/nebula-algorithm-{{algorithm.release}}.jar -p /root/nebula-algorithm/src/main/resources/application.conf + ${SPARK_HOME}/bin/spark-submit --master "local" --class com.vesoft.nebula.algorithm.Main /root/nebula-algorithm/target/nebula-algorithm-3.0-SNAPSHOT.jar -p /root/nebula-algorithm/src/main/resources/application.conf ``` ## 视频 diff --git a/docs-2.0/nebula-plato.md b/docs-2.0/nebula-analytics.md similarity index 80% rename from docs-2.0/nebula-plato.md rename to docs-2.0/nebula-analytics.md index 6f3612a1c0..2f4d461261 100644 --- a/docs-2.0/nebula-plato.md +++ b/docs-2.0/nebula-analytics.md @@ -1,6 +1,6 @@ -# Nebula Plato +# Nebula Analytics -[Nebula Plato](https://github.com/vesoft-inc/nebula-algorithm) 是一款集成了开源高性能图计算框架 [Plato](https://github.com/tencent/plato) 的应用程序,支持利用 Plato 对 Nebula Graph 数据库中的数据执行图计算。 +Nebula Analytics 是一款高性能图计算框架工具,支持对 Nebula Graph 数据库中的数据执行图分析。 !!! enterpriseonly @@ -8,7 +8,7 @@ ## 适用场景 -支持将数据源为 Nebula Graph 集群、HDFS 上的 CSV 文件或本地 CSV 文件中的数据导入 Nebula Plato,并将图计算结果输出至 Nebula Graph 集群、HDFS 上的 CSV 文件或本地 CSV 文件。 +支持将数据源为 Nebula Graph 集群、HDFS 上的 CSV 文件或本地 CSV 文件中的数据导入 Nebula Analytics,并将图计算结果输出至 Nebula Graph 集群、HDFS 上的 CSV 文件或本地 CSV 文件。 ## 使用限制 @@ -16,15 +16,15 @@ ## 版本兼容性 -Nebula Plato 版本和 Nebula Graph 内核的版本对应关系如下。 +Nebula Analytics 版本和 Nebula Graph 内核的版本对应关系如下。 -|Plato client 版本|Nebula Graph 版本| +|Analytics client 版本|Nebula Graph 版本| |:---|:---| -|{{plato.release}}|{{nebula.release}}| +|{{analytics.release}}|{{nebula.release}}| ## 支持算法 -Nebula Plato 支持的图计算算法如下。 +Nebula Analytics 支持的图计算算法如下。 | 算法名 |说明 |分类 | |:----------------------|:----------------|:-----------| @@ -36,35 +36,34 @@ Nebula Plato 支持的图计算算法如下。 | DegreeCentrality | 度中心性 | 节点重要度 | | TriangleCount | 三角计数 | 图特征 | | LPA | 标签传播 | 社区发现 | +| HANP | 标签传播进阶版 | 社区发现 | | WCC | 联通分量 | 社区发现 | | LOUVAIN | 社区发现 | 社区发现 | -| HANP | 跳衰减和节点偏好 | 社区发现 | | Clustering Coefficient| 聚集系数 | 聚类 | -## 安装 Nebula Plato +## 安装 Nebula Analytics -在多个机器安装多个 Nebula Plato 服务构成集群时,需要安装路径相同,并设置节点间 SSH 免密登录。 - -### RPM包安装 +在多个机器安装由多个 Nebula Analytics 服务构成的集群时,需要安装路径相同,并设置节点间 SSH 免密登录。 ```bash -sudo rpm -i nebula-plato-1.0-centos.x86_64.rpm --prefix /home/xxx/nebula-plato +sudo rpm -i nebula-analytics-1.0.0-centos.x86_64.rpm --prefix /home/xxx/nebula-analytics ``` + + ## 使用方法 安装完成后,用户可以设置不同算法的参数,然后执行脚本,即可获得算法的结果,并导出为指定格式。 -1. 选择 Nebula Plato 集群的任一节点,进入目录`scripts`。 +1. 选择 Nebula Analytics 集群的任一节点,进入目录`scripts`。 ```bash $ cd scripts @@ -135,7 +136,7 @@ sudo rpm -i nebula-plato-1.0-centos.x86_64.rpm --prefix /home/xxx/nebula-plato # 写回时,每次写入的行数。 --write_batch_size=1000 # 写回失败的数据所存储的文件。 - --err_file=/home/jie.wang/plato/err.txt + --err_file=/home/xxx/analytics/err.txt ``` 2. 修改需要使用的算法脚本,例如`run_pagerank.sh`,设置相关参数。 @@ -208,10 +209,10 @@ sudo rpm -i nebula-plato-1.0-centos.x86_64.rpm --prefix /home/xxx/nebula-plato ITERATIONS=${ITERATIONS:=100} ``` -3. 修改配置文件`cluster`,设置执行算法的 Nebula Plato 集群节点和任务分配权重。 +3. 修改配置文件`cluster`,设置执行算法的 Nebula Analytics 集群节点和任务分配权重。 ```bash - # Nebula Plato 集群节点 IP 地址:任务分配权重 + # Nebula Analytics 集群节点 IP 地址:任务分配权重 192.168.8.200:1 192.168.8.201:1 192.168.8.202:1 @@ -227,4 +228,4 @@ sudo rpm -i nebula-plato-1.0-centos.x86_64.rpm --prefix /home/xxx/nebula-plato - 输出至 Nebula Graph 集群,请根据`nebula.conf`的设置查看计算结果。 - - 输出至 HDFS 上的 CSV 文件或本地 CSV 文件,请根据图计算脚本内的`OUTPUT`设置查看计算结果,计算结果为`.gz`格式的压缩文件。 \ No newline at end of file + - 输出至 HDFS 上的 CSV 文件或本地 CSV 文件,请根据图计算脚本内的`OUTPUT`设置查看计算结果,计算结果为`.gz`格式的压缩文件。 diff --git a/docs-2.0/nebula-bench.md b/docs-2.0/nebula-bench.md index c9a0f909fb..5834784c64 100644 --- a/docs-2.0/nebula-bench.md +++ b/docs-2.0/nebula-bench.md @@ -12,6 +12,7 @@ Nebula Bench 是一款利用 LDBC 数据集对 Nebula Graph 进行性能测试 [Release](https://github.com/vesoft-inc/nebula-bench/releases/tag/{{bench.tag}}) + 详细使用说明请参见 [Nebula Bench](https://github.com/vesoft-inc/nebula-bench/blob/{{bench.branch}}/README_cn.md)。 diff --git a/docs-2.0/7.data-security/2.backup-restore/1.what-is-br.md b/docs-2.0/nebula-br/1.what-is-br.md similarity index 90% rename from docs-2.0/7.data-security/2.backup-restore/1.what-is-br.md rename to docs-2.0/nebula-br/1.what-is-br.md index c76bbe5ac7..f9adaf9076 100644 --- a/docs-2.0/7.data-security/2.backup-restore/1.what-is-br.md +++ b/docs-2.0/nebula-br/1.what-is-br.md @@ -6,11 +6,10 @@ Backup&Restore(简称 BR)是一款命令行界面(CLI)工具,可以帮 - 一键操作备份和恢复数据。 - 支持基于以下备份文件恢复数据: - - 本地磁盘(SSD 或 HDD) - - Hadoop 分布式文件系统(HDFS) - - 阿里云对象存储(Alibaba Cloud OSS) - - 亚马逊对象存储(Amazon S3)(TODO:coding) -- 支持备份整个 Nebula Graph 集群,暂不支持指定图空间数据。 + - 本地磁盘(SSD 或 HDD),建议仅在测试环境使用。 + - 兼容亚马逊对象存储(Amazon S3)云存储服务接口,例如:阿里云对象存储(Alibaba Cloud OSS)、MinIO、Ceph RGW 等。 +- 支持备份并恢复整个 Nebula Graph 集群。 +- (实验性功能)支持备份指定图空间数据。 ## 限制 @@ -22,8 +21,10 @@ Backup&Restore(简称 BR)是一款命令行界面(CLI)工具,可以帮 - 数据备份过程中,指定图空间中的 DDL 和 DML 语句将会阻塞,我们建议在业务低峰期进行操作,例如凌晨 2 点至 5 点。 - 数据恢复仅支持在相同拓扑的集群上进行,即原集群和目标集群的主机数量必须相同。 - 数据恢复需要删除数据并重启,建议离线进行。 +- (实验性功能)如果备份 A 集群中的某个指定图空间,此备份无法还原至另一个集群 B,还原该指定图空间时将清除集群中其余所有图空间。 - + + + ## 如何使用 BR 可以按照如下步骤使用 BR: diff --git a/docs-2.0/7.data-security/2.backup-restore/2.compile-br.md b/docs-2.0/nebula-br/2.compile-br.md similarity index 85% rename from docs-2.0/7.data-security/2.backup-restore/2.compile-br.md rename to docs-2.0/nebula-br/2.compile-br.md index d6b4116510..f8acbae645 100644 --- a/docs-2.0/7.data-security/2.backup-restore/2.compile-br.md +++ b/docs-2.0/nebula-br/2.compile-br.md @@ -9,7 +9,7 @@ ## 操作步骤 -1. 克隆`nebula-storage`库至机器。 +1. 克隆`nebula-br`库至机器。 ```bash git clone https://github.com/vesoft-inc/nebula-br.git @@ -31,8 +31,8 @@ ```bash [nebula-br]$ bin/br version -Nebula Backup And Restore Ultility Tool,V-0.1.0 - GitSha: 8e994dc +Nebula Backup And Restore Utility Tool,V-0.6.0 + GitSha: 079e7c7 GitRef: master please run "help" subcommand for more infomation. ``` diff --git a/docs-2.0/nebula-br/3.br-backup-data.md b/docs-2.0/nebula-br/3.br-backup-data.md new file mode 100644 index 0000000000..1990ab4a3f --- /dev/null +++ b/docs-2.0/nebula-br/3.br-backup-data.md @@ -0,0 +1,66 @@ +# 使用 BR 备份数据 + +BR 编译成功后,可以备份整个图空间的数据,本文介绍如何使用 BR 备份数据。 + +## 准备工作 + +- BR 编译完成。如何编译 BR,请参见[编译 BR](2.compile-br.md)。 + +- 确认 Nebula Graph 服务正在运行中。 + +- 已下载 [nebula-agent](https://github.com/vesoft-inc/nebula-agent) 并在集群中的每个主机上运行代理服务。 + +- 如果在本地保存备份文件,需要在 Meta 服务器、Storage 服务器和 BR 机器上创建绝对路径相同的目录,并记录绝对路径,同时需要保证账号对该目录有写权限。 + + !!! Note + + 在生产环境中,我们建议用户将 NFS (Network File System)存储设备挂载到 Meta 服务器、Storage 服务器和 BR 机器上进行本地备份,或者使用 Alibaba Cloud OSS、Amazon S3 进行远程备份。否则当需要通过本地文件恢复数据时,必须手动将这些备份文件移动到指定目录,会导致数据冗余和某些问题。更多信息,请参见[使用 BR 恢复数据](4.br-restore-data.md)。 + +## 操作步骤 + +运行以下命令对整个集群进行全量备份操作。 + +!!! Note + + 确保备份文件的路径存在。 + +```bash +$ ./bin/br backup full --meta --storage +``` + +例如: + +- 运行以下命令对 meta 服务的地址为`127.0.0.1:9559`的整个集群进行全量备份操作,并将备份文件保存到本地的 `/home/nebula/backup/`路径下。 + + !!! caution + + 如果有多个 metad 地址,可以使用其中任意一个。 + + ```bash + $ ./bin/br backup full --meta "127.0.0.1:9559" --storage "local:///home/nebula/backup/" + ``` + +- 运行以下命令对 meta 服务的地址为`127.0.0.1:9559`的整个集群进行全量备份操作,并将备份文件保存到兼容 s3 协议的对象存储服务 `br-test` 桶下的`backup`中。 + + ```bash + $ ./bin/br backup full --meta "127.0.0.1:9559" --s3.endpoint "http://127.0.0.1:9000" --storage="s3://br-test/backup/" --s3.access_key=minioadmin --s3.secret_key=minioadmin --s3.region=default + ``` + +以下列出命令的相关参数。 + +| 参数 | 数据类型 | 是否必需 | 默认值 | 说明 | +| --- | --- | --- | --- | --- | +| `-h`,`--help` | - | 否 | 无 | 查看帮助。 | +| `--debug` | - | 否 | 无 | 查看更多日志信息。 | +| `--log` | string | 否 | `"br.log"` | 日志路径。 | +| `--meta` | string | 是| 无 | meta 服务的地址和端口号。 | +| `--spaces` | stringArray | 否 | 无 | (实验性功能)指定要备份的图空间名字,未指定将备份所有图空间。 | +| `--storage` | string | 是 | 无 | BR 备份数据存储位置,格式为:`://`
Schema:可选值为 `local` 和 `s3`。选择 s3 时,需要填写`s3.access_key`、`s3.endpoint`、`s3.region`和 `s3.secret_key`。
PATH:存储位置的路径。| +| `--s3.access_key` | string | 否 | 无 | 用于标识用户。 | +| `--s3.endpoint` | string | 否 | 无 | S3 对外服务的访问域名的 URL,指定 http 或 https。 | +| `--s3.region` | string | 否 | 无 | 数据中心所在物理位置。 | +| `--s3.secret_key`| string | 否 | 无 | 用户用于加密签名字符串和用来验证签名字符串的密钥,必须保密。 | + +## 下一步 + +备份文件生成后,可以使用 BR 将备份文件的数据恢复到 Nebula Graph 中。具体操作,请参见[使用 BR 恢复数据](4.br-restore-data.md)。 diff --git a/docs-2.0/nebula-br/4.br-restore-data.md b/docs-2.0/nebula-br/4.br-restore-data.md new file mode 100644 index 0000000000..74d3ba187d --- /dev/null +++ b/docs-2.0/nebula-br/4.br-restore-data.md @@ -0,0 +1,119 @@ +# 使用 BR 恢复数据 + +如果使用 BR 备份了 Nebula Graph 的数据,可以通过备份文件进行数据恢复。本文介绍如何通过备份文件恢复数据。 + +!!! caution + + 恢复执行成功后,目标集群上已有的数据会被删除,然后替换为备份文件中的数据。建议提前备份目标集群上的数据。 + +!!! caution + + 数据恢复需要离线进行。 + +## 准备工作 + +- BR 编译完成。如何编译 BR,请参见[编译 BR](2.compile-br.md)。 + +- 已下载 [nebula-agent](https://github.com/vesoft-inc/nebula-agent) 并在集群中的**每个**主机上运行代理服务。 + +- 确认没有应用程序连接到待恢复数据的 Nebula Graph 集群。 + +- 确认集群的拓扑结构一致,即原集群和目标集群的主机数量一致,且每个主机数据文件夹数量分布一致。 + +## 操作步骤 + +1. 用户可以使用以下命令列出现有备份信息: + + ```bash + $ ./bin/br show --storage + ``` + + 例如,可以使用以下命令列出在本地 `/home/nebula/backup` 路径中的备份的信息。 + ```bash + $ ./bin/br show --storage "local:///home/nebula/backup" + +----------------------------+---------------------+------------------------+-------------+------------+ + | NAME | CREATE TIME | SPACES | FULL BACKUP | ALL SPACES | + +----------------------------+---------------------+------------------------+-------------+------------+ + | BACKUP_2022_02_10_07_40_41 | 2022-02-10 07:40:41 | basketballplayer | true | true | + | BACKUP_2022_02_11_08_26_43 | 2022-02-11 08:26:47 | basketballplayer,foesa | true | true | + +----------------------------+---------------------+------------------------+-------------+------------+ + ``` + + 或使用以下命令列出在兼容 s3 协议的对象存储服务 `br-test` 桶下的`backup`中的备份的信息。 + ```bash + $ ./bin/br show --s3.endpoint "http://127.0.0.1:9000" --storage="s3://br-test/backup/" --s3.access_key=minioadmin --s3.secret_key=minioadmin --s3.region=default + ``` + + 以下列出命令的相关参数。 + + | 参数 | 数据类型 | 是否必需 | 默认值 | 说明 | + | --- | --- | --- | --- | --- | + | `-h,-help` | - | 否 | 无 | 查看帮助。 | + | `--debug` | - | 否 | 无 | 查看更多日志信息。 | + | `--log` | string | 否 | "br.log" | 日志路径。 | + | `--storage` | string | 是 | 无 | BR 备份数据存储位置,格式为:://
Schema:可选值为 `local` 和 `s3`。选择 s3 时,需要填写`s3.access_key`、`s3.endpoint`、`s3.region`和 `s3.secret_key`。
PATH:存储位置的路径。| + | `--s3.access_key` | string | 否 | 无 | 用于标识用户。 | + | `--s3.endpoint` | string | 否 | 无 | S3 对外服务的访问域名的 URL,指定 http 或 https。 | + | `--s3.region` | string | 否 | 无 | 数据中心所在物理位置。 | + | `--s3.secret_key` | string | 否 | 无 | 用户用于加密签名字符串和用来验证签名字符串的密钥,必须保密。 | + +2. 用户可以使用以下命令恢复数据: + ``` + $ ./bin/br restore full --meta --storage --name + ``` + + 例如,可以使用以下命令,将本地 `/home/nebula/backup/` 路径中的数据恢复到为 meta 地址为`127.0.0.1:9559`集群中: + + ``` + $ ./bin/br restore full --meta "127.0.0.1:9559" --storage "local:///home/nebula/backup/" --name BACKUP_2021_12_08_18_38_08 + ``` + + 或者使用以下命令,将兼容 s3 协议的对象存储服务 `br-test` 桶下的`backup`的备份,恢复到 meta 服务的地址为`127.0.0.1:9559`的集群中。 + ```bash + br restore full --meta "127.0.0.1:9559" --s3.endpoint "http://127.0.0.1:9000" --storage="s3://br-test/backup/" --s3.access_key=minioadmin --s3.secret_key=minioadmin --s3.region="default" --name BACKUP_2021_12_08_18_38_08 + ``` + + 如果返回如下信息,表示数据已经恢复成功。 + ```bash + Restore succeed. + ``` + + !!! caution + + 如果用户新集群的IP和备份集群不同,在恢复集群后需要使用`add host`向新集群中添加 Storage 主机。 + + 以下列出命令的相关参数。 + + | 参数 | 数据类型 | 是否必需 | 默认值 | 说明 | + | --- | --- | --- | --- | --- | + | `-h,-help` | - | 否 | - | 查看帮助。 | + | `--debug` | - | 否 | 无 | 查看更多日志信息。 | + | `--log` | string | 否 | "br.log" | 日志路径。 | + | `--meta` | string |是| 无 | meta 服务的地址和端口号。 | + | `--name` | string | 是 | 无 | 备份名字。 | + | `--storage` | string | 是 | 无 | BR 备份数据存储位置,格式为:://
Schema:可选值为 `local` 和 `s3`。选择 s3 时,需要填写`s3.access_key`、`s3.endpoint`、`s3.region`和 `s3.secret_key`。
PATH:存储位置的路径。| + | `--s3.access_key` | string | 否 | 无 | 用于标识用户。 | + | `--s3.endpoint` | string | 否 | 无 | S3 对外服务的访问域名的 URL,指定 http 或 https。 | + | `--s3.region` | string | 否 | 无 | 数据中心所在物理位置。 | + | `--s3.secret_key` | string | 否 | 无 | 用户用于加密签名字符串和用来验证签名字符串的密钥,必须保密。 | + +3. 如果在备份期间发现任何错误,用户可以使用以下命令清理临时文件。该命令将清理集群和外部存储中的文件,同时用户也可以使用该命令清理外部存储中的旧的备份文件。 + + ``` + $ ./bin/br cleanup --meta --storage --name + ``` + + 以下列出命令的相关参数。 + + | 参数 | 数据类型 | 是否必需 | 默认值 | 说明 | + | --- | --- | --- | --- | --- | + | `-h,-help` | - | 否 | - | 查看帮助。 | + | `--debug` | - | 否 | 无 | 查看更多日志信息。 | + | `--log` | string | 否 | "br.log" | 日志路径。 | + | `--meta` | string |是| 无 | meta 服务的地址和端口号。 | + | `--name` | string | 是 | 无 | 备份名字。 | + | `--storage` | string | 是 | 无 | BR 备份数据存储位置,格式为:://
Schema:可选值为 `local` 和 `s3`。选择 s3 时,需要填写`s3.access_key`、`s3.endpoint`、`s3.region`和 `s3.secret_key`。
PATH:存储位置的路径。| + | `--s3.access_key` | string | 否 | 无 | 用于标识用户。 | + | `--s3.endpoint` | string | 否 | 无 | S3 对外服务的访问域名的 URL,指定 http 或 https。 | + | `--s3.region` | string | 否 | 无 | 数据中心所在物理位置。 | + | `--s3.secret_key` | string | 否 | 无 | 用户用于加密签名字符串和用来验证签名字符串的密钥,必须保密。 | diff --git a/docs-2.0/nebula-cloud.md b/docs-2.0/nebula-cloud.md new file mode 100644 index 0000000000..56a1b95a1a --- /dev/null +++ b/docs-2.0/nebula-cloud.md @@ -0,0 +1,5 @@ +# Nebula Graph Cloud + +Nebula Graph Cloud(简称 Cloud )是一款支持 [Azure](https://azure.microsoft.com/zh-cn/) 平台,在云上搭建 Nebula Graph 数据库的产品,支持一键部署 Nebula Graph。用户可以在几分钟内创建一个图数据库,并快速扩展计算、存储等资源。 + +目前仅支持内核为 2.6.2 的 Nebula Graph ,用户可点击 [什么是 Nebula Graph Cloud](https://docs.nebula-graph.com.cn/2.6.2/nebula-cloud/1.what-is-cloud/) 查看更多。 diff --git a/docs-2.0/nebula-cloud/2.how-to-create-subsciption.md b/docs-2.0/nebula-cloud/2.how-to-create-subsciption.md index ae999a99df..21d383b361 100644 --- a/docs-2.0/nebula-cloud/2.how-to-create-subsciption.md +++ b/docs-2.0/nebula-cloud/2.how-to-create-subsciption.md @@ -8,24 +8,24 @@ 1. 进入 [Azure市场](https://portal.azure.com/?l=en.en-us#blade/Microsoft_Azure_Marketplace/GalleryMenuBlade/selectedMenuItemId/home),在市场中的搜索栏搜索 Nebula Graph Cloud,或直接点击 [Nebula Graph Cloud]() 进入购买页面。[TODO] 2. 用户根据需求选定计划,选择**创建 + 订阅**。 - 1. 在**订阅 Nebula Graph Cloud**的**基本信息**选项卡中,输入或选择以下信息: - - - 项目详细信息 + 1. 在**订阅 Nebula Graph Cloud**的**基本信息**选项卡中,输入或选择以下信息: + - 项目详细信息 + |设置项|预设值| |:---|:---| |订阅|选择用户的订阅。| |资源组|选择用户已有的资源组或新建一个资源组。| - - SaaS 详情信息 + - SaaS 详情信息 |设置项|预设值| |:---|:---| |名称|输入 SaaS 订阅创建名称。| |定时收费|选择**开**或**关**。| - 2. 在页面的下方,选择**下一步:标记**的按钮。 - 3. (可选)在**标记**选项卡中,输入**名称:值**。 - 4. 在页面的下方,选择**订阅**的按钮,等待时间约 2 分钟。 + 2. 在页面的下方,选择**下一步:标记**的按钮。 + 3. (可选)在**标记**选项卡中,输入**名称:值**。 + 4. 在页面的下方,选择**订阅**的按钮,等待时间约 2 分钟。 -3. 订阅完成后,用户需点击**在发布者站点上打开 SaaS 帐户**创建并配置 Solution。详细信息,参考[如何配置 Solution](../nebula-nebula-cloud/3.how-to-set-solution.md)。 +3. 订阅完成后,用户需点击**在发布者站点上打开 SaaS 帐户**创建并配置 Solution。详细信息,参考[如何配置 Solution](3.how-to-set-solution.md)。 diff --git a/docs-2.0/nebula-cloud/3.how-to-set-solution.md b/docs-2.0/nebula-cloud/3.how-to-set-solution.md index 1297e9c5e2..b699f16524 100644 --- a/docs-2.0/nebula-cloud/3.how-to-set-solution.md +++ b/docs-2.0/nebula-cloud/3.how-to-set-solution.md @@ -6,22 +6,22 @@ Solution 指运行在 Nebula Graph Cloud 上的 Nebula Graph 数据库。在 Azu 1. 在 Azure 上订阅后,若要完成购买,请在页面上点击**立即配置账户**即跳转至 Nebula Graph Cloud 登录页面。 2. 在 Nebula Graph Cloud 中登录订阅服务的 Azure 账号。 - 1. 在 **Provider** 选择**区域**。 + 1. 在 **供应商** 选择**区域**。 !!! caution 为提升服务性能,建议选择的区域应与业务区域在同一区域。 - 2. 在 **Instance** 中,选择查询引擎的类型及数量,存储引擎的类型、磁盘大小及数量。 + 2. 在 **实例** 中,选择查询引擎的类型及数量,存储引擎的类型、磁盘大小及数量。 !!! caution 为保证服务高可用,建议至少配置2个查询引擎和3个存储引擎。 - 3. 在 **Nebula Graph** 中,输入指定 Azure 账号邮箱为 Root 用户。 - 4. 在页面的下方,选择 **Next** 的按钮。 - 5. 确定选择无误后,在页面的下方,选择 **Create** 的按钮。 -3. 至此,用户已经完成了 Solution 的配置。当在 Cloud 首页上看到 Solution 的状态为 **running**,即认为 Solution 已创建成功。 + 3. 在 **Nebula Graph** 中,输入指定 Azure 账号邮箱为 Root 用户,默认为 Azure 订阅账户。 + 4. 在页面的下方,选择 **下一步** 的按钮。 + 5. 确定选择无误后,在页面的下方,选择 **创建** 的按钮。 +3. 至此,用户已经完成了 Solution 的配置。当在 Cloud 首页上看到 Solution 的状态为 **创建中**,即认为 Solution 已创建成功。 ## Solution 状态 @@ -29,16 +29,16 @@ Solution 指运行在 Nebula Graph Cloud 上的 Nebula Graph 数据库。在 Azu |状态| 状态说明 | |:---|:---| -| creating | Solution 所需资源已经准备完毕,Solution 自动开始创建,此时 Solution 短暂处于 creating 状态,可能持续几分钟到十几分钟。| -| starting | 重新启动 Solution,此时 Solution 短暂处于 starting 状态。 | -| stopping | 用户点击停止 Solution 后,此时 Solution 短暂处于 stopping 状态。 | -| deleting | 用户点击删除 Solution 后,此时 Solution 短暂处于 deleting 状态。 | -| running | Solution 创建成功后,会长时间稳定地处于 running 状态。 | -| stopped | 停止 Solution 后,会长时间稳定地处于 stopped 状态。 | -| deleted | 删除 Solution 后,会长时间稳定地处于 deleted 状态。 | -| create_failed | Solution 创建失败后,会长时间稳定地处于 create_failed 状态。 | -| stop_failed | Solution 停止失败后,会长时间稳定地处于 stop_failed 状态。 | -| start_failed | Solution 开始失败后,会长时间稳定地处于 start_failed 状态。 | +| 创建中 | Solution 所需资源已经准备完毕,Solution 自动开始创建,此时 Solution 短暂处于**创建中**状态,可能持续几分钟到十几分钟。| +| 启动中 | 重新启动 Solution,此时 Solution 短暂处于**启动中**状态。 | +| 停止中 | 用户点击停止 Solution 后,此时 Solution 短暂处于**停止中**状态。 | +| 删除中 | 用户点击删除 Solution 后,此时 Solution 短暂处于**删除中**状态。 | +| 运行中 | Solution 创建成功后,会长时间稳定地处于**运行中**状态。 | +| 已停止 | 停止 Solution 后,会长时间稳定地处于**已停止**状态。 | +| 已删除 | 删除 Solution 后,会长时间稳定地处于**已删除**状态。 | +| 创建失败 | Solution 创建失败后,会长时间稳定地处于**创建失败**状态。 | +| 停止失败 | Solution 停止失败后,会长时间稳定地处于**停止失败**状态。 | +| 启动失败 | Solution 开始失败后,会长时间稳定地处于**启动失败**状态。 | !!! caution @@ -47,5 +47,5 @@ Solution 指运行在 Nebula Graph Cloud 上的 Nebula Graph 数据库。在 Azu !!! caution - 如果 Solution 处于 create_failed、stop_failed、start_failed 态,用户可以重新执行 **创建、停止、开始** 的操作。 + 如果 Solution 处于创建失败、停止失败、启动失败态,用户可以重新执行 **创建、停止、开始** 的操作。 diff --git a/docs-2.0/nebula-cloud/5.solution/5.0.introduce-solution.md b/docs-2.0/nebula-cloud/5.solution/5.0.introduce-solution.md index 2a7ae5394e..9bff689d5d 100644 --- a/docs-2.0/nebula-cloud/5.solution/5.0.introduce-solution.md +++ b/docs-2.0/nebula-cloud/5.solution/5.0.introduce-solution.md @@ -2,30 +2,44 @@ 在 Solution 页面中,不同的角色将会看到不同的侧边栏。具体角色权限,详情参见 [Cloud Solution 角色身份说明](../4.user-role-description.md)。 -## Solution Info 页面介绍 +## 详情页面介绍 -在 Cloud 的首页点击 Solution 名字进入指定的 Solution Info 页面。Solution Info 页面由以下几个部分组成:Basic Info、Instance Info、Price Info、Getting Started。用户可以在此页面查看每个部分的详细的信息。 +在 Cloud 的首页点击 Solution 名字进入指定的详情页面。详情页面由以下几个部分组成:基本信息、实例信息、价格、入门指南。用户可以在此页面查看每个部分的详细的信息。 -## Applications 页面介绍 +![详情](../figs/cl-ug-001.png) -在侧边栏点击 **Applications** 进入 Cloud 配套周边工具的跳转页面,不同的用户角色将会在 **Applications** 页面看到不同的周边工具。详情信息,参见 [配套的应用](../5.solution/5.1.supporting-application.md)。 +## 应用页面介绍 -## Connectivity 页面介绍 +在侧边栏点击**应用**进入 Cloud 配套周边工具的跳转页面,不同的用户角色将会在**应用**页面看到不同的周边工具。详情信息,参见 [配套的应用](../5.solution/5.1.supporting-application.md)。 -在侧边栏点击 **Connectivity** 进入 Private Link 设置页面,在页面中可根据提示设置 Private Link,让用户能够通过虚拟网络中的专用节点访问 Nebula Graph 数据库。详情信息,参见 [Private Link](../5.solution/5.2.connection-configuration-and-use.md)。 +![应用](../figs/cl-ug-002.png) -## Root Management 页面介绍 +## 链接页面介绍 -在侧边栏点击 **Root Management** 进入 Root 账号管理页面。详情信息,参见[角色与权限管理](../5.solution/5.3.role-and-authority-management.md)。 +在侧边栏点击**链接**进入私有链接设置页面,在页面中可根据提示设置私有链接,让用户能够通过虚拟网络中的专用节点访问 Nebula Graph 数据库。详情信息,参见 [Private Link](../5.solution/5.2.connection-configuration-and-use.md)。 -## User Management 页面介绍 +![链接](../figs/cl-ug-003.png) -在侧边栏点击 **User Management** 进入 User 账号管理页面。详情信息,参见[角色与权限管理](../5.solution/5.3.role-and-authority-management.md)。 +## Root 权限管理页面介绍 -## Audit Log 页面介绍 +在侧边栏点击**Root 权限管理**进入 Root 账号管理页面。详情信息,参见[角色与权限管理](../5.solution/5.3.role-and-authority-management.md)。 -在侧边栏点击 **Audit Log** 进入操作记录页面,用户可以根据 **Create Solution**、**Start Solution**、**Stop Solution** 等操作信息,选择时间段,筛选出操作人和操作记录。 +![root](../figs/cl-ug-004.png) -## Settings 页面介绍 +## User 权限管理页面介绍 -在侧边栏点击 **Settings** 进入设置页面,用户可以在设置中停止solution或transfer solution。 +在侧边栏点击**User 权限管理**进入 User 账号管理页面。详情信息,参见[角色与权限管理](../5.solution/5.3.role-and-authority-management.md)。 + +![user](../figs/cl-ug-005.png) + +## 审计日志页面介绍 + +在侧边栏点击**审计日志**进入操作记录页面,用户可以根据**所有**、**创建 Solution**、**更改权限** 等操作信息,选择时间段,筛选出操作人和操作记录。 + +![审计日志](../figs/cl-ug-006.png) + +## 设置页面介绍 + +在侧边栏点击**设置**进入设置页面,用户可以在设置中**停止Solution**或**转移 Solution**。 + +![设置](../figs/cl-ug-007.png) \ No newline at end of file diff --git a/docs-2.0/nebula-cloud/5.solution/5.2.connection-configuration-and-use.md b/docs-2.0/nebula-cloud/5.solution/5.2.connection-configuration-and-use.md index d5db3aafd5..a0608cebe0 100644 --- a/docs-2.0/nebula-cloud/5.solution/5.2.connection-configuration-and-use.md +++ b/docs-2.0/nebula-cloud/5.solution/5.2.connection-configuration-and-use.md @@ -6,70 +6,79 @@ Solution 可在 Connectivity 中设置 Private Link 让用户能够通过虚拟 1. 输入订阅 ID 后点击**创建**服务,创建时间大约需要2分钟。 + ![create](../figs/cl-ug-008.png) + !!! note - 订阅 ID 在 Azure Portal 的 **订阅** 页面中查看。用户可以点击 [Subscriptions](https://portal.azure.com/?l=en.en-us#blade/Microsoft_Azure_Billing/SubscriptionsBlade) 页面快速访问。 + 订阅 ID 在 Azure Portal 的 **订阅** 页面中查看。用户可以点击 [Subscriptions](https://portal.azure.com/?l=en.en-us#blade/Microsoft_Azure_Billing/SubscriptionsBlade)页面快速访问。 2. 创建成功后用户可使用**别名**连接到 Azure 资源,在 Azure 中创建专用终结点。 - 1. 在 Azure 首页的搜索框内输入**专用链接中心**后,选择左侧目录栏中的**专用终结点**。 - 2. 选择 **+ 创建** 按钮。 - 3. 在**创建专用链接服务**的**基本**选项卡中,输入或选择以下信息: + 1. 在 Azure 首页的搜索框内输入**专用链接中心**后,选择左侧目录栏中的**专用终结点**。 + 2. 选择 **+ 创建** 按钮。 + ![创建](../figs/cl-ug-009.png) + 3. 在**创建专用链接服务**的**基本**选项卡中,输入或选择以下信息: - - 项目详细信息 + - 项目详细信息 |设置项|预设值| |:---|:---| |订阅|选择用户的订阅。| |资源组|选择用户已有的资源组或新建一个资源组。| - - 实例详情信息 + - 实例详情信息 |设置项|预设值| |:---|:---| |名称|输入用户专用终结点的名字。| |区域|选择区域。| + + ![基本](../figs/cl-ug-010.png) !!! caution 为提升服务性能,选择的区域尽量与业务区域在同一区域。 - 4. 在页面的下方,选择**下一步:资源**的按钮。 - 5. 在**资源**选项卡中,输入或选择以下信息: + 4. 在页面的下方,选择**下一步:资源**的按钮。 + 5. 在**资源**选项卡中,输入或选择以下信息: - |设置项|预设值| - |:---|:---| - |连接方法|选择**按资源 ID 或别名连接到 Azure 资源**。| - |资源ID或别名|输入别名。| - |请求消息|输入消息,此将发送给资源所有者。| + |设置项|预设值| + |:---|:---| + |连接方法|选择**按资源 ID 或别名连接到 Azure 资源**。| + |资源ID或别名|输入别名。| + |请求消息|输入消息,此将发送给资源所有者。| !!! note - 别名在 Nebula Graph Cloud 的 Connectivity 页面中,点击 ![copy](../figs/copy.png) 可一键复制。 + 别名在 Nebula Graph Cloud 的链接页面中,点击 ![copy](../figs/copy.png) 可一键复制。 + + ![资源](../figs/cl-ug-011.png) - 6. 在页面的下方,选择**下一步:配置**的按钮。 - 7. 在**配置**选项卡中,选择以下信息: + 6. 在页面的下方,选择**下一步:配置**的按钮。 + 7. 在**配置**选项卡中,选择以下信息: - |设置项|预设值| - |:---|:---| - |虚拟网络|选择虚拟网络。| - |子网|选择虚拟网络中的子网。| + |设置项|预设值| + |:---|:---| + |虚拟网络|选择虚拟网络。| + |子网|选择虚拟网络中的子网。| !!! note 目前不支持与专用 DNS 集成。 + + ![配置](../figs/cl-ug-012.png) - 8. 在页面的下方,选择**下一步:标记**的按钮。 - 9. (可选)在**标记**选项卡中,输入**名称/值对**。 - 10. 在页面的下方,选择**下一步:查看 + 创建**的按钮。 - 11. 选择**创建**按钮。 + 8. 在页面的下方,选择**下一步:标记**的按钮。 + 9. (可选)在**标记**选项卡中,输入**名称/值对**。 + 10. 在页面的下方,选择**下一步:查看 + 创建**的按钮。 + 11. 选择**创建**按钮。 -3. 创建好**专用终结点**后,复制**专用 IP** 并写入 Cloud 的 Connectivity 页面,点击**创建**按钮。 +3. 创建好**专用终结点**后,复制**专用 IP** 并写入 Cloud 的链接页面,点击**创建**按钮。 !!! note - 在 Cloud 中仅存储 Private Link Endpoint IP 信息,用户可以随时点击 ![edit](../figs/edit.png) 进行修改。 + 在 Cloud 中仅存储私有链接的专用终结点 IP 信息,用户可以随时点击 ![edit](../figs/edit.png) 进行修改。 -## 如何使用 Private Link 连接 Nebula Graph +## 如何使用私有链接连接 Nebula Graph -用户可以使用 Private Link 通过 Nebula Console 连接 Nebula Graph。详情信息,参见[连接 Nebula Graph](../../reuse/source_connect-to-nebula-graph.md)。 +用户可以使用私有链接通过 Nebula Console 连接 Nebula Graph。详情信息,参见[连接 Nebula Graph](../../2.quick-start/3.connect-to-nebula-graph.md)。 diff --git a/docs-2.0/nebula-cloud/6.pricing.md b/docs-2.0/nebula-cloud/6.pricing.md index e69de29bb2..88bca84664 100644 --- a/docs-2.0/nebula-cloud/6.pricing.md +++ b/docs-2.0/nebula-cloud/6.pricing.md @@ -0,0 +1,2 @@ +# 价格 + diff --git a/docs-2.0/nebula-cloud/7.terms-and-conditions.md b/docs-2.0/nebula-cloud/7.terms-and-conditions.md index 00c44ef5d3..535623d5b4 100644 --- a/docs-2.0/nebula-cloud/7.terms-and-conditions.md +++ b/docs-2.0/nebula-cloud/7.terms-and-conditions.md @@ -12,119 +12,117 @@ Nebula Graph Cloud(以下简称为“云服务”)是由杭州欧若数网 1. 数据保留 - 用户到Azure平台取消订阅或用户欠费30天后自动取消订阅。取消订阅后的数据保留期限为7天,7天后该服务项下用户存储的全部业务数据将被永久删除,不可恢复。 + 用户到Azure平台取消订阅或用户欠费30天后自动取消订阅。取消订阅后的数据保留期限为7天,7天后该服务项下用户存储的全部业务数据将被永久删除,不可恢复。 2. 服务内容 - 本协议中的“产品和/或服务”指:欧若数网向您提供的云服务,具体服务内容以您所使用或订购的内容为准。 + 本协议中的“产品和/或服务”指:欧若数网向您提供的云服务,具体服务内容以您所使用或订购的内容为准。 - 根据实际需要和欧若数网不时提供的其他服务内容,欧若数网可能与您另行签订其他协议。同时,即使未另行签订其他协议,您使用云服务的具体服务也将被视为您同意欧若数网关于该等具体服务的任何要求。**如果其他协议和本服务协议之间存在冲突,应以其他协议为准,但以该冲突和与该协议特定事宜相关为限。** + 根据实际需要和欧若数网不时提供的其他服务内容,欧若数网可能与您另行签订其他协议。同时,即使未另行签订其他协议,您使用云服务的具体服务也将被视为您同意欧若数网关于该等具体服务的任何要求。**如果其他协议和本服务协议之间存在冲突,应以其他协议为准,但以该冲突和与该协议特定事宜相关为限。** - 欧若数网保留随时变更、中止或终止部分免费服务的权利,并保留根据实际情况随时调整免费的云服务种类、形式的权利。欧若数网不承担因任何免费云服务的调整给您造成的损失。欧若数网有权在未来恰当的时机对任何免费云服务内容收取相应的服务费用,在开始收费前,我们将通过站内通知、邮件、官网公告等形式予以通知。如您不同意修改、变更付费内容,则应停止使用该云服务。 + 欧若数网保留随时变更、中止或终止部分免费服务的权利,并保留根据实际情况随时调整免费的云服务种类、形式的权利。欧若数网不承担因任何免费云服务的调整给您造成的损失。欧若数网有权在未来恰当的时机对任何免费云服务内容收取相应的服务费用,在开始收费前,我们将通过站内通知、邮件、官网公告等形式予以通知。如您不同意修改、变更付费内容,则应停止使用该云服务。 - 您同意欧若数网为满足用户需求、提升产品使用体验等需要调整、升级收费服务,包括服务种类、形式等。如因某些情况欧若数网需要终止向您提供的收费服务,我们将提前通过站内通知、邮件、官网公告等形式予以通知。**您同意如果欧若数网终止提供某项收费服务,我们的义务仅在于向您返还您尚未使用的服务期对应的部分费用。您同意欧若数网无需因收费服务的调整、升级或终止向您承担责任。** 但无论如何,欧若数网将尽合理的努力给您预留合理的时间以便您为该等服务变更、中止或终止做出应对。 + 您同意欧若数网为满足用户需求、提升产品使用体验等需要调整、升级收费服务,包括服务种类、形式等。如因某些情况欧若数网需要终止向您提供的收费服务,我们将提前通过站内通知、邮件、官网公告等形式予以通知。**您同意如果欧若数网终止提供某项收费服务,我们的义务仅在于向您返还您尚未使用的服务期对应的部分费用。您同意欧若数网无需因收费服务的调整、升级或终止向您承担责任。** 但无论如何,欧若数网将尽合理的努力给您预留合理的时间以便您为该等服务变更、中止或终止做出应对。 3. 注册 - 为了能访问和使用云服务,您同意以下事项:依云服务网站上的注册提示填写准确真实的注册邮箱、密码和名称,并确保今后更新的登录邮箱、名称等资料的有效性和合法性。若您提供任何违法、虚假、不道德或欧若数网认为不适合出现在云服务平台上的资料,或者欧若数网有理由怀疑您的资料属于病毒程序或恶意操作,或者您违反本服务协议的规定,我们有权暂停或终止您的账号,并拒绝您于现在和未来使用云服务之全部或任何部分。 + 为了能访问和使用云服务,您同意以下事项:依云服务网站上的注册提示填写准确真实的注册邮箱、密码和名称,并确保今后更新的登录邮箱、名称等资料的有效性和合法性。若您提供任何违法、虚假、不道德或欧若数网认为不适合出现在云服务平台上的资料,或者欧若数网有理由怀疑您的资料属于病毒程序或恶意操作,或者您违反本服务协议的规定,我们有权暂停或终止您的账号,并拒绝您于现在和未来使用云服务之全部或任何部分。 - 尽管有前述规定,欧若数网无义务对任何用户的任何登记资料承担任何责任,包括但不限于鉴别、核实任何登记资料的真实性、准确性、完整性、适用性和/或是否为最新资料的责任。 + 尽管有前述规定,欧若数网无义务对任何用户的任何登记资料承担任何责任,包括但不限于鉴别、核实任何登记资料的真实性、准确性、完整性、适用性和/或是否为最新资料的责任。 - 同时,欧若数网建议您妥善保管您的注册邮箱、密码和名称,准确输入该等信息将作为您访问登录并使用云服务的关键环节。如果您发现有人未经授权使用您的账户信息或怀疑任何人可能在未经授权的情况下能够访问您的私有内容,您应立即更改密码,并向我们反馈。 + 同时,欧若数网建议您妥善保管您的注册邮箱、密码和名称,准确输入该等信息将作为您访问登录并使用云服务的关键环节。如果您发现有人未经授权使用您的账户信息或怀疑任何人可能在未经授权的情况下能够访问您的私有内容,您应立即更改密码,并向我们反馈。 4. 使用 - 我们鼓励用户充分利用云服务自由地创建内容。您可以自由使用任何您拥有使用权(包括上传、发布、共享内容所需的复制权、信息网络传播权等使用权)的用户业务数据。同时,您不应在云服务上使用受版权保护的内容,包括但不限于未经权利人许可使用或超越许可范围使用或许可期限已经届满且未展期的内容。 + 我们鼓励用户充分利用云服务自由地创建内容。您可以自由使用任何您拥有使用权(包括上传、发布、共享内容所需的复制权、信息网络传播权等使用权)的用户业务数据。同时,您不应在云服务上使用受版权保护的内容,包括但不限于未经权利人许可使用或超越许可范围使用或许可期限已经届满且未展期的内容。 - 用户不得使用云服务发送或传播敏感信息和违反国家法律制度的信息,包括但不限于下列信息: + 用户不得使用云服务发送或传播敏感信息和违反国家法律制度的信息,包括但不限于下列信息: - - 反对宪法所确定的基本原则的; - - 危害国家安全,泄露国家秘密,颠覆国家政权,破坏国家统一的; - - 损害国家荣誉和利益的; - - 煽动民族仇恨、民族歧视,破坏民族团结的; - - 破坏国家宗教政策,宣扬邪教和封建迷信的; - - 散布谣言,扰乱社会秩序,破坏社会稳定的; - - 散布淫秽、色情、赌博、暴力、凶杀、恐怖或者教唆犯罪的; - - 侮辱或者诽谤他人,侵害他人合法权益的; - - 含有法律、行政法规禁止的其他内容的。 + - 反对宪法所确定的基本原则的; + - 危害国家安全,泄露国家秘密,颠覆国家政权,破坏国家统一的; + - 损害国家荣誉和利益的; + - 煽动民族仇恨、民族歧视,破坏民族团结的; + - 破坏国家宗教政策,宣扬邪教和封建迷信的; + - 散布谣言,扰乱社会秩序,破坏社会稳定的; + - 散布淫秽、色情、赌博、暴力、凶杀、恐怖或者教唆犯罪的; + - 侮辱或者诽谤他人,侵害他人合法权益的; + - 含有法律、行政法规禁止的其他内容的。 - 您承诺发布的内容要:爱国、守法、自律、真实、文明。不传播任何非法的、骚扰性的、中伤他人的、辱骂性的、恐吓性的、伤害性的、庸俗的,淫秽的、危害国家安全的、泄露国家机密的、破坏国家宗教政策和民族团结的以及其它违反法律法规及政策的内容。若用户的行为不符合以上提到的服务条款,欧若数网将作出独立判断立即暂停或终止用户的服务账号。用户需自行对其全部行为承担法律责任,欧若数网不承担任何法律责任,欧若数网因此受到的损失应由客户全额赔偿。 + 您承诺发布的内容要:爱国、守法、自律、真实、文明。不传播任何非法的、骚扰性的、中伤他人的、辱骂性的、恐吓性的、伤害性的、庸俗的,淫秽的、危害国家安全的、泄露国家机密的、破坏国家宗教政策和民族团结的以及其它违反法律法规及政策的内容。若用户的行为不符合以上提到的服务条款,欧若数网将作出独立判断立即暂停或终止用户的服务账号。用户需自行对其全部行为承担法律责任,欧若数网不承担任何法律责任,欧若数网因此受到的损失应由客户全额赔偿。 5. 知识产权 - 欧若数网完全拥有云服务(包括对其进行的任何开发和升级)的所有权及所有相关的知识产权(包括但不限于源代码、目标代码、文档资料、界面设计、版面框架、以及任何由欧若数网根据维护与技术支持提供的软件、资料等)。您认同欧若数网拥有的所有权及知识产权,并承诺尊重及不以任何方式侵害欧若数网的所有权及知识产权。未经欧若数网书面许可,您不得使用包括但不限于复制、传播、转让、许可等方式使用或提供他人使用上述知识成果,否则应承担相应的责任并赔偿由此给欧若数网造成的损失,且欧若数网有权终止您对云服务的使用且不退还任何费用。 + 欧若数网完全拥有云服务(包括对其进行的任何开发和升级)的所有权及所有相关的知识产权(包括但不限于源代码、目标代码、文档资料、界面设计、版面框架、以及任何由欧若数网根据维护与技术支持提供的软件、资料等)。您认同欧若数网拥有的所有权及知识产权,并承诺尊重及不以任何方式侵害欧若数网的所有权及知识产权。未经欧若数网书面许可,您不得使用包括但不限于复制、传播、转让、许可等方式使用或提供他人使用上述知识成果,否则应承担相应的责任并赔偿由此给欧若数网造成的损失,且欧若数网有权终止您对云服务的使用且不退还任何费用。 - 您对于自己创作并在云服务上发布的合法内容依法享有著作权及其他相关权利。 + 您对于自己创作并在云服务上发布的合法内容依法享有著作权及其他相关权利。 - 您在欧若数网发布违反法律规定或侵犯他人知识产权或其他合法权益的内容,欧若数网有权予以删除,并保留移交司法机关处理的权利,如因此给欧若数网造成损失的,应当予以赔偿。 + 您在欧若数网发布违反法律规定或侵犯他人知识产权或其他合法权益的内容,欧若数网有权予以删除,并保留移交司法机关处理的权利,如因此给欧若数网造成损失的,应当予以赔偿。 6. 用户个人信息保护和数据安全 - 欧若数网会按现有技术提供相应的安全措施来保护您的信息,提供合理的安全保障。欧若数网将在任何时候尽力做到使您的信息不被泄漏、毁损或丢失,但同时也请您注意在信息网络上不存在绝对完善的安全措施,请妥善保管好相关信息。 + 欧若数网会按现有技术提供相应的安全措施来保护您的信息,提供合理的安全保障。欧若数网将在任何时候尽力做到使您的信息不被泄漏、毁损或丢失,但同时也请您注意在信息网络上不存在绝对完善的安全措施,请妥善保管好相关信息。 - 其他隐私条款见《隐私政策》。 + 其他隐私条款见《隐私政策》。 7. 用户业务数据 - 欧若数网理解并认可,您通过云服务提供的服务,加工、存储、上传、下载、分发以及通过其他方式处理的数据,均为您的用户业务数据,您完全拥有您的用户业务数据。 + 欧若数网理解并认可,您通过云服务提供的服务,加工、存储、上传、下载、分发以及通过其他方式处理的数据,均为您的用户业务数据,您完全拥有您的用户业务数据。 - 针对于您的用户业务数据,欧若数网除执行您的服务要求外,不进行任何未获授权的使用及披露;但以下情形除外: - 在国家有关机关依法查询或调阅用户业务数据时,欧若数网具有按照相关法律法规或政策文件要求提供配合,并向第三方或者行政、司法等机构披露的义务; - 您和欧若数网另行协商一致。 + 针对于您的用户业务数据,欧若数网除执行您的服务要求外,不进行任何未获授权的使用及披露;但以下情形除外:在国家有关机关依法查询或调阅用户业务数据时,欧若数网具有按照相关法律法规或政策文件要求提供配合,并向第三方或者行政、司法等机构披露的义务;您和欧若数网另行协商一致。 - **您可自行对您的用户业务数据进行删除、更改等操作。如您已经删除服务或删除数据,欧若数网将删除您的数据,按照您的指令不再保留该等数据。就数据的删除、更改等操作,您应谨慎操作。** + **您可自行对您的用户业务数据进行删除、更改等操作。如您已经删除服务或删除数据,欧若数网将删除您的数据,按照您的指令不再保留该等数据。就数据的删除、更改等操作,您应谨慎操作。** - **您理解并同意:当服务期届满、服务提前终止(包括双方协商一致提前终止,其他原因导致的提前终止等)或您发生欠费时,除法律法规明确规定、主管部门要求或双方另有约定,欧若数网仅在 72 小时内继续存储您的用户业务数据(如有),72 小时后欧若数网将删除所有用户业务数据,包括所有缓存或者备份的副本,不再保留您的任何用户业务数据。** + **您理解并同意:当服务期届满、服务提前终止(包括双方协商一致提前终止,其他原因导致的提前终止等)或您发生欠费时,除法律法规明确规定、主管部门要求或双方另有约定,欧若数网仅在 72 小时内继续存储您的用户业务数据(如有),72 小时后欧若数网将删除所有用户业务数据,包括所有缓存或者备份的副本,不再保留您的任何用户业务数据。** - **用户业务数据一经删除,即不可恢复;您应承担数据因此被删除所引发的后果和责任,您理解并同意,欧若数网没有继续保留、导出或者返还用户业务数据的义务。** + **用户业务数据一经删除,即不可恢复;您应承担数据因此被删除所引发的后果和责任,您理解并同意,欧若数网没有继续保留、导出或者返还用户业务数据的义务。** 8. 不可抗力及免责声明 - 您知悉并同意,下列情况下,欧若数网无需向您承担任何责任: + 您知悉并同意,下列情况下,欧若数网无需向您承担任何责任: - 由于您使用不当、维护不当或保密不当,导致数据、资料、密码等丢失或泄漏,或其他非因欧若数网原因导致的个人信息的泄漏,欧若数网不承担任何法律责任; + 由于您使用不当、维护不当或保密不当,导致数据、资料、密码等丢失或泄漏,或其他非因欧若数网原因导致的个人信息的泄漏,欧若数网不承担任何法律责任; - 您应对您的用户业务数据的合法性以及获得用户业务数据的方式的合法性负责,因上述用户业务数据引发的一切纠纷,由您承担全部法律责任,欧若数网不承担任何法律责任; + 您应对您的用户业务数据的合法性以及获得用户业务数据的方式的合法性负责,因上述用户业务数据引发的一切纠纷,由您承担全部法律责任,欧若数网不承担任何法律责任; - 您理解并同意:我们的云服务是按照现有技术和条件所能达到的现状提供的;我们会尽最大合理努力向您提供服务,确保服务的连贯性和安全性;但我们不能随时预见和防范法律、技术以及其他风险,包括但不限于不可抗力、病毒、木马、黑客攻击、系统不稳定、第三方服务瑕疵、政府行为等原因可能导致的服务中断、数据丢失以及其他的损失和风险; + 您理解并同意:我们的云服务是按照现有技术和条件所能达到的现状提供的;我们会尽最大合理努力向您提供服务,确保服务的连贯性和安全性;但我们不能随时预见和防范法律、技术以及其他风险,包括但不限于不可抗力、病毒、木马、黑客攻击、系统不稳定、第三方服务瑕疵、政府行为等原因可能导致的服务中断、数据丢失以及其他的损失和风险; - 您理解并同意:我们的云服务并非为某些特定目的而设计,包括但不限于核设施、军事用途、医疗设施、交通通讯等重要领域;如果因为软件或服务的原因导致上述操作失败而带来人员伤亡、财产损失和环境破坏等,我们不承担法律责任。 + 您理解并同意:我们的云服务并非为某些特定目的而设计,包括但不限于核设施、军事用途、医疗设施、交通通讯等重要领域;如果因为软件或服务的原因导致上述操作失败而带来人员伤亡、财产损失和环境破坏等,我们不承担法律责任。 9. 服务变更/中断/终止 - 如果为了完成系统维护或升级必须暂停网络服务、调整服务功能的,欧若数网将尽可能事先在网站上进行通告。 + 如果为了完成系统维护或升级必须暂停网络服务、调整服务功能的,欧若数网将尽可能事先在网站上进行通告。 - 如发生下列任何一种情形,欧若数网有权单方面中断或终止向用户提供服务而无需事先通知用户: + 如发生下列任何一种情形,欧若数网有权单方面中断或终止向用户提供服务而无需事先通知用户: - - 用户提供的个人资料不真实; + - 用户提供的个人资料不真实; - - 用户违反法律法规、本服务条款规定的; + - 用户违反法律法规、本服务条款规定的; - - 出于安全的原因或其他必要的情形。 + - 出于安全的原因或其他必要的情形。 - 您理解并同意:为技术升级、服务体系升级或者因经营策略调整或配合国家重大技术、法规政策等变化,欧若数网不保证永久地提供某种服务,或可能变更所提供服务的形式、规格或其他方面,在终止该种服务或进行此种变更前,欧若数网将尽最大努力且提前以网站公告、站内信、邮件等一种或多种方式进行事先通知;如终止提供该种服务的,欧若数网将尽合理的努力给您预留合理的时间,妥善处理后续事宜。 + 您理解并同意:为技术升级、服务体系升级或者因经营策略调整或配合国家重大技术、法规政策等变化,欧若数网不保证永久地提供某种服务,或可能变更所提供服务的形式、规格或其他方面,在终止该种服务或进行此种变更前,欧若数网将尽最大努力且提前以网站公告、站内信、邮件等一种或多种方式进行事先通知;如终止提供该种服务的,欧若数网将尽合理的努力给您预留合理的时间,妥善处理后续事宜。 10. 服务协议的完善和修改 - 您理解并同意:欧若数网有权根据互联网的发展和中华人民共和国有关法律、法规的变化,不时地完善和修改欧若数网服务协议。欧若数网保留随时修改服务协议的权利,用户在使用云服务时,有必要对最新的服务协议进行仔细阅读和重新确认,当发生相关争议时,以最新的服务协议为准。 + 您理解并同意:欧若数网有权根据互联网的发展和中华人民共和国有关法律、法规的变化,不时地完善和修改欧若数网服务协议。欧若数网保留随时修改服务协议的权利,用户在使用云服务时,有必要对最新的服务协议进行仔细阅读和重新确认,当发生相关争议时,以最新的服务协议为准。 11. 其他 - 本服务协议及其下的服务受中华人民共和国法律管辖,并按之解释。 + 本服务协议及其下的服务受中华人民共和国法律管辖,并按之解释。 - 用户使用本服务的行为若有任何违反国家法律法规或侵犯任何第三方合法权益的情形,欧若数网有权直接删除该等违反规定的信息,并可以暂停或终止向该用户提供服务。 + 用户使用本服务的行为若有任何违反国家法律法规或侵犯任何第三方合法权益的情形,欧若数网有权直接删除该等违反规定的信息,并可以暂停或终止向该用户提供服务。 - 若用户利用本服务从事任何违法或侵权行为,由用户自行承担全部责任,欧若数网不承担任何法律责任。因此给欧若数网或任何第三方造成任何损失的,用户应负责全额赔偿。 + 若用户利用本服务从事任何违法或侵权行为,由用户自行承担全部责任,欧若数网不承担任何法律责任。因此给欧若数网或任何第三方造成任何损失的,用户应负责全额赔偿。 - 用户因为违反本协议而应赔偿欧若数网的损失,包括但不限于违约金、赔偿金、公证费、诉讼费、保全费、公告费、鉴定费、律师费、差旅费等。 + 用户因为违反本协议而应赔偿欧若数网的损失,包括但不限于违约金、赔偿金、公证费、诉讼费、保全费、公告费、鉴定费、律师费、差旅费等。 - 欧若数网有权将本协议的权利义务全部或者部分转移给欧若数网的关联公司,同时关联公司不会实质性降低您可获得服务的质量,否则欧若数网与关联公司向您承担连带责任。 + 欧若数网有权将本协议的权利义务全部或者部分转移给欧若数网的关联公司,同时关联公司不会实质性降低您可获得服务的质量,否则欧若数网与关联公司向您承担连带责任。 - 若双方之间另有盖章文本,且与网络页面点击确认的本协议存在不一致之处,以双方盖章的文本内容为准。 + 若双方之间另有盖章文本,且与网络页面点击确认的本协议存在不一致之处,以双方盖章的文本内容为准。 - 若双方就本服务协议或其执行发生任何争议,应首先友好协商解决;协商不成时,任何一方均可向欧若数网注册地所在的人民法院提起诉讼。 + 若双方就本服务协议或其执行发生任何争议,应首先友好协商解决;协商不成时,任何一方均可向欧若数网注册地所在的人民法院提起诉讼。 12. 联系我们 - 欢迎您对我们的服务协议提出意见。如有任何问题、意见或疑虑,请发邮件至 legal@vesoft.com ,此电子邮件地址作为本服务协议的组成部分可能会不时进行更新。 + 欢迎您对我们的服务协议提出意见。如有任何问题、意见或疑虑,请发邮件至 legal@vesoft.com ,此电子邮件地址作为本服务协议的组成部分可能会不时进行更新。 diff --git a/docs-2.0/nebula-cloud/8.privacy-policy.md b/docs-2.0/nebula-cloud/8.privacy-policy.md index 0d5e9fe7e5..d55e8137f8 100644 --- a/docs-2.0/nebula-cloud/8.privacy-policy.md +++ b/docs-2.0/nebula-cloud/8.privacy-policy.md @@ -7,18 +7,29 @@ 本政策仅适用于由杭州欧若数网科技有限公司(英文名称为 vesoft Inc.,以下简称“欧若数网”和“我们”)提供的图数据库产品或服务,包括: 如果您有任何疑问、意见或建议,请通过以下联系方式与我们联系: + - 电子邮件:legal@vesoft.com + - 电话:(+86) 0571-28120658 本政策将帮助您了解以下内容: + - 我们如何收集和使用您的个人信息 + - 如何使用 Cookie 和同类技术 + - 如何共享、转让、公开披露您的个人信息 + - 我们如何保护您的个人信息 + - 您的权利 + - 我们如何处理儿童的个人信息 + - 您的个人信息如何在全球范围转移 + - 本政策如何更新 + - 如何联系我们 欧若数网深知个人信息对您的重要性,并会尽全力保护您的个人信息安全可靠。我们致力于维持您对我们的信任,恪守以下原则,保护您的个人信息:权责一致原则、目的明确原则、选择同意原则、最小必要原则、确保安全原则、主体参与原则、公开透明原则等。同时,欧若数网承诺,我们将按业界成熟的安全标准,采取相应的安全保护措施来保护您的个人信息。 请在使用我们的产品或服务前,仔细阅读并了解本《隐私政策》。一旦您开始使用我们的产品或服务,将被视为对本政策内容的接受和认可。 @@ -122,7 +133,7 @@ 按照中国相关的法律、法规、标准,以及其他国家、地区的通行做法,我们保障您对自己的个人信息行使以下权利: -### (一)访问您的个人信息 +### (一)访问您的个人信息 只要欧若数网的产品和服务已经提供了个人资料信息读写功能,您均有权自行访问您的个人信息,法律法规规定的例外情况除外。 diff --git a/docs-2.0/nebula-cloud/figs/cl-ug-001.png b/docs-2.0/nebula-cloud/figs/cl-ug-001.png new file mode 100644 index 0000000000..ae279e2e85 Binary files /dev/null and b/docs-2.0/nebula-cloud/figs/cl-ug-001.png differ diff --git a/docs-2.0/nebula-cloud/figs/cl-ug-002.png b/docs-2.0/nebula-cloud/figs/cl-ug-002.png new file mode 100644 index 0000000000..3abfecd606 Binary files /dev/null and b/docs-2.0/nebula-cloud/figs/cl-ug-002.png differ diff --git a/docs-2.0/nebula-cloud/figs/cl-ug-003.png b/docs-2.0/nebula-cloud/figs/cl-ug-003.png new file mode 100644 index 0000000000..4a37d3cfec Binary files /dev/null and b/docs-2.0/nebula-cloud/figs/cl-ug-003.png differ diff --git a/docs-2.0/nebula-cloud/figs/cl-ug-004.png b/docs-2.0/nebula-cloud/figs/cl-ug-004.png new file mode 100644 index 0000000000..f84ad1d58f Binary files /dev/null and b/docs-2.0/nebula-cloud/figs/cl-ug-004.png differ diff --git a/docs-2.0/nebula-cloud/figs/cl-ug-005.png b/docs-2.0/nebula-cloud/figs/cl-ug-005.png new file mode 100644 index 0000000000..568b6999ee Binary files /dev/null and b/docs-2.0/nebula-cloud/figs/cl-ug-005.png differ diff --git a/docs-2.0/nebula-cloud/figs/cl-ug-006.png b/docs-2.0/nebula-cloud/figs/cl-ug-006.png new file mode 100644 index 0000000000..54f4fd0b54 Binary files /dev/null and b/docs-2.0/nebula-cloud/figs/cl-ug-006.png differ diff --git a/docs-2.0/nebula-cloud/figs/cl-ug-007.png b/docs-2.0/nebula-cloud/figs/cl-ug-007.png new file mode 100644 index 0000000000..7e33cfac86 Binary files /dev/null and b/docs-2.0/nebula-cloud/figs/cl-ug-007.png differ diff --git a/docs-2.0/nebula-cloud/figs/cl-ug-008.png b/docs-2.0/nebula-cloud/figs/cl-ug-008.png new file mode 100644 index 0000000000..6e8feab4e8 Binary files /dev/null and b/docs-2.0/nebula-cloud/figs/cl-ug-008.png differ diff --git a/docs-2.0/nebula-cloud/figs/cl-ug-009.png b/docs-2.0/nebula-cloud/figs/cl-ug-009.png new file mode 100644 index 0000000000..652ab75b55 Binary files /dev/null and b/docs-2.0/nebula-cloud/figs/cl-ug-009.png differ diff --git a/docs-2.0/nebula-cloud/figs/cl-ug-010.png b/docs-2.0/nebula-cloud/figs/cl-ug-010.png new file mode 100644 index 0000000000..b0e3ce7e4c Binary files /dev/null and b/docs-2.0/nebula-cloud/figs/cl-ug-010.png differ diff --git a/docs-2.0/nebula-cloud/figs/cl-ug-011.png b/docs-2.0/nebula-cloud/figs/cl-ug-011.png new file mode 100644 index 0000000000..117a7261ab Binary files /dev/null and b/docs-2.0/nebula-cloud/figs/cl-ug-011.png differ diff --git a/docs-2.0/nebula-cloud/figs/cl-ug-012.png b/docs-2.0/nebula-cloud/figs/cl-ug-012.png new file mode 100644 index 0000000000..768ff170ce Binary files /dev/null and b/docs-2.0/nebula-cloud/figs/cl-ug-012.png differ diff --git a/docs-2.0/nebula-console.md b/docs-2.0/nebula-console.md index 484d740bb2..269343d5ae 100644 --- a/docs-2.0/nebula-console.md +++ b/docs-2.0/nebula-console.md @@ -98,12 +98,12 @@ Nebula Console 是 Nebula Graph 的原生命令行客户端,用于连接 Nebul ## 加载测试数据集 -测试数据集名称为 nba,详细 Schema 信息和数据信息请使用相关`SHOW`命令查看。 +测试数据集名称为 basketballplayer,详细 Schema 信息和数据信息请使用相关`SHOW`命令查看。 加载测试数据集命令如下: ```ngql -nebula> :play nba; +nebula> :play basketballplayer; ``` ## 重复执行 diff --git a/docs-2.0/nebula-dashboard-ent/1.what-is-dashboard-ent.md b/docs-2.0/nebula-dashboard-ent/1.what-is-dashboard-ent.md index b47db1947c..f3931544f3 100644 --- a/docs-2.0/nebula-dashboard-ent/1.what-is-dashboard-ent.md +++ b/docs-2.0/nebula-dashboard-ent/1.what-is-dashboard-ent.md @@ -2,6 +2,7 @@ Nebula Dashboard(简称 Dashboard)是一款用于监控和管理 Nebula Graph 多集群中机器和服务状态的可视化工具。本文主要介绍企业版 Dashboard,社区版详情参见[什么是 Nebula Dashboard(社区版)](../nebula-dashboard/1.what-is-dashboard.md)。 +![intro-overview](figs/intro-overview.gif) ## 产品功能 - 创建指定版本的 Nebula Graph 集群,支持批量导入节点、一键添加服务等功能。 @@ -24,7 +25,7 @@ Nebula Dashboard(简称 Dashboard)是一款用于监控和管理 Nebula Grap - 监控数据默认更新频率约为 7 秒。 - 监控数据默认保留 14 天,即只能查询最近 14 天内的监控数据。 -- 只支持 2.0.1 及以上版本的 Nebula Graph。 +- 只支持 2.5.1 及以上版本的 Nebula Graph。 - 建议使用最新版本的 Chrome 访问 Dashboard。 - 建议使用官方提供的安装包进行集群创建或导入。 @@ -38,6 +39,7 @@ Nebula Graph 的版本和 Dashboard 企业版的版本对应关系如下。 |Nebula Graph 版本|Dashboard 版本| |:---|:---| +|2.5.1~3.0.0|1.1.0| |2.0.1~2.6.1|1.0.2| |2.0.1~2.6.1|1.0.1| |2.0.1~2.6.1|1.0.0| diff --git a/docs-2.0/nebula-dashboard-ent/2.deploy-connect-dashboard-ent.md b/docs-2.0/nebula-dashboard-ent/2.deploy-connect-dashboard-ent.md index 7e9ab3af61..e54ccee2d7 100644 --- a/docs-2.0/nebula-dashboard-ent/2.deploy-connect-dashboard-ent.md +++ b/docs-2.0/nebula-dashboard-ent/2.deploy-connect-dashboard-ent.md @@ -14,9 +14,9 @@ | 端口号 | 说明 | | ------ | --------------------------------- | | 7005 | Dashboard 提供 web 服务的端口。 | - | 8090 | nebula-http-gateway 服务的端口。 | - | 9090 | prometheus 服务的端口。 | + | 9090 | Prometheus 服务的端口。 | | 9200 | nebula-stats-exporter 服务的端口。 | + | 9093 | Alertmanager 服务的端口。接收 Prometheus 告警,发送告警通知给 Dashboard。| - 准备 License。 @@ -34,67 +34,88 @@ 2. 使用`tar -xzvf`解压 tar 包。 - ```bash - $ tar -xzvf nebula-dashboard-ent-.linux-amd64.tar.gz - ``` - - 例如: - - ```bash - $ tar -xzvf nebula-dashboard-ent-1.0.0.linux-amd64.tar.gz - ``` - -3. 使用`vim config/config.yaml`命令修改配置文件。 - - ```bash - # 数据库信息 - database: - dialect: mysql # 使用的数据库类型,目前仅支持 MySql - host: 192.168.8.157 # 连接的 MySql 数据库的 ip 地址 - port: 3306 # 连接的 MySql 数据库的端口号 - username: root # 登陆 MySql 的账户 - password: nebula # 登陆 MySql 的密码 - name: dashboard # 对应的数据库名称 - autoMigrate: true # 自动创建数据库表,默认为 true - # exporter 端口信息 - exporter: - nodePort: 9100 # node-exporter 服务的端口 - nebulaPort: 9200 # nebula-stats-exporter 服务的端口 - # 服务信息 - proxy: - gateway: - target: "127.0.0.1:8090" # gateway 服务的 IP 地址和端口 - prometheus: - target: "127.0.0.1:9090" # prometheus 服务的 IP 地址和端口 - ``` + ```bash + $ tar -xzvf nebula-dashboard-ent-.linux-amd64.tar.gz + ``` + + 例如: + + ```bash + $ tar -xzvf nebula-dashboard-ent-{{dashboard_ent.release}}.linux-amd64.tar.gz + ``` + +3. 使用`vim config/config.yaml`命令设置配置文件。 + + ```bash + # 数据库信息 + database: + dialect: mysql # 使用的数据库类型,目前仅支持 MySQL。 + host: 192.168.8.157 # 连接的 MySQL 数据库的 IP 地址。 + port: 3306 # 连接的 MySQL 数据库的端口号。 + username: root # 登陆 MySQL 的账户。 + password: nebula # 登陆 MySQL 的密码。 + name: dashboard # 对应的数据库名称。 + autoMigrate: true # 自动创建数据库表,默认为 true。 + # exporter 端口信息 + exporter: + nodePort: 9100 # node-exporter 服务的端口。 + nebulaPort: 9200 # nebula-stats-exporter 服务的端口。 + # 服务信息 + proxy: + prometheus: + target: "127.0.0.1:9090" # prometheus 服务的 IP 地址和端口。 + alertmanager: + target: "127.0.0.1:9093" # alertmanager 服务的 IP 地址和端口。 + # 邀请 LDAP 账号的发件人邮箱信息 + mail: + host: smtp.office365.com # SMTP 服务器地址。 + port: 587 # SMTP 服务器的端口号。 + username: "" # SMTP 服务器的用户名。 + password: "" # SMTP 服务器的密码。 + # 系统信息 + system: + webAddress: http://127.0.0.1:7005 # 邮件被邀请人连接 Dashboard 的访问地址。 + messageStore: 90 # 保存告警消息的天数,默认 90 天。 + # LDAP 信息 + ldap: + server: ldap://127.0.0.1 # LDAP 服务器地址。 + bindDN: cn=admin,dc=vesoft,dc=com # LDAP 服务器登录用户名。 + bindPassword: "" # LDAP 服务器登录密码。 + baseDN: dc=vesoft,dc=com # 查询用户数据的路径。 + userFilter: "&(objectClass=*)" # 查询条件。 + emailKey: mail # LDAP 数据库存放邮箱信息的字段名。 + ``` 4. 拷贝 License 至`nebula-dashboard-ent`目录下。 - ```bash - $ cp -r - ``` + ```bash + $ cp -r + ``` - 例如: - ```bash - $ cp -r nebula.license /usr/local/nebula-dashboard-ent - ``` + 例如: + ```bash + $ cp -r nebula.license /usr/local/nebula-dashboard-ent + ``` 5. 启动 Dashboard。 - 可以使用以下命令一键启动 Dashboard。 - ```bash - $ cd scripts - $ sudo ./dashboard.service start all - ``` - 或是执行以下命令,分别启动 prometheus、webserver、exporter 和 gateway 服务以启动 Dashboard。 - ```bash - $ cd scripts - $ sudo ./dashboard.service start prometheus # 启动 prometheus 服务 - $ sudo ./dashboard.service start webserver #启动 webserver 服务 - $ sudo ./dashboard.service start exporter #启动 exporter 服务 - $ sudo ./dashboard.service start gateway #启动 gateway 服务 - ``` + 可以使用以下命令一键启动 Dashboard。 + ```bash + $ cd scripts + $ sudo ./dashboard.service start all + ``` + 或是执行以下命令,分别启动 prometheus、webserver、exporter 和 gateway 服务以启动 Dashboard。 + ```bash + $ cd scripts + $ sudo ./dashboard.service start prometheus # 启动 Prometheus 服务 + $ sudo ./dashboard.service start webserver #启动 Webserver 服务 + $ sudo ./dashboard.service start exporter #启动 Exporter 服务 + $ sudo ./dashboard.service start gateway #启动 Gateway 服务 + ``` +!!! note + + 在启动 Dashboard 后,如再修改配置文件的话,在修改后,可在`scripts`目录下执行`dashboard.service restart all`同步修改至 Dashboard 客户端页面中。 ## 管理 Dashboard 服务 Dashboard 使用脚本`dashboard.service`管理服务,包括启动、停止和查看。 @@ -128,6 +149,7 @@ Dashboard 的安装在当前目录下,用户可以用以下命令管理服务 $ sudo /dashboard/scripts/dashboard.service start all #启动 Dashboard 所有服务 $ sudo /dashboard/scripts/dashboard.service stop all #停止 Dashboard 所有服务 $ sudo /dashboard/scripts/dashboard.service status all #查看 Dashboard 所有服务状态 +$ sudo /dashboard/scripts/dashboard.service restart all #重启 Dashboard 所有服务状态 ``` ## 连接 Dashboard diff --git a/docs-2.0/nebula-dashboard-ent/3.create-import-dashboard/1.create-cluster.md b/docs-2.0/nebula-dashboard-ent/3.create-import-dashboard/1.create-cluster.md index dc6f8ed77e..b3021d112d 100644 --- a/docs-2.0/nebula-dashboard-ent/3.create-import-dashboard/1.create-cluster.md +++ b/docs-2.0/nebula-dashboard-ent/3.create-import-dashboard/1.create-cluster.md @@ -15,9 +15,10 @@ 1. 配置每个 Host 的 IP 信息,本示例设置为`192.168.8.144`。 2. 配置 SSH 信息,本示例设置如下:SSH 端口号为`22`,SSH 用户名为 `vesoft`,SSH 密码为`nebula`。 3. 选择 Nebula Graph 安装包,本示例为`nebula-graph-2.6.1.el7.x86_64rpm`。 - 4. (可选)输入节点名,可以对节点进行备注。本示例设置为`Node_1`。 + 4. 自定义集群的安装路径。本示例为默认安装路径`.nebula/cluster`。 + 5. (可选)输入节点名,可以对节点进行备注。本示例设置为`Node_1`。 - ![cluster](../figs/ds-021.png) + ![cluster](../figs/ds-021.png) - **批量导入节点**,需要添加每个节点的相关信息。批量导入需要先选择安装包后单击**下载 CSV 模版**。按照模版填写后上传,尽量确保节点信息正确,否则容易造成上传失败。 diff --git a/docs-2.0/nebula-dashboard-ent/4.cluster-operator/2.monitor.md b/docs-2.0/nebula-dashboard-ent/4.cluster-operator/2.monitor.md index f2dbed477d..f9aa9438f6 100644 --- a/docs-2.0/nebula-dashboard-ent/4.cluster-operator/2.monitor.md +++ b/docs-2.0/nebula-dashboard-ent/4.cluster-operator/2.monitor.md @@ -1,6 +1,6 @@ # 集群监控 -本文主要介绍 Dashboard 的集群监控中的节点监控和服务监控。 +本文主要介绍 Dashboard 的集群监控中的节点监控、服务监控、图空间监控。 ## 节点监控 @@ -29,5 +29,24 @@ ![service](../figs/ds-005.png) - 默认最多可选择 14 天的监控数据进行查看,也可以快捷选择 1 小时、6 小时、12 小时、1 天、3 天、7 天和 14 天,支持修改查看时间。 - 可以选择需要查看的机器和监控指标。监控指标详情请参见[监控指标说明](../7.monitor-parameter.md)。 + - Graph 服务支持一系列基于图空间的监控指标。详情参见下文**图空间监控**。 - 可以设置基线,作为参考标准线。 - - 可以查看当前服务的状态。 \ No newline at end of file + - 可以查看当前服务的状态。 + +## 图空间监控 + +!!! note + + 使用图空间指标前,用户需要在 Graph 服务中,设置`enable_space_level_metrics`为`true`。具体操作,参见[更新配置](4.manage.md)。 + +图空间的监控指标记录不同图空间的数据。目前,只有 Graph 服务支持基于图空间的监控指标。 + +只有当图空间指标的行为被触发后,用户才能指定图空间查看对应的图空间指标的信息。Dashboard 支持的图空间指标,参见[图空间](../7.monitor-parameter.md)。 + + + + + + + + diff --git a/docs-2.0/nebula-dashboard-ent/4.cluster-operator/3.cluster-information.md b/docs-2.0/nebula-dashboard-ent/4.cluster-operator/3.cluster-information.md index bfa3bc907c..1589ccfbf4 100644 --- a/docs-2.0/nebula-dashboard-ent/4.cluster-operator/3.cluster-information.md +++ b/docs-2.0/nebula-dashboard-ent/4.cluster-operator/3.cluster-information.md @@ -32,7 +32,13 @@ 选择指定图空间,查看指定图空间的 Partition 分布情况。 ## 服务信息 -展示 Storage 服务的基本信息。用户可以通过右上角的 **Balance Date** 按钮启动任务,均衡分布集群中的所有分片。参数说明如下: + +展示 Storage 服务的基本信息。参数说明如下: + + + | 参数 | 说明 | | :--- | :--- | @@ -63,6 +69,6 @@ | :--- | :--- | | `Job ID` | 显示作业 ID。 | | `Command` | 显示命令类型。 | -| `Status` | 显示作业或任务的状态。状态说明参见[作业状态](../../3.ngql-guide/18.operation-and-maintenance-statements/4.job-statements.md#_6)。 | +| `Status` | 显示作业或任务的状态。状态说明参见[作业状态](../../3.ngql-guide/18.operation-and-maintenance-statements/4.job-statements.md#_2)。 | |`Start Time`|显示作业或任务开始执行的时间。| -| `Stop Time` | 显示作业或任务结束执行的时间,结束后的状态包括`FINISHED`、`FAILED`或`STOPPED`。 | \ No newline at end of file +| `Stop Time` | 显示作业或任务结束执行的时间,结束后的状态包括`FINISHED`、`FAILED`或`STOPPED`。 | diff --git a/docs-2.0/nebula-dashboard-ent/4.cluster-operator/4.manage.md b/docs-2.0/nebula-dashboard-ent/4.cluster-operator/4.manage.md index 809df778e0..bf16358f4c 100644 --- a/docs-2.0/nebula-dashboard-ent/4.cluster-operator/4.manage.md +++ b/docs-2.0/nebula-dashboard-ent/4.cluster-operator/4.manage.md @@ -26,6 +26,7 @@ 单击**停止**/**重启**,会立即中断进行中的任务,可能会导致数据不一致,请在业务低峰期执行该操作。 + ## 更新配置 diff --git a/docs-2.0/nebula-dashboard-ent/7.monitor-parameter.md b/docs-2.0/nebula-dashboard-ent/7.monitor-parameter.md index cd8cc0787c..99da74138f 100644 --- a/docs-2.0/nebula-dashboard-ent/7.monitor-parameter.md +++ b/docs-2.0/nebula-dashboard-ent/7.monitor-parameter.md @@ -135,3 +135,21 @@ | num_vertices_deleted | 删除的点数量。 | | num_vertices_inserted | 插入的点数量。 | | transfer_leader_latency_us | Raft 协议中转移 Leader 的延迟时间。 | + + +### 图空间 + +| 参数 | 说明 | +| ---------------------------------------------- | ----------------------------------------- | +| num_active_queries | 当前正在执行的查询数。 | +| num_aggregate_executors | 聚合(Aggregate)算子执行时间。 | +| num_indexscan_executors | 索引扫描(IndexScan)算子执行时间。 | +| num_killed_queries | 被终止的查询数量。 | +| num_queries | 查询次数。 | +| num_query_errors_leader_changes | 因查询错误而导致的 Leader 变更的次数。 | +| num_query_errors | 查询错误次数。 | +| num_sentences | Graphd 服务接收的语句数。 | +| num_slow_queries | 慢查询次数。 | +| num_sort_executors | 排序(Sort)算子执行时间。 | +| optimizer_latency_us | 优化器阶段延时。 | +| query_latency_us | 查询平均延迟时间。 | \ No newline at end of file diff --git a/docs-2.0/nebula-dashboard-ent/8.faq.md b/docs-2.0/nebula-dashboard-ent/8.faq.md index d49a25541a..ac41bda800 100644 --- a/docs-2.0/nebula-dashboard-ent/8.faq.md +++ b/docs-2.0/nebula-dashboard-ent/8.faq.md @@ -28,11 +28,13 @@ Nebula Graph 是分布式图数据库,可以支持运行时动态扩展和缩 Meta 服务主要存储 Nebula Graph 数据库中的元数据。一旦 Meta 服务出现问题,整个集群会面临瘫痪风险。且 Meta 处理的数据量较少,一般不会出现扩缩容场景,因此我们直接在 Dashboard 中禁用了操作 Meta,防止出现用户误操作导致集群不可用的情况。 + ## 为什么无法启动 Dashboard(企业版)? diff --git a/docs-2.0/nebula-dashboard-ent/9.alerts.md b/docs-2.0/nebula-dashboard-ent/9.alerts.md index 55195bdc69..de102b65f7 100644 --- a/docs-2.0/nebula-dashboard-ent/9.alerts.md +++ b/docs-2.0/nebula-dashboard-ent/9.alerts.md @@ -2,6 +2,7 @@ 监控告警是对 Nebula Graph 集群的监控指标进行报警的服务。用户可以查看告警信息,设置告警规则和告警接收方。 +![Alerts](figs/alerts.gif) ## 告警信息 @@ -12,7 +13,7 @@ - 支持根据信息的严重级别、类型、状态,筛选告警信息。用户可单击**重置**置空所有的筛选项。 - 用户可标记告警信息的处理状态,告警信息处理状态默认为`unsolved`,用户可手动标记为`处理中`和`已解决`状态。 -用户不可删除告警信息,但可在`nebula-dashboard-ent/config/config.yaml`文件中,通过修改`messageStore`参数的值来设置保存告警信息的天数。Nebula Dashboard 默认保存 90 天内的信息。 +用户不可删除告警信息,但可在`nebula-dashboard-ent/config/config.yaml`文件中,通过修改`messageStore`参数的值来设置保存告警信息的天数。Nebula Dashboard 默认保存 90 天内的信息。具体操作,参见[部署 Dashboard](2.deploy-connect-dashboard-ent.md)。 ## 告警规则 diff --git a/docs-2.0/nebula-dashboard-ent/figs/alerts.gif b/docs-2.0/nebula-dashboard-ent/figs/alerts.gif new file mode 100644 index 0000000000..91c4f81479 Binary files /dev/null and b/docs-2.0/nebula-dashboard-ent/figs/alerts.gif differ diff --git a/docs-2.0/nebula-dashboard-ent/figs/ds-021.png b/docs-2.0/nebula-dashboard-ent/figs/ds-021.png index 84b9796ed6..6b60a6ea52 100644 Binary files a/docs-2.0/nebula-dashboard-ent/figs/ds-021.png and b/docs-2.0/nebula-dashboard-ent/figs/ds-021.png differ diff --git a/docs-2.0/nebula-dashboard-ent/figs/intro-overview.gif b/docs-2.0/nebula-dashboard-ent/figs/intro-overview.gif new file mode 100644 index 0000000000..f59b69c48d Binary files /dev/null and b/docs-2.0/nebula-dashboard-ent/figs/intro-overview.gif differ diff --git a/docs-2.0/nebula-dashboard/1.what-is-dashboard.md b/docs-2.0/nebula-dashboard/1.what-is-dashboard.md index cf78d052d4..0dd08eea6d 100644 --- a/docs-2.0/nebula-dashboard/1.what-is-dashboard.md +++ b/docs-2.0/nebula-dashboard/1.what-is-dashboard.md @@ -40,8 +40,10 @@ Nebula Graph 的版本和 Dashboard 社区版的版本对应关系如下。 |Nebula Graph 版本|Dashboard 版本| |:---|:---| +|2.5.1~3.0.0|1.1.0| |2.0.1~2.5.1|1.0.2| |2.0.1~2.5.1|1.0.1| + ## 更新说明 [Release](https://github.com/vesoft-inc/nebula-dashboard/releases/tag/{{dashboard.branch}}) diff --git a/docs-2.0/nebula-dashboard/2.deploy-dashboard.md b/docs-2.0/nebula-dashboard/2.deploy-dashboard.md index bfa93c2d69..8d27704010 100644 --- a/docs-2.0/nebula-dashboard/2.deploy-dashboard.md +++ b/docs-2.0/nebula-dashboard/2.deploy-dashboard.md @@ -28,11 +28,11 @@ | Dashboard 安装包 | Nebula Graph 版本 | | :----- | :----- | -| [nebula-graph-dashboard-{{ dashboard.release }}.x86_64.tar.gz](https://oss-cdn.nebula-graph.com.cn/nebula-graph-dashboard/{{ dashboard.release }}/nebula-graph-dashboard-{{ dashboard.release }}.x86_64.tar.gz) | 2.5.0 | +| [nebula-dashboard-{{ dashboard.release }}.x86_64.tar.gz](https://oss-cdn.nebula-graph.com.cn/nebula-graph-dashboard/{{ dashboard.release }}/nebula-dashboard-{{ dashboard.release }}.x86_64.tar.gz) | 2.5.1~3.0.0 | ## 目录结构说明 -执行命令`tar -xvf nebula-graph-dashboard-{{ dashboard.release }}.x86_64.tar.gz`解压缩,目录`nebula-graph-dashboard`内一共有 5 个子目录,说明如下。 +执行命令`tar -xvf nebula-dashboard-{{ dashboard.release }}.x86_64.tar.gz`解压缩,目录`nebula-dashboard/vendors`内一共有 4 个子目录,说明如下。 |目录名称|说明|端口号| |:---|:---|:---| @@ -40,9 +40,8 @@ |nebula-stats-exporter | 收集集群的性能指标,包括服务 IP 地址、版本和监控指标(例如查询数量、查询延迟、心跳延迟等)。|9200| |prometheus | 存储监控数据的时间序列数据库。|9090| |nebula-http-gateway | 为集群服务提供 HTTP 接口,执行 nGQL 语句与 Nebula Graph 数据库进行交互。|8090| -|nebula-graph-dashboard| 提供 Dashboard 服务。该目录名称与根目录相同,请注意区分,后文所述`nebula-graph-dashboard`是指子目录。|7003| -5 个目录需要按照部署需要,复制到各个机器上,详情请参见下文。 +4 个目录需要按照部署需要,复制到各个机器上,详情请参见下文。 ## 操作步骤 @@ -64,12 +63,11 @@ $ nohup ./node-exporter --web.listen-address=":9100" & !!! note - 只需要在`nebula-graph-dashboard`服务所在机器部署`nebula-stats-exporter`服务。 + 只需要在`nebula-dashboard`服务所在机器部署`nebula-stats-exporter`服务。 1. 在目录`nebula-stats-exporter`内修改文件`config.yaml`,配置所有服务的 HTTP 端口,示例如下: ```bash - version: v0.0.4 clusters: - name: nebula instances: @@ -123,7 +121,7 @@ $ nohup ./node-exporter --web.listen-address=":9100" & !!! note - 只需要在`nebula-graph-dashboard`服务所在机器部署`prometheus`服务。 + 只需要在`nebula-dashboard`服务所在机器部署`prometheus`服务。 1. 在目录`prometheus`内修改文件`prometheus.yaml`,配置`node-exporter`服务和`nebula-stats-exporter`服务的 IP 地址和端口,示例如下: @@ -132,7 +130,7 @@ $ nohup ./node-exporter --web.listen-address=":9100" & scrape_interval: 5s evaluation_interval: 5s scrape_configs: - - job_name: 'nebula-exporter' + - job_name: 'nebula-stats-exporter' static_configs: - targets: [ '192.168.xx.100:9200' # nebula-stats-exporter 服务的 IP 地址和端口。 @@ -161,7 +159,7 @@ $ nohup ./node-exporter --web.listen-address=":9100" & !!! note - 只需要在`nebula-graph-dashboard`服务所在机器部署`nebula-http-gateway`服务。 + 只需要在`nebula-dashboard`服务所在机器部署`nebula-http-gateway`服务。 在目录`nebula-http-gateway`内执行如下命令启动服务: @@ -171,30 +169,27 @@ $ nohup ./nebula-httpd & 服务启动后,可以在浏览器中输入`:8090`检查服务是否正常启动。 -### 部署`nebula-graph-dashboard`服务 +### 部署`dashboard`服务 -1. 在目录`nebula-graph-dashboard/static/`内修改文件`custom.json`,配置 Graph 服务的 IP 地址和端口,示例如下: +1. 在目录`nebula-dashboard`内修改文件`config.json`,配置 Graph 服务的 IP 地址,端口和配置代理服域名,示例如下: ```bash - { - "connection": { - "ip": "192.168.xx.4", - "port": 9669 - }, - "alias": { - "ip:port": "instance1" - }, - "chartBaseLine": { - - } - } - ... + port: 7003 + proxy: + gateway: + target: "127.0.0.1:8090" // nebula-http-gateway 服务的 IP 和端口号。 + prometheus: + target: "127.0.0.1:9090" // Prometheus 服务的 IP 和端口号。 + nebulaServer: + ip: "192.168.8.143" // 部署 Graph 服务的机器 IP。 + port: 9669 // Graph 服务的端口号。 + ... ``` -2. 在目录`nebula-graph-dashboard`内执行如下命令启动服务: +2. 在目录`nebula-dashboard`内执行如下命令启动服务: ```bash - $ npm run start + $ nohup ./dashboard & ``` 服务启动后,可以在浏览器中输入`:7003`检查服务是否正常启动。 @@ -208,6 +203,5 @@ $ kill $(lsof -t -i :9100) # 停止 node-exporter 服务 $ kill $(lsof -t -i :9200) # 停止 nebula-stats-exporter 服务 $ kill $(lsof -t -i :9090) # 停止 prometheus 服务 $ kill $(lsof -t -i :8090) # 停止 nebula-http-gateway 服务 -$ cd nebula-graph-dashboard -$ npm run stop # 停止 nebula-graph-dashboard 服务 +$ kill $(lsof -t -i :7003) # 停止 dashboard 服务 ``` diff --git a/docs-2.0/nebula-dashboard/3.connect-dashboard.md b/docs-2.0/nebula-dashboard/3.connect-dashboard.md index ca20f94d0e..16d87cd131 100644 --- a/docs-2.0/nebula-dashboard/3.connect-dashboard.md +++ b/docs-2.0/nebula-dashboard/3.connect-dashboard.md @@ -10,10 +10,14 @@ Dashboard 部署完成后,可以通过浏览器登录使用 Dashboard。 ## 操作步骤 -1. 确认`nebula-graph-dashboard`服务所在机器的 IP 地址,在浏览器中输入`:7003`打开登录页面。 +1. 确认`nebula-dashboard`服务所在机器的 IP 地址,在浏览器中输入`:7003`打开登录页面。 2. 输入 Nebula Graph 数据库的账号和密码,单击登录。 + !!! note + + 输入 Nebula Graph 数据库的账号和密码前,确保在`config.json`文件中配置了部署 Graph 服务的机器 IP。更多信息,参见[部署 Dashboard](2.deploy-dashboard.md)。 + - 如果 Nebula Graph 已经启用身份验证,用户可以使用已创建的账号连接 Dashboard。 - 如果 Nebula Graph 未启用身份验证,用户只能使用默认用户`root`和任意密码连接 Dashboard。 diff --git a/docs-2.0/nebula-dashboard/4.use-dashboard.md b/docs-2.0/nebula-dashboard/4.use-dashboard.md index cc7a5394e9..0355bbfe7b 100644 --- a/docs-2.0/nebula-dashboard/4.use-dashboard.md +++ b/docs-2.0/nebula-dashboard/4.use-dashboard.md @@ -14,7 +14,7 @@ Dashboard 页面主要分为机器、服务、管理三个部分,本文将详 可以查看最近一天的 CPU、内存、负载、磁盘和上下行流量变化情况。 - 如果需要查看某一项更详细的监控指标,可以单击模块右上角的![眼睛](eye.png) 按钮,或者在左侧单击监控项。 + 如果需要查看某一项更详细的监控指标,可以单击模块右上角的![眼睛](eye.png) 按钮,或者在左侧单击监控项。 - CPU、内存、负载、磁盘、流量 @@ -36,7 +36,7 @@ Dashboard 页面主要分为机器、服务、管理三个部分,本文将详 可以查看最近一天各种服务的监控指标变化情况,右上角还可以切换到**版本**页面查看所有服务的 IP 地址和版本。 - 如果需要查看某一种服务更详细的监控指标,可以单击模块右上角的 ![眼睛](eye.png) 按钮,或者在左侧单击具体服务。 + 如果需要查看某一种服务更详细的监控指标,可以单击模块右上角的![眼睛](eye.png)按钮,或者在左侧单击具体服务。 !!! note @@ -50,6 +50,8 @@ Dashboard 页面主要分为机器、服务、管理三个部分,本文将详 - 可以选择需要查看监控数据的机器、监控指标、聚合方式和周期。监控指标详情请参见[监控指标说明](6.monitor-parameter.md)。 + - Graph 服务支持一系列基于图空间的监控指标。详情,参见[图空间监控](../nebula-dashboard-ent/4.cluster-operator/2.monitor.md)。 + - 可以设置基线,作为参考标准线。 - 可以查看当前服务的状态。 diff --git a/docs-2.0/nebula-dashboard/6.monitor-parameter.md b/docs-2.0/nebula-dashboard/6.monitor-parameter.md index f72b8865ff..89fc362b72 100644 --- a/docs-2.0/nebula-dashboard/6.monitor-parameter.md +++ b/docs-2.0/nebula-dashboard/6.monitor-parameter.md @@ -136,4 +136,21 @@ | num_tags_deleted | 删除的 Tag 数量。 | | num_vertices_deleted | 删除的点数量。 | | num_vertices_inserted | 插入的点数量。 | -| transfer_leader_latency_us | Raft 协议中转移 Leader 的延迟时间。 | \ No newline at end of file +| transfer_leader_latency_us | Raft 协议中转移 Leader 的延迟时间。 | + +### 图空间 + +| 参数 | 说明 | +| ---------------------------------------------- | ----------------------------------------- | +| num_active_queries | 当前正在执行的查询数。 | +| num_aggregate_executors | 聚合(Aggregate)算子执行时间。 | +| num_indexscan_executors | 索引扫描(IndexScan)算子执行时间。 | +| num_killed_queries | 被终止的查询数量。 | +| num_queries | 查询次数。 | +| num_query_errors_leader_changes | 因查询错误而导致的 Leader 变更的次数。 | +| num_query_errors | 查询错误次数。 | +| num_sentences | Graphd 服务接收的语句数。 | +| num_slow_queries | 慢查询次数。 | +| num_sort_executors | 排序(Sort)算子执行时间。 | +| optimizer_latency_us | 优化器阶段延时。 | +| query_latency_us | 查询平均延迟时间。 | \ No newline at end of file diff --git a/docs-2.0/nebula-exchange/about-exchange/ex-ug-limitations.md b/docs-2.0/nebula-exchange/about-exchange/ex-ug-limitations.md index 92547dc7ae..734c8b1b1d 100644 --- a/docs-2.0/nebula-exchange/about-exchange/ex-ug-limitations.md +++ b/docs-2.0/nebula-exchange/about-exchange/ex-ug-limitations.md @@ -1,6 +1,6 @@ # 使用限制 -本文描述 Exchange 2.x 的一些使用限制。 +本文描述 Exchange 3.x 的一些使用限制。 ## 版本兼容性 @@ -8,21 +8,19 @@ Nebula Exchange 版本(即 JAR 包版本)和 Nebula Graph 内核的版本对 |Exchange client 版本|Nebula Graph 版本| |:---|:---| -|2.5-SNAPSHOT|nightly| -|{{exchange.release}}|2.6.0、{{nebula.release}}| -|2.5.1|2.5.0、2.5.1| -|2.5.0|2.5.0、2.5.1| +|3.0-SNAPSHOT|nightly| +|{{exchange.release}}|{{nebula.release}}| +|2.6.x|2.6.x | +|2.5.x|2.5.x | |2.1.0|2.0.0、2.0.1| |2.0.1|2.0.0、2.0.1| |2.0.0|2.0.0、2.0.1| JAR 包有两种获取方式:[自行编译](../ex-ug-compile.md)或者从 maven 仓库下载。 -如果正在使用 Nebula Graph 1.x,请使用 [Nebula Exchange 1.x](https://github.com/vesoft-inc/nebula-java/tree/v1.0/tools "Click to go to GitHub")。 - ## 使用环境 -Exchange 2.x 支持以下操作系统: +Exchange 3.x 支持以下操作系统: - CentOS 7 - macOS @@ -48,6 +46,7 @@ Exchange 2.x 支持以下操作系统: | Parquet 文件 | 支持 | 支持 | 支持 | | HBase | 支持 | 支持 | 支持 | | MySQL | 支持 | 支持 | 支持 | + | PostgreSQL | 支持 | 支持 | 支持 | | ClickHouse | 支持 | 支持 | 支持 | | Neo4j | 不支持 | 支持 | 不支持 | | Hive | 支持 | 支持 | 支持 | diff --git a/docs-2.0/nebula-exchange/about-exchange/ex-ug-what-is-exchange.md b/docs-2.0/nebula-exchange/about-exchange/ex-ug-what-is-exchange.md index 7c6dcc0a7c..cef04451df 100644 --- a/docs-2.0/nebula-exchange/about-exchange/ex-ug-what-is-exchange.md +++ b/docs-2.0/nebula-exchange/about-exchange/ex-ug-what-is-exchange.md @@ -68,7 +68,9 @@ Exchange {{exchange.release}} 支持将以下格式或来源的数据转换为 N - 图数据库:[Neo4j](../use-exchange/ex-ug-import-from-neo4j.md)(Client 版本 2.4.5-M1) -- 关系型数据库:[MySQL](../use-exchange/ex-ug-import-from-mysql.md) +- 关系型数据库: + - [MySQL](../use-exchange/ex-ug-import-from-mysql.md) + - [PostgreSQL](../use-exchange/ex-ug-import-from-mysql.md) - 列式数据库:[ClickHouse](../use-exchange/ex-ug-import-from-clickhouse.md) diff --git a/docs-2.0/nebula-exchange/ex-ug-FAQ.md b/docs-2.0/nebula-exchange/ex-ug-FAQ.md index f3b5581018..3ce6852845 100644 --- a/docs-2.0/nebula-exchange/ex-ug-FAQ.md +++ b/docs-2.0/nebula-exchange/ex-ug-FAQ.md @@ -56,7 +56,7 @@ $SPARK_HOME/bin/spark-submit --class com.vesoft.nebula.exchange.Exchange \ --files application.conf \ --conf spark.driver.extraClassPath=./ \ --conf spark.executor.extraClassPath=./ \ -nebula-exchange-2.0.0.jar \ +nebula-exchange-3.0.0.jar \ -c application.conf ``` @@ -123,7 +123,7 @@ nebula-exchange-2.0.0.jar \ --conf spark.driver.extraJavaOptions=-Dfile.encoding=utf-8 \ --conf spark.executor.extraJavaOptions=-Dfile.encoding=utf-8 \ --class com.vesoft.nebula.exchange.Exchange \ - -c + -c ``` 如果是在 YARN 中,则用以下命令: @@ -137,7 +137,7 @@ nebula-exchange-2.0.0.jar \ --conf spark.executor.extraClassPath=./ \ --conf spark.driver.extraJavaOptions=-Dfile.encoding=utf-8 \ --conf spark.executor.extraJavaOptions=-Dfile.encoding=utf-8 \ - \ + \ -c application.conf ``` @@ -205,4 +205,4 @@ Exchange 是在 Spark Writer 基础上开发的 Spark 应用程序,二者均 ### Q:Exchange 传输数据的性能如何? -Exchange 的性能测试数据和测试方法参见 [Nebula Exchange test result](https://github.com/vesoft-inc/nebula-exchange/blob/master/bench/exchange-test.md)。 +Exchange 的性能测试数据和测试方法参见 [Nebula Exchange test result](https://github.com/vesoft-inc/nebula-exchange/blob/{{exchange.branch}}/bench/exchange-test.md)。 diff --git a/docs-2.0/nebula-exchange/ex-ug-compile.md b/docs-2.0/nebula-exchange/ex-ug-compile.md index 566bbf330b..770300b3f8 100644 --- a/docs-2.0/nebula-exchange/ex-ug-compile.md +++ b/docs-2.0/nebula-exchange/ex-ug-compile.md @@ -63,7 +63,7 @@ !!! note JAR 文件版本号会因 Nebula Java Client 的发布版本而变化。用户可以在 [Releases 页面](https://github.com/vesoft-inc/nebula-java/releases)查看最新版本。 -迁移数据时,用户可以参考配置文件 [`target/classes/application.conf`](https://github.com/vesoft-inc/nebula-exchange/blob/master/nebula-exchange/src/main/resources/application.conf)。 +迁移数据时,用户可以参考配置文件 [`target/classes/application.conf`](https://github.com/vesoft-inc/nebula-exchange/blob/master/nebula-exchange_spark_2.4/src/main/resources/application.conf)。 ### 下载依赖包失败 diff --git a/docs-2.0/nebula-exchange/parameter-reference/ex-ug-parameter.md b/docs-2.0/nebula-exchange/parameter-reference/ex-ug-parameter.md index e280626477..4bd8d1f5da 100644 --- a/docs-2.0/nebula-exchange/parameter-reference/ex-ug-parameter.md +++ b/docs-2.0/nebula-exchange/parameter-reference/ex-ug-parameter.md @@ -1,6 +1,6 @@ # 配置说明 -本文介绍使用 Nebula Exchange 时如何修改配置文件 [`application.conf`](https://github.com/vesoft-inc/nebula-exchange/blob/master/nebula-exchange/src/main/resources/application.conf)。 +本文介绍使用 Nebula Exchange 时如何修改配置文件 [`application.conf`](https://github.com/vesoft-inc/nebula-exchange/blob/master/nebula-exchange_spark_2.4/src/main/resources/application.conf)。 修改配置文件之前,建议根据数据源复制并修改文件名称,便于区分。例如数据源为 CSV 文件,可以复制为`csv_application.conf`。 @@ -131,15 +131,15 @@ |`tags.database`|string|-|是|Neo4j 中保存源数据的数据库名。| |`tags.check_point_path`|string|`/tmp/test`|否|设置保存导入进度信息的目录,用于断点续传。如果未设置,表示不启用断点续传。| -### MySQL 源特有参数 +### MySQL/PostgreSQL 源特有参数 |参数|数据类型|默认值|是否必须|说明| |:---|:---|:---|:---|:---| -|`tags.host`|string|-|是|MySQL 服务器地址。| -|`tags.port`|string|-|是|MySQL 服务器端口。| +|`tags.host`|string|-|是|MySQL/PostgreSQL 服务器地址。| +|`tags.port`|string|-|是|MySQL/PostgreSQL 服务器端口。| |`tags.database`|string|-|是|数据库名称。| |`tags.table`|string|-|是|需要作为数据源的表名称。| -|`tags.user`|string|-|是|拥有读取权限的 MySQL 用户名。| +|`tags.user`|string|-|是|拥有读取权限的 MySQL/PostgreSQL 用户名。| |`tags.password`|string|-|是|用户名对应密码。| |`tags.sentence`|string|-|是|查询数据源的语句。例如`"select teamid, name from basketball.team order by teamid;"`。| @@ -184,6 +184,7 @@ |参数|数据类型|默认值|是否必须|说明| |:---|:---|:---|:---|:---| |`tags.path`|string|-|是|指定需要生成 SST 文件的源文件的路径。| +|`tags.repartitionWithNebula`|bool|`false`|否|生成 SST 文件时是否要基于 Nebula Graph 中图空间的 partition 进行数据重分区。开启该功能可减少 DOWNLOAD 和 INGEST SST 文件需要的时间。| ### Nebula Graph 源特有参数 @@ -218,6 +219,13 @@ |`edges.batch`|int|`256`|是|单批次写入 Nebula Graph 的最大边数量。| |`edges.partition`|int|`32`|是|Spark 分片数量。| +### 生成 SST 时的特有参数 + +|参数|数据类型|默认值|是否必须|说明| +|:---|:---|:---|:---|:---| +|`edges.path`|string|-|是|指定需要生成 SST 文件的源文件的路径。| +|`edges.repartitionWithNebula`|bool|`false`|否|生成 SST 文件时是否要基于 Nebula Graph 中图空间的 partition 进行数据重分区。开启该功能可减少 DOWNLOAD 和 INGEST SST 文件需要的时间。| + ### Nebula Graph 源特有参数 |参数|数据类型|默认值|是否必须|说明| diff --git a/docs-2.0/nebula-exchange/use-exchange/ex-ug-import-from-clickhouse.md b/docs-2.0/nebula-exchange/use-exchange/ex-ug-import-from-clickhouse.md index 6bdb274e2b..2a54e20639 100644 --- a/docs-2.0/nebula-exchange/use-exchange/ex-ug-import-from-clickhouse.md +++ b/docs-2.0/nebula-exchange/use-exchange/ex-ug-import-from-clickhouse.md @@ -242,6 +242,9 @@ field:dst_player } + # 指定一个列作为 rank 的源(可选)。 + #ranking: rank + # 单批次写入 Nebula Graph 的数据条数。 batch: 256 @@ -269,6 +272,10 @@ target: { field:teamid } + + # 指定一个列作为 rank 的源(可选)。 + #ranking: rank + batch: 256 partition: 32 } diff --git a/docs-2.0/nebula-exchange/use-exchange/ex-ug-import-from-hbase.md b/docs-2.0/nebula-exchange/use-exchange/ex-ug-import-from-hbase.md index 40c8cdb3e4..116bd36989 100644 --- a/docs-2.0/nebula-exchange/use-exchange/ex-ug-import-from-hbase.md +++ b/docs-2.0/nebula-exchange/use-exchange/ex-ug-import-from-hbase.md @@ -264,6 +264,9 @@ ROW COLUMN+CELL field:dst_player } + # 指定一个列作为 rank 的源(可选)。 + #ranking: rank + # 单批次写入 Nebula Graph 的数据条数。 batch: 256 @@ -293,6 +296,9 @@ ROW COLUMN+CELL field:teamid } + # 指定一个列作为 rank 的源(可选)。 + #ranking: rank + batch: 256 partition: 32 } diff --git a/docs-2.0/nebula-exchange/use-exchange/ex-ug-import-from-hive.md b/docs-2.0/nebula-exchange/use-exchange/ex-ug-import-from-hive.md index 7ebe29a04b..fd3daa7ace 100644 --- a/docs-2.0/nebula-exchange/use-exchange/ex-ug-import-from-hive.md +++ b/docs-2.0/nebula-exchange/use-exchange/ex-ug-import-from-hive.md @@ -296,6 +296,9 @@ scala> sql("select playerid, teamid, start_year, end_year from basketball.serve" field: dst_player } + # 指定一个列作为 rank 的源(可选)。 + #ranking: rank + # 单批次写入 Nebula Graph 的最大数据条数。 batch: 256 @@ -319,6 +322,10 @@ scala> sql("select playerid, teamid, start_year, end_year from basketball.serve" target: { field: teamid } + + # 指定一个列作为 rank 的源(可选)。 + #ranking: rank + batch: 256 partition: 32 } @@ -354,7 +361,7 @@ ${SPARK_HOME}/bin/spark-submit --master "local" --class com.vesoft.nebula.excha GO FROM "player100" OVER follow; ``` -用户也可以使用命令 [`SHOW STATS`](../../3.ngql-guide/7.general-query-statements/6.show/14.show-stats/) 查看统计数据。 +用户也可以使用命令 [`SHOW STATS`](../../3.ngql-guide/7.general-query-statements/6.show/14.show-stats.md) 查看统计数据。 ### 步骤 6:(如有)在 Nebula Graph 中重建索引 diff --git a/docs-2.0/nebula-exchange/use-exchange/ex-ug-import-from-kafka.md b/docs-2.0/nebula-exchange/use-exchange/ex-ug-import-from-kafka.md index 52685d35b5..414afe2aa3 100644 --- a/docs-2.0/nebula-exchange/use-exchange/ex-ug-import-from-kafka.md +++ b/docs-2.0/nebula-exchange/use-exchange/ex-ug-import-from-kafka.md @@ -217,6 +217,9 @@ field:dstPersonId } + # 指定一个列作为 rank 的源(可选)。 + #ranking: rank + # 单批次写入 Nebula Graph 的数据条数。 batch: 10 @@ -247,6 +250,9 @@ field:teamId } + # 指定一个列作为 rank 的源(可选)。 + #ranking: rank + batch: 10 partition: 10 interval.seconds: 10 diff --git a/docs-2.0/nebula-exchange/use-exchange/ex-ug-import-from-maxcompute.md b/docs-2.0/nebula-exchange/use-exchange/ex-ug-import-from-maxcompute.md index c16c1cef83..bb9c23ce1f 100644 --- a/docs-2.0/nebula-exchange/use-exchange/ex-ug-import-from-maxcompute.md +++ b/docs-2.0/nebula-exchange/use-exchange/ex-ug-import-from-maxcompute.md @@ -264,6 +264,9 @@ field: dst_player } + # 指定一个列作为 rank 的源(可选)。 + #ranking: rank + # Spark 分区数量 partition:10 @@ -294,6 +297,10 @@ target:{ field: teamid } + + # 指定一个列作为 rank 的源(可选)。 + #ranking: rank + partition:10 batch:10 } diff --git a/docs-2.0/nebula-exchange/use-exchange/ex-ug-import-from-mysql.md b/docs-2.0/nebula-exchange/use-exchange/ex-ug-import-from-mysql.md index 39f33bd0b6..16eac40e17 100644 --- a/docs-2.0/nebula-exchange/use-exchange/ex-ug-import-from-mysql.md +++ b/docs-2.0/nebula-exchange/use-exchange/ex-ug-import-from-mysql.md @@ -1,6 +1,6 @@ -# 导入 MySQL 数据 +# 导入 MySQL/PostgreSQL 数据 -本文以一个示例说明如何使用 Exchange 将存储在 MySQL 上的数据导入 Nebula Graph。 +本文以一个示例说明如何使用 Exchange 将存储在 MySQL 上的数据导入 Nebula Graph,也适用于从 PostgreSQL 导出数据到 Nebula Graph。 ## 数据集 @@ -277,6 +277,9 @@ mysql> desc serve; field: dst_player } + # 指定一个列作为 rank 的源(可选)。 + #ranking: rank + # 单批次写入 Nebula Graph 的数据条数。 batch: 256 @@ -307,6 +310,10 @@ mysql> desc serve; target: { field: teamid } + + # 指定一个列作为 rank 的源(可选)。 + #ranking: rank + batch: 256 partition: 32 } diff --git a/docs-2.0/nebula-exchange/use-exchange/ex-ug-import-from-pulsar.md b/docs-2.0/nebula-exchange/use-exchange/ex-ug-import-from-pulsar.md index aa7e01ea37..a9de2e3fb7 100644 --- a/docs-2.0/nebula-exchange/use-exchange/ex-ug-import-from-pulsar.md +++ b/docs-2.0/nebula-exchange/use-exchange/ex-ug-import-from-pulsar.md @@ -229,6 +229,9 @@ field:dst_player } + # 指定一个列作为 rank 的源(可选)。 + #ranking: rank + # 单批次写入 Nebula Graph 的数据条数。 batch: 10 @@ -262,6 +265,9 @@ field:teamid } + # 指定一个列作为 rank 的源(可选)。 + #ranking: rank + batch: 10 partition: 10 interval.seconds: 10 diff --git a/docs-2.0/nebula-exchange/use-exchange/ex-ug-import-from-sst.md b/docs-2.0/nebula-exchange/use-exchange/ex-ug-import-from-sst.md index 8160c66674..7874230078 100644 --- a/docs-2.0/nebula-exchange/use-exchange/ex-ug-import-from-sst.md +++ b/docs-2.0/nebula-exchange/use-exchange/ex-ug-import-from-sst.md @@ -170,7 +170,7 @@ SST 文件是一个内部包含了任意长度的有序键值对集合的文件 # Spark 相关配置 spark: { app: { - name: Nebula Exchange 2.0 + name: Nebula Exchange {{exchange.release}} } master:local @@ -279,6 +279,9 @@ SST 文件是一个内部包含了任意长度的有序键值对集合的文件 # 指定 Spark 分片数量。 partition: 32 + + # 生成 SST 文件时是否要基于 Nebula Graph 中图空间的 partition 进行数据重分区。 + repartitionWithNebula: false } # 设置 Tag team 相关信息。 @@ -324,6 +327,9 @@ SST 文件是一个内部包含了任意长度的有序键值对集合的文件 # 指定 Spark 分片数量。 partition: 32 + + # 生成 SST 文件时是否要基于 Nebula Graph 中图空间的 partition 进行数据重分区。 + repartitionWithNebula: false } # 如果需要添加更多点,请参考前面的配置进行添加。 @@ -380,6 +386,9 @@ SST 文件是一个内部包含了任意长度的有序键值对集合的文件 # 指定 Spark 分片数量。 partition: 32 + + # 生成 SST 文件时是否要基于 Nebula Graph 中图空间的 partition 进行数据重分区。 + repartitionWithNebula: false } # 设置 Edge type serve 相关信息。 @@ -431,6 +440,9 @@ SST 文件是一个内部包含了任意长度的有序键值对集合的文件 # 指定 Spark 分片数量。 partition: 32 + + # 生成 SST 文件时是否要基于 Nebula Graph 中图空间的 partition 进行数据重分区。 + repartitionWithNebula: false } ] diff --git a/docs-2.0/nebula-explorer/about-explorer/ex-ug-what-is-explorer.md b/docs-2.0/nebula-explorer/about-explorer/ex-ug-what-is-explorer.md index 1007b2b150..e67efa6c94 100644 --- a/docs-2.0/nebula-explorer/about-explorer/ex-ug-what-is-explorer.md +++ b/docs-2.0/nebula-explorer/about-explorer/ex-ug-what-is-explorer.md @@ -2,15 +2,13 @@ Nebula Explorer (简称 Explorer)是一款可以通过 Web 访问的可视化图探索工具,搭配 Nebula Graph 内核使用,用于与图数据进行可视化交互。即使没有图数据操作经验,用户也可以快速成为图专家。 -![Explorer](../figs/explorer.png) - !!! enterpriseonly Explorer 仅在企业版提供。 !!! Note - 用户也可以在 [Explorer](https://explorer.nebula-graph.com.cn/) 在线试用部分功能。 + 用户可以[在线试用 Explorer](https://explorer.nebula-graph.com.cn/) 部分功能。 ## 适用场景 @@ -22,15 +20,17 @@ Nebula Explorer (简称 Explorer)是一款可以通过 Web 访问的可视 ## 产品优点 -- 易于安装:简单步骤即可完成部署。 +- [易于安装](../deploy-connect/ex-ug-deploy.md):简单步骤即可完成部署。 + +- [易于使用](../ex-ug-shortcuts.md):使用简洁的可视化交互方式,无需构思 nGQL 语句,轻松实现图探索。 -- 易于使用:使用简洁的可视化交互方式,无需构思 nGQL 语句,轻松实现图探索。 +- [灵活性强](../ex-ug-query-exploration.md):支持通过 VID、Tag、Subgraph 等方式查询数据。 -- 灵活性强:支持通过 VID、Tag、Subgraph 等方式查询数据。 +- [探索拓展](../ex-ug-graph-exploration.md):支持对多个点进行拓展操作、查询多个点的共同邻居、查询起点到终点之间的路径等操作。 -- 多种操作:支持对多个点进行拓展操作、查询多个点的共同邻居、查询起点到终点之间的路径等操作。 +- [多样展示](../canvas-operations/canvas-overview.md):支持修改画布中点的颜色和图标,突出关键节点;也支持使用不同布局模式展示数据。 -- 多样展示:支持修改画布中点的颜色和 icon,突出关键节点。也可以在层次图(dagre)、力导向图(force)、环形图(circular)中自由选择数据的展示方式。 +- [数据存储](../canvas-operations/canvas-snapshot.md):支持保存和导入画布数据。 diff --git a/docs-2.0/nebula-explorer/canvas-operations/canvas-overview.md b/docs-2.0/nebula-explorer/canvas-operations/canvas-overview.md new file mode 100644 index 0000000000..5efc7dca3c --- /dev/null +++ b/docs-2.0/nebula-explorer/canvas-operations/canvas-overview.md @@ -0,0 +1,63 @@ +# 画布概览 + +用户可在画布中可视化地探索图数据。本文主要介绍画布的组成及相关功能。 + +画布概览图如下: + +![canvas](../figs/canvas-overview.png) + +## 顶部页签 + +用户可以通过单击画布顶部加号![canvas_tab](../figs/list-add.png)图标同时操作多个画布。 + +![canvas_overview](../figs/canvas-graphspace.png) + +- 不同画布上的数据可以来自同一个图空间也可以来自不同的图空间。 +- 除了最左边页签的第一个画布外,用户可以自定义画布的名称。 + +## 可视化模式 + +用户可以选择 **2D 模式**和 **3D 模式**可视化地在画布上探索图数据。更多信息,参见[可视化模式](visualization-mode.md)。 + +## 数据存储 + +用户可以通过创建快照,或以图片、CSV 文件的方式导出画布以存储当前画布数据。 + +在页面右上方: + +- 单击![snapshot](../figs/graph-snapshot.png)创建快照。更多信息,参见[画布快照](canvas-snapshot.md)。 +- 单击![PNG](../figs/topbar-exportPNG.png)以图片形式存储画布数据。 +- 单击![CSV](../figs/topbar-exportCSV.png)以 CSV 文件的方式存储画布数据。 + + +## 搜索框 + +在页面左上方的搜索框中,输入 VID 或者 Tag 的属性值定位目标点。 + +## 多布局 + +Explorer 支持 6 种布局方式展示画布上的数据之间的关系。 + +| 力导向图 | 层次图 | 环形图 | 网格 | 神经网络 | 辐射 | +| -------- | ------ | ------ | ----- | -------- | ----- | +| ![graphView](../figs/Thumbnail-graphView.png) | ![treeView](../figs/Thumbnail-treeView.png) | ![sphereView](../figs/Thumbnail-sphereView.png) | ![grid](../figs/Thumbnail-Grid.png) | ![neural](../figs/Thumbnail-neuralNetwork.png) | ![radial](../figs/Thumbnail-Radial.png) | + +![layouts](../figs/layout.gif) + +## 缩略图 + +全屏展示画布中的图,收起缩略图,缩小或放大画布中的图等。同时在缩略图的左下角显示了画布中的图占总图的百分比。 + +![](../figs/thumbnail.png) + +## 数据概览 + +在页面右侧,单击![list-left](../figs/list-left.png)展开数据概览面板。 + +![dataView](../figs/dataview.png) + +- 可以在数据概览面板中看到画布中的 Tag 数、Edge type 数,及对应的点和边的数量。 +- 在数据概览面板,单击 Tag 颜色图标,可自定义 Tag 相同的点的颜色、尺寸、图标。 + + !!! note + Tag 完全相同的 VID 点的颜色相同。在画布中右键单击单个点可手动修改一个点的样式。 diff --git a/docs-2.0/nebula-explorer/canvas-operations/canvas-snapshot.md b/docs-2.0/nebula-explorer/canvas-operations/canvas-snapshot.md new file mode 100644 index 0000000000..0d2916b6b5 --- /dev/null +++ b/docs-2.0/nebula-explorer/canvas-operations/canvas-snapshot.md @@ -0,0 +1,31 @@ +# 管理快照 + +Explorer 的快照功能可保存图探索得到的可视化结果,以便再次打开浏览器时还原保存的图数据。 + +## 创建快照 + +1. 在画布右上角,单击相机![snapshot](../figs/graph-snapshot.png)图标。 +2. 填写快照名称和备注(选填)。 +3. 单击**提交**。 + +!!! note + + 已创建的快照被存放在历史快照中。更多信息,参见下文。 + + +## 历史快照 + +在 Explorer 页面左侧导航栏,单击![snapshot_history](../figs/snapshot-history.png)图标进入历史快照列表页面。用户可切换图空间查看相应图空间的历史快照,还可以导入历史快照至画布,下载历史快照至本地,以及删除快照。 + +在目标历史快照右侧的**操作**列下: + +- 单击![snapshot_import](../figs/snapshot-import.png)导入历史快照至新画布中。 +- 单击![snapshot_export](../figs/snapshot-export.png)以 JSON 的格式下载历史快照至本地。 +- 单击![snapshot_delete](../figs/snapshot-delete.png)删除历史快照。 + +在历史快照列表左上方,单击**导入快照**可导入之前下载的 JSON 格式文件至快照列表中,以便用户之间离线共享快照数据。系统会根据 JONS 文件中记录的图空间信息将导入的快照自动放置于相应的图空间中。 + +!!! note + + 目前最多存储 50 个历史快照。 + diff --git a/docs-2.0/nebula-explorer/canvas-operations/visualization-mode.md b/docs-2.0/nebula-explorer/canvas-operations/visualization-mode.md new file mode 100644 index 0000000000..08cd15c5cf --- /dev/null +++ b/docs-2.0/nebula-explorer/canvas-operations/visualization-mode.md @@ -0,0 +1,40 @@ +# 可视化模式 + +Explorer 支持 **2D** 和 **3D** 两种可视化模式探索数据。2D 模式支持数据查看和图操作;3D 模式通过不同视角对图数据进行探索,适用于数据量级比较高或者需要演示的场合。 + +!!! note + + 3D 模式下,不可进行图数据的操作。 + +![visualizaiton_mode](../figs/visualization.gif) + +## 2D 模式 + +2D 模式下可对画布上的数据进行探索操作: + +![2D](../figs/2d-mode.png) + +| 参数 | 说明 | +| ---------- | ------------------------------------------------------------ | +| 出入度权重 | 根据画布中所有点的出边和入边的条数,自动调整点的大小。 | +| 重置出入度 | 重置画布中的点至原始大小。 | +| 信息检测 | 孤立点:检测画布中所有的无边点。
悬挂边:检测画布中只有一条无向边的点。
环检测:检测由边和点连接在一起形成循环的路径。 | + +有关更多的 2D 模式下可进行的操作,参见[画布功能](canvas-overview.md)。 + + +## 3D 模式 + +![2D](../figs/3d-mode.png) + +在页面左上方,单击视图切换开关可切换至 3D 视图模式。3D 视图模式下,可切换回到 2D 图探索模式,并且不会对 2D 的探索产生任何副作用。 + +| 参数 | 说明 | +| -------- | ------------------------------------------------------------ | +| 鸟瞰 | 以鸟瞰的方式展示当前图空间的所有数据(以最少 2 万点和 2 千边进行查询)。 | +| 画质 | 高:点以球的形式展示,光影效果更好。
低:点以圆的形式展示,可以支持更大数据量。 | +| 重新受力 | 当不同的点重叠时,分散点与点之间的距离。 | + +!!! compatibility "历史版本兼容性" + + 针对 3.0.0 以下版本的 Nebula Graph,需要创建索引后才可以使用鸟瞰功能。更多信息,参见[创建索引](../../3.ngql-guide/14.native-index-statements/1.create-native-index.md)。 diff --git a/docs-2.0/nebula-explorer/deploy-connect/ex-ug-connect.md b/docs-2.0/nebula-explorer/deploy-connect/ex-ug-connect.md index 2a9366d9cb..34b0ad1941 100644 --- a/docs-2.0/nebula-explorer/deploy-connect/ex-ug-connect.md +++ b/docs-2.0/nebula-explorer/deploy-connect/ex-ug-connect.md @@ -6,7 +6,7 @@ 在连接 Nebula Graph 数据库前,用户需要确认以下信息: -- 已经安装部署了 Explorer。详细信息参考[部署 Explorer](../deploy-connect/ex-ug-connect.md)。 +- 已经安装部署了 Explorer。详细信息,参见[部署 Explorer](../deploy-connect/ex-ug-deploy.md)。 - Nebula Graph 的 Graph 服务本机 IP 地址以及服务所用端口。默认端口为 `9669`。 @@ -16,11 +16,11 @@ 如果 Nebula Graph 已经启用了身份验证,并且已经创建了不同角色的用户,用户只能使用被分配到的账号和密码登录数据库。如果未启用身份验证,用户可以使用 `root` 用户名和任意密码登录数据库。关于启用身份验证,参考 [Nebula Graph 用户手册](../../README.md "点击进入 Nebula Graph 用户手册")。 -## 操作步骤 +## 连接数据库 按以下步骤连接 Nebula Graph 数据库: -1. 在 Explorer 的 **配置数据库** 页面上,输入以下信息: +1. 在 Explorer 的**配置数据库**页面上,输入以下信息: - **Host**:填写 Nebula Graph 的 Graph 服务本机 IP 地址及端口。格式为 `ip:port`。如果端口未修改,则使用默认端口 `9669`。 @@ -28,16 +28,19 @@ 即使 Nebula Graph 数据库与 Explorer 部署在同一台机器上,用户也必须在 **Host** 字段填写这台机器的本机 IP 地址,而不是 `127.0.0.1` 或者 `localhost`。 - - **用户名** 和 **密码**:根据 Nebula Graph 的身份验证设置填写登录账号和密码。 + - **用户名**和**密码**:根据 Nebula Graph 的身份验证设置填写登录账号和密码。 - 如果未启用身份验证,可以填写默认用户名 `root` 和任意密码。 - 如果已启用身份验证,但是未创建账号信息,用户只能以 GOD 角色登录,必须填写 `root` 及对应的密码 `nebula`。 - 如果已启用身份验证,同时又创建了不同的用户并分配了角色,不同角色的用户使用自己的账号和密码登录。 - ![Nebula Graph Explorer 的登录页面](../figs/ex-ug-002-1.png) +2. 完成设置后,点击**登录**按钮。 -2. 完成设置后,点击 **登录** 按钮。 - 如果能看到如下图所示的界面,表示已经成功连接到 Nebula Graph 数据库。 + !!! note - ![Explorer 进入控制台页面,表示成功连接到 Nebula Graph](../figs/ex-ug-003.png "Nebula Graph 连接成功") + 一次连接会话持续 30 分钟。如果超过 30 分钟没有操作,会话即断开,用户需要重新登录数据库。 -一次连接会话持续 30 分钟。如果超过 30 分钟没有操作,会话即断开,用户需要重新登录数据库。 +## 断开连接 + +在页面左侧工具栏中,选择设置![icon](../figs/nav-setup.png)图标 > 清空连接。 + +如果浏览器上显示**配置数据库**页面,表示 Explorer 已经成功断开了与 Nebula Graph 数据库的连接。 diff --git a/docs-2.0/nebula-explorer/deploy-connect/ex-ug-deploy.md b/docs-2.0/nebula-explorer/deploy-connect/ex-ug-deploy.md index f65ee2de77..5c89f78db0 100644 --- a/docs-2.0/nebula-explorer/deploy-connect/ex-ug-deploy.md +++ b/docs-2.0/nebula-explorer/deploy-connect/ex-ug-deploy.md @@ -1,6 +1,6 @@ # 部署 Explorer -本文介绍如何在本地通过 RPM 和 tar 包部署 Explorer。 +本文介绍如何在本地通过 RPM 和 TAR 包部署 Explorer。 ## Nebula Graph 版本支持 @@ -10,8 +10,11 @@ | Nebula Graph 版本 | Explorer 版本 | | --- | --- | -| 2.5.x | 2.0.0 | +| 2.5.x ~ 3.0.0| 2.2.0| | 2.6.x | 2.1.0 | +| 2.5.x | 2.0.0 | + + ## RPM 部署 @@ -81,12 +84,14 @@ ### 启停服务 支持使用 systemctl 服务控制项目启停。 + ```bash $ systemctl status nebula-explorer #查看服务状态 $ systemctl stop nebula-explorer #停止服务 $ systemctl start nebula-explorer #启动服务 ``` -也可以在安装目录下使用以下命令,手动启动或停止服务: +也可以在安装目录下使用以下命令,手动启动或停止服务。 + ```bash $ cd ./scripts/rpm $ bash ./start.sh #启动服务 @@ -100,7 +105,7 @@ $ bash ./stop.sh #停止服务 ```bash $ sudo rpm -e nebula-explorer-.x86_64 ``` -## tar 包部署 +## TAR 包部署 ### 前提条件 @@ -128,7 +133,7 @@ $ sudo rpm -e nebula-explorer-.x86_64 ### 安装及部署 -1. 根据需要下载 tar 包,建议选择最新版本。 +1. 根据需要下载 TAR 包,建议选择最新版本。 !!! enterpriseonly @@ -151,7 +156,7 @@ $ sudo rpm -e nebula-explorer-.x86_64 $ cp -r nebula.license /usr/local/nebula-explorer ``` -4. 进入`nebula-explorer`文件夹,启动 explorer。 +4. 进入`nebula-explorer`文件夹,启动 Explorer。 ```bash $ cd nebula-explorer @@ -172,6 +177,10 @@ $ kill $(lsof -t -i :7002) 在浏览器窗口中看到以下登录界面表示已经成功部署并启动了 Explorer。 -![Nebula Explorer 登录页面](../figs/ex-ug-002-1.png) +![Nebula Explorer 登录页面](../figs/explorer_deploy.png) + +!!! note + + 首次登录 Nebula Explorer 的时候,页面显示*最终用户许可协议*的内容,请仔细阅读并单击**同意**。 进入 Explorer 登录界面后,用户需要连接 Nebula Graph。详细信息,参考[连接数据库](../deploy-connect/ex-ug-connect.md)。 diff --git a/docs-2.0/nebula-explorer/deploy-connect/ex-ug-reset-connection.md b/docs-2.0/nebula-explorer/deploy-connect/ex-ug-reset-connection.md deleted file mode 100644 index fc69cc3afe..0000000000 --- a/docs-2.0/nebula-explorer/deploy-connect/ex-ug-reset-connection.md +++ /dev/null @@ -1,6 +0,0 @@ -# 清空链接 - -Explorer 还连接在某个 Nebula Graph 数据库时,在工具栏中,选择 设置 ![icon](../figs/nav-setup.png) > 清空连接,如下图所示: -![清空链接](../figs/ex-ug-004.png) - -之后,如果浏览器上显示 **配置数据库** 页面,表示 Explorer 已经成功断开了与 Nebula Graph 数据库的连接。 diff --git a/docs-2.0/nebula-explorer/ex-ug-graph-exploration.md b/docs-2.0/nebula-explorer/ex-ug-graph-exploration.md new file mode 100644 index 0000000000..f6cfc1a6a9 --- /dev/null +++ b/docs-2.0/nebula-explorer/ex-ug-graph-exploration.md @@ -0,0 +1,62 @@ +# 探索拓展 + +图数据库的探索拓展功能分为以下四类: + +- 拓展 +- 共同邻居 +- 路径查询 +- 查看属性 + +![query_exploration](figs/exploration_query.gif) + +## 前提条件 + +使用**探索拓展**的所有功能前,确保画布中有点数据。具体操作,参见[开始探索](ex-ug-query-exploration.md)。 + +## 拓展 + +在左侧导航栏,单击![expand](figs/nav-expand.png)图标,打开**拓展**窗口。用户可以双击某一点,对该点进行拓展。也可以右键框选画布中的多个点,在操作栏中修改边类型,选择边的流入流出方向,修改点的颜色,规定拓展步数和自定义过滤条件。 + +| 参数 | 描述 | +| -------- | ------------------------------------------------------------ | +| 边类型 | 默认显示并选中图空间中的所有边。 | +| 方向 | 定义所有选中点的边的方向来查询目标点,包括`流出`、`流入`、`双向`三个选项。 | +| 点的样式 | `按标签类型分类`:目标点的显示颜色和相应的 Tag 颜色一致。
`自定义样式`:自定义目标点的显示颜色。 | +| 步数 | `单步`:自定义选中点至目标点的跳数。
`范围`:自定义选中点至目标点的范围。 | +| 筛选条件 | 根据筛选条件查询目标点。 | + +!!! Note + + 系统会在面板内的配置被修改后保存当前配置,当双击点或者右键对点快捷拓展时候会以当前配置进行拓展。 + + +## 共同邻居 + +在左侧导航栏,单击![commonneighbor](figs/nav-commonNeighbor.png)图标,打开**共同邻居**窗口。用户可以选中画布中的两个点或多个点,查询它们的共同邻居。选中的点无共同邻居时,默认返回**没有相应数据**。 + +关于如何选中两个点或者多个点的操作,参见[常规操作](ex-ug-shortcuts.md)。 + + +## 路径查询 + +在左侧导航栏,单击![findpath](figs/nav-findPath.png)图标,打开**路径查询**窗口。**用户可以选中画布中的两个点,默认框选的第一个点为起点,第二个点为终点。**用户可自定义边的类型和方向,规定拓展步数,选择查询路径。 + +| 参数 | 描述 | +| -------- | ------------------------------------------------------------ | +| 边类型 | 默认显示并选中图数据库中的所有边。 | +| 方向 | 定义起始点的边的方向来查询和目标点的路径,包括`流出`、`流入`、`双向`三个选项。 | +| 查询类型 | `全路径`:显示从起点至终点所有路径的点和边。
`最短路径`:显示从起点至终点的最短路径的点和边。
`非循环路径`:显示从起点至终点的非循环路径的点和边。 | +| 选中步骤 | 起始点至终点的路径的条数。 | +| 筛选条件 | 根据筛选条件筛选目标点。 | + +## 查看属性 + +在左侧导航栏,单击![propertyview](figs/nav-propertyView.png)图标,打开**查看属性**窗口。用户可以选择在画布中展示或隐藏点或边的属性。 + +!!! note + + - 缩放比例大于 90% 时候在画布上才会显示点属性,小于 90% 的时候会自动隐藏。 + - 缩放比例大于 100% 时候在画布上才会显示边属性,小于 100% 的时候会自动隐藏。 + + + diff --git a/docs-2.0/nebula-explorer/ex-ug-page-overview.md b/docs-2.0/nebula-explorer/ex-ug-page-overview.md new file mode 100644 index 0000000000..7480500fd2 --- /dev/null +++ b/docs-2.0/nebula-explorer/ex-ug-page-overview.md @@ -0,0 +1,49 @@ +# 页面概览 + +本文介绍 Explorer 的基本组成,帮忙用户了解 Explorer 的各功能。 + +Explorer 由导航栏和画布两大模块组成。 + +![explorer-overview](figs/explorer-overview-1.png) + +!!! note + + 登录 Explorer 后,用户需选择并单击一个目标图空间,才可进入画布页面并解锁左侧导航栏的查询及分析功能。 + +![explorer-overview-graph_space](figs/explorer-overview-graphspace.png) + +## 导航栏 + +用户可以通过单击 Explorer 页面左侧的图标进行图数据导入、图数据分析与探索等操作。左侧导航栏的图标及描述如下: + +| 图标 | 描述 | +| ----- | ---- | +| ![query](figs/nav-query2.png) | 输入 VID、Tag 和子图等信息后,匹配的数据会显示到画布上。更多信息,参见[查询方式](ex-ug-query-exploration.md)。 | +| ![filter](figs/nav-filter.png) | 对画布中显示的点进行过滤。更多信息,参见[节点筛选](node-filtering.md)。 | +| ![expand](figs/nav-expand.png) | 选择页面上的节点并进行自定义拓展,包括方向、步数、过滤条件等。 | +| ![commonNeighbor](figs/nav-commonNeighbor.png) | 选择页面上至少两个点并查看它们的共同邻居。 | +| ![findPath](figs/nav-findPath.png) | 查询起点到终点之间的所有路径、最短路径和非循环路径。 | +| ![propertyView](figs/nav-propertyView.png) | 选择是否显画布中的点或边的属性值。 | +| ![hide](figs/nav-miss.png) | 隐藏画布中选中的点边。 | +| ![hideReverse](figs/nav-missReverse.png) | 隐藏画布中未选择的所有点边。 | +| ![Revoke](figs/nav-Revoke.png) | 撤销上一步新增或隐藏的操作。 | +| ![Redo](figs/redo.png) | 恢复上一步撤销的操作。 | +| ![snapshot](figs/snapshot-history.png) | 查看历史快照信息。更多信息,参见[画布快照](canvas-operations/canvas-snapshot.md)。 | +| ![graphSpace](figs/nav-graphSpace.png) | 查看所有图空间,单击图空间可创建相应图空间的画布。 | +| ![Help](figs/nav-help.png) | 查看 Explorer 操作文档、论坛内容等。 | +| ![Setup](figs/nav-setup.png) | 查看用户名和快捷键、修改语言设置、限制返回结果数量、清除 Explorer 链接等。| +| ![Console](figs/nav-console.png) | 使用命令行查询,然后将查询结果导入至画布中。更多信息,参见[控制台](explorer-console.md)。 | + +## 画布 + +图数据可视化地展示在画布中。Explorer 的画布由以下部分组成: + +- 顶部页签 +- 可视化模式 +- 数据存储 +- 搜索框 +- 多布局 +- 缩略图 +- 数据概览 + +更多信息,参见[画布操作](canvas-operations/canvas-overview.md)。 diff --git a/docs-2.0/nebula-explorer/ex-ug-query-exploration.md b/docs-2.0/nebula-explorer/ex-ug-query-exploration.md new file mode 100644 index 0000000000..4022eb641e --- /dev/null +++ b/docs-2.0/nebula-explorer/ex-ug-query-exploration.md @@ -0,0 +1,52 @@ +# 开始探索 + +!!! note + + 使用查询功能前,需要选中并单击目标图空间。 + +!!! compatibility "历史版本兼容性" + + 针对 3.0.0 以下版本的 Nebula Graph,需要创建索引后才可以使用查询功能。更多信息,参见[创建索引](../3.ngql-guide/14.native-index-statements/1.create-native-index.md)。 + +用户进行图数据的探索和分析前,首先需要先单击**开始**图标![query](figs/nav-query2.png)然后查询目标数据。查询到的数据会显示在画布中。查询方式如下: + +- VID 查询 +- Tag 查询 +- 子图查询 + +## VID 查询 + +用户可输入点的 ID(VID)查询目标点然后基于目标点进行探索和分析。 + +支持手动输入、随机导入、文件导入 VID。 + +!!! note + + - 输入或者导入的数据必须存在于图数据库中。 + - 查询区域中每行仅支持填入一个 VID。 + +以下以图空间`nba`及相关数据为例演示如何查询数据。 + +![VID QUERY](figs/vid_query.gif) + +## Tag 查询 + +!!! note + +使用 **Tag 查询** 方式查询数据,确保对应的图空间中已存在相应的 Tag 和索引。更多信息,参见[创建 Tag](../3.ngql-guide/10.tag-statements/1.create-tag.md) 和[创建索引](../3.ngql-guide/14.native-index-statements/1.create-native-index.md)。 + +用户可以对输出的结果进行数量上的限制和对结果进行过滤。 + +以下查询 10 个年龄大于 30 岁,且不等于 40 岁的球员。 + +![tag](figs/query_tag.png) + +## 子图查询 + +**子图查询**方式的必选值为 VID。用户可以输入一个或多个 VID,指定查询的步数、边类型及流入流出的方向查询子图数据。以下给出 VID 值为 `Kings`和`Suns`,步数为`2` ,边类型为`server`和`like`的入边的示例。 + +!!! note + + 当输入多个 VID 时,VID 之间以`Enter`键隔开。 + +![tag](figs/query_subgraph.png) \ No newline at end of file diff --git a/docs-2.0/nebula-explorer/ex-ug-shortcuts.md b/docs-2.0/nebula-explorer/ex-ug-shortcuts.md new file mode 100644 index 0000000000..cee74d2397 --- /dev/null +++ b/docs-2.0/nebula-explorer/ex-ug-shortcuts.md @@ -0,0 +1,29 @@ +# 基本操作和快捷键 + +本文列出了 Explorer 的基本操作及快捷键。 + +## 基本操作 + +| 操作 | 说明 | +| ---------------- | ------------------------------------------------------------ | +| 移动画布 | 在画布空白处鼠标左键拖拽移动。 | +| 放大或缩小画布 | 鼠标滚轮向下放大画布,向上缩小画布。 | +| 选中单节点或单边 | 鼠标左键单击节点或边。 | +| 选中多节点或多边 | 同时按住 Shift 和鼠标左键单击点或边。 | +| 批量选中数据 | 按住鼠标右键并框选数据;或者同时按住 Shift 和鼠标左键,并框选数据。 | +| 选中节点移动 | 鼠标左键拖拽选中节点。 | + + +## 快捷键 + +| 操作 | 说明 | +| :-- | :--| +| Enter | 拓展 | +| Shift + '-' | 缩小 | +| Shift + '+' | 放大 | +| Shift + 'l' | 显示 | +| Ctrl/Cmd + 'z' | 撤销 | +| Ctrl/Cmd + Shift + 'z' | 回退 | +| Ctrl/Cmd + 'a' | 选中所有点| +| 选中 + 'del'| 隐藏 | +| 选中 + Shift + 'del' | 隐藏其他 | diff --git a/docs-2.0/nebula-explorer/explorer-console.md b/docs-2.0/nebula-explorer/explorer-console.md new file mode 100644 index 0000000000..c2f4ffabe1 --- /dev/null +++ b/docs-2.0/nebula-explorer/explorer-console.md @@ -0,0 +1,32 @@ +# 控制台 + +Explorer 的控制台功能允许用户手动输入 nGQL 语句,并将查询结果导入 Explorer 的画布中进行可视化呈现。 + +!!! note + + 使用控制台功能前,确保用户已选择目标图空间。 + +## 输入 nGQL 语句 + +1. 在左侧导航栏,单击![console_input](figs/nav-console.png)。 +2. 在控制台页面的输入框中,填写 nGQL 查询语句。更多信息,参见 [nGQL 命令汇总](../2.quick-start/6.cheatsheet-for-ngql-command.md)。 +3. 单击![run](figs/console_run.png)图标。 +4. (可选)单击![history](figs/console_history.png)查看历史执行的命令。 +5. (可选)单击![clear](figs/console_delete.png)清除当前输入框中的语句。 + +## nGQL 语句结果展示 + +在控制台页面的下方区域,显示执行命令的输出结果。 + +结果以表格的形式展现,用户可单击**导出 CSV 文件**将表格的显示的数据保存至本地。 + +在表格最下方显示执行命令的耗时,单位秒(s)。 + +## 导入 nGQL 语句结果至画布 + +可以将查询的结果直接导入至画布中。单击**查看子图**: + +- **清除插入**:清除画布中的数据,然后插入查询结果的数据至画布中。 +- **增量插入**:在画布的数据基础上,新增查询结果的数据至画布中。画布中相同的数据会被覆盖。 + + diff --git a/docs-2.0/nebula-explorer/figs/2d-mode.png b/docs-2.0/nebula-explorer/figs/2d-mode.png new file mode 100644 index 0000000000..e2ae5168e6 Binary files /dev/null and b/docs-2.0/nebula-explorer/figs/2d-mode.png differ diff --git a/docs-2.0/nebula-explorer/figs/3d-mode.png b/docs-2.0/nebula-explorer/figs/3d-mode.png new file mode 100644 index 0000000000..1d540e91a7 Binary files /dev/null and b/docs-2.0/nebula-explorer/figs/3d-mode.png differ diff --git a/docs-2.0/nebula-explorer/figs/Thumbnail-Grid.png b/docs-2.0/nebula-explorer/figs/Thumbnail-Grid.png new file mode 100644 index 0000000000..c661693fed Binary files /dev/null and b/docs-2.0/nebula-explorer/figs/Thumbnail-Grid.png differ diff --git a/docs-2.0/nebula-explorer/figs/Thumbnail-Radial.png b/docs-2.0/nebula-explorer/figs/Thumbnail-Radial.png new file mode 100644 index 0000000000..c03b434046 Binary files /dev/null and b/docs-2.0/nebula-explorer/figs/Thumbnail-Radial.png differ diff --git a/docs-2.0/nebula-explorer/figs/Thumbnail-graphView.png b/docs-2.0/nebula-explorer/figs/Thumbnail-graphView.png index d4fcc3e4de..3230dad2ee 100644 Binary files a/docs-2.0/nebula-explorer/figs/Thumbnail-graphView.png and b/docs-2.0/nebula-explorer/figs/Thumbnail-graphView.png differ diff --git a/docs-2.0/nebula-explorer/figs/Thumbnail-neuralNetwork.png b/docs-2.0/nebula-explorer/figs/Thumbnail-neuralNetwork.png new file mode 100644 index 0000000000..f8d2317b07 Binary files /dev/null and b/docs-2.0/nebula-explorer/figs/Thumbnail-neuralNetwork.png differ diff --git a/docs-2.0/nebula-explorer/figs/Thumbnail-sphereView.png b/docs-2.0/nebula-explorer/figs/Thumbnail-sphereView.png index c25f31516d..724269e389 100644 Binary files a/docs-2.0/nebula-explorer/figs/Thumbnail-sphereView.png and b/docs-2.0/nebula-explorer/figs/Thumbnail-sphereView.png differ diff --git a/docs-2.0/nebula-explorer/figs/Thumbnail-treeView.png b/docs-2.0/nebula-explorer/figs/Thumbnail-treeView.png index 0f2bdcdf3c..c237e92b67 100644 Binary files a/docs-2.0/nebula-explorer/figs/Thumbnail-treeView.png and b/docs-2.0/nebula-explorer/figs/Thumbnail-treeView.png differ diff --git a/docs-2.0/nebula-explorer/figs/canvas-graphspace.png b/docs-2.0/nebula-explorer/figs/canvas-graphspace.png new file mode 100644 index 0000000000..4bf2529ec9 Binary files /dev/null and b/docs-2.0/nebula-explorer/figs/canvas-graphspace.png differ diff --git a/docs-2.0/nebula-explorer/figs/canvas-overview.png b/docs-2.0/nebula-explorer/figs/canvas-overview.png new file mode 100644 index 0000000000..86950a4266 Binary files /dev/null and b/docs-2.0/nebula-explorer/figs/canvas-overview.png differ diff --git a/docs-2.0/nebula-explorer/figs/console_delete.png b/docs-2.0/nebula-explorer/figs/console_delete.png new file mode 100644 index 0000000000..9433026330 Binary files /dev/null and b/docs-2.0/nebula-explorer/figs/console_delete.png differ diff --git a/docs-2.0/nebula-explorer/figs/console_history.png b/docs-2.0/nebula-explorer/figs/console_history.png new file mode 100644 index 0000000000..c7078ea224 Binary files /dev/null and b/docs-2.0/nebula-explorer/figs/console_history.png differ diff --git a/docs-2.0/nebula-explorer/figs/console_run.png b/docs-2.0/nebula-explorer/figs/console_run.png new file mode 100644 index 0000000000..ba6ac9ad79 Binary files /dev/null and b/docs-2.0/nebula-explorer/figs/console_run.png differ diff --git a/docs-2.0/nebula-explorer/figs/dataview.png b/docs-2.0/nebula-explorer/figs/dataview.png new file mode 100644 index 0000000000..6cdeee2941 Binary files /dev/null and b/docs-2.0/nebula-explorer/figs/dataview.png differ diff --git a/docs-2.0/nebula-explorer/figs/ex-ug-001.png b/docs-2.0/nebula-explorer/figs/ex-ug-001.png deleted file mode 100644 index bbccfd3427..0000000000 Binary files a/docs-2.0/nebula-explorer/figs/ex-ug-001.png and /dev/null differ diff --git a/docs-2.0/nebula-explorer/figs/ex-ug-002-1.png b/docs-2.0/nebula-explorer/figs/ex-ug-002-1.png deleted file mode 100644 index 390f3b1bc0..0000000000 Binary files a/docs-2.0/nebula-explorer/figs/ex-ug-002-1.png and /dev/null differ diff --git a/docs-2.0/nebula-explorer/figs/ex-ug-002.png b/docs-2.0/nebula-explorer/figs/ex-ug-002.png deleted file mode 100644 index f5db7ef388..0000000000 Binary files a/docs-2.0/nebula-explorer/figs/ex-ug-002.png and /dev/null differ diff --git a/docs-2.0/nebula-explorer/figs/ex-ug-003.png b/docs-2.0/nebula-explorer/figs/ex-ug-003.png deleted file mode 100644 index edfddf141b..0000000000 Binary files a/docs-2.0/nebula-explorer/figs/ex-ug-003.png and /dev/null differ diff --git a/docs-2.0/nebula-explorer/figs/ex-ug-004-1.png b/docs-2.0/nebula-explorer/figs/ex-ug-004-1.png deleted file mode 100644 index 2f3b14bcb9..0000000000 Binary files a/docs-2.0/nebula-explorer/figs/ex-ug-004-1.png and /dev/null differ diff --git a/docs-2.0/nebula-explorer/figs/ex-ug-004.png b/docs-2.0/nebula-explorer/figs/ex-ug-004.png deleted file mode 100644 index f957f356bc..0000000000 Binary files a/docs-2.0/nebula-explorer/figs/ex-ug-004.png and /dev/null differ diff --git a/docs-2.0/nebula-explorer/figs/ex-ug-005.png b/docs-2.0/nebula-explorer/figs/ex-ug-005.png deleted file mode 100644 index ccc3036f24..0000000000 Binary files a/docs-2.0/nebula-explorer/figs/ex-ug-005.png and /dev/null differ diff --git a/docs-2.0/nebula-explorer/figs/ex-ug-006.png b/docs-2.0/nebula-explorer/figs/ex-ug-006.png deleted file mode 100644 index ce0e87c2cd..0000000000 Binary files a/docs-2.0/nebula-explorer/figs/ex-ug-006.png and /dev/null differ diff --git a/docs-2.0/nebula-explorer/figs/ex-ug-007.png b/docs-2.0/nebula-explorer/figs/ex-ug-007.png deleted file mode 100644 index 4a6c1b09e8..0000000000 Binary files a/docs-2.0/nebula-explorer/figs/ex-ug-007.png and /dev/null differ diff --git a/docs-2.0/nebula-explorer/figs/ex-ug-008.png b/docs-2.0/nebula-explorer/figs/ex-ug-008.png deleted file mode 100644 index 67bd3b1fb2..0000000000 Binary files a/docs-2.0/nebula-explorer/figs/ex-ug-008.png and /dev/null differ diff --git a/docs-2.0/nebula-explorer/figs/ex-ug-009-1.png b/docs-2.0/nebula-explorer/figs/ex-ug-009-1.png deleted file mode 100644 index b3bad34b06..0000000000 Binary files a/docs-2.0/nebula-explorer/figs/ex-ug-009-1.png and /dev/null differ diff --git a/docs-2.0/nebula-explorer/figs/ex-ug-009-2.png b/docs-2.0/nebula-explorer/figs/ex-ug-009-2.png deleted file mode 100644 index c4dd12bcb6..0000000000 Binary files a/docs-2.0/nebula-explorer/figs/ex-ug-009-2.png and /dev/null differ diff --git a/docs-2.0/nebula-explorer/figs/ex-ug-010.png b/docs-2.0/nebula-explorer/figs/ex-ug-010.png deleted file mode 100644 index 00ec1f1ded..0000000000 Binary files a/docs-2.0/nebula-explorer/figs/ex-ug-010.png and /dev/null differ diff --git a/docs-2.0/nebula-explorer/figs/ex-ug-011-1.png b/docs-2.0/nebula-explorer/figs/ex-ug-011-1.png deleted file mode 100644 index a2d84b7673..0000000000 Binary files a/docs-2.0/nebula-explorer/figs/ex-ug-011-1.png and /dev/null differ diff --git a/docs-2.0/nebula-explorer/figs/ex-ug-011-2.png b/docs-2.0/nebula-explorer/figs/ex-ug-011-2.png deleted file mode 100644 index 40d87530d4..0000000000 Binary files a/docs-2.0/nebula-explorer/figs/ex-ug-011-2.png and /dev/null differ diff --git a/docs-2.0/nebula-explorer/figs/ex-ug-012-1.png b/docs-2.0/nebula-explorer/figs/ex-ug-012-1.png deleted file mode 100644 index cbdd815524..0000000000 Binary files a/docs-2.0/nebula-explorer/figs/ex-ug-012-1.png and /dev/null differ diff --git a/docs-2.0/nebula-explorer/figs/ex-ug-012-2.png b/docs-2.0/nebula-explorer/figs/ex-ug-012-2.png deleted file mode 100644 index 10cb692210..0000000000 Binary files a/docs-2.0/nebula-explorer/figs/ex-ug-012-2.png and /dev/null differ diff --git a/docs-2.0/nebula-explorer/figs/ex-ug-013-1.png b/docs-2.0/nebula-explorer/figs/ex-ug-013-1.png deleted file mode 100644 index 198eeb4fda..0000000000 Binary files a/docs-2.0/nebula-explorer/figs/ex-ug-013-1.png and /dev/null differ diff --git a/docs-2.0/nebula-explorer/figs/ex-ug-013-2.png b/docs-2.0/nebula-explorer/figs/ex-ug-013-2.png deleted file mode 100644 index 807fc22ae2..0000000000 Binary files a/docs-2.0/nebula-explorer/figs/ex-ug-013-2.png and /dev/null differ diff --git a/docs-2.0/nebula-explorer/figs/ex-ug-014-1.png b/docs-2.0/nebula-explorer/figs/ex-ug-014-1.png deleted file mode 100644 index 67834411af..0000000000 Binary files a/docs-2.0/nebula-explorer/figs/ex-ug-014-1.png and /dev/null differ diff --git a/docs-2.0/nebula-explorer/figs/ex-ug-014-2.png b/docs-2.0/nebula-explorer/figs/ex-ug-014-2.png deleted file mode 100644 index 353715a6df..0000000000 Binary files a/docs-2.0/nebula-explorer/figs/ex-ug-014-2.png and /dev/null differ diff --git a/docs-2.0/nebula-explorer/figs/ex-ug-015-1.png b/docs-2.0/nebula-explorer/figs/ex-ug-015-1.png deleted file mode 100644 index 09c2bd221c..0000000000 Binary files a/docs-2.0/nebula-explorer/figs/ex-ug-015-1.png and /dev/null differ diff --git a/docs-2.0/nebula-explorer/figs/ex-ug-015-2.png b/docs-2.0/nebula-explorer/figs/ex-ug-015-2.png deleted file mode 100644 index e4e3d4365b..0000000000 Binary files a/docs-2.0/nebula-explorer/figs/ex-ug-015-2.png and /dev/null differ diff --git a/docs-2.0/nebula-explorer/figs/ex-ug-016-1.png b/docs-2.0/nebula-explorer/figs/ex-ug-016-1.png deleted file mode 100644 index 1214c48950..0000000000 Binary files a/docs-2.0/nebula-explorer/figs/ex-ug-016-1.png and /dev/null differ diff --git a/docs-2.0/nebula-explorer/figs/ex-ug-016-2.png b/docs-2.0/nebula-explorer/figs/ex-ug-016-2.png deleted file mode 100644 index 00aa008829..0000000000 Binary files a/docs-2.0/nebula-explorer/figs/ex-ug-016-2.png and /dev/null differ diff --git a/docs-2.0/nebula-explorer/figs/ex-ug-017-1.png b/docs-2.0/nebula-explorer/figs/ex-ug-017-1.png deleted file mode 100644 index 7053b4c5a0..0000000000 Binary files a/docs-2.0/nebula-explorer/figs/ex-ug-017-1.png and /dev/null differ diff --git a/docs-2.0/nebula-explorer/figs/ex-ug-017-2.png b/docs-2.0/nebula-explorer/figs/ex-ug-017-2.png deleted file mode 100644 index 89908c55b8..0000000000 Binary files a/docs-2.0/nebula-explorer/figs/ex-ug-017-2.png and /dev/null differ diff --git a/docs-2.0/nebula-explorer/figs/ex-ug-018-1.png b/docs-2.0/nebula-explorer/figs/ex-ug-018-1.png deleted file mode 100644 index 7651ae55e0..0000000000 Binary files a/docs-2.0/nebula-explorer/figs/ex-ug-018-1.png and /dev/null differ diff --git a/docs-2.0/nebula-explorer/figs/ex-ug-018-2.png b/docs-2.0/nebula-explorer/figs/ex-ug-018-2.png deleted file mode 100644 index d14aba6a11..0000000000 Binary files a/docs-2.0/nebula-explorer/figs/ex-ug-018-2.png and /dev/null differ diff --git a/docs-2.0/nebula-explorer/figs/ex-ug-019.png b/docs-2.0/nebula-explorer/figs/ex-ug-019.png deleted file mode 100644 index f048c54844..0000000000 Binary files a/docs-2.0/nebula-explorer/figs/ex-ug-019.png and /dev/null differ diff --git a/docs-2.0/nebula-explorer/figs/ex-ug-020.png b/docs-2.0/nebula-explorer/figs/ex-ug-020.png deleted file mode 100644 index e9b9825ac8..0000000000 Binary files a/docs-2.0/nebula-explorer/figs/ex-ug-020.png and /dev/null differ diff --git a/docs-2.0/nebula-explorer/figs/ex-ug-021.png b/docs-2.0/nebula-explorer/figs/ex-ug-021.png deleted file mode 100644 index 8563db877a..0000000000 Binary files a/docs-2.0/nebula-explorer/figs/ex-ug-021.png and /dev/null differ diff --git a/docs-2.0/nebula-explorer/figs/ex-ug-022.png b/docs-2.0/nebula-explorer/figs/ex-ug-022.png deleted file mode 100644 index a0bbb5b240..0000000000 Binary files a/docs-2.0/nebula-explorer/figs/ex-ug-022.png and /dev/null differ diff --git a/docs-2.0/nebula-explorer/figs/ex-ug-023-1.png b/docs-2.0/nebula-explorer/figs/ex-ug-023-1.png deleted file mode 100644 index 68dde05f07..0000000000 Binary files a/docs-2.0/nebula-explorer/figs/ex-ug-023-1.png and /dev/null differ diff --git a/docs-2.0/nebula-explorer/figs/ex-ug-023.png b/docs-2.0/nebula-explorer/figs/ex-ug-023.png deleted file mode 100644 index 05f4b6bcdd..0000000000 Binary files a/docs-2.0/nebula-explorer/figs/ex-ug-023.png and /dev/null differ diff --git a/docs-2.0/nebula-explorer/figs/ex-ug-024-1.png b/docs-2.0/nebula-explorer/figs/ex-ug-024-1.png deleted file mode 100644 index 975ee5ea81..0000000000 Binary files a/docs-2.0/nebula-explorer/figs/ex-ug-024-1.png and /dev/null differ diff --git a/docs-2.0/nebula-explorer/figs/ex-ug-025-1.png b/docs-2.0/nebula-explorer/figs/ex-ug-025-1.png deleted file mode 100644 index f3d9e608e7..0000000000 Binary files a/docs-2.0/nebula-explorer/figs/ex-ug-025-1.png and /dev/null differ diff --git a/docs-2.0/nebula-explorer/figs/ex-ug-025.png b/docs-2.0/nebula-explorer/figs/ex-ug-025.png deleted file mode 100644 index 58daa0d63c..0000000000 Binary files a/docs-2.0/nebula-explorer/figs/ex-ug-025.png and /dev/null differ diff --git a/docs-2.0/nebula-explorer/figs/ex-ug-026-1.png b/docs-2.0/nebula-explorer/figs/ex-ug-026-1.png deleted file mode 100644 index 761f655e49..0000000000 Binary files a/docs-2.0/nebula-explorer/figs/ex-ug-026-1.png and /dev/null differ diff --git a/docs-2.0/nebula-explorer/figs/ex-ug-027-1.png b/docs-2.0/nebula-explorer/figs/ex-ug-027-1.png deleted file mode 100644 index 5050df24ff..0000000000 Binary files a/docs-2.0/nebula-explorer/figs/ex-ug-027-1.png and /dev/null differ diff --git a/docs-2.0/nebula-explorer/figs/ex-ug-028.png b/docs-2.0/nebula-explorer/figs/ex-ug-028.png deleted file mode 100644 index 679f2124b5..0000000000 Binary files a/docs-2.0/nebula-explorer/figs/ex-ug-028.png and /dev/null differ diff --git a/docs-2.0/nebula-explorer/figs/ex-ug-029.png b/docs-2.0/nebula-explorer/figs/ex-ug-029.png deleted file mode 100644 index bb52a95a8f..0000000000 Binary files a/docs-2.0/nebula-explorer/figs/ex-ug-029.png and /dev/null differ diff --git a/docs-2.0/nebula-explorer/figs/exploration_query.gif b/docs-2.0/nebula-explorer/figs/exploration_query.gif new file mode 100644 index 0000000000..8004f589ac Binary files /dev/null and b/docs-2.0/nebula-explorer/figs/exploration_query.gif differ diff --git a/docs-2.0/nebula-explorer/figs/explorer-overview-1.png b/docs-2.0/nebula-explorer/figs/explorer-overview-1.png new file mode 100644 index 0000000000..2d09e9bec8 Binary files /dev/null and b/docs-2.0/nebula-explorer/figs/explorer-overview-1.png differ diff --git a/docs-2.0/nebula-explorer/figs/explorer-overview-graphspace.png b/docs-2.0/nebula-explorer/figs/explorer-overview-graphspace.png new file mode 100644 index 0000000000..40029d4763 Binary files /dev/null and b/docs-2.0/nebula-explorer/figs/explorer-overview-graphspace.png differ diff --git a/docs-2.0/nebula-explorer/figs/explorer.png b/docs-2.0/nebula-explorer/figs/explorer.png deleted file mode 100644 index d8c4449219..0000000000 Binary files a/docs-2.0/nebula-explorer/figs/explorer.png and /dev/null differ diff --git a/docs-2.0/nebula-explorer/figs/explorer_deploy.png b/docs-2.0/nebula-explorer/figs/explorer_deploy.png new file mode 100644 index 0000000000..5860ec8c26 Binary files /dev/null and b/docs-2.0/nebula-explorer/figs/explorer_deploy.png differ diff --git a/docs-2.0/nebula-explorer/figs/graph-snapshot.png b/docs-2.0/nebula-explorer/figs/graph-snapshot.png new file mode 100644 index 0000000000..be50f85a88 Binary files /dev/null and b/docs-2.0/nebula-explorer/figs/graph-snapshot.png differ diff --git a/docs-2.0/nebula-explorer/figs/layout.gif b/docs-2.0/nebula-explorer/figs/layout.gif new file mode 100644 index 0000000000..a1c7403c83 Binary files /dev/null and b/docs-2.0/nebula-explorer/figs/layout.gif differ diff --git a/docs-2.0/nebula-explorer/figs/list-add.png b/docs-2.0/nebula-explorer/figs/list-add.png new file mode 100644 index 0000000000..61ec8f99db Binary files /dev/null and b/docs-2.0/nebula-explorer/figs/list-add.png differ diff --git a/docs-2.0/nebula-explorer/figs/list-left.png b/docs-2.0/nebula-explorer/figs/list-left.png new file mode 100644 index 0000000000..7c91fa2165 Binary files /dev/null and b/docs-2.0/nebula-explorer/figs/list-left.png differ diff --git a/docs-2.0/nebula-explorer/figs/nav-Revoke.png b/docs-2.0/nebula-explorer/figs/nav-Revoke.png index b48942a0ab..0aeaa9ff2d 100644 Binary files a/docs-2.0/nebula-explorer/figs/nav-Revoke.png and b/docs-2.0/nebula-explorer/figs/nav-Revoke.png differ diff --git a/docs-2.0/nebula-explorer/figs/nav-commonNeighbor.png b/docs-2.0/nebula-explorer/figs/nav-commonNeighbor.png new file mode 100644 index 0000000000..11d52ae222 Binary files /dev/null and b/docs-2.0/nebula-explorer/figs/nav-commonNeighbor.png differ diff --git a/docs-2.0/nebula-explorer/figs/nav-console.png b/docs-2.0/nebula-explorer/figs/nav-console.png new file mode 100644 index 0000000000..9bb9d5af0e Binary files /dev/null and b/docs-2.0/nebula-explorer/figs/nav-console.png differ diff --git a/docs-2.0/nebula-explorer/figs/nav-delete.png b/docs-2.0/nebula-explorer/figs/nav-delete.png deleted file mode 100644 index 3e3a89962d..0000000000 Binary files a/docs-2.0/nebula-explorer/figs/nav-delete.png and /dev/null differ diff --git a/docs-2.0/nebula-explorer/figs/nav-deleteReverse.png b/docs-2.0/nebula-explorer/figs/nav-deleteReverse.png deleted file mode 100644 index 320910ca55..0000000000 Binary files a/docs-2.0/nebula-explorer/figs/nav-deleteReverse.png and /dev/null differ diff --git a/docs-2.0/nebula-explorer/figs/nav-expand.png b/docs-2.0/nebula-explorer/figs/nav-expand.png new file mode 100644 index 0000000000..bc04f94b75 Binary files /dev/null and b/docs-2.0/nebula-explorer/figs/nav-expand.png differ diff --git a/docs-2.0/nebula-explorer/figs/nav-filter.png b/docs-2.0/nebula-explorer/figs/nav-filter.png index b05eea3a51..83f852589e 100644 Binary files a/docs-2.0/nebula-explorer/figs/nav-filter.png and b/docs-2.0/nebula-explorer/figs/nav-filter.png differ diff --git a/docs-2.0/nebula-explorer/figs/nav-findPath.png b/docs-2.0/nebula-explorer/figs/nav-findPath.png new file mode 100644 index 0000000000..554cbc5839 Binary files /dev/null and b/docs-2.0/nebula-explorer/figs/nav-findPath.png differ diff --git a/docs-2.0/nebula-explorer/figs/nav-frameSelect.png b/docs-2.0/nebula-explorer/figs/nav-frameSelect.png deleted file mode 100644 index 946fc747e0..0000000000 Binary files a/docs-2.0/nebula-explorer/figs/nav-frameSelect.png and /dev/null differ diff --git a/docs-2.0/nebula-explorer/figs/nav-graphSpace.png b/docs-2.0/nebula-explorer/figs/nav-graphSpace.png index 1c643c34a3..ecb75978d5 100644 Binary files a/docs-2.0/nebula-explorer/figs/nav-graphSpace.png and b/docs-2.0/nebula-explorer/figs/nav-graphSpace.png differ diff --git a/docs-2.0/nebula-explorer/figs/nav-help.png b/docs-2.0/nebula-explorer/figs/nav-help.png index bc2e17b59e..a74ffcb616 100644 Binary files a/docs-2.0/nebula-explorer/figs/nav-help.png and b/docs-2.0/nebula-explorer/figs/nav-help.png differ diff --git a/docs-2.0/nebula-explorer/figs/nav-miss.png b/docs-2.0/nebula-explorer/figs/nav-miss.png index c6e0e264b7..a6a33a8eb4 100644 Binary files a/docs-2.0/nebula-explorer/figs/nav-miss.png and b/docs-2.0/nebula-explorer/figs/nav-miss.png differ diff --git a/docs-2.0/nebula-explorer/figs/nav-missReverse.png b/docs-2.0/nebula-explorer/figs/nav-missReverse.png index d695b2dc17..f75e1bd0b2 100644 Binary files a/docs-2.0/nebula-explorer/figs/nav-missReverse.png and b/docs-2.0/nebula-explorer/figs/nav-missReverse.png differ diff --git a/docs-2.0/nebula-explorer/figs/nav-moveCanvas.png b/docs-2.0/nebula-explorer/figs/nav-moveCanvas.png deleted file mode 100644 index c628ab93ac..0000000000 Binary files a/docs-2.0/nebula-explorer/figs/nav-moveCanvas.png and /dev/null differ diff --git a/docs-2.0/nebula-explorer/figs/nav-propertyView.png b/docs-2.0/nebula-explorer/figs/nav-propertyView.png index 678f51ee2c..d19b270432 100644 Binary files a/docs-2.0/nebula-explorer/figs/nav-propertyView.png and b/docs-2.0/nebula-explorer/figs/nav-propertyView.png differ diff --git a/docs-2.0/nebula-explorer/figs/nav-query.png b/docs-2.0/nebula-explorer/figs/nav-query.png deleted file mode 100644 index 29c2edad3a..0000000000 Binary files a/docs-2.0/nebula-explorer/figs/nav-query.png and /dev/null differ diff --git a/docs-2.0/nebula-explorer/figs/nav-query2.png b/docs-2.0/nebula-explorer/figs/nav-query2.png new file mode 100644 index 0000000000..a9c15c60c4 Binary files /dev/null and b/docs-2.0/nebula-explorer/figs/nav-query2.png differ diff --git a/docs-2.0/nebula-explorer/figs/nav-setup.png b/docs-2.0/nebula-explorer/figs/nav-setup.png index b1d5ab283d..df141c8d77 100644 Binary files a/docs-2.0/nebula-explorer/figs/nav-setup.png and b/docs-2.0/nebula-explorer/figs/nav-setup.png differ diff --git a/docs-2.0/nebula-explorer/figs/nav-singleSelect.png b/docs-2.0/nebula-explorer/figs/nav-singleSelect.png deleted file mode 100644 index 29b1cf3656..0000000000 Binary files a/docs-2.0/nebula-explorer/figs/nav-singleSelect.png and /dev/null differ diff --git a/docs-2.0/nebula-explorer/figs/node-filtering.png b/docs-2.0/nebula-explorer/figs/node-filtering.png new file mode 100644 index 0000000000..7bafbea42b Binary files /dev/null and b/docs-2.0/nebula-explorer/figs/node-filtering.png differ diff --git a/docs-2.0/nebula-explorer/figs/query_subgraph.png b/docs-2.0/nebula-explorer/figs/query_subgraph.png new file mode 100644 index 0000000000..a86c11e64b Binary files /dev/null and b/docs-2.0/nebula-explorer/figs/query_subgraph.png differ diff --git a/docs-2.0/nebula-explorer/figs/query_tag.png b/docs-2.0/nebula-explorer/figs/query_tag.png new file mode 100644 index 0000000000..a4481c09e5 Binary files /dev/null and b/docs-2.0/nebula-explorer/figs/query_tag.png differ diff --git a/docs-2.0/nebula-explorer/figs/redo.png b/docs-2.0/nebula-explorer/figs/redo.png new file mode 100644 index 0000000000..39453e2380 Binary files /dev/null and b/docs-2.0/nebula-explorer/figs/redo.png differ diff --git a/docs-2.0/nebula-explorer/figs/rightclickmenu-commonNeighbor.png b/docs-2.0/nebula-explorer/figs/rightclickmenu-commonNeighbor.png deleted file mode 100644 index 3a21d94c07..0000000000 Binary files a/docs-2.0/nebula-explorer/figs/rightclickmenu-commonNeighbor.png and /dev/null differ diff --git a/docs-2.0/nebula-explorer/figs/rightclickmenu-expand.png b/docs-2.0/nebula-explorer/figs/rightclickmenu-expand.png deleted file mode 100644 index c128c110df..0000000000 Binary files a/docs-2.0/nebula-explorer/figs/rightclickmenu-expand.png and /dev/null differ diff --git a/docs-2.0/nebula-explorer/figs/rightclickmenu-findPath.png b/docs-2.0/nebula-explorer/figs/rightclickmenu-findPath.png deleted file mode 100644 index d4d1215fd1..0000000000 Binary files a/docs-2.0/nebula-explorer/figs/rightclickmenu-findPath.png and /dev/null differ diff --git a/docs-2.0/nebula-explorer/figs/sidebar-unfold.png b/docs-2.0/nebula-explorer/figs/sidebar-unfold.png deleted file mode 100644 index 294ab6771a..0000000000 Binary files a/docs-2.0/nebula-explorer/figs/sidebar-unfold.png and /dev/null differ diff --git a/docs-2.0/nebula-explorer/figs/snapshot-delete.png b/docs-2.0/nebula-explorer/figs/snapshot-delete.png new file mode 100644 index 0000000000..b4d23eda2e Binary files /dev/null and b/docs-2.0/nebula-explorer/figs/snapshot-delete.png differ diff --git a/docs-2.0/nebula-explorer/figs/snapshot-export.png b/docs-2.0/nebula-explorer/figs/snapshot-export.png new file mode 100644 index 0000000000..18aab2132a Binary files /dev/null and b/docs-2.0/nebula-explorer/figs/snapshot-export.png differ diff --git a/docs-2.0/nebula-explorer/figs/snapshot-history.png b/docs-2.0/nebula-explorer/figs/snapshot-history.png new file mode 100644 index 0000000000..1ce2a2f274 Binary files /dev/null and b/docs-2.0/nebula-explorer/figs/snapshot-history.png differ diff --git a/docs-2.0/nebula-explorer/figs/snapshot-import.png b/docs-2.0/nebula-explorer/figs/snapshot-import.png new file mode 100644 index 0000000000..1c893f4eab Binary files /dev/null and b/docs-2.0/nebula-explorer/figs/snapshot-import.png differ diff --git a/docs-2.0/nebula-explorer/figs/thumbnail.png b/docs-2.0/nebula-explorer/figs/thumbnail.png new file mode 100644 index 0000000000..597b9fc616 Binary files /dev/null and b/docs-2.0/nebula-explorer/figs/thumbnail.png differ diff --git a/docs-2.0/nebula-explorer/figs/topbar-exportCSV.png b/docs-2.0/nebula-explorer/figs/topbar-exportCSV.png new file mode 100644 index 0000000000..43c376ef80 Binary files /dev/null and b/docs-2.0/nebula-explorer/figs/topbar-exportCSV.png differ diff --git a/docs-2.0/nebula-explorer/figs/topbar-exportPNG.png b/docs-2.0/nebula-explorer/figs/topbar-exportPNG.png new file mode 100644 index 0000000000..d16288ae8a Binary files /dev/null and b/docs-2.0/nebula-explorer/figs/topbar-exportPNG.png differ diff --git a/docs-2.0/nebula-explorer/figs/vid_query.gif b/docs-2.0/nebula-explorer/figs/vid_query.gif new file mode 100644 index 0000000000..a99cd96b64 Binary files /dev/null and b/docs-2.0/nebula-explorer/figs/vid_query.gif differ diff --git a/docs-2.0/nebula-explorer/figs/visualization.gif b/docs-2.0/nebula-explorer/figs/visualization.gif new file mode 100644 index 0000000000..41273c502d Binary files /dev/null and b/docs-2.0/nebula-explorer/figs/visualization.gif differ diff --git a/docs-2.0/nebula-explorer/node-filtering.md b/docs-2.0/nebula-explorer/node-filtering.md new file mode 100644 index 0000000000..3b59e756c8 --- /dev/null +++ b/docs-2.0/nebula-explorer/node-filtering.md @@ -0,0 +1,22 @@ +# 节点筛选 + +用户可通过一组或多组筛选条件对画布中显示的点进行过滤。筛选条件包括:Tag、属性、运算符、值。 + +!!! note + + 每一组筛选条件只针对带此 Tag 的数据,满足条件会被自动添加选中状态,不满足则置灰。其他 Tag 数据状态不受影响。 + +## 前提条件 + +使用**节点筛选**功能前,确保画布中有点数据。具体操作,参见[开始探索](ex-ug-query-exploration.md)。 + +## 示例 + +以下示例为筛选画布中年龄大于 33 岁的球员。 + +1. 在左侧导航栏中,单击**节点筛选**图标![node-filter](figs/nav-filter.png)。 +2. 单击**添加筛选条件**,然后填入对应值(如下图所示)。 +3. (可选)重复第二步骤,添加多个筛选条件。 +4. 打开**启动筛选**开关。 + +![](figs/node-filtering.png) diff --git a/docs-2.0/nebula-explorer/operation-guide/ex-ug-canvas.md b/docs-2.0/nebula-explorer/operation-guide/ex-ug-canvas.md deleted file mode 100644 index c52ca7dc77..0000000000 --- a/docs-2.0/nebula-explorer/operation-guide/ex-ug-canvas.md +++ /dev/null @@ -1,40 +0,0 @@ -# 画布操作 - -本文主要介绍画布中的操作。 - -## 查看点边 - -移动鼠标到点或边上,详细查看点和边的数据,同一点上的多个 Tag 通过`|`分开。以下展示 VID 为 `107` 的点的详细信息: -![show](../figs/ex-ug-024-1.png) - -## 批量选中 - -Explorer 支持批量选中多个点边,并查看选中点边的数据,详细数据可以在画布左下角的点边概览打开并查看。同时也支持导出选中点或边的 CSV 文件。 -![review](../figs/ex-ug-027-1.png) - -### 框选操作 - -点击 ![frameselect](../figs/nav-frameSelect.png) 图标后,按住左键拖拽并框选多个点和边。示例如下: -![select](../figs/ex-ug-023.png) - -### 点击选择多个节边 - -点击 ![singleselect](../figs/nav-singleSelect.png) 图标或按住 Shift 后,用鼠标单击并选中多个点和边,单击空白处取消选择。示例如下: -![select](../figs/ex-ug-025.png) - -## 快速操作 - -用户可以选择一个或多个点和边,在空白处点击右键可以进行对点进行扩展、查找两个点之间的路径、在页面中显示或隐藏其属性等操作。用户选择的点和边数据会影响到可以执行的操作,具体操作的说明参见[图探索拓展](../operation-guide/ex-ug-graph-exploration.md)。 -![quick](../figs/ex-ug-026-1.png) - -点击 **适合选中尺寸** 可以将选中的数据,移动到画布的中心,方便用户查看。 - -## 节点筛选 - -用户可以对画布中显示的点进行过滤。在该示例中,选择 Tag 为 `player`,`age>=35` 的点,并启动过滤。 - -!!! note - - 每一组筛选条件只针对带此 Tag 的数据,满足条件会被自动添加选中状态,不满足则置灰。其他 Tag 数据状态不受影响。 - -![filter](../figs/ex-ug-029.png) diff --git a/docs-2.0/nebula-explorer/operation-guide/ex-ug-graph-exploration.md b/docs-2.0/nebula-explorer/operation-guide/ex-ug-graph-exploration.md deleted file mode 100644 index 0d73b3c810..0000000000 --- a/docs-2.0/nebula-explorer/operation-guide/ex-ug-graph-exploration.md +++ /dev/null @@ -1,36 +0,0 @@ -# 图探索拓展 - -图探索拓展分为以下四类: - -- 拓展 -- 共同邻居 -- 路径查询 -- 查看属性 - -## 拓展 - -在菜单栏,点击 ![expand](../figs/rightclickmenu-expand.png) 图标,打开 **拓展** 窗口。用户可以双击某一点,对该点进行拓展。也可以框选画布中的多个点,在如下操作栏中修改边类型,选择边的流入流出方向,修改点的颜色,规定拓展步数和自定义过滤条件。 - -!!! Note - - 面板内配置修改后会保存当前配置,当双击或者右键快捷拓展时候会以当前配置进行拓展。 - -![expand](../figs/ex-ug-013-2.png) - -## 共同邻居 - -在菜单栏,点击 ![commonneighbor](../figs/rightclickmenu-commonNeighbor.png) 图标,打开 **共同邻居** 窗口。用户可以选中画布中的两个点或多个点,查询它们的共同邻居。选中的点无共同邻居时,默认返回 **没有相应数据** 。 - -![common_neighbor](../figs/ex-ug-014-2.png) - -## 路径查询 - -在菜单栏,点击 ![findpath](../figs/rightclickmenu-findPath.png) 图标,打开 **路径查询** 窗口。用户可以选中画布中的两个点,默认框选的第一个点为起点,第二个点为终点。用户可自定义边的类型和方向,规定拓展步数,选择查询以下三种路径: `All path`,`Shortest path` 和 `Noloop path`。 - -![find_path](../figs/ex-ug-015-2.png) - -## 查看属性 - -在菜单栏,点击 ![propertyview](../figs/nav-propertyView.png) 图标,打开 **查看属性** 窗口。用户可以选择在画布中展示或隐藏点或边的属性。点击确认后,缩放比例大于 100% 时候才会显示属性在画布上,小于 100% 的时候会自动隐藏。 - -![show_property](../figs/ex-ug-016-2.png) diff --git a/docs-2.0/nebula-explorer/operation-guide/ex-ug-page-overview.md b/docs-2.0/nebula-explorer/operation-guide/ex-ug-page-overview.md deleted file mode 100644 index 75c386cb6b..0000000000 --- a/docs-2.0/nebula-explorer/operation-guide/ex-ug-page-overview.md +++ /dev/null @@ -1,95 +0,0 @@ -# 页面概览 - -本文主要介绍 Explorer 的主页面。 - -## 概览 - -![Explorer](../figs/explorer.png) - -Explorer 的主页面分为五个部分: - -- 标签栏 -- 侧边栏 -- 画布 -- 缩略图 -- 关系列表 - -## 标签栏 - -- 导出图形:支持导出当前视图的 CSV 文件或 PNG(图片)文件。 - -- 新增画布:支持创建多个画布,最多仅能打开 10 个画布。 - -## 侧边栏 - -侧边栏包括五个部分,用户可以点击按钮对图进行探索、修改画布上点的内容等等。 - -- 查询探索:在进行探索之前,用户需要查询数据并显示在画布中。 - -- 画布操作:包括框选画布中的点、拖动画布、选中多条点边功能。 - -- 图探索拓展:包括对点的拓展、查找多个点的共同邻居、查找两个点的路径、显示属性切换等功能。 - -- 隐藏及撤销:对画布中显示的数据进行视图隐藏、撤回上一步操作。 - -- 设置和帮助:切换图空间、查找帮助、修改设置等。 - -### 查询探索 - -- 开始:单击 ![query](../figs/nav-query.png) 图标,通过 VID、Tag 和子图,查询数据并显示到页面上。 - -### 画布操作 - -- 框选模式:单击 ![frameSelect](../figs/nav-frameSelect.png) 图标,支持框选画布中的点和边。 -- 选中多条点边:单击 ![singleSelect](../figs/nav-singleSelect.png) 图标,可以方便的点击画布中的点和边,单击空白处取消选择。 -- 拖动画布:单击 ![moveCanvas](../figs/nav-moveCanvas.png) 图标,支持拖动画布的位置。 -- 节点过滤:单击 ![filter](../figs/nav-filter.png) 图标,支持对画布中显示的点进行过滤。 - -更多详细信息参考[画布操作](../operation-guide/ex-ug-canvas.md)。 - -### 图探索扩展 - -- 拓展:单击 ![expand](../figs/rightclickmenu-expand.png) 图标,选择页面上的节点并进行自定义拓展,包括拓展方向、拓展步数、过滤条件等。 -- 共同邻居:单击 ![commonNeighbor](../figs/rightclickmenu-commonNeighbor.png) 图标,选择页面上至少两个点并查看它们的共同邻居。 -- 路径查询:单击 ![findPath](../figs/rightclickmenu-findPath.png) 图标,可以查询起点到终点之间的 `all paths` 、 `Shortest path` 或者是 `Noloop path` 的路径。 -- 查看属性:单击 ![propertyView](../figs/nav-propertyView.png) 图标,选择是否显画布中的点或边的属性值。 - -更多详细信息参考[图探索拓展](../operation-guide/ex-ug-graph-exploration.md)。 - -### 删除及撤销 - -- 隐藏:单击 ![miss](../figs/nav-miss.png) 图标,可以隐藏画布中选中的点边。 -- 隐藏其他:单击 ![missreverse](../figs/nav-missReverse.png) 图标,可以隐藏画布中未选择的所有点边。 -- 撤销:单击 ![Revoke](../figs/nav-Revoke.png) 图标,撤销上一步新增或隐藏的操作。 - -### 设置及帮助 - -- 选择图空间:单击 ![graphSpace](../figs/nav-graphSpace.png) 图标,切换当前图空间。 -- 帮助:单击 ![help](../figs/nav-help.png) 图标,查看更多信息。 -- 设置:单击 ![setup](../figs/nav-setup.png) 图标,可以查看用户名和快捷键、修改语言设置、清除 Explorer 链接等。 - -## 画布 - -画布主要分为: - -- 图:显示通过 VID、Tag 或子图查询的数据。 - -- 点边概览:默认隐藏,在当前画布选中点和边时才显示。点击如图标识,用户可以打开菜单,查看当前子图中选中的点和边的详细数据。 - - ![review](../figs/ex-ug-027-1.png) - -更多详细操作参考[画布操作](../operation-guide/ex-ug-canvas.md)。 - -## 缩略图 - -用户可以通过缩略图上的按钮,完成图模式的切换,全屏展示画布中的图,收起缩略图,缩小或放大画布中的图等。同时在缩略图的左下角显示了画布中的图占总图的百分比。 - -- 图模式切换:用户可以切换画布中图的展示模式。 - - | 图标 | ![force](../figs/Thumbnail-graphView.png) | ![dagre](../figs/Thumbnail-treeView.png) | ![circular](../figs/Thumbnail-sphereView.png) | - | ---- | ---- |----| ----| - | 展示模式 | force(力导向图) | dagre(层次图) | circular(环形图) | - -## 关系列表 - -点击右侧的 ![unfold](../figs/sidebar-unfold.png) 图标,用户可以打开菜单,查看画布中 Tag 和 Edge 的数量、搜索 Tag 和 Edge ,同时也支持修改点的颜色和图标。 diff --git a/docs-2.0/nebula-explorer/operation-guide/ex-ug-query-exploration.md b/docs-2.0/nebula-explorer/operation-guide/ex-ug-query-exploration.md deleted file mode 100644 index e133f837c7..0000000000 --- a/docs-2.0/nebula-explorer/operation-guide/ex-ug-query-exploration.md +++ /dev/null @@ -1,23 +0,0 @@ -# 查询探索 - -在 Explorer 中,用户可以选择以下查询方式,展示数据: - -- VID 查询 -- Tag 查询 -- 子图查询 - -## VID 查询 - -用户可以通过输入 VID 或者生成 VID 的数据查询,一行仅支持一个数据。同时也支持随机导入数据和文件导入数据。确认添加后,数据会显示在画布中。以下给出示例: - -![VID](../figs/ex-ug-009-2.png) - -## Tag 查询 - -基于 Tag 查询,必选值为 Tag 和索引。用户可以对输出的结果进行数量上的限制和结果进行过滤。以下查询 10 个年龄大于 30 岁,且不等于 40 岁的球员,示例如下: -![Tag](../figs/ex-ug-011-2.png) - -## 子图查询 - -基于子图查询,必选值为 VID 。用户可以查看一个或多个点的子图,支持规定子图的步数、边类型及流入流出的方向。以下给出 VID 值为 101 ,步数为 4 ,边类型为 server 和 like 的入边的示例: -![Query](../figs/ex-ug-012-2.png) \ No newline at end of file diff --git a/docs-2.0/nebula-explorer/operation-guide/ex-ug-relationship-list.md b/docs-2.0/nebula-explorer/operation-guide/ex-ug-relationship-list.md deleted file mode 100644 index bfab6137f1..0000000000 --- a/docs-2.0/nebula-explorer/operation-guide/ex-ug-relationship-list.md +++ /dev/null @@ -1,11 +0,0 @@ -# 关系列表 - -用户可以在关系列表中,选中点和边。选中 Tag 为 `player` 的 9 个点,选中 Edge 为 `serve` 的 7 条边,示例如下: - -![select](../figs/ex-ug-017-2.png) - -同时,用户可以修改 Tag 的颜色和图标,使得关键节点更为突出。 - -在默认情况下,Tag 完全相同的 VID 点的颜色相同,并且也支持手动修改一个点或一组 Tag 完全相同的点的颜色及图标。例如标签为 `bachelor`, `player`和 `team` 的点,修改其中一个点的颜色,在关系列表中你可以点开查看,示例如下: - -![icon](../figs/ex-ug-018-2.png) \ No newline at end of file diff --git a/docs-2.0/nebula-explorer/operation-guide/ex-ug-shortcuts.md b/docs-2.0/nebula-explorer/operation-guide/ex-ug-shortcuts.md deleted file mode 100644 index afb07a5f47..0000000000 --- a/docs-2.0/nebula-explorer/operation-guide/ex-ug-shortcuts.md +++ /dev/null @@ -1,12 +0,0 @@ -# 快捷键 - -本文列出了 Explorer 支持的快捷键。 - -| 操作 | 说明 | -| :-- | :--| -| Shift + 'Enter' | 拓展 | -| Shift + '-' | 缩小 | -| Shift + '+' | 放大 | -| Shift + 'l' | 显示 | -| Shift + 'z' | 撤销 | -| 选中 + Shift + 'del' | 删除 | diff --git a/docs-2.0/nebula-importer/config-with-header.md b/docs-2.0/nebula-importer/config-with-header.md index 633375b52f..91ef824ccb 100644 --- a/docs-2.0/nebula-importer/config-with-header.md +++ b/docs-2.0/nebula-importer/config-with-header.md @@ -75,8 +75,8 @@ ## 配置示例 ```yaml -# 连接的 Nebula Graph 版本,连接 2.x 时设置为 v2。 -version: v2 +# 连接的 Nebula Graph 版本,连接 3.x 时设置为 v3。 +version: v3 description: example @@ -180,4 +180,4 @@ files: !!! Note - 点 ID 的数据类型需要和`clientSettings.postStart.commands`中的创建图空间语句的数据类型一致。 \ No newline at end of file + 点 ID 的数据类型需要和`clientSettings.postStart.commands`中的创建图空间语句的数据类型一致。 diff --git a/docs-2.0/nebula-importer/config-without-header.md b/docs-2.0/nebula-importer/config-without-header.md index c95d33ca02..40ee7ee151 100644 --- a/docs-2.0/nebula-importer/config-without-header.md +++ b/docs-2.0/nebula-importer/config-without-header.md @@ -34,8 +34,8 @@ ## 配置示例 ```yaml -# 连接的 Nebula Graph 版本,连接 2.x 时设置为 v2。 -version: v2 +# 连接的 Nebula Graph 版本,连接 3.x 时设置为 v3。 +version: v3 description: example diff --git a/docs-2.0/nebula-importer/use-importer.md b/docs-2.0/nebula-importer/use-importer.md index d8118baaae..91d44dd65a 100644 --- a/docs-2.0/nebula-importer/use-importer.md +++ b/docs-2.0/nebula-importer/use-importer.md @@ -30,7 +30,7 @@ Importer 适用于将本地 CSV 文件的内容导入至 Nebula Graph 中。 - Nebula Graph 中已创建 Schema,包括图空间、Tag 和 Edge type,或者通过参数`clientSettings.postStart.commands`设置。 -- 运行 Importer 的机器已部署 Golang 环境。详情请参见 [Golang 环境搭建](https://github.com/vesoft-inc/nebula-importer/blob/release-v2.0.0-ga/docs/golang-install.md)。 +- 运行 Importer 的机器已部署 Golang 环境。详情请参见 [Golang 环境搭建](https://github.com/vesoft-inc/nebula-importer/blob/{{importer.branch}}/docs/golang-install.md)。 ## 操作步骤 @@ -57,10 +57,7 @@ Importer 适用于将本地 CSV 文件的内容导入至 Nebula Graph 中。 !!! note 请使用正确的分支。 - Nebula Graph 1.x 和 2.x 的 rpc 协议不同,因此: - - - Nebula Importer v1 分支只能连接 Nebula Graph 1.x。 - - Nebula Importer master 分支和 v2 分支可以连接 Nebula Graph 2.x。 + Nebula Graph 2.x 和 3.x 的 rpc 协议不同。 2. 进入目录`nebula-importer`。 @@ -127,7 +124,7 @@ $ docker run --rm -ti \ - ``:本地 yaml 配置文件的绝对路径。 - ``:本地 CSV 数据文件的绝对路径。 -- ``:Nebula Graph 2.x 请填写`v2`。 +- ``:Nebula Graph 3.x 请填写`v3`。 !!! note 建议使用相对路径。如果使用本地绝对路径,请检查路径映射到 Docker 中的路径。 @@ -145,14 +142,14 @@ Nebula Importer 通过`nebula-importer/examples/v2/example.yaml`配置文件来 示例配置如下: ```yaml -version: v2 +version: v3 description: example removeTempFiles: false ``` |参数|默认值|是否必须|说明| |:---|:---|:---|:---| -|`version`|v2|是|目标 Nebula Graph 的版本。| +|`version`|v3|是|目标 Nebula Graph 的版本。| |`description`|example|否|配置文件的描述。| |`removeTempFiles`|false|否|是否删除临时生成的日志和错误数据文件。| @@ -229,7 +226,7 @@ files: |`files.limit`|-|否|读取数据的行数限制。| |`files.inOrder`|-|否|是否按顺序在文件中插入数据行。如果为`false`,可以避免数据倾斜导致的导入速率降低。| |`files.type`|-|是|文件类型。| -|`files.csv.withHeader`|`false`|是|是否有表头。详情请参见[关于 CSV 文件表头](#csvheader)。| +|`files.csv.withHeader`|`false`|是|是否有表头。详情请参见[关于 CSV 文件表头](#csv_header)。| |`files.csv.withLabel`|`false`|是|是否有 LABEL。详情请参见[有表头配置说明](config-with-header.md)。| |`files.csv.delimiter`|`","`|是|指定 csv 文件的分隔符。只支持一个字符的字符串分隔符。| diff --git a/docs-2.0/nebula-spark-connector.md b/docs-2.0/nebula-spark-connector.md index 733c3e187b..65a621356c 100644 --- a/docs-2.0/nebula-spark-connector.md +++ b/docs-2.0/nebula-spark-connector.md @@ -229,7 +229,7 @@ df.write.nebula(config, nebulaWriteVertexConfig).writeVertices() |`withSpace` |是| Nebula Graph 图空间名称。 | |`withTag` |是| 写入点时需要关联的 Tag 名称。 | |`withVidField` |是| DataFrame 中作为点 ID 的列。 | - |`withVidPolicy` |否| 写入点 ID 时,采用的映射函数,Nebula Graph 2.x 仅支持 HASH。默认不做映射。 | + |`withVidPolicy` |否| 写入点 ID 时,采用的映射函数,Nebula Graph 仅支持 HASH。默认不做映射。 | |`withVidAsProp` |否| DataFrame 中作为点 ID 的列是否也作为属性写入。默认值为`false`。如果配置为`true`,请确保 Tag 中有和`VidField`相同的属性名。 | |`withUser` |否| Nebula Graph 用户名。若未开启[身份验证](7.data-security/1.authentication/1.authentication.md),无需配置用户名和密码。 | |`withPasswd` |否| Nebula Graph 用户名对应的密码。 | @@ -243,9 +243,9 @@ df.write.nebula(config, nebulaWriteVertexConfig).writeVertices() |`withSpace` |是| Nebula Graph 图空间名称。 | |`withEdge` |是| 写入边时需要关联的 Edge type 名称。 | |`withSrcIdField` |是| DataFrame 中作为起始点的列。 | - |`withSrcPolicy` |否| 写入起始点时,采用的映射函数,Nebula Graph 2.x 仅支持 HASH。默认不做映射。 | + |`withSrcPolicy` |否| 写入起始点时,采用的映射函数,Nebula Graph 仅支持 HASH。默认不做映射。 | |`withDstIdField` |是| DataFrame 中作为目的点的列。 | - |`withDstPolicy` |否| 写入目的点时,采用的映射函数,Nebula Graph 2.x 仅支持 HASH。默认不做映射。 | + |`withDstPolicy` |否| 写入目的点时,采用的映射函数,Nebula Graph 仅支持 HASH。默认不做映射。 | |`withRankField` |否| DataFrame 中作为 rank 的列。默认不写入 rank。 | |`withSrcAsProperty` |否| DataFrame 中作为起始点的列是否也作为属性写入。默认值为`false`。如果配置为`true`,请确保 Edge type 中有和`SrcIdField`相同的属性名。 | |`withDstAsProperty` |否| DataFrame 中作为目的点的列是否也作为属性写入。默认值为`false`。如果配置为`true`,请确保 Edge type 中有和`DstIdField`相同的属性名。 | diff --git a/docs-2.0/nebula-studio/about-studio/st-ug-check-updates.md b/docs-2.0/nebula-studio/about-studio/st-ug-check-updates.md index 615cd03cae..2218c6591a 100644 --- a/docs-2.0/nebula-studio/about-studio/st-ug-check-updates.md +++ b/docs-2.0/nebula-studio/about-studio/st-ug-check-updates.md @@ -12,4 +12,4 @@ Studio 处于持续开发状态中。用户可以通过 [Studio 发布版本更 成功连接 Studio 后,用户可以在页面右上角点击版本号,再点击 **新发布**,前往查看 Studio 的版本更新记录。 -![在页面右上角点击版本号,并在弹出菜单里点击“新发布”](../figs/st-ug-014.png "查看 Studio 版本更新记录") +![在页面右上角点击版本号,并在弹出菜单里点击“新发布”](../figs/st-ug-014-1.png "查看 Studio 版本更新记录") diff --git a/docs-2.0/nebula-studio/about-studio/st-ug-limitations.md b/docs-2.0/nebula-studio/about-studio/st-ug-limitations.md index a472f1247e..1faca0d0c5 100644 --- a/docs-2.0/nebula-studio/about-studio/st-ug-limitations.md +++ b/docs-2.0/nebula-studio/about-studio/st-ug-limitations.md @@ -12,9 +12,9 @@ | --- | --- | | 1.x | 1.x| | 2.0 & 2.0.1 | 2.x | -| 2.5.0 & 2.5.1 | 3.0.0 | -| 2.6.0 | 3.1.0 | -| 2.6.1 | 3.1.0 | +| 2.5.x | 3.0.0 | +| 2.6.x | 3.1.0 | +| 3.0.0 | 3.2.0 | ## 系统架构 @@ -22,16 +22,6 @@ Studio 目前仅支持 x86_64 架构。 ## 数据上传 - - Studio 上传数据仅支持上传无表头的 CSV 文件,但是,单个文件大小及保存时间不受限制,而且数据总量以本地存储容量为准。 ## 数据备份 @@ -44,7 +34,7 @@ Studio 上传数据仅支持上传无表头的 CSV 文件,但是,单个文 - `USE `:只能在 **Space** 下拉列表中选择图空间,不能运行这个语句选择图空间。 - **控制台** 上使用 nGQL 语句时,用户可以直接回车换行,不能使用换行符。 - ## 浏览器支持 diff --git a/docs-2.0/nebula-studio/about-studio/st-ug-release-note.md b/docs-2.0/nebula-studio/about-studio/st-ug-release-note.md index 6d5043aafd..c108c51359 100644 --- a/docs-2.0/nebula-studio/about-studio/st-ug-release-note.md +++ b/docs-2.0/nebula-studio/about-studio/st-ug-release-note.md @@ -1,25 +1,20 @@ # Studio 版本更新说明 -## v3.1.0(2021.10.29) - -- 功能增强: - - 适配 Nebula 2.6.0。 - - 新增在 Kubernetes 集群里使用 Helm 部署并启动 Studio。 - - 新增 GEO 数据类型。 - - 图探索 - - 新增配置节点图标功能。 +## v3.2.1(2022.02.17) - 修复: - - Schema - - 修复以关键字命名的 Tag/Edge 或其下属性时会报错的问题。 - - 修复数据类型不完善的问题,补充 date/time/datetime/int32/int16/int8 等类型枚举。 + - 移除 rpm 包安装前对 node 环境的检查。 + - 修复导出 csv 文件时的解析问题 -- 兼容: - - 去除 Studio 对 nebula-importer 的依赖,用 http-gateway 兼容相关功能。 - -## v3.0.0(2021.08.13) +## v3.2.0(2022.02.15) - 功能增强: + - 适配 Nebula 3.0.0,优化用户体验。 + - 新增 DEB 部署并启动 Studio。 + - 导入: + - 导入时需要输入密码确认,以增强安全性。 + - 控制台: + - 支持保存参数,用于参数化查询。 - - 适配 Nebula 2.5.0。 - - 配置 Schema 中支持给 Space、Tag、Edge Type、Index 添加 COMMENT。 +- 兼容: + - 移除 Node 环境,去除 Studio 对 Node.js 的依赖。 diff --git a/docs-2.0/nebula-studio/about-studio/st-ug-terms.md b/docs-2.0/nebula-studio/about-studio/st-ug-terms.md index 57087b3671..b69eaa56dd 100644 --- a/docs-2.0/nebula-studio/about-studio/st-ug-terms.md +++ b/docs-2.0/nebula-studio/about-studio/st-ug-terms.md @@ -6,6 +6,4 @@ - Nebula Graph:一款开源图数据库管理系统(Graph Database Management System),擅长处理千亿个点和万亿条边的超大规模数据集。详细信息,参考 [Nebula Graph 用户手册](../../README.md "点击前往 Nebula Graph 用户手册")。 - \ No newline at end of file +- Nebula Graph Cloud:一款支持 Azure 平台,在云上搭建 Nebula Graph 数据库的产品,支持一键部署 Nebula Graph,集成了可视化图数据库管理工具 Nebula Graph Studio、Nebula Dashboard、Nebula Explorer。详细信息,参考 [什么是 Nebula Graph Cloud](../../nebula-cloud/1.what-is-cloud.md)。 diff --git a/docs-2.0/nebula-studio/about-studio/st-ug-what-is-graph-studio.md b/docs-2.0/nebula-studio/about-studio/st-ug-what-is-graph-studio.md index 517be590e8..e35e35f2c6 100644 --- a/docs-2.0/nebula-studio/about-studio/st-ug-what-is-graph-studio.md +++ b/docs-2.0/nebula-studio/about-studio/st-ug-what-is-graph-studio.md @@ -4,18 +4,16 @@ Nebula Graph Studio(简称 Studio)是一款可以通过 Web 访问的开源 ## 发行版本 -可以使用以下四种方式安装部署 Studio: +可以使用以下五种方式安装部署 Studio: -- Docker 版本:用户可以使用 Docker 服务部署 Studio,并连接到 Nebula Graph 数据库。详细信息参考 [Docker 部署 Studio](../deploy-connect/st-ug-deploy.md)。 -- RPM 版本:用户可以使用 RPM 服务部署 Studio,并连接到 Nebula Graph 数据库。详细信息参考 [RPM 部署 Studio](../deploy-connect/st-ug-deploy.md)。 -- tar 包安装部署:用户可以使用 tar 包安装并部署 Studio,并连接到 Nebula Graph 数据库。详细信息参考 [tar 包部署 Studio](../deploy-connect/st-ug-deploy.md)。 +- 用户可以使用 Docker 服务、RPM 服务、tar 包和 DEB 包安装部署 Studio,并连接到 Nebula Graph 数据库。详细信息参考 [部署 Studio](../deploy-connect/st-ug-deploy.md)。 - 使用 Helm 安装部署:在 Kubernetes 集群里使用 Helm 安装并部署 Studio,并连接到 Nebula Graph 数据库。详细信息参考[使用 Helm 部署 Nebula Graph Studio](../deploy-connect/st-ug-deploy-by-helm.md)。 -四种部署方式功能基本相同,在使用 Studio 时可能会受到限制。详细信息,参考[使用限制](st-ug-limitations.md)。 +五种部署方式功能基本相同,在使用 Studio 时可能会受到限制。详细信息,参考[使用限制](st-ug-limitations.md)。 ## 产品功能 @@ -31,15 +29,13 @@ Studio 具备以下功能: 如果有以下任一需求,都可以使用 Studio: -- 有一份数据集,想进行可视化图探索或者数据分析。用户可以使用 Docker Compose 包部署 Nebula Graph,再使用 Studio 完成可视化操作。 +- 有一份数据集,想进行可视化图探索或者数据分析。用户可以使用 Docker Compose 部署 Nebula Graph,再使用 Studio 完成可视化操作。 - 已经安装部署了 Nebula Graph 数据库,并且已经导入数据集,想使用 GUI 工具执行 nGQL 语句查询、可视化图探索或者数据分析。 - 刚开始学习 nGQL(Nebula Graph Query Language),但是不习惯用命令行工具,更希望使用 GUI 工具查看语句输出的结果。 ## 身份验证 - +对于云服务版 Studio,只有操作权限为 **ROOT** 和 **USER** 的 Nebula Graph Cloud 用户可以登录 Studio。详细信息参考 [配套的应用(Dashboard/Studio/Explorer)](../../nebula-cloud/5.solution/5.1.supporting-application.md)。 因为 Nebula Graph 默认不启用身份验证,所以,一般情况下用户可以使用 `root` 账号和任意密码登录 Studio。 diff --git a/docs-2.0/nebula-studio/deploy-connect/st-ug-deploy-by-helm.md b/docs-2.0/nebula-studio/deploy-connect/st-ug-deploy-by-helm.md index c43ed06af3..264ac61652 100644 --- a/docs-2.0/nebula-studio/deploy-connect/st-ug-deploy-by-helm.md +++ b/docs-2.0/nebula-studio/deploy-connect/st-ug-deploy-by-helm.md @@ -51,16 +51,11 @@ $ helm uninstall my-studio | 参数 | 默认值 | 描述 | |:---|:---|:---| | replicaCount | 0 | Deployment 的副本数。 | -| image.httpGateway.name | vesoft/nebula-http-gateway | nebula-http-gateway 镜像的仓库地址。 | | image.nebulaStudio.name | vesoft/nebula-graph-studio | nebula-graph-studio 镜像的仓库地址。 | -| image.nginx.name | nginx | nginx 镜像的仓库地址。 | -| image.httpGateway.version | v2.1.1 | nebula-http-gateway 的版本。 | -| image.nebulaStudio.version | v3.1.0 | nebula-graph-studio 的版本。 | -| image.nginx.version | alpine | nginx 的版本。 | +| image.nebulaStudio.version | v3.2.0 | nebula-graph-studio 的版本。 | | service.type | ClusterIP | 服务类型,必须为`NodePort`,`ClusterIP`或`LoadBalancer`其中之一。 | | service.port | 7001 | nebula-graph-studio 中 web 服务的端口。 | -| resources.httpGateway | {} | nebula-http-gateway 的资源限制/请求。 | +| service.nodePort | 32701 | Kubernetes 集群外部访问 nebula-studio 的代理端口。 | | resources.nebulaStudio | {} | nebula-studio 的资源限制/请求。 | -| resources.nginx | {} | nginx 的资源限制/请求。 | | persistent.storageClassName | "" | storageClass 名称,如果不指定就使用默认值。 | | persistent.size | 5Gi | 存储盘大小。 | diff --git a/docs-2.0/nebula-studio/deploy-connect/st-ug-deploy.md b/docs-2.0/nebula-studio/deploy-connect/st-ug-deploy.md index 27a4df6da2..e0ed28b71f 100644 --- a/docs-2.0/nebula-studio/deploy-connect/st-ug-deploy.md +++ b/docs-2.0/nebula-studio/deploy-connect/st-ug-deploy.md @@ -3,7 +3,7 @@ Nebula Graph Studio( 以下简称 Studio )支持云端或本地部署。云服务版 Studio 只能在 Nebula Graph Cloud Service 上使用。当在 Nebula Graph Cloud Service 上创建 Nebula Graph 实例时即自动完成云服务版本 Studio 的部署,一键直连即可使用,不需要自己部署。详细信息参考 [《Nebula Graph Cloud Service 用户手册》](https://cloud-docs.nebula-graph.com.cn/cn/posts/manage-instances/dbaas-ug-connect-nebulastudio/ "点击前往 Nebula Graph Cloud Service 用户手册")。 --> -本文介绍如何在本地通过 Docker、RPM 和 tar 包部署 Studio。 +本文介绍如何在本地通过 Docker、RPM、DEB 和 tar 包部署 Studio。 !!! Note @@ -17,24 +17,13 @@ Nebula Graph Studio( 以下简称 Studio )支持云端或本地部署。云 - Nebula Graph 服务已经部署并启动。详细信息,参考 [Nebula Graph 安装部署](../../4.deployment-and-installation/1.resource-preparations.md "点击前往 Nebula Graph 安装部署")。 -- 使用的 Linux 发行版为 CentOS ,安装有 lsof 和版本为 v10.16.0 + 以上的 [Node.js](https://nodejs.org/zh-cn/)。 - - !!! note - - `node` 及 `npm` 命令需要安装在 `/usr/bin/`目录下,以防出现 RPM 安装时 node 命令找不到的情况。 - 例如 nodejs12 默认目录为`/opt/rh/rh-nodejs12`,用户可以使用以下命令建立软连接: - - ```bash - $ sudo ln -s /opt/rh/rh-nodejs12/root/usr/bin/node /usr/bin/node - $ sudo ln -s /opt/rh/rh-nodejs12/root/usr/bin/npm /usr/bin/npm - ``` +- 使用的 Linux 发行版为 CentOS ,安装有 lsof。 - 确保在安装开始前,以下端口处于未被使用状态。 | 端口号 | 说明 | | ---- | ---- | | 7001 | Studio 提供 web 服务使用。 | - | 8080 | Nebula HTTP Gateway Client 进行 HTTP 通信使用。 | ### 安装 @@ -46,17 +35,20 @@ Nebula Graph Studio( 以下简称 Studio )支持云端或本地部署。云 2. 使用`sudo rpm -i `命令安装 RPM 包。 - 例如,安装 Studio {{studio.release}} 版本需要运行以下命令: + 例如,安装 Studio {{studio.release}} 版本需要运行以下命令,默认安装路径为`/usr/local/nebula-graph-studio`: ```bash $ sudo rpm -i nebula-graph-studio-{{studio.release}}.x86_64.rpm ``` + 也可以使用以下命令安装到指定路径: + ```bash + $ sudo rpm -i nebula-graph-studio-{{studio.release}}.x86_64.rpm --prefix= + ``` 当屏幕返回以下信息时,表示 PRM 版 Studio 已经成功启动。 ```bash - egg started on http://0.0.0.0:7001 - nohup: 把输出追加到"nohup.out" + Created symlink from /etc/systemd/system/multi-user.target.wants/nebula-graph-studio.service to /usr/lib/systemd/system/nebula-graph-studio.service. ``` 3. 启动成功后,在浏览器地址栏输入 `http://ip address:7001`。 @@ -95,20 +87,19 @@ $ lsof -i:7001 如果端口被占用,且无法结束该端口上进程,用户可以通过以下命令修改 Studio 服务启动端口,并重新启动服务。 ```bash //修改 studio 服务启动端口 -$ vi config/config.default.js +$ vi config/example-config.yaml //修改 -... - config.cluster = { - listen: { - port: 7001, // 修改这个端口号,改成任意一个当前可用的即可 - hostname: '0.0.0.0', - }, - }; -... - -//重新启动 npm -$ npm run start +web: +# task_id_path: +# upload_dir: +# tasks_dir: +# sqlitedb_file_path: +# ip: + port: 7001 // 修改这个端口号,改成任意一个当前可用的即可 + +//重启服务 +$ systemctl restart nebula-graph-studio.service ``` ## tar 包部署 Studio @@ -119,16 +110,13 @@ $ npm run start - Nebula Graph 服务已经部署并启动。详细信息,参考 [Nebula Graph 安装部署](../../4.deployment-and-installation/1.resource-preparations.md "点击前往 Nebula Graph 安装部署")。 -- 使用的 Linux 上安装有版本为 v10.12.0 以上的 Node.js。 - - 确保在安装开始前,以下端口处于未被使用状态。 | 端口号 | 说明 | | ---- | ---- | | 7001 | Studio 提供的 web 服务 | - | 8080 | Nebula-http-gateway,Client 的 HTTP 服务 | -### 安装 +### 安装部署 1. 根据需要下载 tar 包,建议选择最新版本。 @@ -142,31 +130,18 @@ $ npm run start tar -xvf nebula-graph-studio-{{studio.release}}.x86_64.tar.gz ``` -### 部署 - -!!! Note - - 根目录 nebula-graph-studio 下一共有两个安装包:nebula-graph-studio 和 nebula-http-gateway。用户需要在同一台机器上分别部署并启动服务,才能完成 Studio 的部署。 - -1. 部署 nebula-http-gateway 并启动。 - - ```bash - $ cd nebula-http-gateway - $ nohup ./nebula-httpd & - ``` - -2. 部署 nebula-graph-studio 并启动。 +3. 部署 nebula-graph-studio 并启动。 ```bash $ cd nebula-graph-studio - $ npm run start + $ ./server ``` !!! caution - Studio {{studio.release}} 版本不需要依赖于 nebula-importer,故安装部署方式与 Studio v3.0.0 不同。 + Studio {{studio.release}} 版本不需要依赖于 nebula-importer 和 nebula-http-gateway,故安装部署方式与 Studio v3.1.0 不同。 -3. 启动成功后,在浏览器地址栏输入 `http://ip address:7001`。 +4. 启动成功后,在浏览器地址栏输入 `http://ip address:7001`。 如果在浏览器窗口中能看到以下登录界面,表示已经成功部署并启动 Studio。 @@ -176,9 +151,54 @@ $ npm run start 用户可以采用 `kill pid` 的方式来关停服务: ```bash -$ kill $(lsof -t -i :8080) # stop nebula-http-gateway -$ cd nebula-graph-studio -$ npm run stop # stop nebula-graph-studio +$ kill $(lsof -t -i :7001) # stop nebula-graph-studio +``` + +## DEB 部署 Studio + +### 前提条件 + +在通过 DEB 部署安装 Studio 之前,用户需要确认以下信息: + +- Nebula Graph 服务已经部署并启动。详细信息,参考 [Nebula Graph 安装部署](../../4.deployment-and-installation/1.resource-preparations.md "点击前往 Nebula Graph 安装部署")。 + +- 使用的 Linux 发行版为 Ubuntu。 + +- 确保在安装开始前,以下端口处于未被使用状态。 + + | 端口号 | 说明 | + | ---- | ---- | + | 7001 | Studio 提供的 web 服务 | + + +### 安装 + +1. 根据需要选择并下载 DEB 包,建议选择最新版本。常用下载链接如下: + + | 安装包 | 检验和 | Nebula 版本 | + | ----- | ----- | ----- | + | [nebula-graph-studio-{{studio.release}}.x86_64.deb](https://oss-cdn.nebula-graph.com.cn/nebula-graph-studio/{{studio.release}}/nebula-graph-studio-{{studio.release}}.x86_64.deb) | [nebula-graph-studio-{{studio.release}}.x86_64.deb.sha256](https://oss-cdn.nebula-graph.com.cn/nebula-graph-studio/{{studio.release}}/nebula-graph-studio-{{studio.release}}.x86_64.deb.sha256) | {{ nebula.release }} | + +2. 使用`sudo dpkg -i `命令安装 DEB 包。 + + 例如,安装 Studio {{studio.release}} 版本需要运行以下命令: + + ```bash + $ sudo dpkg -i nebula-graph-studio-{{studio.release}}.x86_64.deb + ``` + +3. 启动成功后,在浏览器地址栏输入 `http://ip address:7001`。 + + 如果在浏览器窗口中能看到以下登录界面,表示已经成功部署并启动 Studio。 + + ![Nebula Graph Studio 登录界面](../figs/st-ug-001-1.png "Nebula Graph Studio 登录界面") + +### 卸载 + +用户可以使用以下的命令卸载 Studio。 + +```bash +$ sudo dpkg -r nebula-graph-studio-{{studio.release}}.x86_64 ``` ## Docker 部署 Studio @@ -194,7 +214,6 @@ $ npm run stop # stop nebula-graph-studio | 端口号 | 说明 | | ---- | ---- | | 7001 | Studio 提供的 web 服务 | - | 8080 | Nebula-http-gateway,Client 的 HTTP 服务 | - (可选)在中国大陆从 Docker Hub 拉取 Docker 镜像的速度可能比较慢,用户可以使用 `registry-mirrors` 参数配置加速镜像。例如,如果要使用 Docker 中国区官方镜像、网易镜像和中国科技大学的镜像,则按以下格式配置 `registry-mirrors` 参数: @@ -218,7 +237,7 @@ $ npm run stop # stop nebula-graph-studio | 安装包 | Nebula Graph 版本 | | ----- | ----- | - | [nebula-graph-studio-v{{studio.release}}.tar.gz](https://oss-cdn.nebula-graph.com.cn/nebula-graph-studio/nebula-graph-studio-v{{studio.release}}.tar.gz) | {{nebula.release}} | + | [nebula-graph-studio-v{{studio.release}}.tar.gz](https://oss-cdn.nebula-graph.com.cn/nebula-graph-studio/{{studio.release}}/nebula-graph-studio-v{{studio.release}}.tar.gz) | {{nebula.release}} | 2. 创建`nebula-graph-studio-v{{studio.release}}`目录,并将安装包解压至目录中。 @@ -247,9 +266,7 @@ $ npm run stop # stop nebula-graph-studio 当屏幕返回以下信息时,表示 Docker 版 Studio 已经成功启动。 ```bash - Creating docker_client_1 ... done Creating docker_web_1 ... done - Creating docker_nginx_1 ... done ``` 6. 启动成功后,在浏览器地址栏输入 `http://ip address:7001`。 diff --git a/docs-2.0/nebula-studio/figs/chaxun.png b/docs-2.0/nebula-studio/figs/chaxun.png new file mode 100644 index 0000000000..f681e76640 Binary files /dev/null and b/docs-2.0/nebula-studio/figs/chaxun.png differ diff --git a/docs-2.0/nebula-studio/figs/st-ug-001.png b/docs-2.0/nebula-studio/figs/st-ug-001.png deleted file mode 100644 index 56daeaf523..0000000000 Binary files a/docs-2.0/nebula-studio/figs/st-ug-001.png and /dev/null differ diff --git a/docs-2.0/nebula-studio/figs/st-ug-003-1.png b/docs-2.0/nebula-studio/figs/st-ug-003-1.png deleted file mode 100644 index 95946d3f1e..0000000000 Binary files a/docs-2.0/nebula-studio/figs/st-ug-003-1.png and /dev/null differ diff --git a/docs-2.0/nebula-studio/figs/st-ug-004.png b/docs-2.0/nebula-studio/figs/st-ug-004.png deleted file mode 100644 index 7dee381920..0000000000 Binary files a/docs-2.0/nebula-studio/figs/st-ug-004.png and /dev/null differ diff --git a/docs-2.0/nebula-studio/figs/st-ug-005.png b/docs-2.0/nebula-studio/figs/st-ug-005.png deleted file mode 100644 index 001e5ae05e..0000000000 Binary files a/docs-2.0/nebula-studio/figs/st-ug-005.png and /dev/null differ diff --git a/docs-2.0/nebula-studio/figs/st-ug-006.png b/docs-2.0/nebula-studio/figs/st-ug-006.png deleted file mode 100644 index ecde01f1fe..0000000000 Binary files a/docs-2.0/nebula-studio/figs/st-ug-006.png and /dev/null differ diff --git a/docs-2.0/nebula-studio/figs/st-ug-007.png b/docs-2.0/nebula-studio/figs/st-ug-007.png deleted file mode 100644 index 38ceb25ae1..0000000000 Binary files a/docs-2.0/nebula-studio/figs/st-ug-007.png and /dev/null differ diff --git a/docs-2.0/nebula-studio/figs/st-ug-009.png b/docs-2.0/nebula-studio/figs/st-ug-009.png deleted file mode 100644 index 6719096bbf..0000000000 Binary files a/docs-2.0/nebula-studio/figs/st-ug-009.png and /dev/null differ diff --git a/docs-2.0/nebula-studio/figs/st-ug-010.png b/docs-2.0/nebula-studio/figs/st-ug-010.png deleted file mode 100644 index a2affa766b..0000000000 Binary files a/docs-2.0/nebula-studio/figs/st-ug-010.png and /dev/null differ diff --git a/docs-2.0/nebula-studio/figs/st-ug-011.png b/docs-2.0/nebula-studio/figs/st-ug-011.png deleted file mode 100644 index be904991f8..0000000000 Binary files a/docs-2.0/nebula-studio/figs/st-ug-011.png and /dev/null differ diff --git a/docs-2.0/nebula-studio/figs/st-ug-012.png b/docs-2.0/nebula-studio/figs/st-ug-012.png deleted file mode 100644 index 0c0ec76738..0000000000 Binary files a/docs-2.0/nebula-studio/figs/st-ug-012.png and /dev/null differ diff --git a/docs-2.0/nebula-studio/figs/st-ug-013.png b/docs-2.0/nebula-studio/figs/st-ug-013.png deleted file mode 100644 index c29af27bc0..0000000000 Binary files a/docs-2.0/nebula-studio/figs/st-ug-013.png and /dev/null differ diff --git a/docs-2.0/nebula-studio/figs/st-ug-014-1.png b/docs-2.0/nebula-studio/figs/st-ug-014-1.png new file mode 100644 index 0000000000..8c9ba1e7fb Binary files /dev/null and b/docs-2.0/nebula-studio/figs/st-ug-014-1.png differ diff --git a/docs-2.0/nebula-studio/figs/st-ug-014-2.png b/docs-2.0/nebula-studio/figs/st-ug-014-2.png deleted file mode 100644 index 0652d709d2..0000000000 Binary files a/docs-2.0/nebula-studio/figs/st-ug-014-2.png and /dev/null differ diff --git a/docs-2.0/nebula-studio/figs/st-ug-014.png b/docs-2.0/nebula-studio/figs/st-ug-014.png deleted file mode 100644 index b8a601ab1e..0000000000 Binary files a/docs-2.0/nebula-studio/figs/st-ug-014.png and /dev/null differ diff --git a/docs-2.0/nebula-studio/figs/st-ug-015-1.png b/docs-2.0/nebula-studio/figs/st-ug-015-1.png deleted file mode 100644 index ff481c538b..0000000000 Binary files a/docs-2.0/nebula-studio/figs/st-ug-015-1.png and /dev/null differ diff --git a/docs-2.0/nebula-studio/figs/st-ug-016-1.png b/docs-2.0/nebula-studio/figs/st-ug-016-1.png deleted file mode 100644 index aa42fa210e..0000000000 Binary files a/docs-2.0/nebula-studio/figs/st-ug-016-1.png and /dev/null differ diff --git a/docs-2.0/nebula-studio/figs/st-ug-022-1.png b/docs-2.0/nebula-studio/figs/st-ug-022-1.png deleted file mode 100644 index 591dfe19ff..0000000000 Binary files a/docs-2.0/nebula-studio/figs/st-ug-022-1.png and /dev/null differ diff --git a/docs-2.0/nebula-studio/figs/st-ug-022.png b/docs-2.0/nebula-studio/figs/st-ug-022.png deleted file mode 100644 index b33d1ff8b9..0000000000 Binary files a/docs-2.0/nebula-studio/figs/st-ug-022.png and /dev/null differ diff --git a/docs-2.0/nebula-studio/figs/st-ug-023-1.png b/docs-2.0/nebula-studio/figs/st-ug-023-1.png deleted file mode 100644 index b4a1009b46..0000000000 Binary files a/docs-2.0/nebula-studio/figs/st-ug-023-1.png and /dev/null differ diff --git a/docs-2.0/nebula-studio/figs/st-ug-040.png b/docs-2.0/nebula-studio/figs/st-ug-040.png deleted file mode 100644 index 2725e63406..0000000000 Binary files a/docs-2.0/nebula-studio/figs/st-ug-040.png and /dev/null differ diff --git a/docs-2.0/nebula-studio/figs/st-ug-041.png b/docs-2.0/nebula-studio/figs/st-ug-041.png deleted file mode 100644 index 2129ef844e..0000000000 Binary files a/docs-2.0/nebula-studio/figs/st-ug-041.png and /dev/null differ diff --git a/docs-2.0/nebula-studio/figs/st-ug-042.png b/docs-2.0/nebula-studio/figs/st-ug-042.png deleted file mode 100644 index 45add9269d..0000000000 Binary files a/docs-2.0/nebula-studio/figs/st-ug-042.png and /dev/null differ diff --git a/docs-2.0/nebula-studio/figs/st-ug-043.png b/docs-2.0/nebula-studio/figs/st-ug-043.png deleted file mode 100644 index c11cf0757b..0000000000 Binary files a/docs-2.0/nebula-studio/figs/st-ug-043.png and /dev/null differ diff --git a/docs-2.0/nebula-studio/figs/st-ug-044.png b/docs-2.0/nebula-studio/figs/st-ug-044.png deleted file mode 100644 index 4ff17fb07f..0000000000 Binary files a/docs-2.0/nebula-studio/figs/st-ug-044.png and /dev/null differ diff --git a/docs-2.0/nebula-studio/figs/st-ug-045.png b/docs-2.0/nebula-studio/figs/st-ug-045.png deleted file mode 100644 index 1d74884cbd..0000000000 Binary files a/docs-2.0/nebula-studio/figs/st-ug-045.png and /dev/null differ diff --git a/docs-2.0/nebula-studio/figs/st-ug-046.png b/docs-2.0/nebula-studio/figs/st-ug-046.png index 32f7e52910..21a89903d8 100644 Binary files a/docs-2.0/nebula-studio/figs/st-ug-046.png and b/docs-2.0/nebula-studio/figs/st-ug-046.png differ diff --git a/docs-2.0/nebula-studio/figs/st-ug-055-1.png b/docs-2.0/nebula-studio/figs/st-ug-055-1.png deleted file mode 100644 index d3eb01b6fa..0000000000 Binary files a/docs-2.0/nebula-studio/figs/st-ug-055-1.png and /dev/null differ diff --git a/docs-2.0/nebula-studio/figs/st-ug-055-2.png b/docs-2.0/nebula-studio/figs/st-ug-055-2.png new file mode 100644 index 0000000000..7b1fc79561 Binary files /dev/null and b/docs-2.0/nebula-studio/figs/st-ug-055-2.png differ diff --git a/docs-2.0/nebula-studio/figs/st-ug-055.png b/docs-2.0/nebula-studio/figs/st-ug-055.png deleted file mode 100644 index 546a19bc36..0000000000 Binary files a/docs-2.0/nebula-studio/figs/st-ug-055.png and /dev/null differ diff --git a/docs-2.0/nebula-studio/manage-schema/st-ug-crud-tag.md b/docs-2.0/nebula-studio/manage-schema/st-ug-crud-tag.md index 14b59552b6..d80802355e 100644 --- a/docs-2.0/nebula-studio/manage-schema/st-ug-crud-tag.md +++ b/docs-2.0/nebula-studio/manage-schema/st-ug-crud-tag.md @@ -28,9 +28,9 @@ Studio v{{ studio.release }} 及以后版本。请更新版本,详细操作参 5. 在 **创建** 页面上,完成以下设置: - a. **名称**:按提示信息输入合规的 Tag 名称。本示例中,输入 `player` 和 `team`。 + 1. **名称**:按提示信息输入合规的 Tag 名称。本示例中,输入 `player` 和 `team`。 - b. (可选)如果 Tag 需要属性,在 **定义属性** 模块左上角,点击勾选框,并在展开的列表中,完成以下操作: + 2. (可选)如果 Tag 需要属性,在 **定义属性** 模块左上角,点击勾选框,并在展开的列表中,完成以下操作: - 输入属性名称、数据类型和默认值。 @@ -38,7 +38,7 @@ Studio v{{ studio.release }} 及以后版本。请更新版本,详细操作参 - 如果要删除某个属性,在该属性所在行,点击 ![表示删除的图标](../figs/st-ug-020.png "删除") 图标。 - c. (可选)Tag 未设置索引时,用户可以设置 TTL:在 **设置 TTL** 模块左上角,点击勾选框,并在展开的列表中设置 `TTL_COL` 和 `TTL_DURATION` 参数信息。关于这两个参数的详细信息,参考 [TTL 配置](../../3.ngql-guide/8.clauses-and-options/ttl-options.md "点击前往 Nebula Graph 网站")。 + 3. (可选)Tag 未设置索引时,用户可以设置 TTL:在 **设置 TTL** 模块左上角,点击勾选框,并在展开的列表中设置 `TTL_COL` 和 `TTL_DURATION` 参数信息。关于这两个参数的详细信息,参考 [TTL 配置](../../3.ngql-guide/8.clauses-and-options/ttl-options.md "点击前往 Nebula Graph 网站")。 6. 完成设置后,在 **对应的 nGQL **面板,用户能看到与上述配置等价的 nGQL 语句。 diff --git a/docs-2.0/nebula-studio/use-console/st-ug-console.md b/docs-2.0/nebula-studio/use-console/st-ug-console.md index 80dbfef672..0c630d34ff 100644 --- a/docs-2.0/nebula-studio/use-console/st-ug-console.md +++ b/docs-2.0/nebula-studio/use-console/st-ug-console.md @@ -2,7 +2,7 @@ Studio 的控制台界面如下图所示。 -![控制台界面截图](../figs/st-ug-055-1.png "控制台") +![控制台界面截图](../figs/st-ug-055-2.png "控制台") 下表列出了控制台界面上的各种功能。 @@ -10,11 +10,12 @@ Studio 的控制台界面如下图所示。 | :-- | :--| :-- | | 1 | 工具栏 | 点击 **控制台** 页签进入控制台页面。 | | 2 | 选择图空间 | 在 **当前图空间** 列表中选择一个图空间。
**说明**:Studio 不支持直接在输入框中运行 `USE ` 语句。 | -| 3 | 输入框 | 在输入框中输入 nGQL 语句后,点击 ![表示运行的图标](../figs/st-ug-008.png "运行按钮") 按钮运行语句。用户可以同时输入多个语句同时运行,语句之间以 `;` 分隔。 -| 4 | 清空输入框 | 点击 ![表示清空的图标](../figs/st-ug-056.png "清空按钮") 按钮,清空输入框中已经输入的内容。 | -| 5 | 历史清单 | 点击 ![表示语句记录的图标](../figs/st-ug-057.png "查看语句记录") 按钮,在语句运行记录列表里,点击其中一个语句,输入框中即自动输入该语句。列表里提供最近 15 次语句运行记录。 | -| 6 | 运行 | 在输入框中输入 nGQL 语句后,点击 ![表示运行的图标](../figs/st-ug-008.png "运行按钮") 按钮即开始运行语句。 | -| 7 | 语句运行状态 | 运行 nGQL 语句后,这里显示语句运行状态。如果语句运行成功,语句以绿色显示。如果语句运行失败,语句以红色显示。 | -| 8 | 结果窗口 | 显示语句运行结果。如果语句会返回结果,结果窗口会以表格形式呈现返回的结果。 | -| 9 | 导出 CSV 文件 | 运行 nGQL 语句返回结果后,点击 **导出 CSV 文件** 按钮即能将结果以 CSV 文件的形式导出。 | -| 10 | 图探索功能键 | 根据运行的 nGQL 语句,用户可以点击图探索功能键将返回的结果导入 **图探索** 进行可视化展现,例如[导入图探索](st-ug-open-in-explore.md)和[查看子图](st-ug-visualize-subgraph.md)。 | +| 3 | 自定义参数展示 | 点击 ![查询](../figs/chaxun.png)按钮可展开自定义参数,用于参数化查询,详情信息可见[管理参数](../../nebula-console.md)。| +| 4 | 输入框 | 在输入框中输入 nGQL 语句后,点击 ![表示运行的图标](../figs/st-ug-008.png "运行按钮") 按钮运行语句。用户可以同时输入多个语句同时运行,语句之间以 `;` 分隔。 +| 5 | 清空输入框 | 点击 ![表示清空的图标](../figs/st-ug-056.png "清空按钮") 按钮,清空输入框中已经输入的内容。 | +| 6 | 历史清单 | 点击 ![表示语句记录的图标](../figs/st-ug-057.png "查看语句记录") 按钮,在语句运行记录列表里,点击其中一个语句,输入框中即自动输入该语句。列表里提供最近 15 次语句运行记录。 | +| 7 | 运行 | 在输入框中输入 nGQL 语句后,点击 ![表示运行的图标](../figs/st-ug-008.png "运行按钮") 按钮即开始运行语句。 | +| 8 | 语句运行状态 | 运行 nGQL 语句后,这里显示语句运行状态。如果语句运行成功,语句以绿色显示。如果语句运行失败,语句以红色显示。 | +| 9 | 结果窗口 | 显示语句运行结果。如果语句会返回结果,结果窗口会以表格形式呈现返回的结果。 | +| 10 | 导出 CSV 文件 | 运行 nGQL 语句返回结果后,点击 **导出 CSV 文件** 按钮即能将结果以 CSV 文件的形式导出。 | +| 11 | 图探索功能键 | 根据运行的 nGQL 语句,用户可以点击图探索功能键将返回的结果导入 **图探索** 进行可视化展现,例如[导入图探索](st-ug-open-in-explore.md)和[查看子图](st-ug-visualize-subgraph.md)。 | diff --git a/docs-2.0/reuse/source_connect-to-nebula-graph.md b/docs-2.0/reuse/source_connect-to-nebula-graph.md index 99eebca12d..d914550384 100644 --- a/docs-2.0/reuse/source_connect-to-nebula-graph.md +++ b/docs-2.0/reuse/source_connect-to-nebula-graph.md @@ -16,6 +16,12 @@ Nebula Graph 支持多种类型客户端,包括 CLI 客户端、GUI 客户端 - 运行 Nebula Console 的机器和运行 Nebula Graph 的服务器网络互通。 +- Nebula Console 版本兼容 Nebula Graph 版本。 + + !!! note + + 版本相同的 Nebula Console 和 Nebula Graph 兼容程度最高,版本不同的 Nebula Console 连接 Nebula Graph 时,可能会有兼容问题,或者无法连接并报错`incompatible version between client and server`。 + ### 操作步骤 1. 在 [Nebula Console](https://github.com/vesoft-inc/nebula-console/releases "the nebula-console Releases page") 下载页面,确认需要的版本,单击** Assets**。 @@ -69,7 +75,7 @@ Nebula Graph 支持多种类型客户端,包括 CLI 客户端、GUI 客户端 | 参数 | 说明 | | - | - | | `-h` | 显示帮助菜单。 | - | `-addr` | 设置要连接的 graphd 服务的 IP 地址。默认地址为 127.0.0.1。如果 Nebula Graph 部署在 [Nebula Cloud](../nebula-cloud/1.what-is-cloud.md) 上,用户需要创建 [Private Link](../nebula-cloud/5.solution/5.2.connection-configuration-and-use.md),设置为专用终结点的 IP 地址。 | + | `-addr` | 设置要连接的 graphd 服务的 IP 地址。默认地址为 127.0.0.1。如果 Nebula Graph 部署在 [Nebula Cloud](https://docs.nebula-graph.com.cn/2.6.2/nebula-cloud/1.what-is-cloud/) 上,用户需要创建 [Private Link](https://docs.nebula-graph.com.cn/2.6.2/nebula-cloud/5.solution/5.2.connection-configuration-and-use),设置为专用终结点的 IP 地址。 | | `-port` | 设置要连接的 graphd 服务的端口。默认端口为 9669。| | `-u/-user` | 设置 Nebula Graph 账号的用户名。未启用身份认证时,可以使用任意已存在的用户名(默认为`root`)。 | | `-p/-password` | 设置用户名对应的密码。未启用身份认证时,密码可以填写任意字符。 | diff --git a/docs-2.0/reuse/source_manage-service.md b/docs-2.0/reuse/source_manage-service.md index 258dd459b1..0ba792189d 100644 --- a/docs-2.0/reuse/source_manage-service.md +++ b/docs-2.0/reuse/source_manage-service.md @@ -85,7 +85,7 @@ $ sudo /usr/local/nebula/scripts/nebula.service stop all 在`nebula-docker-compose/`目录内执行如下命令停止 Nebula Graph 服务: ```bash -nebula-docker-compose]$ docker-compose down +[nebula-docker-compose]$ docker-compose down Stopping nebula-docker-compose_graphd_1 ... done Stopping nebula-docker-compose_graphd2_1 ... done Stopping nebula-docker-compose_storaged0_1 ... done @@ -144,7 +144,7 @@ Nebula Graph 服务由 Meta 服务、Graph 服务和 Storage 服务共同提供 在`nebula-docker-compose`目录内执行如下命令查看 Nebula Graph 服务状态: ```bash -nebula-docker-compose]$ docker-compose ps +[nebula-docker-compose]$ docker-compose ps Name Command State Ports --------------------------------------------------------------------------------------------------------------------------------------------------------------------- nebula-docker-compose_graphd1_1 /usr/local/nebula/bin/nebu ... Up (healthy) 0.0.0.0:49223->19669/tcp, 0.0.0.0:49222->19670/tcp, 0.0.0.0:49224->9669/tcp @@ -185,7 +185,7 @@ a74054c6ae25 vesoft/nebula-graphd:nightly "/usr/local/nebula/b…" 36 mi 最后登录容器排查问题 ```bash -nebula-docker-compose]$ docker exec -it 2a6c56c405f5 bash +[nebula-docker-compose]$ docker exec -it 2a6c56c405f5 bash [root@2a6c56c405f5 nebula]# ``` diff --git a/docs-2.0/stylesheets/extra.css b/docs-2.0/stylesheets/extra.css index 8494c932df..e4dd0fc797 100644 --- a/docs-2.0/stylesheets/extra.css +++ b/docs-2.0/stylesheets/extra.css @@ -1,3 +1,19 @@ .md-grid { max-width: initial; - } \ No newline at end of file + } + +/* nebula 黑夜主题色 */ +:root{ + --md-primary-fg-color:#a27e7e; /* 导航栏页面颜色 */ + --md-accent-fg-color: #FA8072; /* 选中/悬浮颜色 */ +} + +/* nebula 白天主题色 */ +[data-md-color-scheme="nebula"]{ + --md-primary-fg-color: #002FA7; /* 导航栏页面颜色 */ + --md-accent-fg-color: #00FFFF; /* 选中/悬浮颜色 */ + + --md-code-fg-color: rgb(12, 21, 26); /* 代码段字体色 */ + --md-code-bg-color: #eaebec;/* 代码段背景色 */ + --md-typeset-color: #000000;/* 普通背景字 */ +} \ No newline at end of file diff --git a/docs-2.0/stylesheets/logo.css b/docs-2.0/stylesheets/logo.css index 8c1029c7db..e618be43b4 100644 --- a/docs-2.0/stylesheets/logo.css +++ b/docs-2.0/stylesheets/logo.css @@ -6,6 +6,6 @@ } .md-header .md-logo img { - width: 187px; - height: 40px; + width: 187px !important; + height: 40px !important; } \ No newline at end of file diff --git a/docs-2.0/stylesheets/note.css b/docs-2.0/stylesheets/note.css index 731976555a..262e1618f5 100644 --- a/docs-2.0/stylesheets/note.css +++ b/docs-2.0/stylesheets/note.css @@ -20,18 +20,18 @@ background-image: url('data:image/svg+xml;charset=utf-8,') !important; @@ -43,18 +43,18 @@ background-image: url('data:image/svg+xml;charset=utf-8,') !important; @@ -67,18 +67,18 @@ background-image: url('data:image/svg+xml;charset=utf-8,') !important; @@ -90,13 +90,13 @@ background-image: url('data:image/svg+xml;charset=utf-8, .admonition-title, .md-typeset .performance > summary { -background-color: rgba(255,145,0, 0.5); -border-color: rgb(255,145,0); +background-color: rgba(255,168,38, 0.5); +border-color: rgb(255,168,38); } .md-typeset .performance > .admonition-title::before, .md-typeset .performance > summary::before { -background-color: rgb(255,145,0); +background-color: rgb(255,168,38); -webkit-mask-image: var(--md-admonition-icon--performance); mask-image: var(--md-admonition-icon--performance); background-image: url('data:image/svg+xml;charset=utf-8,') !important; diff --git a/mkdocs.yml b/mkdocs.yml index 8bde05e10a..df42f26cfc 100755 --- a/mkdocs.yml +++ b/mkdocs.yml @@ -10,7 +10,7 @@ repo_name: 'vesoft-inc/nebula-docs-cn' repo_url: 'https://github.com/vesoft-inc/nebula-docs-cn' # Copyright -copyright: Copyright © 2021 Nebula Graph - 浙ICP备20010487号 +copyright: Copyright © 2022 Nebula Graph - 浙ICP备20010487号 # Configuration theme: @@ -18,6 +18,7 @@ theme: custom_dir: overrides logo: 'https://cloud-cdn.nebula-graph.com.cn/vesoft-nebula-logo-white.png' favicon: 'assets/images/favicon.ico' + # Change color in `stylesheets > extra.css` palette: - scheme: default primary: teal @@ -58,62 +59,61 @@ extra: base111b: 1.1.1-beta base220: 2.2.1 base300: 3.0.0 - release: 3.1.0 + release: 3.2.1 explorer: - base100: 1.0.0 - release: 2.1.0 + release: 2.2.0 exchange_ent: - release: 2.6.1 - branch: v2.6.1 + release: 3.0.0 + branch: v3.0.0 exchange: - release: 2.6.1 - branch: v2.6 - tag: v2.6.1 + release: 3.0.0 + branch: v3.0.0 + tag: v3.0.0 importer: - release: 2.6.0 - branch: v2.6.0 + release: 3.0.0 + branch: v3.0.0 algorithm: - release: 2.5.1 - branch: v2.5 - plato: + release: 3.0.0 + branch: v3.0.0 + analytics: release: 1.0.0 branch: v1.0.0 sparkconnector: - release: 2.6.1 - branch: v2.6 - tag: v2.6.1 + release: 3.0.0 + branch: v3.0.0 + tag: v3.0.0 flinkconnector: - release: 2.6.1 - branch: v2.6 - tag: v2.6.1 + release: 3.0.0 + branch: v3.0.0 + tag: v3.0.0 dockercompose: - release: 2.6.0 - branch: v2.6.0 + release: 3.0.0 + branch: v3.0.0 common: release: 2.5.0 dashboard: - release: 1.0.2 + release: 1.1.0 base100: 1.0.0 - branch: v1.0.2 + branch: v1.1.0 dashboard_ent: - release: 1.0.0 + release: 1.1.0 console: - release: 2.6.0 - branch: v2.6.0 + release: 3.0.0 + branch: v3.0.0 br: - release: 0.5.0 + release: 0.6.0 cpp: - release: 2.5.0 - branch: v2.5.0 + release: 3.0.0 + branch: v3.0.0 java: - release: 2.6.1 - branch: v2.6.1 + release: 3.0.0 + branch: v3.0.0 python: - release: 2.6.0 - branch: v2.6.0 + release: 3.0.0 + branch: v3.0.0 go: - release: 2.6.0 - branch: v2.6.0 + release: 3.0.0 + branch: release-v3.0.0 bench: release: 1.0.0 branch: master @@ -308,10 +308,12 @@ nav: - 设置企业版 License: 4.deployment-and-installation/deploy-license.md - 管理服务: 4.deployment-and-installation/manage-service.md - 连接服务: 4.deployment-and-installation/connect-to-nebula-graph.md - - 管理逻辑机架(Zone): 4.deployment-and-installation/5.zone.md + - 管理 Storage 主机: 4.deployment-and-installation/manage-storage-host.md +# - 管理逻辑机架(Zone): 4.deployment-and-installation/5.zone.md + - 升级版本: - - 升级历史版本至当前版本: 4.deployment-and-installation/3.upgrade-nebula-graph/upgrade-nebula-graph-to-latest.md - - 升级 v2.0.x 至当前版本: 4.deployment-and-installation/3.upgrade-nebula-graph/upgrade-nebula-from-200-to-latest.md + - 升级 Nebula Graph 版本: 4.deployment-and-installation/3.upgrade-nebula-graph/upgrade-nebula-graph-to-latest.md +# - 升级 v2.0.x 至当前版本: 4.deployment-and-installation/3.upgrade-nebula-graph/upgrade-nebula-from-200-to-latest.md - 卸载 Nebula Graph: 4.deployment-and-installation/4.uninstall-nebula-graph.md - 配置与日志: @@ -334,14 +336,15 @@ nav: - 用户管理: 7.data-security/1.authentication/2.management-user.md - 内置角色权限: 7.data-security/1.authentication/3.role-list.md - OpenLDAP 验证: 7.data-security/1.authentication/4.ldap.md -# - 备份恢复: -# - 什么是 BR: 7.data-security/2.backup-restore/1.what-is-br.md -# - 编译 BR: 7.data-security/2.backup-restore/2.compile-br.md -# - 使用 BR 备份数据: 7.data-security/2.backup-restore/3.br-backup-data.md -# - 使用 BR 恢复数据: 7.data-security/2.backup-restore/4.br-restore-data.md - 管理快照: 7.data-security/3.manage-snapshot.md - SSL 加密: 7.data-security/4.ssl.md + - 备份恢复(BR): + - 什么是 BR: nebula-br/1.what-is-br.md + - 编译 BR: nebula-br/2.compile-br.md + - 使用 BR 备份数据: nebula-br/3.br-backup-data.md + - 使用 BR 恢复数据: nebula-br/4.br-restore-data.md + - 最佳实践: - Compaction: 8.service-tuning/compaction.md - Storage 负载均衡: 8.service-tuning/load-balance.md @@ -354,26 +357,27 @@ nav: - 客户端: - 客户端介绍: 14.client/1.nebula-client.md + - Nebula Console: nebula-console.md - Nebula CPP: 14.client/3.nebula-cpp-client.md - Nebula Java: 14.client/4.nebula-java-client.md - Nebula Python: 14.client/5.nebula-python-client.md - Nebula Go: 14.client/6.nebula-go-client.md - - Nebula Graph Cloud: - - 什么是 Nebula Graph Cloud: nebula-cloud/1.what-is-cloud.md - - 创建订阅: nebula-cloud/2.how-to-create-subsciption.md - - 配置Solution: nebula-cloud/3.how-to-set-solution.md - - Cloud Solution 角色身份说明: nebula-cloud/4.user-role-description.md - - Solution 操作: - - Solution: nebula-cloud/5.solution/5.0.introduce-solution.md - - 配套的应用(Dashboard/Studio/Explorer): nebula-cloud/5.solution/5.1.supporting-application.md - - Private Link: nebula-cloud/5.solution/5.2.connection-configuration-and-use.md - - 管理角色权限: nebula-cloud/5.solution/5.3.role-and-authority-management.md - - 价格: nebula-cloud/6.pricing.md - - 用户服务条款: nebula-cloud/7.terms-and-conditions.md - - 隐私政策条款: nebula-cloud/8.privacy-policy.md - - - Nebula Console: nebula-console.md + - Nebula Graph Cloud: nebula-cloud.md + +# - Nebula Graph Cloud: +# - 什么是 Nebula Graph Cloud: nebula-cloud/1.what-is-cloud.md +# - 创建订阅: nebula-cloud/2.how-to-create-subsciption.md +# - 配置Solution: nebula-cloud/3.how-to-set-solution.md +# - Cloud Solution 角色身份说明: nebula-cloud/4.user-role-description.md +# - Solution 操作: +# - Solution: nebula-cloud/5.solution/5.0.introduce-solution.md +# - 配套的应用(Dashboard/Studio/Explorer): nebula-cloud/5.solution/5.1.supporting-application.md +# - Private Link: nebula-cloud/5.solution/5.2.connection-configuration-and-use.md +# - 管理角色权限: nebula-cloud/5.solution/5.3.role-and-authority-management.md +# - 价格: nebula-cloud/6.pricing.md +# - 用户服务条款: nebula-cloud/7.terms-and-conditions.md +# - 隐私政策条款: nebula-cloud/8.privacy-policy.md - Nebula Graph Studio: - Studio 版本更新说明: nebula-studio/about-studio/st-ug-release-note.md @@ -436,18 +440,20 @@ nav: - 常见问题 FAQ: nebula-dashboard-ent/8.faq.md - Nebula Explorer: - - 什么是 Nebula Explorer: nebula-explorer/about-explorer/ex-ug-what-is-explorer.md - - 安装与登录: - - 部署 Explorer: nebula-explorer/deploy-connect/ex-ug-deploy.md - - 连接数据库: nebula-explorer/deploy-connect/ex-ug-connect.md - - 清除连接: nebula-explorer/deploy-connect/ex-ug-reset-connection.md - - 操作指南: - - 页面概览: nebula-explorer/operation-guide/ex-ug-page-overview.md - - 查询探索: nebula-explorer/operation-guide/ex-ug-query-exploration.md - - 图探索拓展: nebula-explorer/operation-guide/ex-ug-graph-exploration.md - - 画布操作: nebula-explorer/operation-guide/ex-ug-canvas.md - - 关系列表: nebula-explorer/operation-guide/ex-ug-relationship-list.md - - 快捷键: nebula-explorer/operation-guide/ex-ug-shortcuts.md + - 什么是 Nebula Explorer: nebula-explorer/about-explorer/ex-ug-what-is-explorer.md + - 安装与登录: + - 部署 Explorer: nebula-explorer/deploy-connect/ex-ug-deploy.md + - 连接数据库: nebula-explorer/deploy-connect/ex-ug-connect.md + - 页面概览: nebula-explorer/ex-ug-page-overview.md + - 开始探索: nebula-explorer/ex-ug-query-exploration.md + - 节点筛选: nebula-explorer/node-filtering.md + - 探索拓展: nebula-explorer/ex-ug-graph-exploration.md + - 画布功能: + - 画布概览: nebula-explorer/canvas-operations/canvas-overview.md + - 可视化模式: nebula-explorer/canvas-operations/visualization-mode.md + - 画布快照: nebula-explorer/canvas-operations/canvas-snapshot.md + - 控制台: nebula-explorer/explorer-console.md + - 基本操作和快捷键: nebula-explorer/ex-ug-shortcuts.md - Nebula Importer: - 使用 Nebula Importer: nebula-importer/use-importer.md @@ -468,7 +474,7 @@ nav: - 导入 ORC 文件数据: nebula-exchange/use-exchange/ex-ug-import-from-orc.md - 导入 Parquet 文件数据: nebula-exchange/use-exchange/ex-ug-import-from-parquet.md - 导入 HBase 数据: nebula-exchange/use-exchange/ex-ug-import-from-hbase.md - - 导入 MySQL 数据: nebula-exchange/use-exchange/ex-ug-import-from-mysql.md + - 导入 MySQL/PostgreSQL 数据: nebula-exchange/use-exchange/ex-ug-import-from-mysql.md - 导入 ClickHouse 数据: nebula-exchange/use-exchange/ex-ug-import-from-clickhouse.md - 导入 Neo4j 数据: nebula-exchange/use-exchange/ex-ug-import-from-neo4j.md - 导入 Hive 数据: nebula-exchange/use-exchange/ex-ug-import-from-hive.md @@ -479,25 +485,25 @@ nav: - 导出 Nebula Graph 数据: nebula-exchange/use-exchange/ex-ug-export-from-nebula.md - Exchange 常见问题: nebula-exchange/ex-ug-FAQ.md - - Nebula Operator: - - 什么是 Nebula Operator: nebula-operator/1.introduction-to-nebula-operator.md - - 使用流程: nebula-operator/6.get-started-with-operator.md - - 部署 Nebula Operator: nebula-operator/2.deploy-nebula-operator.md - - 部署 Nebula Graph集群: - - 使用 Kubectl 部署 Nebula Graph 集群: nebula-operator/3.deploy-nebula-graph-cluster/3.1create-cluster-with-kubectl.md - - 使用 Helm 部署 Nebula Graph 集群: nebula-operator/3.deploy-nebula-graph-cluster/3.2create-cluster-with-helm.md - - 配置 Nebula Graph 集群: - - 自定义 Nebula Graph 集群的配置参数: nebula-operator/8.custom-cluster-configurations/8.1.custom-conf-parameter.md - - 回收 PV: nebula-operator/8.custom-cluster-configurations/8.2.pv-reclaim.md - - 均衡扩容后的 Storage 数据: nebula-operator/8.custom-cluster-configurations/8.3.balance-data-when-scaling-storage.md - - 升级 Nebula Graph 集群: nebula-operator/9.upgrade-nebula-cluster.md - - 连接 Nebula Graph 数据库: nebula-operator/4.connect-to-nebula-graph-service.md - - 故障自愈: nebula-operator/5.operator-failover.md - - 常见问题: nebula-operator/7.operator-faq.md +# - Nebula Operator: +# - 什么是 Nebula Operator: nebula-operator/1.introduction-to-nebula-operator.md +# - 使用流程: nebula-operator/6.get-started-with-operator.md +# - 部署 Nebula Operator: nebula-operator/2.deploy-nebula-operator.md +# - 部署 Nebula Graph集群: +# - 使用 Kubectl 部署 Nebula Graph 集群: nebula-operator/3.deploy-nebula-graph-cluster/3.1create-cluster-with-kubectl.md +# - 使用 Helm 部署 Nebula Graph 集群: nebula-operator/3.deploy-nebula-graph-cluster/3.2create-cluster-with-helm.md +# - 配置 Nebula Graph 集群: +# - 自定义 Nebula Graph 集群的配置参数: nebula-operator/8.custom-cluster-configurations/8.1.custom-conf-parameter.md +# - 回收 PV: nebula-operator/8.custom-cluster-configurations/8.2.pv-reclaim.md +# #banlance-3.1 notice Exclude - 均衡扩容后的 Storage 数据: nebula-operator/8.custom-cluster-configurations/8.3.balance-data-when-scaling-storage.md +# - 升级 Nebula Graph 集群: nebula-operator/9.upgrade-nebula-cluster.md +# - 连接 Nebula Graph 数据库: nebula-operator/4.connect-to-nebula-graph-service.md +# - 故障自愈: nebula-operator/5.operator-failover.md +# - 常见问题: nebula-operator/7.operator-faq.md - Nebula Algorithm: nebula-algorithm.md - - Nebula Plato: nebula-plato.md + - Nebula Analytics: nebula-analytics.md - Nebula Spark Connector: nebula-spark-connector.md @@ -545,10 +551,13 @@ plugins: # Exclude files with unix-style wildcards (globs) glob: # Exclude all files in a directory. The path starts with the directory name in docs-2.0, such as `20.appendix/*`. - - 7.data-security/2.backup-restore/* - nebula-flink/* - CHANGELOG.md - spark-connector/* + - nebula-operator/* + - 4.deployment-and-installation/5.zone.md + - 4.deployment-and-installation/3.upgrade-nebula-graph/upgrade-nebula-from-200-to-latest.md + - nebula-cloud/* # Exclude the file with the following file name. # - abc.md # Exclude files with regular expressions (regexes) @@ -556,8 +565,8 @@ plugins: # - '.*\.(tmp|bin|tar)$' - with-pdf: - copyright: 2021 vesoft Inc. - cover_subtitle: master sinnce 2.6.1 + copyright: 2022 vesoft Inc. + cover_subtitle: master sinnce 3.0.0 author: 吴敏,周瑶,梁振亚,杨怡璇,黄凤仙 cover: true back_cover: true diff --git a/overrides/partials/header.html b/overrides/partials/header.html similarity index 99% rename from overrides/partials/header.html rename to overrides/partials/header.html index dce5c274c5..023ed66359 100644 --- a/overrides/partials/header.html +++ b/overrides/partials/header.html @@ -97,4 +97,4 @@ } } } - + \ No newline at end of file