Skip to content
This repository has been archived by the owner on Mar 30, 2018. It is now read-only.

refactor documentation #2150

Merged
merged 26 commits into from
Jul 15, 2016
Merged

refactor documentation #2150

merged 26 commits into from
Jul 15, 2016

Conversation

christo4ferris
Copy link
Contributor

@christo4ferris christo4ferris commented Jul 9, 2016

Description

refactor of docs to make the use of fabric components more accessible to mere mortals and without requiring that binaries and images be built by the user. This turned into a major refactoring exercise.

Motivation and Context

There were a number of things that needed to be addressed. First, there was lots of redundant documentation about how to start components etc that was either conflicting, or at the very least inconsistent. I attempted to refactor things so that there is setup, build, and operational separation.

More could be and should be done, but I don't think it makes sense to leave this outstanding any longer.

Fixes #2144

How Has This Been Tested?

I have gone through and tested the various directions personally.

Checklist:

  • I have added a Signed-off-by.
  • I have either added documentation to cover my changes or this change requires no new documentation.
  • I have either added unit tests to cover my changes or this change requires no new tests.
  • [] I have run golint and have fixed valid warnings in code I have added or modified. This tool generates false positives so you may choose to ignore some warnings. The goal is clean, consistent, and readable code.

Signed-off-by: Christopher Ferris chrisfer@us.ibm.com

initial refactor of devnet-setup to improve the organization and to
make the use of fabric more accessible to mere mortals without
requiring a build of the binaries and images.

Fixes: #2144

Signed-off-by: Christopher Ferris <chrisfer@us.ibm.com>

[ci skip]
@dco-bot
Copy link

dco-bot commented Jul 9, 2016

Hi christo4ferris,

Thanks for submitting this pull request!

I can confirm that the DCO1.1 sign-off has been included. It is okay to process this pull request.

dco-bot

@christo4ferris
Copy link
Contributor Author

I'm interested in initial feedback on my refactor of devnet-setup.md @joshhus @srderson @muralisrini

I am also interested in help with membership services usage. What was previously described is far from comprehensive or informative. It probably deserves a document of its own. I don't feel confident that I know enough (yet) about use of membersrvc to be writing the tutorial, but am willing to give it a go with some guidance.


This approach simply leverages the Docker images that the Hyperledger Fabric project publishes to [DockerHub](https://hub.docker.com/u/hyperledger/dashboard/) and either Docker commands or Docker Compose descriptions of the network one wishes to create.
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Link is 404 for me. https://hub.docker.com/u/hyperledger works. Maybe because I'm not logged in?

fix typo and broken link

Signed-off-by: Christopher Ferris <chrisfer@us.ibm.com>

[ci skip]
@srderson
Copy link
Contributor

srderson commented Jul 9, 2016

Looks better already. I'd suggest changing the name of the file from devnet-setup.md to Setting Up a Network.md as it will be more clear in the table of contents at http://hyperledger-fabric.readthedocs.io/en/latest/. Also, I would suggest moving out the the dev-setup folder to possibly just a Setup folder?

removed index.md from mkdocs.yml because it was a nothing burger
deleted index.md
created Setup directory
renamed SandboxSetup.md
Chaincode-setup.md and moved to Setup directory
renamed dev-setup/install.md build.md because it was really build
instructions
cleaned up build.md
moved dev-setup/JAVAChaincode.md to Setup
relevant changes in README.md to account for renaming of various files
removed TravisCI_Readme.md from mkdocs.yml because it is not relevant
to anyone but the Hyperledger CI team
moved TravisCI_Readme.md to top level directory
moved dev-setup/ca-setup.md to Setup
moved dev-setup/logging-control.md to Setup
made change in core.yml to account for relocated logging-control.md

Signed-off-by: Christopher Ferris <chrisfer@us.ibm.com>

[ci skip]
@christo4ferris
Copy link
Contributor Author

@srderson took your suggestion and it is becoming a bit more involved than I had planned originally. However, I am pretty pleased thus far with the progress. I have moved all of the setup to a Setup directory and I added that to the main index. Then I had to accommodate all the moving around which triggered a bit more refactoring.

@rameshthoomu is there a way to generate the mkdocs against a pull request or a personal repo? I'd like to see how this looks.

cleaned up ca-setup.md
use ‘Chaincode’ capitalization consistently in README
minor tweaks to devenv.md

Signed-off-by: Christopher Ferris <chrisfer@us.ibm.com>

[ci skip]
@rameshthoomu
Copy link
Contributor

@christo4ferris : mkdocs works only on Push notifications. yes, it is possible to setup on a personal repo.
I have pulled this PR and did some modifications to mkdocs.yaml and included index.md in docs folder (It is required for mkdocs to build the documentation). Below is the mkdocs generated document looks like on this PR.

http://chaincode-docs.readthedocs.io/en/latest/. I have observed 404 not found errors in couple places. Will send you the list of observations in sometime.

Just for reference, I have created draft version on ReadTheDocs Readme.md. https://github.com/rameshthoomu/fabric/blob/tools/docs/RTD.md

add links to TOC in protocol-specification.md

Signed-off-by: Christopher Ferris <chrisfer@us.ibm.com>

[ci skip]
fix broken internal links

Signed-off-by: Christopher Ferris <chrisfer@us.ibm.com>

[ci skip]
@christo4ferris
Copy link
Contributor Author

@rameshthoomu can you please investigate the jenkins "failure" - I used [ci skip] because just docs changed but Jenkins seems to think that skipping == fail. https://jenkins.hyperledger.org/job/fabric-github-verify-x86_64/557/console

@rameshthoomu
Copy link
Contributor

seems there is an open issue in Jenkins ci-skip plugin.. Created an issue in Jenkins JIRA.

Merge remote-tracking branch 'hyperledger/master' into issue-2144
fix up node idk doc README.md

Signed-off-by: Christopher Ferris <chrisfer@us.ibm.com>
@christo4ferris christo4ferris changed the title [WIP] refactor devnet-setup.md refactor documentation Jul 13, 2016
@christo4ferris
Copy link
Contributor Author

@hyperledger/fabric-maintainers @joshhus @nickgaski @mastersingh24 @smithbk I think that this is ready to merge. The docs still need some additional attention, but this hopefully makes things a bit better organized and hopefully up to date (worked on my machine;-)

@christo4ferris
Copy link
Contributor Author

check that... just had a discussion with @muralisrini about --peer-chaincodedev flag and I need to tweak the chaincode dev page a bit before we merge.

@christo4ferris christo4ferris changed the title refactor documentation [WIP] refactor documentation Jul 13, 2016
relocated and refactored the NodeSDK setup
reworked some of the chaincode setup docs
other cosmetic tweaks

Signed-off-by: Christopher Ferris <chrisfer@us.ibm.com>

[ci skip]
@christo4ferris christo4ferris changed the title [WIP] refactor documentation refactor documentation Jul 14, 2016
@christo4ferris
Copy link
Contributor Author

okay @hyperledger/fabric-maintainers @joshhus @nickgaski @mastersingh24 @smithbk I think that this is ready for review. Thanks.

@christo4ferris
Copy link
Contributor Author

Note that Jenkins failure is result of Jenkins bug with [ci skip]. There are no code changes in this PR (well, excepting to a comment in core.yaml that changed the reference to a markdown file).

fix broken link and mkdocs.yml

Signed-off-by: Christopher Ferris <chrisfer@us.ibm.com>

[ci skip]
more broken links fixed
minor cosmetic tweaks

Signed-off-by: Christopher Ferris <chrisfer@us.ibm.com>

[ci skip]
### Logging control

See [Logging Control](logging-control.md) for information on controlling
logging output from the `peer` and chaincodes.
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

" 'peer' and deployed chaincode." ?

address more reviewer feedback

Signed-off-by: Christopher Ferris <chrisfer@us.ibm.com>

[ci skip]
address remaining reviewer comments

Signed-off-by: Christopher Ferris <chrisfer@us.ibm.com>

[ci skip]
one last one?

Sigbed-off-by: Christopher Ferris <chrisfer@us.ibm.com>

[ci skip]
@christo4ferris
Copy link
Contributor Author

thanks @srderson @JonathanLevi @joshhus for the reviews!

@srderson
Copy link
Contributor

LGTM. Thanks for the reviews @JonathanLevi and @joshhus ! We can continue making improvements in future PRs.

@srderson srderson merged commit f7d9321 into hyperledger-archives:master Jul 15, 2016
@joshhus
Copy link
Contributor

joshhus commented Jul 15, 2016

I'm adding comments to the PR, much better method.

@joshhus
Copy link
Contributor

joshhus commented Jul 15, 2016

ah okay, next one.


For example, a peer that is also a validator would have a role value of 6.

When the CA is started for the first time, it will generate all of its required state (e.g., internal databases, CA certificates, blockchain keys, etc.) and writes this state to the directory given in its configuration. The certificates for the CA services (i.e., for the ECA, TCA, and TLSCA) are self-signed as the current default. If those certificates shall be signed by some root CA, this can be done manually by using the `*.priv` and `*.pub` private and public keys in the CA state directory, and replacing the self-signed `*.cert` certificates with root-signed ones. The next time the CA is launched, it will read and use those root-signed certificates.
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

"... of its required state attributes ..." ? or "states" ...
"... and write its state ..." or "states"

Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

@joshhus sorry, thought you were done... @JonathanLevi plans to take on ca-setup.md. Please feel free to submit PRs for any other changes.

@christo4ferris christo4ferris deleted the issue-2144 branch July 15, 2016 21:15
srderson pushed a commit that referenced this pull request Jul 18, 2016
align pub/fabric-peer.md with #2150

Fixes: #2242

Signed-off-by: Christopher Ferris <chrisfer@us.ibm.com>
@joshhus
Copy link
Contributor

joshhus commented Jul 21, 2016

I looked at some of the other files incl. /devenv.md and /build.md, and find nothing major - looks good. Minor nits to look out for moving fwd (can reduce translation flags down the road):

  • Vagrant and Docker and Behave always capitalized, unless as dir names, e.g.
  • When introducing a following code sample or list, e.g., end the lead-in sentence with a colon: (rather than nothing, or a period.)
  • Use "set up" two words when it's a verb; use "setup" one word when it's a noun.

lhaskins pushed a commit to lhaskins/fabric-archive that referenced this pull request Oct 14, 2016
* initial refactor of devnet-setup

initial refactor of devnet-setup to improve the organization and to
make the use of fabric more accessible to mere mortals without
requiring a build of the binaries and images.

Fixes: hyperledger-archives#2144

Signed-off-by: Christopher Ferris <chrisfer@us.ibm.com>

[ci skip]

* fix typo and 404

fix typo and broken link

Signed-off-by: Christopher Ferris <chrisfer@us.ibm.com>

[ci skip]

* this is turning into a major refactor of docs

removed index.md from mkdocs.yml because it was a nothing burger
deleted index.md
created Setup directory
renamed SandboxSetup.md
Chaincode-setup.md and moved to Setup directory
renamed dev-setup/install.md build.md because it was really build
instructions
cleaned up build.md
moved dev-setup/JAVAChaincode.md to Setup
relevant changes in README.md to account for renaming of various files
removed TravisCI_Readme.md from mkdocs.yml because it is not relevant
to anyone but the Hyperledger CI team
moved TravisCI_Readme.md to top level directory
moved dev-setup/ca-setup.md to Setup
moved dev-setup/logging-control.md to Setup
made change in core.yml to account for relocated logging-control.md

Signed-off-by: Christopher Ferris <chrisfer@us.ibm.com>

[ci skip]

* the docs refactor continues

cleaned up ca-setup.md
use ‘Chaincode’ capitalization consistently in README
minor tweaks to devenv.md

Signed-off-by: Christopher Ferris <chrisfer@us.ibm.com>

[ci skip]

* add links to TOC in protocol-specification.md

add links to TOC in protocol-specification.md

Signed-off-by: Christopher Ferris <chrisfer@us.ibm.com>

[ci skip]

* fix broken internal links

fix broken internal links

Signed-off-by: Christopher Ferris <chrisfer@us.ibm.com>

[ci skip]

* relocated and refactored the NodeSDK setup

relocated and refactored the NodeSDK setup
reworked some of the chaincode setup docs
other cosmetic tweaks

Signed-off-by: Christopher Ferris <chrisfer@us.ibm.com>

[ci skip]

* fix broken link and mkdocs.yml

fix broken link and mkdocs.yml

Signed-off-by: Christopher Ferris <chrisfer@us.ibm.com>

[ci skip]

* more broken links fixed

more broken links fixed
minor cosmetic tweaks

Signed-off-by: Christopher Ferris <chrisfer@us.ibm.com>

[ci skip]

* address typos in sdk/node/README.md

address typos in sdk/node/README.md and docs/Setup/NodeSDK-setup.md

Signed-off-by: Christopher Ferris <chrisfer@us.ibm.com>

[ci skip]

* fixed double space after period

fixed double space after period

Signed-off-by: Christopher Ferris <chrisfer@us.ibm.com>

[ci skip]

* fix we''ll typo

fix we''ll typo

Signed-off-by: Christopher Ferris <chrisfer@us.ibm.com>

* address review comments

address review comments

Signed-off-by: Christopher Ferris <chrisfer@us.ibm.com>

[ci skip]

* address additional review comments

address additional review comments

Signed-off-by: Christopher Ferris <chrisfer@us.ibm.com>

[ci skip]

* address grammar issue

address grammar issue

Signed-off-by: Christopher Ferris <chrisfer@us.ibm.com>

[ci skip]

* add SystemChaincode/noop.md

add SystemChaincode/noop.md

Signed-off-by: Christopher Ferris <chrisfer@us.ibm.com>

[ci skip]

* fix grammar nits

fix grammar nits

Signed-off-by: Christopher Ferris <chrisfer@us.ibm.com>

[ci skip]

* fix typos

fix typos

Signed-off-by: Christopher Ferris <chrisfer@us.ibm.com>

[ci skip]

* address review feedback from @joshhus

address review feedback from @joshhus

Signed-off-by: Christopher Ferris <chrisfer@us.ibm.com>

[ci skip]

* address more reviewer feedback

address more reviewer feedback

Signed-off-by: Christopher Ferris <chrisfer@us.ibm.com>

[ci skip]

* address remaining reviewer comments

address remaining reviewer comments

Signed-off-by: Christopher Ferris <chrisfer@us.ibm.com>

[ci skip]

* one last one?

one last one?

Sigbed-off-by: Christopher Ferris <chrisfer@us.ibm.com>

[ci skip]
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
None yet
Development

Successfully merging this pull request may close these issues.

docs for building dev env and setting up a network are very confusing
6 participants