Change Password

Input error
Input error
Input error
Submit

Change Nickname

Current Nickname:
Submit
Search
v4.0
    v4.0

    Server Connection

    Server Connection and Authentication

    import { ConnectionPool } from "@ultipa/ultipa-node-sdk";
    
    // Declare Ultipa cluster addresses
    let hosts = [
        "192.168.1.11:60061",
        "192.168.1.12:60061",
        "192.168.1.13:60061"
    ]
    let username = "******"
    let password = "******"
    
    // Ultipa connection pool
    let connPool = new ConnectionPool(hosts, username, password)
    
    // Create Ultipa Client and test connection
    let client = await connPool.getActive()
    let isSuccess = await client.test()
    console.log(isSuccess);
    
    

    Acquire Ultipa Client Connection

    • The client appeared in the rest of this manual represents the Ultipa Client created from ConnectionPool, this procedure will be omitted in the examples hereafter.
    let client = await connPool.getActive()
    

    UQL Example

    • Execution of a UQL.
    
    // eg: find nodes in graphset 'default'
    let uqlResult = await client.uql(`find().nodes() as n return n{*} limit 3`, {
        graphSetName: "default"
    })
    if (uqlResult.status.code === ULTIPA.Code.SUCCESS) {
        // success
        console.log(uqlResult.data);
    } else {
        console.log(uqlResult.status);
    }
    
    Please complete the following information to download this book
    *
    公司名称不能为空
    *
    公司邮箱必须填写
    *
    你的名字必须填写
    *
    你的电话必须填写
    *
    你的电话必须填写