mirror of
https://github.com/bigchaindb/bigchaindb.git
synced 2024-10-13 13:34:05 +00:00
Merge pull request #1894 from bigchaindb/issue/1875/json-schema-validation-is-ipdb-protocol
Removed appendix page w/ tx JSON Schema files & updated transaction-m…
This commit is contained in:
commit
1de7e55ac3
@ -10,6 +10,16 @@ The aim is to provide:
|
|||||||
[implementations](http://json-schema.org/implementations.html) written in
|
[implementations](http://json-schema.org/implementations.html) written in
|
||||||
different languages)
|
different languages)
|
||||||
|
|
||||||
|
## Sources
|
||||||
|
|
||||||
|
The file defining the JSON Schema for votes (`vote.yaml`) is BigchainDB-specific.
|
||||||
|
|
||||||
|
The files defining the JSON Schema for transactions (`transaction_*.yaml`)
|
||||||
|
are copied from the [IPDB Protocol](https://github.com/ipdb/ipdb-protocol).
|
||||||
|
If you want to add a new version, you must add it to the IPDB Protocol first.
|
||||||
|
(You can't change existing versions. Those were used to validate old transactions
|
||||||
|
and are needed to re-check those transactions.)
|
||||||
|
|
||||||
## Learn about JSON Schema
|
## Learn about JSON Schema
|
||||||
|
|
||||||
A good resource is [Understanding JSON Schema](http://spacetelescope.github.io/understanding-json-schema/index.html).
|
A good resource is [Understanding JSON Schema](http://spacetelescope.github.io/understanding-json-schema/index.html).
|
||||||
|
@ -28,5 +28,4 @@ Appendices
|
|||||||
install-with-lxd
|
install-with-lxd
|
||||||
run-with-vagrant
|
run-with-vagrant
|
||||||
run-with-ansible
|
run-with-ansible
|
||||||
tx-yaml-files
|
|
||||||
vote-yaml
|
vote-yaml
|
||||||
|
@ -1,34 +0,0 @@
|
|||||||
The Transaction Schema Files
|
|
||||||
============================
|
|
||||||
|
|
||||||
BigchainDB checks all :ref:`transactions <The Transaction Model>`
|
|
||||||
against a formal schema
|
|
||||||
defined in some JSON Schema files.
|
|
||||||
The contents of those files are copied below.
|
|
||||||
To understand those contents
|
|
||||||
(i.e. JSON Schema), check out
|
|
||||||
`"Understanding JSON Schema"
|
|
||||||
<https://spacetelescope.github.io/understanding-json-schema/index.html>`_
|
|
||||||
by Michael Droettboom or
|
|
||||||
`json-schema.org <http://json-schema.org/>`_.
|
|
||||||
|
|
||||||
|
|
||||||
transaction_v1.0.yaml
|
|
||||||
---------------------
|
|
||||||
|
|
||||||
.. literalinclude:: ../../../../bigchaindb/common/schema/transaction_v1.0.yaml
|
|
||||||
:language: yaml
|
|
||||||
|
|
||||||
|
|
||||||
transaction_create_v1.0.yaml
|
|
||||||
----------------------------
|
|
||||||
|
|
||||||
.. literalinclude:: ../../../../bigchaindb/common/schema/transaction_create_v1.0.yaml
|
|
||||||
:language: yaml
|
|
||||||
|
|
||||||
|
|
||||||
transaction_transfer_v1.0.yaml
|
|
||||||
------------------------------
|
|
||||||
|
|
||||||
.. literalinclude:: ../../../../bigchaindb/common/schema/transaction_transfer_v1.0.yaml
|
|
||||||
:language: yaml
|
|
@ -69,6 +69,14 @@ The Transaction Schema
|
|||||||
----------------------
|
----------------------
|
||||||
|
|
||||||
BigchainDB checks all transactions (JSON documents)
|
BigchainDB checks all transactions (JSON documents)
|
||||||
against a formal schema defined in :ref:`some JSON Schema files
|
against a formal schema defined
|
||||||
(copied verbatim into the Appendices)
|
in some `JSON Schema <http://json-schema.org/>`_ files.
|
||||||
<The Transaction Schema Files>`.
|
Those files are part of the IPDB Protocol.
|
||||||
|
Their official source is the ``tx_schema/`` directory
|
||||||
|
in the `ipdb/ipdb-protocol repository on GitHub
|
||||||
|
<https://github.com/ipdb/ipdb-protocol>`_,
|
||||||
|
but BigchainDB Server uses copies of those files;
|
||||||
|
those copies can be found
|
||||||
|
in the ``bigchaindb/common/schema/`` directory
|
||||||
|
in the `bigchaindb/bigchaindb repository on GitHub
|
||||||
|
<https://github.com/bigchaindb/bigchaindb>`_.
|
||||||
|
Loading…
x
Reference in New Issue
Block a user