Login | Register
My pages Projects Community openCollabNet

CABIE Database Schema

Table Description
activetestimage each row provides information on images currently running on smoketest machines
authtable each row stores an ip address for machines granted administrative privelages
buildservers each row stores information for each machine defined as a buildserver using CABIE
changes each row stores changes from cm systems associated with a particular build
comments each row can store text associated for a particular build
configuration each row stores configuration for a unique job defined on the buildserver
joblog each row stores log information for each step executed by a defined job
jobs each row stores collected information for each completed job defined on the buildsrever
locktest each row acts as a semaphore locking the smoketest server while it is executing smoketests
monitorservers each row stores port information for the thread running the monitorserver
pending each row stores files that are pending update for a defined build
polltest reserved for future use
proctree each row stores process ids for each active build
promotion each row stores job information for jobs promoted to a test state
removed each row stores job information for job output removed by the buildserver
restore each row stores backup job information for currently executing builds
results each row stores smoke test results for tested jobs
run each row stores running data for currently active smoketest sessions
semaphores each row acts as a semaphore locking a defined job while it is executing on a buildserver
serverids each row stores the process id of the running buildserver/monitor
stage each row acts as a staging area for jobs that have completed building and are awaiting smoketest
subscription each row stores email addresses for those interested in receiving email about a particular named job
testconfiguration each row stores configuration for a unique smoketest defined on the buildserver
testserver each row stores information about active test servers allowing remote restarts of servers that have failed somketests
teststate each row stores information about tests being performed or completed.

Schema: Text Description

This outlines all of the tables and rows currently associated with CABIE. The tables which are designated as buildserver tables are required for the correct operation of CABIE. Those denoted as smoketest are used by defined smoketest jobs which are currently quite custom and are not distributed with CABIE. The tables are there however and may be used for custom applications.

The commands used by CABIE to populate or manipulate tables are also supplied along with the summary descriptions at the head of each table. '<' denotes the command as input to CABIE, '>' denotes the command as output to CABIE

activetestimage table: activetestimage descriptions

smoketest:   Maybe used for semaphore operations on active smoketest deployments. Currently used to determine string substitution in the imagereference for the next active OS image to be deployed.

Table activetestimage Structure:
Field Type Description
server varchar(30) server the smoketests will be executed from, does not need to be the same as deployserver
deployserver varchar(30) the name of the target server for installation or deployment
imagename varchar(64) the name of the raw OS image deployed onto the smoketest server
title varchar(30) the name or title of the individual smoketest
buildserver varchar(30) the name of the buildserver where the build job originated
jobname varchar(30) the name of the build job as found on the buildserver
job varchar(30) the unique ID of the job as found on the buildserver
installimage varchar(30) the name of the image to be installed on the raw OS image
imagereference varchar(30) the name of a configuration file which may be used to deploy the raw OS image

authtable table: authtable descriptions

buildserver:   Used for adding or removing machines from an authorized list providing additional commands.

Associated buildserver commands:

    < authorize
    < unauthorize
    > authorized

Table authtable Structure:
Field Type Description
server varchar(30) the name of the buildserver for which authorization is requested
machine varchar(128) the name or ip address of the machine to be authorized by the buildserver

buildservers table: buildservers descriptions

buildserver:   Initialized by starting the buildserver (buildserver -s port -m port -d).

Associated buildserver commands:

    > servers
    > sysinfo
    < shutdown

Table buildservers Structure:
Field Type Description
server varchar(30) the name of the machine the buildserver is running on
description blob a description of the sw/hw the buildserver is running on ala uname -s
port int(6) the port number the build server is listening on
status int(1) the current state of the buildserver (0 or 1)
globalmail varchar(64) whether or not to deliver global email for all failed builds

changes table: changes descriptions

buildserver:   Populated by the the build command upon the completion of a build job.

Associated buildserver commands:

    < build
    < notify
    > changes
    > changed

Table changes Structure:
Field Type Description
server varchar(30) the name of the machine the buildserver is running on
title varchar(30) the name of the build job running on the buildserver
job varchar(25) the unique ID of the job titled <title> completed on the buildserver
changes text each entry identifies the change made for <job> on <server> for <title>

comments table: comments descriptions

buildserver:   Populated by shared scripts (buildfuncs.pl, gencomments) looking for bug numbers in file or change logs

Associated web applications:

    > genweb
    < gencomments

Table comments Structure:
Field Type Description
server varchar(30) the name of the machine the buildserver is running on
title varchar(30) the name of the build job running on the buildserver
job varchar(25) the unique ID of the job titled <title> completed on the buildserver
comment blob a string containing any comment made for <job> on <server> for <title>

configuration table: configuration descriptions

buildserver:   Populated by createjob initially. Contains charastics for each job defined on the buildserver.

Associated buildserver commands:

    < createjob
    < clone
    > describe

Table configuration Structure:
Field Type Description
server varchar(30) the name of the buildserver the build job is defined to run on
title varchar(30) the title of the build job running on the buildserver
port varchar(64) the port associated with the CM system where the source for the build job is to be found
client text the client name (perforce) or modules (CVS) that are to be accessed for the build job
top varchar(255) the top level directory name where the source for the build job will reside
type varchar(255) the type of build job - retail, debug, or both (literally)
toolsdir longtext the path used to locate the tools used for the build job
isimake varchar(4) unused, set to no
keeplevel int(4) used to determine the number of completed jobs to save before removal
comment longtext used for the description of a build job
sccs varchar(16) used to determine the CM system used for the build job (cvs or perforce)
browserlink longtext used to generate a browserlink to the appropriate CM tool, currently tested with CVSWEB and P4Web
state int(2) used to determine whether or not the build job is accessable (0 = visible, 1 = not visible)
spam int(1) used to determine whether or not to send spam on broken builds to globally defined group (in hostname.cm)
buildsize bigint(64) used to determine how much diskspace a build job requires for completion

joblog table: joblog descriptions

buildserver:   Populated by build command. Contains current state of a running build

Associated buildserver commands:

    > jobstate
    > joblog

Table joblog Structure:
Field Type Description
server varchar(30) the name of the buildserver the build job is defined on
title varchar(30) the title of the build job running on the buildserver
message varchar(255) a message describing the current step in a build while running (must have (retail) or (debug) in the string)
step int(2) the step which corrleates with the genweb interface used to determine the color supplied as the background

jobs table: jobs descriptions

buildserver:   Populated by build command. Collects data from all jobs active on the buildserver

Associated buildserver commands:

    > runstats
    > genweb
    > xmldump

Table jobs Structure:
Field Type Description
server varchar(30) the name of the buildserver the build job is defined on
title varchar(30) the title of the build job as defined on the buildserver
job varchar(25) the unique id of the build job completed running on the buildserver
start int(15) the start time of the build job completed on the buildserver in unix format $os->_get_time())
end int(15) the completion time of the build job completed on the buildserver in unix format $os->_get_time())
status int(2) the completion status for the completed job on the buildserver (0 = untested, 1 = failed build, 2 = failed test)
info blob currently used by CVS only in determining the last check in, into the completed job
sccs varchar(16) used to preserve the CM system used for a completed job in case the CM system is replaced
browserlink blob used to preserve the CM browser link of a completed job in case the CM browser is replaced
buildsize bigint(64) used to preserve the amount of disk space occupied by a completed job, averaged to determine disk usage
port varchar(64) used to preserve the port for the CM system used for a completed build in case the CM system is replaced
removed int(1)

locktest table: locktest descriptions

smoketest:   Maybe used for semaphore operations on active smoketest deployments. Currently used to lock a smoketest machine from redeployment of an image.

Table locktest Structure:
Field Type Description
server varchar(30) the name of the testserver the smoketest image is deployed to
title varchar(30) the title smoketest job being deployed to the testserver
buildjob varchar(30) the title:unique_id of the job being deployed to the testserver

monitorservers table: monitorservers descriptions

buildserver:   Initialized by starting the buildserver (buildserver -s port -m port -d). This port is used in association with a thread that polls the CM system for changes

Associated buildserver commands:

    > nextjob

Table monitorservers Structure:
Field Type Description
server varchar(30) the name of the machine the monitor server (secondary port to the build server) is running on
port int(6) the port number the monitor server (secondary port to the build server) is listening on
status int(1) the current state of the buildserver (0 or 1)

pending table: pending descriptions

buildserver:   This table is populated by the thread utilizing the monitorserver port. When a job is executing, and new changes are pending this will show up in the genweb page as a star noting that additional files require updating

Associated buildserver commands:

    NONE

Table pending Structure:
Field Type Description
server varchar(30) the name of the machine the build server is running on
title varchar(30) the title of the build job defined on the buildserver
changes blob a pending list of files to be updated when the next build job is executed

polltest table: polltest descriptions

smoketest:    Currently unused

Table polltest Structure:
Field Type Description
server varchar(30) reserved for future use
title varchar(30) reserved for future use

proctree table: proctree descriptions

buildserver:    Used to track all process id's that have been forked using internal $os->forkprocess calls. Tracks only calls for which a wait was set. Clears out ids when the wait has completed.
Currently internal.

Table proctree Structure:
Field Type Description
server varchar(30) the name of the machine the build server is running on
title varchar(30) the title of the build job defined on the buildserver
job varchar(25) the unique id of the build job currently running on the buildserver
cmd blob the cmd execd for the build job on the buildserver
pid int(64) the pid for the execd command running for the build job on the buildserver

promotion table: promotion descriptions

buildserver:    Used to track jobs thathave been promoted by the build administrator.
Associated buildserver commands:

    < promote

Table promotion Structure:
Field Type Description
server varchar(30) the name of the machine the buildserver is running on
title varchar(30) the title of the promoted build job built on the buildserver
job varchar(25) the unique id of the build job promoted on the buildserver
at varchar(26) the time in unix time format when the build job was promoted on the buildserver
bywhom varchar(60) the ip address of the machine that promoted the build job on the buildserver
comment blob comment used to describe why the build was promoted

removed table: removed descriptions

buildserver:   Tracks build jobs removed automatically based upon the keep level

Table removed Structure:
Field Type Description
server varchar(30) the name of the machine the buildserver is running on
title varchar(30) the title of the build job output targeted for removal from the buildserver
job varchar(25) the unique id of the build job output targeted for removal from the buildserver
at varchar(26) the time in unix format when the attempted removal of the build job output from the buildserver occured
action varchar(16) the time in unix format when the attempted removal of the build job output from the buildserver occured
directory blob the directory name of the where build job output exists when the removal is attempted

restore table: restore descriptions

buildserver:   Initialized by a running build. Duplicates information from the semaphores table for a running job. Used to recover active information in case the enable command is accidently performed on a running job.
Associated buildserver commands:

    < recover

Table restore Structure:
Field Type Description
server varchar(30) the name of the machine the current build job is running on
title varchar(30) the title of the build job currently running on the buildserver
message varchar(255) a string indicating the job state of the build job currently running on the buildserver
time int(15) time in unix time format for the start of the build job currently running on the buildserver
state int(2) the step which corrleates with the genweb interface used to determine the color supplied as the background

results table: results descriptions

testserver:   Initialized by a completed testserver. Records are copied from the run table to the results table.
Associated buildserver commands:

    > teststatus -c

Table results Structure:
Field Type Description
server varchar(30) the name of the server that smoketests, ui tests etc. were executed on
deployserver varchar(30) the name of the server that the install image was installed on
title varchar(30) the title of the smoketest installation
buildserver varchar(30) the name of the buildserver the installed job originated from
jobname varchar(30) the name of the build job on the buildserver that created the installation
job varchar(30) the unique ID of the build job on the buildserver that created the installation
start int(15) the time in unix time format when the smoketest installation started
end int(15) the time in unix time format when the smoketest installation ended
teststatus int(1) the integer results of the smoketest (not defined currently)

run table: run descriptions

testserver:   Initialized by a running testserver. Records are copied from the stage table to the run table.
Associated buildserver commands:

    > teststatus -r

Table run Structure:
Field Type Description
server varchar(30) the name of the server that smoketests, ui tests etc. are to be executed on
deployserver varchar(30) the name of the server that the install image will be installed on
title varchar(30) the title of the smoketest installation
buildserver varchar(30) the name of the buildserver the installing job originated from
jobname varchar(30) the name of the build job on the buildserver that created the installation
job varchar(30) the unique ID of the build job on the buildserver that created the installation
start int(15) the time in unix time format when the smoketest installation started
end int(15) the time in unix time format when the smoketest installation ended
state int(1) the current state of the smoketest deployment machine (currently unused)
message blob text message indicating the step currently executing for the smoketest installation
dependserver varchar(30) the name of any server this smoketest server may have to wait for

semaphores table: semaphores descriptions

buildserver:   Initialized by running a build, or by enabling/disabling a build
Associated buildserver commands:

    > jobstate
    < disable
    < enable
    < recover
    < build

Table semaphores Structure:
Field Type Description
server varchar(30) the name of the machine the current build job is running on
title varchar(30) the title of the build job currently running on the buildserver
message varchar(255) a string indicating the job state of the build job currently running on the buildserver
time int(15) time in unix time format for the start of the build job currently running on the buildserver
state int(2) the step which corrleates with the genweb interface used to determine the color supplied as the background

serverids table: serverids descriptions

buildserver:   Initialized by starting the buildserver (buildserver -s port -m port -d)
Associated buildserver commands:

    > getid
    < shutdown

Table serverids Structure:
Field Type Description
server varchar(30) the name of the running buildserver/monitorserver
type varchar(30) the type of server (server|monitor)
pid varchar(30) the process id of the running server (NA on Windows)

stage table: stage descriptions

testserver: Stores information about completed builds that are ready for testing. Allows builds to continue on while testservers work on previous builds.
Associated buildserver commands:

    > teststatus -p

Table stage Structure:
Field Type Description
server varchar(30) the name of the server that smoketests, ui tests etc. are to be executed on
deployserver varchar(30) the name of the server that the install image will be installed on
imagename varchar(64) the name of the raw OS image deployed onto the smoketest server
bootscript varchar(64) the name of the bootscript run on a freshly deployed OS image
title varchar(30) the title of the smoketest installation
buildserver varchar(30) the name of the buildserver the installing job originates from
jobname varchar(30) the name of the build job on the buildserver that created the installation media
job varchar(30) the unique ID of the build job on the buildserver that created the installation
state int(1) the current state of the smoketest deployment machine (currently unused)
installimage varchar(30) the name of the image to be installed onto the raw OS image
attempt int(1) the number of attempts that may be required to get the image to be installed onto the raw OS image
dependserver varchar(30) the name of any server this smoketest server may have to wait for

subscription table: subscription descriptions

buildserver: Stores email addresses of those who may be interested in build output information via email
Associated buildserver commands:

    > subscribers
    < subscribe

Table subscription Structure:
Field Type Description
server varchar(30) the name of the machine the buildserver is running on
title varchar(30) the title of the build job for which email subscription is requested
address varchar(64) the email address which would like email notification upon completion of build job running on buildserver

testconfiguration table: testconfiguration descriptions

smoketest:   Stores information about testservers their images, configuration files, bootscripts etc.

Table testconfiguration Structure:
Field Type Description
server varchar(30) the name of the server that smoketests, ui tests etc. are to be executed on
title varchar(30) the title of the smoketest installation
type int(1) the type of install that is being performed as int matched with type in environment
imagename varchar(64) the name of the raw OS image deployed onto the smoketest server
bootscript varchar(64) the name of the bootscript run on a freshly deployed OS image
comment blob used for the description of a smoketest job
state int(1) used to determine whether or not the smoketest is active (0 = active, 1 = inactive)
nextjob varchar(30) unused at this time
spam int(1) unused at this time
buildjob varchar(30) buildserver:title of job running on buildserver associated with this smoketest job
deployto varchar(30) the target machine for the image to be deployed to
platform varchar(30) the target platform for which the image is compatible (w2k, sol, linux)
imageserver varchar(30) the server where a virtual image resides for deployment of a clean OS to the deployto box
imagereference varchar(30) the name of a configuration file which may be used to deploy the raw OS image onto deployto
attempts int(11) the number of attempts that may be required to get the image to be installed onto the raw OS image
dependserver varchar(30) the name of any server the deployto server may have to wait for
completed int(2)

testserver table: testserver descriptions

smoketest/buildserver:   Stores information about active testservers and their states which can be accessed via the buildserver while tests are running
Associated buildserver command:

    > testserver
    < testserver -f servername

Table testserver Structure:
Field Type Description
server varchar(30) the name of the testserver
state int(1) the state of the testserver. 1=running or waiting for imaging, 0=unhappy. If the testserver is unhappy it will not reimage and will require running build testserver -f servername

teststate table: teststate descriptions

smoketest:   Stores information about testservers and their current tests which can be accessed via the buildserver while tests are running
Associated buildserver command:

    > xmldump

Table teststate Structure:
Field Type Description
title varchar(30) the title of the smoketest as defined in testconfiguration
buildserver varchar(30) the buildserver where the build job was run
jobname varchar(30) the name of the build job run on the buildserver
job varchar(30) the job number of the build job run on the buildserver
step varchar(30) the name of the teststep run or running
state int(1) the state of the teststep run or running. 0=idle, 1=running, 2=passed 3=failed
start int(15) the start time of the teststep run or running
end int(15) the end time of the teststep run