Astro-Wise Federation

ASTRO-WISE federation


i. Dataservers


Current situation


Soon


ii. CVS


Current situation



iii. Database federation


Current situation


Soon


Persistency Basics



class BiasFrame(BaseFrame):
    instrument      = persistent('', Instrument, None)
    chip            = persistent('', Chip, None)
    observing_block = persistent('', ObservingBlock, None)
    timestamp_start = persistent('', DateTime.DateTimeType, DateTime.DateTime(1990,1,1))
    timestamp_end   = persistent('', DateTime.DateTimeType, DateTime.DateTime(2030,1,1))
    creation_date   = persistent('', DateTime.DateTimeType, DateTime.DateTime(1990,1,1))
    raw_bias_frames = persistent('The frames used to construct this frame', RawBiasFrame, [])
    process_params  = persistent('Processing parameters', BiasFrameParameters, None)
    prev            = persistent('Comparison frame')




CREATE TYPE "BiasFrame$"

UNDER "BaseFrame$"
(
   "raw_bias_frames" "BiasFrame$raw_bias_frames",
   "instrument" REF "Instrument$",
   "timestamp_start" DATE,
   "prev" REF "BiasFrame$",
   "observing_block" REF "ObservingBlock$",
   "chip" REF "Chip$","timestamp_end" DATE,
   "process_params" REF "BiasFrameParameters$",
   "creation_date" DATE
)
NOT FINAL
;

CREATE TABLE "BiasFrame"
OF "BiasFrame$"
NOT SUBSTITUTABLE AT ALL LEVELS
NESTED
TABLE "raw_bias_frames"
  STORE AS "BiasFrame-raw_bias_frames"
;

CREATE VIEW "BiasFrame+"
OF "BiasFrame$"
UNDER "BaseFrame+"
AS
   SELECT *
   FROM "BiasFrame"
   WITH READ ONLY
;


for flat in (TwilightFlatFrame.chip.name == 'A5506-4') &
            (TwilightFlatFrame.creation_date > DateTime.DateTime(2003,11,31)):

    print flat.filename, flat.bias.filename

    flat.retrieve()
    flat.bias.retrieve()




Scalability


Locally, a client-server architecture of Oracle is deployed. awe clients connect to the local database via the network.

Different servers communicate with each other (OAC, USM , Terapix etc) via iii) and i).

Servers exchange the METAdata / DBObjects, but not the files. Files are handled by the dataserver.