Skip to content
Rob Smith edited this page Dec 21, 2014 · 4 revisions

Coding Standards

Current

  • Collector default configuration should be in the get_default_config method of the class
  • All collectors should verify before doing. For example, if the collector requires the existance of a file, check to verify that it exists and is readable before opening.
  • Unit tests are highly recommended
  • PEP-8
  • Documentation should be done docstr style at the start of the collector. This is how we generate the wiki
  • use small high-resolution units as default (such as bits or bytes). this gives you most options afterwards. note that graphite will show k/M/G etc prefixes by default if needed.
  • The use of positional arguments for functions is strongly discouraged.
Clone this wiki locally