Uploaded image for project: 'CDAP'
  1. CDAP
  2. CDAP-1976

All examples need to follow the same pattern

    Details

    • Type: Bug
    • Status: Resolved
    • Priority: Major
    • Resolution: Fixed
    • Affects Version/s: 2.8.0
    • Fix Version/s: 3.1.0
    • Component/s: Docs
    • Labels:
    • Rank:
      1|hzyq13:

      Description

      All the examples (and guides and tutorials) should follow the same pattern for how they are written, especially with regard to code. They should all have a portion at the start that describes the conventions, and then follows from there.

      We should avoid repeating Windows commands, and instead direct users to substitute ".bat" instead.

      Instead of

      $ <path-to-CDAP-SDK>/bin/cdap-cli.sh get flow status Wise.WiseFlow
      

      we should use

      $ ./bin/cdap-cli.sh get flow status Wise.WiseFlow
      

      All curl examples should include

      $ curl -w'\n' localhost:10000/v3/namespaces/default/streams/logEventStream
      

      so that when they run, the user gets clean output that is easy to read and follow. They should not have to hunt for the results because they were run into the following command-prompt.

      A style guide for examples should be added to the wiki.

        Attachments

          Activity

            People

            • Assignee:
              John John Jackson
              Reporter:
              John John Jackson
            • Votes:
              0 Vote for this issue
              Watchers:
              2 Start watching this issue

              Dates

              • Created:
                Updated:
                Resolved: