Versions Compared

Key

  • This line was added.
  • This line was removed.
  • Formatting was changed.

...

Java Object ClassJava Collection ClassDefault Database TableDescription
BeamEnergyBeamEnergyCollectionbeam_energiesnominal beam energies
EcalBadChannelEcalBadChannelCollectionecal_bad_channelsECal bad channel list
EcalCalibrationEcalCalibrationCollectionecal_calibrationsper channel ECal pedestals and noise
EcalChannelEcalChannelCollectionecal_channelsECal channel information including map of DAQ to physical channels
EcalGainEcalGainCollectionecal_gainsper channel ECal gains
EcalLedEcalLedCollectionecal_ledsper crystal LED configuration
EcalLedCalibrationEcalLedCalibrationCollectionecal_led_calibrationsper crystal LED calibration information (from calibration run)
EcalPulseWidthEcalPulseWidthCollectionecal_pulse_widthsECal signal pulse width (currently unused in recon)
EcalTimeShiftEcalTimeShiftCollectionecal_time_shiftsECal signal time shift (currently unused in recon)
SvtAlignmentConstantSvtAlignmentConstantCollectionsvt_alignment_constants

SVT alignment constants in Millepede format

may be disabled using -DdisableSvtAlignmentConstants

SvtBadChannelSvtBadChannelCollectionsvt_bad_channelsSVT bad channel list
SvtBiasConstantSvtBiasConstantCollectionsvt_bias_constantsSVT bias setting for a time range
SvtCalibrationSvtCalibrationCollectionsvt_calibrationsper channel SVT noise and pedestal measurements
SvtChannelSvtChannelCollectionsvt_channelsSVT channel information
SvtDaqMappingSvtDaqMappingCollectionsvt_daq_mapSVT mapping of DAQ to physical channels
SvtGainSvtGainCollectionsvt_gainsper channel SVT gains
SvtMotorPositionSvtMotorPositionCollectionsvt_motor_positionsSVT motor position in mm
SvtShapeFitParametersSvtShapeFitParametersCollectionsvt_shape_fit_parametersSVT parameters for the signal fit

SvtT0Shift

SvtT0ShiftCollection

svt_t0_shifts

SVT T0 (first sample) shifts

SvtTimingConstants

SvtTimingConstantsCollection

svt_timing_constantsSVT timing configuration constants including offset and phase

TestRunSvtChannel

TestRunSvtChannelCollection

test_run_svt_channelstest run SVT channel information

TestRunSvtDaqMapping

TestRunSvtDaqMappingCollection

test_run_svt_daq_maptest run SVT DAQ mapping

TestRunSvtT0Shift

TestRunSvtT0ShiftCollection

test_run_svt_t0_shiftstest run SVT T0 shift

 

Database Schema

Conditions Collections

...

Database Schema

Each type of condition has an associated database table which contains records with conditions information plus a few additional pieces of information.

Data Tables

For instance, this is the table schema for the BeamEnergy condition.

No Format
mysql> describe beam_energies;
+---------------+---------+------+-----+---------+----------------+
| Field         | Type    | Null | Key | Default | Extra          |
+---------------+---------+------+-----+---------+----------------+
| id            | int(11) | NO   | PRI | NULL    | auto_increment |
| collection_id | int(11) | NO   |     | NULL    |                |
| beam_energy   | double  | NO   |     | NULL    |                |
+---------------+---------+------+-----+---------+----------------+
3 rows in set (0.00 sec)

The id is the row ID used to uniquely identify the record.  The collection_id associates a set of records together into a collection.  Every data table has these two fields plus additional columns with the conditions data.

Conditions Table

The conditions table associates collections with a run number range.

No Format
mysql> describe conditions;
+---------------+--------------+------+-----+-------------------+-----------------------------+
| Field         | Type         | Null | Key | Default           | Extra                       |
+---------------+--------------+------+-----+-------------------+-----------------------------+
| id            | int(11)      | NO   | PRI | NULL              | auto_increment              |
| run_start     | int(11)      | NO   |     | NULL              |                             |
| run_end       | int(11)      | NO   |     | NULL              |                             |
| updated       | timestamp    | NO   |     | CURRENT_TIMESTAMP | on update CURRENT_TIMESTAMP |
| created       | datetime     | NO   |     | NULL              |                             |
| tag           | varchar(256) | YES  |     | NULL              |                             |
| created_by    | varchar(255) | YES  |     | NULL              |                             |
| notes         | longtext     | YES  |     | NULL              |                             |
| name          | varchar(40)  | NO   |     | NULL              |                             |
| table_name    | varchar(50)  | NO   |     | NULL              |                             |
| collection_id | int(11)      | NO   |     | NULL              |                             |
+---------------+--------------+------+-----+-------------------+-----------------------------+
11 rows in set (0.01 sec)

The run_start and run_end give a range of run numbers for which the conditions are valid.  These can be the same number to specify a single run.

The table_name gives the name of the table containing the conditions data.

The collection_id gives the collection ID to load from the table.

This table is modeled by the ConditionsRecord class which is accessible via the DatabaseConditionsManager.

When multiple collections of the same type are valid for the current run, the most recently added one will be used by default.