Skip to contents

The TileDB-Cloud-R is in early-access release. We’re committed to ongoing multilingual support for TileDB Cloud API services, and TileDB-Cloud-R is a key part of that effort.

Manual and autogen layers

This package implements an R client to the TileDB Cloud REST service.

The bulk of the code is automatically generated via OpenAPI from the TileDB Cloud REST service API specification. This provides – by definition – thorough coverage of the API. On the other hand, there are fewer examples, code needs to be validated manually, and the style of the autogenerated code makes heavy use of R6 classes. Autogenerated functions and classes all start with uppercase letters, and can be found in the Reference section labeled as such.

Several key API entrypoints have a manual layer wrapping them. These files are R/manual_layer_*.R in the source code. Manually written functions all start with lowercase letters, and can be found in the Reference section labeled as such.

A few manually written functions are not exported by the package but do appear in the documentation. Their names start with a leading ., and they can be found in the Reference section labeled as such.

For example, using the manual-layer function tiledbcloud::array_info we can write simply:

tiledbcloud::array_info("namespace-goes-here", "arrayname-goes-here")

instead of what we would need to do using autogen-layer functions:

api.client.instance <- ApiClient$new(
  basePath="https://api.tiledb.com/v1",
  accessToken=Sys.getenv("TILEDB_REST_TOKEN"),
  username=Sys.getenv("TILEDB_REST_USERNAME"),
  password=Sys.getenv("TILEDB_REST_PASSWORD"))
# This in turn has its own manual-layer function wrapping it:
# api.client.instance <- get_api_client_instance()
array.api.instance <- ArrayApi$new(api.client.instance)
array.api.instance$GetArrayMetadata(namespace, arrayname)$toJSON()

Prioritization for development

  • Several key API entrypoints have a manual layer written; not all do.
  • Current efforts focus on user-defined functions (UDFs).
  • Some items in the API are easier to do in the UI – for example, writing array metadata/tags, favoriting, etc. These are lower-priority for manual-layer work.
  • As of late 2021, cloud-R task-graph work is deferred pending current infrastructural work.
  • But implementation is always demand-driven – please contact us as noted below!

Contact

Please visit https://tiledb.com/contact for full contact information including Forum, GitHub, Twitter, and Slack. Perhaps easiest is file an issue at https://github.com/TileDB-Inc/TileDB-Cloud-R/issues. We look forward to hearing from you!