Skip to content

Coding conventions and licensing

mkalam-alami edited this page Feb 21, 2012 · 3 revisions

Coding conventions and licensing

Java/Javascript

Same conventions as the default ones in Eclipse, except:

  • 4 spaces of indentation instead of a tabulation

(In Eclipse, can be changed by opening Windows > Preferences... then going in Java(Script) > Code style > Formatter ; there create a New one named "easysoa" and Edit it to select for Tab policy Spaces only", and click on OK)

About line endings

See http://help.github.com/line-endings/

XML

Same conventions as the default ones in Eclipse, except:

  • 2 spaces of indentation instead of a tabulation

(Can be changed in XML > XML Files > Editor, there select Indent using spaces instead of tabs and update the Indentation size as specified above, then click OK)

TODO checkstyle maven plugin

Licensing - The short way

Copy/paste this header in every java source file and this header in every node.js source file, and replace PROJECT_NAME by the appropriate top level project name (EasySOA Common, EasySOA Registry, EasySOA Proxy, EasySOA Web) or sample name (EasySOA Samples - PureAirFlowers...).

And maintain contributor names in each source code file, for instance in java by using @author comment tags.

Licensing - The long way

Some utilities to do that in bulk are in easysoa-distribution/licenses.

Top level and samples projects contain full licensing information :

  • a LICENSE file filled with the appropriate license text
  • if it is a Java project, its root Maven POM file is filled with the appropriate licensing information

Here are a few licensing guidelines :

  • FraSCAti is under the LGPL license, which is common for OW2 middleware. Therefore middleware code using FraSCAti will be licensed under the LGPL as well. There is a small amount of other middleware code (for instance samples only relying on Apache-licensed CXF), so in order to stay simple it will be licensed the same way for now.
  • Nuxeo is mostly under the LGPL license. Therefore middleware code using Nuxeo will be licensed under the LGPL as well. Nuxeo's Core is moving to the EPL & Eclipse, which might at some point prove interesting by allowing to do the same at the price of more segmented library dependencies.
  • node.js core and most community libraries are under the MIT license, which is appropriate for infrastructure written in a script language. Therefore code written for the node.js platform can be licensed under the MIT license as well.

Licenses of a few dependencies :

  • LGPL-licensed : FraSCAti, Nuxeo, SOAPUI, Sonar (prospective)
  • Apache-licensed : CXF, Jetty
  • BSD-licensed : EasyWSDL
  • EPL-licensed : Nuxeo Core / Eclipse EPR "Apricot", Jetty
  • MIT-licensed : node.js, connect
Clone this wiki locally