Meego Wiki
Views

Quality/QA-tools/OTS/UserDocumentation/Migration 0.1 0.8

From MeeGo wiki
< Quality | QA-tools | OTS | UserDocumentation
Revision as of 13:43, 3 February 2011 by Tvainio (Talk | contribs)
(diff) ← Older revision | Latest revision (diff) | Newer revision → (diff)
Jump to: navigation, search

Contents

OTS migration from version 0.1.x to 0.8.x

OTS Server

  • First backup all old configurations
/etc/ots-server.ini
/opt/ots.sqlite
/etc/ots_qareports_plugin.conf
Your extension configurations
  • Remove 0.1.x version
sudo apt-get purge python-ots-common python-ots-server python-server python-ots-qareports-plugin python-ots-tools

or

sudo rm -fr /usr/local/lib/python2.6/dist-packages/ots*

or

sudo rm -fr /usr/lib/python2.6/site-packages/ots*

Configuring 0.8 to match 0.1

Email

  • It uses the server's configuration file
/etc/ots_server.ini
  • In 0.1 these settings were defined in your extension config. Copy values from there.
  • If you want to use your 0.1 message_body, remove line break marks '\n' from the string and put all text between the """ -marks.

Default SW configuration and SW products

  • In 0.8 default SW configurations and SW products are defined in the server's configuration.
/etc/ots_server.ini
  • In 0.1 these settings were defined in your extension config.
  • Add one or several SW products under the 'swproducts' section.
[swproducts]
  [[meego_n900]]
    timeout = 60
    distribution_model = default
    email = on
    email-attachments = off
    emmc = ""
    input_plugin = "default"
    [[[device]]]
      devicegroup = n900

  [[meego_aava]]
    timeout = 120
    distribution_model = default
    email = on
    email-attachments = on
    emmc = ""
    input_plugin = "default"
    [[[device]]]
      devicegroup = aava

Django Based server

  • Old database file /opt/ots.sqlite, is not compatible with 0.8 version.
  • No custom ots_config or extension points used anymore. If want to use testrun_db, create new plug-in to OTS server.
  • HTTP logging is automatically on if plug-in is installed.

QA-Reports

  • Configuration file is the same
/etc/ots_qareports_plugin.conf

Other configurations

  • OTS 0.8 uses mainly the server's configuration. Update values from the 0.1 configuration (/etc/ots-server.ini) to 0.8 (/etc/ots_server.ini).
  • No extension points used in 0.8

Input Plugins

OTS 0.1 supports feeding information back to ots client(for example the build machine) with input plugins. The key features of of OTS 0.1 input plugins are:

  • Publish testrun log url to the client in the beginning of the testrun
  • Publish result urls to the client
  • Publish result files to the client
  • Runtime selection of input plugin with testrun options

OTS 0.8 does not support input plugins but is able to do the same things with Publisher plugins. The needed steps are described below. The publisher plugin replacing an input plugin is referred as ClientPublisher.

  • Publish URLs to clients:
  1. All publishers can share their report urls by implementing the get_this_publisher_uris() method. For example ots.plugins.logger shares the the testrun log url by doing this. All reporting tool plugins should do the same.
  2. ClientPublisher needs to implement set_all_publisher_uris(self, uris_dict) method. The uris_dict contains all URLs from all publishers so it's easy to send them to the client in this method. The plugin can also filter the URLs if it does not want to send all of them to the client.
  3. The URL processing is done right after all publishers are loaded so log url gets sent in the beginning of the testrun as expected.
  • Result file Storage
  1. ClientPublisher gets all result files by implementing set_results(self, results). It's easy to send them to client in that method..
  • Dynamic runtime selection of input plugins
  1. All plugin constructors get the additional testrun options as keyword arguments. Disabling and enabling a specific ClientPublisher can be done in the constructor by checking the input parameters.
  • get_changed_packages(self, build_id)
  1. This should be implemented in the particular reporting tool that requires this information. OTS does not use this information in test execution so there's no need to handle this in OTS.

OTS Worker

  • First backup all old configurations
/etc/conductor.conf
/etc/conductor/
/etc/ots.ini
  • Remove 0.1.x version
sudo apt-get purge python-ots-common python-ots-worker

or

sudo rm -fr /usr/local/lib/python2.6/dist-packages/ots*

or

sudo rm -fr /usr/lib/python2.6/site-packages/ots*
  • No changes in the configuration files, just copy old ots.ini and conductor.conf to /etc.
  • No changes to customflasher.
Personal tools