-
Notifications
You must be signed in to change notification settings - Fork 3
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Documentation: Serve docs via https://cratedb-toolkit.readthedocs.io/
- Loading branch information
Showing
15 changed files
with
388 additions
and
7 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,29 @@ | ||
# .readthedocs.yml | ||
# Read the Docs configuration file | ||
|
||
# Details | ||
# - https://docs.readthedocs.io/en/stable/config-file/v2.html | ||
|
||
# Required | ||
version: 2 | ||
|
||
build: | ||
os: "ubuntu-22.04" | ||
tools: | ||
python: "3.11" | ||
|
||
python: | ||
install: | ||
- method: pip | ||
path: . | ||
extra_requirements: | ||
- docs | ||
|
||
sphinx: | ||
configuration: doc/conf.py | ||
builder: html | ||
fail_on_warning: true | ||
|
||
# Optionally build your docs in additional formats such as PDF | ||
#formats: | ||
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,4 +1,4 @@ | ||
# Changes for cratedb-toolkit | ||
# Changelog | ||
|
||
|
||
## Unreleased | ||
|
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1 @@ | ||
/_build |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,20 @@ | ||
# Minimal makefile for Sphinx documentation | ||
# | ||
|
||
# You can set these variables from the command line, and also | ||
# from the environment for the first two. | ||
SPHINXOPTS ?= | ||
SPHINXBUILD ?= sphinx-build | ||
SOURCEDIR = . | ||
BUILDDIR = _build | ||
|
||
# Put it first so that "make" without argument is like "make help". | ||
help: | ||
@$(SPHINXBUILD) -M help "$(SOURCEDIR)" "$(BUILDDIR)" $(SPHINXOPTS) $(O) | ||
|
||
.PHONY: help Makefile | ||
|
||
# Catch-all target: route all unknown targets to Sphinx using the new | ||
# "make mode" option. $(O) is meant as a shortcut for $(SPHINXOPTS). | ||
%: Makefile | ||
@$(SPHINXBUILD) -M $@ "$(SOURCEDIR)" "$(BUILDDIR)" $(SPHINXOPTS) $(O) |
Empty file.
Empty file.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,3 +1,7 @@ | ||
--- | ||
orphan: true | ||
--- | ||
|
||
# Bugs | ||
|
||
## | ||
|
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1 @@ | ||
../CHANGES.md |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,117 @@ | ||
# Configuration file for the Sphinx documentation builder. | ||
# | ||
# For the full list of built-in configuration values, see the documentation: | ||
# https://www.sphinx-doc.org/en/master/usage/configuration.html | ||
|
||
# -- Project information ----------------------------------------------------- | ||
# https://www.sphinx-doc.org/en/master/usage/configuration.html#project-information | ||
|
||
project = "cratedb-toolkit" | ||
copyright = "2023-2024, The CrateDB Developers" | ||
author = "The CrateDB Developers" | ||
|
||
# -- General configuration --------------------------------------------------- | ||
# https://www.sphinx-doc.org/en/master/usage/configuration.html#general-configuration | ||
|
||
extensions = [ | ||
"myst_parser", | ||
"sphinx_copybutton", | ||
"sphinx_design", | ||
"sphinx.ext.intersphinx", | ||
"sphinx.ext.todo", | ||
"sphinx.ext.ifconfig", | ||
"sphinxcontrib.mermaid", | ||
"sphinxext.opengraph", | ||
] | ||
|
||
templates_path = ["_templates"] | ||
exclude_patterns = ["_build", "Thumbs.db", ".DS_Store"] | ||
|
||
|
||
# -- Options for HTML output ------------------------------------------------- | ||
# https://www.sphinx-doc.org/en/master/usage/configuration.html#options-for-html-output | ||
|
||
# The theme to use for HTML and HTML Help pages. See the documentation for | ||
# a list of builtin themes. | ||
# | ||
html_theme = "furo" | ||
|
||
# Theme options are theme-specific and customize the look and feel of a theme | ||
# further. For a list of options available for each theme, see the | ||
# documentation. | ||
|
||
html_title = "CrateDB Toolkit" | ||
|
||
html_theme_options = { | ||
"sidebar_hide_name": False, | ||
# https://github.com/pradyunsg/furo/blob/main/src/furo/assets/styles/variables/_colors.scss | ||
# "light_logo": "cratedb-toolkit-logo-light.svg", | ||
# "dark_logo": "cratedb-toolkit-dark.svg", | ||
} | ||
|
||
# Add any paths that contain custom static files (such as style sheets) here, | ||
# relative to this directory. They are copied after the builtin static files, | ||
# so a file named "default.css" will overwrite the builtin "default.css". | ||
html_static_path = ["_static"] | ||
|
||
# Custom sidebar templates, must be a dictionary that maps document names | ||
# to template names. | ||
# | ||
# The default sidebars (for documents that don't match any pattern) are | ||
# defined by theme itself. Builtin themes are using these templates by | ||
# default: ``['localtoc.html', 'relations.html', 'sourcelink.html', | ||
# 'searchbox.html']``. | ||
# | ||
# html_sidebars = {} | ||
|
||
html_show_sourcelink = True | ||
|
||
|
||
# -- Intersphinx ---------------------------------------------------------- | ||
|
||
intersphinx_mapping = { | ||
"influxio": ("https://influxio.readthedocs.io/", None), | ||
} | ||
linkcheck_ignore = [] | ||
|
||
# Disable caching remote inventories completely. | ||
# http://www.sphinx-doc.org/en/stable/ext/intersphinx.html#confval-intersphinx_cache_limit | ||
# intersphinx_cache_limit = 0 | ||
|
||
|
||
# -- Extension configuration ------------------------------------------------- | ||
|
||
sphinx_tabs_valid_builders = ["linkcheck"] | ||
todo_include_todos = True | ||
|
||
# Configure sphinx-copybutton | ||
copybutton_remove_prompts = True | ||
copybutton_line_continuation_character = "\\" | ||
copybutton_prompt_text = r">>> |\.\.\. |\$ |sh\$ |PS> |cr> |mysql> |In \[\d*\]: | {2,5}\.\.\.: | {5,8}: " | ||
copybutton_prompt_is_regexp = True | ||
|
||
# Configure sphinxext-opengraph | ||
ogp_site_url = "https://cratedb-toolkit.readthedocs.io/" | ||
ogp_enable_meta_description = True | ||
# ogp_image = "http://example.org/image.png" | ||
# ogp_description_length = 300 | ||
|
||
|
||
# -- Options for MyST ------------------------------------------------- | ||
|
||
myst_heading_anchors = 3 | ||
myst_enable_extensions = [ | ||
"attrs_block", | ||
"attrs_inline", | ||
"colon_fence", | ||
"deflist", | ||
"fieldlist", | ||
"html_admonition", | ||
"html_image", | ||
"linkify", | ||
"replacements", | ||
"strikethrough", | ||
"substitution", | ||
"tasklist", | ||
] | ||
myst_substitutions = {} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,130 @@ | ||
(index)= | ||
# CrateDB Toolkit | ||
|
||
[![CI][badge-tests]][project-tests] | ||
[![Coverage Status][badge-coverage]][project-codecov] | ||
[![Documentation][badge-documentation]][project-documentation] | ||
[![License][badge-license]][project-license] | ||
[![Downloads per month][badge-downloads-per-month]][project-downloads] | ||
|
||
[![Supported Python versions][badge-python-versions]][project-pypi] | ||
[![Status][badge-status]][project-pypi] | ||
[![Package version][badge-package-version]][project-pypi] | ||
|
||
» [Documentation] | ||
| [Changelog] | ||
| [PyPI] | ||
| [Issues] | ||
| [Source code] | ||
| [License] | ||
|
||
|
||
```{include} readme.md | ||
:start-line: 22 | ||
``` | ||
|
||
## About | ||
|
||
This software package includes a range of modules and subsystems to work | ||
with CrateDB and CrateDB Cloud efficiently. | ||
|
||
You can use CrateDB Toolkit to run data I/O procedures and automation tasks | ||
of different kinds around CrateDB and CrateDB Cloud. It can be used both as | ||
a standalone program, and as a library. | ||
|
||
It aims for [DWIM]-like usefulness and [UX], and provides CLI and HTTP | ||
interfaces, and others. | ||
|
||
|
||
## Features | ||
|
||
- **Capable:** Connect to the InfluxDB HTTP API, or read from an InfluxDB | ||
TSM data directory directly. | ||
|
||
- **Versatile:** Use it as a command-line program, pipeline element, | ||
or as a library within your own applications. | ||
|
||
- **Polyglot:** Support I/O operations between InfluxDB, any SQL database | ||
supported by SQLAlchemy, file formats supported by pandas/Dask, and | ||
the native InfluxDB line protocol (ILP), on both import and export | ||
directions. | ||
|
||
|
||
## Synopsis | ||
|
||
```shell | ||
|
||
# Export from API to database. | ||
influxio copy \ | ||
"http://example:token@localhost:8086/testdrive/demo" \ | ||
"sqlite://export.sqlite?table=demo" | ||
|
||
# Export from data directory to line protocol format. | ||
influxio copy \ | ||
"file:///path/to/influxdb/engine?bucket-id=372d1908eab801a6&measurement=demo" \ | ||
"file://export.lp" | ||
``` | ||
|
||
|
||
## Documentation | ||
|
||
Please visit the [README](#readme) document to learn what you can do with | ||
the `influxio` package. Effectively, it is all about the `influxio copy` | ||
primitive, which accepts a range of variants on its `SOURCE` and `TARGET` | ||
arguments, in URL formats. | ||
|
||
|
||
## Development | ||
|
||
Contributions are very much welcome. Please visit the [](#sandbox) | ||
documentation to learn about how to spin up a sandbox environment on your | ||
workstation, or create a [ticket][Issues] to report a bug or share an idea | ||
about a possible feature. | ||
|
||
|
||
|
||
```{toctree} | ||
:maxdepth: 3 | ||
:caption: Documentation | ||
:hidden: | ||
install | ||
retention | ||
``` | ||
|
||
```{toctree} | ||
:maxdepth: 1 | ||
:caption: Workbench | ||
:hidden: | ||
sandbox | ||
changes | ||
backlog | ||
``` | ||
|
||
|
||
|
||
[Changelog]: https://github.com/crate-workbench/cratedb-toolkit/blob/main/CHANGES.md | ||
[development documentation]: https://cratedb-toolkit.readthedocs.io/sandbox.html | ||
[Documentation]: https://cratedb-toolkit.readthedocs.io/ | ||
[Issues]: https://github.com/crate-workbench/cratedb-toolkit/issues | ||
[License]: https://github.com/crate-workbench/cratedb-toolkit/blob/main/LICENSE | ||
[PyPI]: https://pypi.org/project/cratedb-toolkit/ | ||
[Source code]: https://github.com/crate-workbench/cratedb-toolkit | ||
[cratedb-toolkit]: https://cratedb-toolkit.readthedocs.io/ | ||
[influxio]: https://influxio.readthedocs.io/ | ||
|
||
[badge-coverage]: https://codecov.io/gh/crate-workbench/cratedb-toolkit/branch/main/graph/badge.svg | ||
[badge-documentation]: https://img.shields.io/readthedocs/cratedb-toolkit | ||
[badge-downloads-per-month]: https://pepy.tech/badge/cratedb-toolkit/month | ||
[badge-license]: https://img.shields.io/github/license/crate-workbench/cratedb-toolkit.svg | ||
[badge-package-version]: https://img.shields.io/pypi/v/cratedb-toolkit.svg | ||
[badge-python-versions]: https://img.shields.io/pypi/pyversions/cratedb-toolkit.svg | ||
[badge-status]: https://img.shields.io/pypi/status/cratedb-toolkit.svg | ||
[badge-tests]: https://github.com/crate-workbench/cratedb-toolkit/actions/workflows/main.yml/badge.svg | ||
[project-codecov]: https://codecov.io/gh/crate-workbench/cratedb-toolkit | ||
[project-documentation]: https://cratedb-toolkit.readthedocs.io/ | ||
[project-downloads]: https://pepy.tech/project/cratedb-toolkit/ | ||
[project-license]: https://github.com/crate-workbench/cratedb-toolkit/blob/main/LICENSE | ||
[project-pypi]: https://pypi.org/project/cratedb-toolkit | ||
[project-tests]: https://github.com/crate-workbench/cratedb-toolkit/actions/workflows/main.yml |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,17 @@ | ||
(install)= | ||
# Install | ||
|
||
Install package. | ||
```shell | ||
pip install --upgrade cratedb-toolkit | ||
``` | ||
|
||
Verify installation. | ||
```shell | ||
cratedb-toolkit --version | ||
``` | ||
|
||
Run with Docker. | ||
```shell | ||
docker run --rm "ghcr.io/crate-workbench/cratedb-toolkit" cratedb-toolkit --version | ||
``` |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,35 @@ | ||
@ECHO OFF | ||
|
||
pushd %~dp0 | ||
|
||
REM Command file for Sphinx documentation | ||
|
||
if "%SPHINXBUILD%" == "" ( | ||
set SPHINXBUILD=sphinx-build | ||
) | ||
set SOURCEDIR=. | ||
set BUILDDIR=_build | ||
|
||
%SPHINXBUILD% >NUL 2>NUL | ||
if errorlevel 9009 ( | ||
echo. | ||
echo.The 'sphinx-build' command was not found. Make sure you have Sphinx | ||
echo.installed, then set the SPHINXBUILD environment variable to point | ||
echo.to the full path of the 'sphinx-build' executable. Alternatively you | ||
echo.may add the Sphinx directory to PATH. | ||
echo. | ||
echo.If you don't have Sphinx installed, grab it from | ||
echo.https://www.sphinx-doc.org/ | ||
exit /b 1 | ||
) | ||
|
||
if "%1" == "" goto help | ||
|
||
%SPHINXBUILD% -M %1 %SOURCEDIR% %BUILDDIR% %SPHINXOPTS% %O% | ||
goto end | ||
|
||
:help | ||
%SPHINXBUILD% -M help %SOURCEDIR% %BUILDDIR% %SPHINXOPTS% %O% | ||
|
||
:end | ||
popd |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1 @@ | ||
../README.md |
Oops, something went wrong.