Dev:Versions: Difference between revisions
[unchecked revision] | [unchecked revision] |
(Content copied from Assemblas Wiki page "Versioning_Policy", some changes for better integration of both parts) |
m (Category added) |
||
Line 113: | Line 113: | ||
</railml> | </railml> | ||
</syntaxhighlight> | </syntaxhighlight> | ||
[[Category:GeneralDescription]] |
Revision as of 14:37, 17 October 2012
Release Policy
Major Release
- Reason
- Commited changes have affects on XML-instance files and should be announced in advance in corresponding railML-newsgroups.
- Decision
- Tagging a major release after railML conferences' consensus
- Version number
- Increasing first digit, e.g.
version="2.0"
- Namespace
- Changing the year in the namespace string, e.g.
xmlns="http://www.railml.org/schemas/2009"
Minor Release
- Reason
- Commited changes have no affects on XML-instance files, but on other coordinators' XSD-schema files.
Commits of new elements, types and/or attributes are allowed. - Decision
- Tagging a minor release after railML coordinators' consensus
- Version number
- Increasing second digit, e.g.
version="2.1"
- Namespace
- Up to now the year changed in the namespace string. Maybe this policy changes from railML 3.0 on the way it was originally intended: not changing the namespace string. e.g.
xmlns="http://www.railml.org/schemas/2011"
Corrigendum
- Reason
- Corrigendum commits and cosmetic changes with no affect on XML-instance files are allowed.
- Decision
- Tagging a corrigendum after railML coordinators' consensus
- Version number
- Increasing third digit, e.g.
version="2.0.1"
- Namespace
- No influence on the namespace string, e.g.
xmlns="http://www.railml.org/schemas/2009"
Unofficial/Developers Version
- Reason
- Depending on the current policy only Subversion commits for corrigendum, minor or major releases are checked into the repository for further feature development.
- Decision
- User requirements from the forum are kept in the railML Trac tickets. The railML coordinators prioritize them, code each single topic in a railMLish way and commit changed files into the Subversion repository. See also Officially released versus developer version
- Version number
- Each atomic Subversion commit is tagged with the increasing Subversion number. The last official version number is expanded by the Subversion release number. e.g.
version="2.1r460"
- Namespace
- No influence on the namespace string, e.g.
xmlns="http://www.railml.org/schemas/2011"
Version numbers and corresponding namespaces
How to describe the version number of a railML file? Or to find out which version a railML file belongs to?
Version numbers
You will find a version attribute in the railML root element <railml> as well as in the root elements of the sub-schemas as <infrastructure>, <rollingstock>, <timetable>. This attribute is to be used for the version number of the railML schema the XML file is based on.
Major, minor and corrigendum version are separated by a dot, the release number is separated by r. Corrigendum and release number are optional:
<major version>.<minor version>[.<corrigendum>][r<release number>]
The following rules apply:
- The release number shall be omitted if a railML file is based on an "official released railML version". This applies to railML 2.0r270 and 2.1r409 which both shall be given as 2.0 respectively 2.1 without release number.
- The release number shall be considered mandatory in all other cases, e. g. if it is "an unofficial release version" but an intermediate. For more information on the relevance of intermediate versions see Officially released versus developer version.
- The attribute version of the root element of the railML file shall be considered mandatory. If the root element of the railML file is <railml>, the attribute version of the subsequent elements <infrastructure>, <rollingstock>, <timetable> are optional. If they are used, they have to be identical to the version of <railml>.
- The corrigendum release number is mandatory, if the release is tagged this way. Otherwise it shall be ommited.
This official railML version number should not be confused with an implementation dependent software version in the metadata elements dc:format and/or dc:identifier.
railML namespace declarations
As above mentioned the XML namespace does also change with the railML version. The following table shows this relationship for all official railML versions.
railML version number | railML namespace string | remote schema location |
---|---|---|
1.0 | no namespace | different schema locations for sub-schemas |
1.1 | http://www.railml.org/schemas/2007 | http://www.railml.org/schemas/2007/railML-1.1/railML.xsd |
2.0 | http://www.railml.org/schemas/2009 | http://www.railml.org/schemas/2009/railML-2.0/railML.xsd |
2.1 | http://www.railml.org/schemas/2011 | http://www.railml.org/schemas/2011/railML-2.1/railML.xsd |
The XML file should declare the same XML namespace (identical string) as defined by its corresponding XML Schema. For general information about namespaces see Defining namespaces and validating railML files.
A railML file based on an intermediate release with remote schema location shall refer to the Subversion repository of the release. This is
http://trac.assembla.com/railML/export/<release number>/trunk/schema/railML.xsd
Examples
railML file of official released railML version 2.0, remote schema location:
<?xml version="1.0" encoding="UTF-8"?> <railml version="2.0" xmlns="http://www.railml.org/schemas/2009" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xsi:schemaLocation="http://www.railml.org/schemas/2009 http://www.railml.org/schemas/2009/railML-2.0/railML.xsd"> ... </railml>
railML file of intermediate release #416 (between official releases 2.1 and 2.2) , remote schema location:
<?xml version="1.0" encoding="UTF-8"?> <railml version="2.1r416" xmlns="http://www.railml.org/schemas/2011" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xsi:schemaLocation="http://www.railml.org/schemas/2011 http://trac.assembla.com/railML/export/416/trunk/schema/railML.xsd"> ... </railml>