Skip to content

WIP

This page is still work in progress.

CMake Overview

The CTA project is built with CMake and consists of a number of components. Here we consider a component to be a directory containing a CMakeLists.txt file. This CMakeLists.txt file defines the libraries, targets and executables generated by that component. Below follows an overview of what these components are, what they generate and how they relate to each other.

CTA defines the following top-level components:

  • eos_cta/
  • eos_grpc_client/
  • cmdline/
  • xroot_plugins/
  • frontend/
  • catalogue/
  • common/
  • disk/
  • mediachanger/
  • objectstore/
  • python/
  • rdbms/
  • scheduler/
  • tapeserver/
  • statistics/
  • cta-release/

It should be noted that some of the top-level components contain smaller sub-components. We consider PackageA to be related to PackageB when:

  • PackageA links PackageB
  • PackageA uses header files from PackageB
  • PackageA uses source files from PackageB

Using this definition, the different components are related as follows:

flowchart LR;
    R[project-root]

    subgraph EXT[External Libraries]
      PROTO[Protobuf]
      GRPC[grpc]
      XROOT[xrootd]
      XROOT_CLIENT[xrootdclient]
      KRB5[krb5]
    end

    subgraph SUB[Submodules]
      XROOT_SSI[xrootd-ssi-protobuf-interface/]
      CAT_SCHEMA[catalogue/cta-catalogue-schema/]
    end

    subgraph DB[Database Libraries]
      POSTGRES[postgres]
      SQLITE[sqlite]
      ORACLE[oracle-instantclient]
    end

    subgraph tl[Top-level Components]
      R --> EOS_CTA[eos_cta/]
      R --> EOS_GRPC[eos_grpc_client/]
      R --> CMD[cmdline/]
      R --> XROOT_PLUG[xroot_plugins/]
      R --> FRONTEND[frontend/]
      R --> CAT[catalogue/]
      R --> COMMON[common/]
      R --> DISK[disk/]
      R --> MEDIA[mediachanger/]
      R --> OBJS[objectstore/]
      R --> PYT[python/]
      R --> RDBMS[rdbms/]
      R --> SCHED[scheduler/]
      R --> TS[tapeserver/]
      R --> STAT[statistics/]
      R --> REL[cta-release/]
    end

    EOS_CTA --> PROTO
    EOS_CTA --> GRPC
    EOS_CTA --> XROOT_SSI

    EOS_GRPC --> PROTO
    EOS_GRPC --> GRPC
    EOS_GRPC --> EOS_CTA

    CMD --> PROTO
    CMD --> XROOT_CLIENT
    CMD --> XROOT_SSI
    CMD --> EOS_CTA

    XROOT_PLUG --> XROOT
    XROOT_PLUG --> PROTO
    XROOT_PLUG --> XROOT_SSI
    XROOT_PLUG --> EOS_CTA
    XROOT_PLUG --> TS
    XROOT_PLUG --> FRONTEND
    XROOT_PLUG --> SCHED
    XROOT_PLUG --> COMMON
    XROOT_PLUG --> OBJS
    XROOT_PLUG --> CAT
    XROOT_PLUG --> CMD

    FRONTEND --> PROTO
    FRONTEND --> GRPC
    FRONTEND --> EOS_CTA
    FRONTEND --> CMD
    FRONTEND --> COMMON
    FRONTEND --> SCHED
    FRONTEND --> OBJS
    FRONTEND --> CAT
    FRONTEND --> KRB5
    FRONTEND --> TS
    FRONTEND --> XROOT_PLUG

    CAT --> CAT_SCHEMA
    CAT --> POSTGRES
    CAT --> ORACLE
    CAT --> RDBMS

    COMMON --> XROOT
    COMMON --> EOS_CTA
    COMMON --> TS

    DISK --> XROOT
    DISK --> XROOT_CLIENT

    MEDIA --> COMMON

    OBJS --> PROTO
    OBJS --> COMMON
    OBJS --> CAT

    RDBMS --> SQLITE
    RDBMS --> POSTGRES
    RDBMS --> ORACLE

    SCHED --> PROTO
    SCHED --> XROOT
    SCHED --> RDBMS
    SCHED --> POSTGRES
    SCHED --> EOS_CTA
    SCHED --> CAT

    TS --> COMMON
    TS --> PROTO
    TS --> XROOT
    TS --> SCHED
    TS --> CAT
    TS --> MEDIA

    STAT --> ORACLE

Component Overview

Before we can explore in more detail how and why these items are related, we first provide an overview for each component (directory containing a CMakeLists.txt that generates something). These are all the targets, libraries and executables generated for the CTA project.


/

  • Targets: fullunittests, helgrind, helgrindBase, helgrindDataTransfer, helgrindInMemoryCatalogue, helgrindOStoreDB, helgrindScheduler, parallelHelgrind, shortunittests, test, valgrind

catalogue/

  • Libraries: ctacatalogue, ctacataloguecmdlineunittests, ctacatalogueinmemory, ctacatalogueocci, ctacataloguepostrgres, ctacataloguesqlite, ctadbconfigcatalogueunittests, ctadropschemacmd, ctainmemorycatalogueunittests, ctaschemachecker
  • Targets: create_pre_oracle_catalogue_schema_cpp, create_pre_sqlit_and_postgres_catalogue_schema_cpp
  • Executables: cta-catalogue-admin-user-create, cta-catalogue-schema-create, cta-catalogue-schema-drop, cta-catalogue-schema-set-production, cta-catalogue-schema-verify, cta-database-poll

catalogue/cta-catalogue-schema/

  • Targets: create_all_schemas_SQL

cmdline/

  • Executables: cta-admin, cta-wfe-test

cmdline/standalone_cli_tools/

  • Libraries: ctaCmdlineToolsCommon
  • Executables: cta-send-event, cta-verify-file

cmdline/standalone_cli_tools/change_storage_class/

  • Executables: cta-change-storage-class

cmdline/standalone_cli_tools/eos_namespace_injection/

  • Executables: cta-eos-namespace-inject

cmdline/standalone_cli_tools/restore_files/

  • Executables: cta-restore-deleted-files

common/

  • Libraries: ctacommon, ctacommonunittests
  • Executables: mutexLtrace

common/exception/

  • Libraries: ctaexceptionunittests

disk/

  • Libraries: ctadisk, ctadiskunittests

eos_cta/

  • Libraries: EosCtaGrpc, XrdSsiPbEosCta

eos_grpc_client/

  • Libraries: EosGrpcClient

frontend/common/

  • Libraries: ctafrontendcommonconfigunittests

frontend/grpc/

  • Executables: cta-admin-grpc, cta-frontend-async-grpc, cta-frontend-grpc

mediachanger/

  • Libraries: ctamediachanger, ctamediachangerunittests

mediachanger/castorrmc/common/

  • Libraries: ctarmccommon

mediachanger/castorrmc/rmc/

  • Executables: cta-rmcd, cta-smc

objectstore/

  • Libraries: ctaobjectstore, ctaobjectstoreunittests
  • Executables: cta-objectstore-collect-orphaned-object, cta-objectstore-create-missing-repack-index, cta-objectstore-dereference-removed-queues, cta-objectstore-dump-object, cta-objectstore-initialize, cta-objectstore-list

rdbms/

  • Libraries: ctadbconfigconnunittests, ctadbconfigstmtunittests, ctainmemoryconnunittests, ctainmemorystmtunittests, ctardbms, ctardbmsunittests

rdbms/wrapper/

  • Libraries: ctardbmsocci, ctardbmspostgres, ctardbmssqlite, ctardbmswrapper, ctardbmswrapperunittests

scheduler/

  • Libraries: ctascheduler, ctascheduler-objectstore, ctascheduler-postgres, ctaschedulerunittests

scheduler/rdbms/schema/

  • Executables: cta-scheduler-schema-create, cta-scheduler-schema-drop

statistics/

  • Libraries: ctastatistics
  • Executables: cta-statistics-save, cta-statistics-update

tapeserver/

  • Libraries: cta-tapedSystemTests
  • Executables: cta-taped

tapeserver/castor/tape/tapeserver/RAO/

  • Libraries: ctarao, ctatapeserverraounittests

tapeserver/castor/tape/tapeserver/SCSI/

  • Libraries: SCSI, ctatapeserverscsiunittests

tapeserver/castor/tape/tapeserver/daemon/

  • Libraries: ctaTapeServerDaemon, ctatapeserverdaemonunittests

tapeserver/castor/tape/tapeserver/drive/

  • Libraries: TapeDrive, ctatapeserverdriveunittests
  • Executables: TapeDriveReadWriteTest

tapeserver/castor/tape/tapeserver/file/

  • Libraries: File, ctatapeserverfileunittests
  • Executables: BasicReadWriteTest, cta-osmReaderTest

tapeserver/castor/tape/tapeserver/system/

  • Libraries: System

tapeserver/daemon/

  • Libraries: ctadaemonunittests, ctadaemonunittests-multiprocess, ctatapedaemon

tapeserver/daemon/common/

  • Libraries: ctatapedaemoncommon, ctatapedaemoncommonunittests

tapeserver/readtp/

  • Executables: cta-readtp

tapeserver/session/

  • Libraries: ctatapesession

tapeserver/tapelabel/

  • Libraries: ctatapelabelunittests
  • Executables: cta-tape-label

tests/

  • Libraries: systemTestHelperTests, unitTestHelper
  • Executables: cta-immutable-file-test, cta-rdbmsUnitTests, cta-systemTests, cta-unitTests, cta-unitTests-multiProcess

xroot_plugins/

  • Libraries: XrdSsiCta

xrootd-ssi-protobuf-interface/test/protobuf/

  • Libraries: XrdSsiPbTest

xrootd-ssi-protobuf-interface/test/src/

  • Libraries: XrdSsiTest
  • Executables: test-client, test-threads