Loading... Loading ...
expand / collapse all

NuoDB REST API Documentation

You can use the REST API to manage the resources that comprise a NuoDB Database. This document provides introductory information about those resources and points you to where you can get more information.

Introduction to NuoDB Domain Administration

A NuoDB Domain is a secure environment for deploying and managing NuoDB distributed Databases. A Domain can contain one or more Databases, and each Database can run on one or more hosts. Each physical machine (host) in the Domain runs a Broker. Brokers are connected to each other. At minimum, a Domain includes one Broker. When expanding a Domain to include additional machines, the Broker on a host that is joining the Domain will use secure access to peer into the Domain.
You can manage a NuoDB Domain in the following ways:
  • Use the Automation Console
  • Use the NuoDB Manager command line tool
  • Use the REST API
Managing a NuoDB Domain includes tasks such as the following:
  • Creating and updating Databases based on built-in templates.
  • Stopping, starting, quiescing Databases
  • Monitoring the health of a Database by, for example, identifying slow queries, checking host and Database statistics, and monitoring events
You can do all of these tasks by means of the REST API. For more information, see Domain Administration.

About NuoDB Automation and Templates

NuoDB uses built-in templates to start and scale Databases on one or more hosts. Templates are Service Level Agreements (SLAs) that define attributes and rules for NuoDB Domains. Four templates are supplied: Single Host, Minimally Redundant, Multi Host, and Geo-distributed. Collectively, these templates can be used for almost all Database requirements. Each template is customizable. For more information, see Templates and Automation.
Here is an example of using the REST API to create a Database using the Single Host template:
curl -u domain:bird -X POST -H "Accept: application/json" -H "Content-type: application/json"
      -d '{ "name": "foo", "username": "dba", "password": "goalie", "template": "Single Host",
            "options": { }, 
            "groupOptions": { "SMs": {"mem": "1g"}, "TEs": {"mem": "2g"} },
            "tagConstraints": { "SMs": {"SM_HOST": "ex:"} },
            "variables": { "HOST": "82808d4d-d85d-4c99-bfe3-e5f76ec71bb5"}}' http://localhost:8888/api/1/databases?createTimeout=5000

REST API Configuration

You can configure parameters, such as user, password, broker host, port, and so on, in the nuodb-rest-api.yml configuration file. For details, see nuodb-rest-api.yml.
NuoDB uses Dropwizard to implement its REST API. For configuration information related to Dropwizard, visit https://dropwizard.github.io/dropwizard/manual/configuration.html.
  • Deprecated.

    {{baseUrl.value || ' '}}

    Body

    Accept:
    no type

    Returns

    Content-Type:
    no type

    Status codes



  • Interfaces not documented

    MireDot believes that the Java methods below correspond to REST interfaces, but somehow had problems parsing/processing these interfaces and therefore excluded them from the generated documentation. We would very much appreciate it if you would send us the interfaces (not the implementations) and the types used (returntype, parameters). This will allow us to further improve MireDot and better document your interfaces in the future.

Below is a list of potential problems detected by MireDot. They can be severe or not. Some of them wil result in low quality documentation, some are real implementation issues. With each warning, the Java method causing the problem is documented.

    • method:

    not shown here because this documentation was generated by the free version of MireDot. As such, not all features are supported.