1 .. This work is licensed under a Creative Commons Attribution 4.0
2 .. International License. http://creativecommons.org/licenses/by/4.0
3 .. Copyright 2017 AT&T Intellectual Property. All rights reserved.
8 This guide describes how to create documentation for the Open Network
9 Automation Platform (ONAP). ONAP projects create a variety of
10 content depending on the nature of the project. For example projects
11 delivering a platform component may have different types of content than
12 a project that creates libraries for a software development kit.
13 The content from each project may be used together as a reference for
14 that project and/or be used in documents that are tailored to a specific
15 user audience and tasks they are performing.
17 Much of the content in this document is derived from similar
18 documentation processes used in other Linux Foundation
19 Projects including OPNFV and Open Daylight.
21 When is documentation required?
22 ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
23 All ONAP project contributions should have corresponding documentation.
24 This includes all new features and changes to features that impact users.
26 How do I create ONAP documentation?
27 ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
28 ONAP documentation is written in ReStructuredText_ (an easy-to-read,
29 what-you-see-is-what-you-get, plain text markup syntax). The process for
30 creating ONAP documentation and what documents are required are
31 described in later sections of this Developer Documentation Guide.
33 .. _ReStructuredText: http://docutils.sourceforge.net/rst.html
35 Why reStructuredText/Sphinx?
36 ~~~~~~~~~~~~~~~~~~~~~~~~~~~~
38 In the past, standard documentation methods included ad-hoc Word documents,
39 PDFs, poorly organized Wikis, and other, often closed, tools like
40 Adobe FrameMaker. The rise of DevOps, Agile, and Continuous Integration,
41 however, created a paradigm shift for those who care about documentation
44 1. Documentation must be tightly coupled with code/product releases.
45 In many cases, particularly with open-source products, many different
46 versions of the same code can be installed in various production
47 environments. DevOps personnel must have access to the correct version
50 2. Resources are often tight, volunteers scarce. With a large software base
51 like ONAP, a small team of technical writers, even if they are also
52 developers, cannot keep up with a constantly changing, large code base.
53 Therefore, those closest to the code should document it as best they can,
54 and let professional writers edit for style, grammar, and consistency.
56 Plain-text formatting syntaxes, such as reStructuredText, Markdown,
57 and Textile, are a good choice for documentation because:
59 a. They are editor agnostic
61 b. The source is nearly as easy to read as the rendered text
63 c. Documentation can be treated exactly as source code is (e.g. versioned,
64 diff'ed, associated with commit messages that can be included
67 d. Shallow learning curve
69 The documentation team chose reStructuredText largely because of Sphinx,
70 a Python-based documentation build system, which uses reStructuredText
71 natively. In a code base as large as ONAP's, cross-referencing between
72 component documentation was deemed critical. Sphinx and reStructuredText
73 have built-in functionality that makes collating and cross-referencing
74 component documentation easier.
76 Which documents should go where?
77 ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
78 A TSC Vote (2020, Feb. 19) approved the following usage policy:
80 **DEVELOPER WIKI** is used for ONAP release, project, subcommitee and
81 development related content, e.g.
83 - project management (meetings, plans, milestones, members, ...)
84 - project specific development guides
85 - ongoing activities and discussions
86 - ONAP community event documentation
88 **READ THE DOCS** is used for all formal ONAP E2E and component documentation,
91 - ONAP overview, architecture, API
92 - ONAP developer guides (e.g. Documentation guide)
93 - ONAP user guides (E2E)
94 - ONAP component guides, release notes
95 - ONAP administration/operations guides
96 - ONAP use-case description and usage
100 The more tightly coupled the documentation is to a particular version
101 of the code, the more likely it is that it should be stored with the
102 code in reStructuredText.
104 The doc team encourages component teams to store as much documentation
105 as reStructuredText as possible because:
107 1. It is easier to edit component documentation for grammar,
108 spelling, clarity, and consistency.
110 2. A consistent formatting syntax across components will allow
111 flexibility in producing different kinds of output.
113 3. It is easier to re-organize the documentation.
115 4. Wiki articles tend to grow in size and not maintained making it hard
116 to find current information.
120 All documentation for project repositories should be structured and stored
121 in or below `<your_project_repo>/docs/` directory as Restructured Text.
122 ONAP jenkins jobs that verify and merge documentation are triggered by
123 RST file changes in the top level docs directory and below.
127 All contributions to the ONAP project are done in accordance with the
128 ONAP licensing requirements. Documentation in ONAP is contributed
129 in accordance with the `Creative Commons 4.0 <https://creativecommons.org/licenses/by/4.0/>`_ license.
130 All documentation files need to be licensed using the text below.
131 The license may be applied in the first lines of all contributed RST
136 .. This work is licensed under a Creative Commons Attribution 4.0 International License.
137 .. http://creativecommons.org/licenses/by/4.0
138 .. Copyright YEAR ONAP or COMPANY or INDIVIDUAL
140 These lines will not be rendered in the html and pdf files.
142 When there are subsequent, significant contributions to a source file
143 from a different contributor, a new copyright line may be appended
144 after the last existing copyright line.
149 When referencing versions of documentation a Read The Docs the following
150 URL conventions should be used
152 +----------------------------------+----------------------------------------+
153 | URL | To Refer to |
154 +==================================+========================================+
155 | docs.onap.org | Most recent approved named release |
156 +----------------------------------+----------------------------------------+
157 | docs.onap.org/en/latest | Latest master branch all projects |
158 +----------------------------------+----------------------------------------+
159 | docs.onap.org/en/*named release* | An approved name release eg. amsterdam |
160 +----------------------------------+----------------------------------------+