Return-Path: X-Original-To: apmail-cloudstack-dev-archive@www.apache.org Delivered-To: apmail-cloudstack-dev-archive@www.apache.org Received: from mail.apache.org (hermes.apache.org [140.211.11.3]) by minotaur.apache.org (Postfix) with SMTP id 10F0D11C87 for ; Mon, 16 Jun 2014 07:27:31 +0000 (UTC) Received: (qmail 11545 invoked by uid 500); 16 Jun 2014 07:27:30 -0000 Delivered-To: apmail-cloudstack-dev-archive@cloudstack.apache.org Received: (qmail 11509 invoked by uid 500); 16 Jun 2014 07:27:30 -0000 Mailing-List: contact dev-help@cloudstack.apache.org; run by ezmlm Precedence: bulk List-Help: List-Unsubscribe: List-Post: List-Id: Reply-To: dev@cloudstack.apache.org Delivered-To: mailing list dev@cloudstack.apache.org Received: (qmail 11496 invoked by uid 99); 16 Jun 2014 07:27:30 -0000 Received: from nike.apache.org (HELO nike.apache.org) (192.87.106.230) by apache.org (qpsmtpd/0.29) with ESMTP; Mon, 16 Jun 2014 07:27:30 +0000 X-ASF-Spam-Status: No, hits=-2.3 required=5.0 tests=RCVD_IN_DNSWL_MED,SPF_HELO_PASS,SPF_PASS X-Spam-Check-By: apache.org Received-SPF: pass (nike.apache.org: domain of santhosh.edukulla@citrix.com designates 103.14.252.240 as permitted sender) Received: from [103.14.252.240] (HELO SMTP.CITRIX.COM.AU) (103.14.252.240) by apache.org (qpsmtpd/0.29) with ESMTP; Mon, 16 Jun 2014 07:27:27 +0000 X-IronPort-AV: E=Sophos;i="5.01,484,1400025600"; d="scan'208";a="7246504" Received: from sinaccessns.citrite.net (HELO SINPEX01CL03.citrite.net) ([10.151.60.9]) by sinpip01.citrite.net with ESMTP; 16 Jun 2014 07:27:00 +0000 Received: from SINPEX01CL02.citrite.net ([169.254.2.107]) by SINPEX01CL03.citrite.net ([169.254.3.175]) with mapi id 14.03.0181.006; Mon, 16 Jun 2014 15:27:00 +0800 From: Santhosh Edukulla To: "dev@cloudstack.apache.org" Subject: RE: Code Documentation Thread-Topic: Code Documentation Thread-Index: AQHPhZI9vQKQM297/02BKbohnc4TRptuntMAgAS0cTo= Date: Mon, 16 Jun 2014 07:26:59 +0000 Message-ID: References: , In-Reply-To: Accept-Language: en-US Content-Language: en-US X-MS-Has-Attach: X-MS-TNEF-Correlator: x-originating-ip: [10.151.46.1] Content-Type: text/plain; charset="us-ascii" Content-Transfer-Encoding: quoted-printable MIME-Version: 1.0 X-DLP: SIN1 X-Virus-Checked: Checked by ClamAV on apache.org Agreed, If we are referring to proper naming convention for self explaining= the code, yes.=20 But, still adding better and more comment strings or doc strings at appropr= iate places, is not going to harm i believe, it just compliments and aids b= etter understanding.=20 We used to add specific examples as well under comments to explain its use = and this can be used to auto generate the docs for easy reading thereafter.= Once in practice and visible, its effect will be more clear i believe. EX: Api documentation( I mean generate docs through added comments with ex= amples, returns, inputs etc ) can be generated like this and can easily doc= ument api usage with examples, today, api documentation is not much there i= believe. =20 Regards, Santhosh ________________________________________ From: rohityadav89@gmail.com [rohityadav89@gmail.com] on behalf of Rohit Ya= dav [bhaisaab@apache.org] Sent: Friday, June 13, 2014 10:59 AM To: dev@cloudstack.apache.org Subject: Re: Code Documentation On Wed, Jun 11, 2014 at 9:58 PM, Santhosh Edukulla < santhosh.edukulla@citrix.com> wrote: > Hi All, > > Many of code areas under CS, currently don't have enough documentation i > believe, we have few one liner comments at places. But, largely, was > missing at various code areas. > > We in one of our earlier project, used to enforce strictly a template for > comments\documentation for every new function added. These comments were > later retrieved automatically to build code documentation easily. This ge= ts > enforced during review itself, or otherwise review wont be accepted. It > will make the flow lot easier to understand some times i believe. > > Please add atleast basic description for every major > interface\class\function, description for input\output arguments for > individual entities. > IMO we should prefer writing code so it documents itself and we save ourselves from maintaining both code and comments. Regards. > > EX: Currently, for below we dont have any comments in general. > > public boolean shutdownNetwork(final long networkId, ReservationContext > context, boolean cleanupElements) > > > Regards, > Santhosh > >