Table Of Contents

Previous topic

Frontier & Squid data related examples

Next topic

Service object related examples

Data export in JSON format

Summary list of JSON export API services


Service endpoint Available presets, AGIS-dev examples Additional options API ref, extra_fields, filters descriptions
/request/site/query/list_rcsites/?json default filter by state (by default shown state=ACTIVE): state|site_state={‘ANY’, ‘ACTIVE’, ‘DISABLED’} Site
/request/site/query/list/?json default, ssb ssb_dict, ssbatlas ssbatlas_dict ssbpilot filter by state (by default shown ANY): state|rc_site_state={‘ANY’, ‘ACTIVE’, ‘DISABLED’} list_sites
/request/ddmendpoint/query/list/?json default filter by state (by default shown ANY): state|site_state|rc_site_state={‘ANY’, ‘ACTIVE’, ‘DISABLED’} list_sites_ddmendpoints
/request/pandaqueue/query/list/?json

default (schedconf), full, ssb ssb_dict, ssbatlas ssbatlas_dict

schedconfig: schedconf.all, schedconfig.all

filter by state (by default shown ANY): site_state|rc_site_state={‘ANY’, ‘ACTIVE’, ‘DISABLED’} list_panda_queues
/request/pandaresource/query/list/?json default (schedconf), full   list_panda_resources
/request/swrelease/query/list/?json default   list_swreleases
/request/swrelease/query/list_presource_sw/?json

default (schedconf)

(10min) cache: list_presource_sw.schedconf.json

  list_panda_swreleases

Retrieving ATLAS Sites topology data in JSON

The service mirrors the functionality provided by agis.api.AGIS.AGIS.list_sites function with additional data exposed. It could accept input filters of list_sites function.

Retrieving Email contacts of sites in JSON

AGIS collects emails contacts for known GOCDB/OIM sites from GOCDB/MyOSG source accordingly.
  • Site.emailContact field stores list of contact emails collected from GOCDB/OIM.
  • ATLASSite.email field represents ATLAS specific contact list which can be modified via WEB UI.

Examples:

# retrieve email contacts of ALL GOCDB/OIM sites (even DISABLED)
http://atlas-agis-api-dev.cern.ch/request/site/query/list_rcsites/?json&state=ANY

JSON OUTPUT:

...
{
  "atlassites": {},
  "cert_status": "Certified",
  "emailContact": "enmr-bmrz@dlist.uni-frankfurt.de",
  "gocdb_pk": "181G0",
  "infoURL": "http://www.bmrz.uni-frankfurt.de",
  "is_pledged": false,
  "last_modified": "2012-09-27T17:10:32.014311",
  "latitude": 50.172669999999997,
  "longitude": 8.6320499999999996,
  "name": "BMRZ-FRANKFURT",
  "rc": "NULL",
  "rc_country": "Switzerland",
  "rc_tier_level": 3,
  "state": "DISABLED",
  "status": "Production",
  "timezone": ""
},
...

Example:

# expose ATLAS specific contacts and GOCDB/OIM ones for RC sites with any ATLAS site associated
http://atlas-agis-api-dev.cern.ch/request/site/query/list/?json&state=ANY&rc_site_state=ANY
# ATLASSite.state=DISABLED, Site.state=ACTIVE
http://atlas-agis-api-dev.cern.ch/request/site/query/list/?json&state=DISABLED&rc_site_state=ACTIVE

JSON OUTPUT:

...
{
  "cloud": "NL",
  "country": "Armenia",
  "ddmendpoints": {
    "AM-04-YERPHI_LOCALGROUPDISK": {
      "state": "ACTIVE"
    },
    "AM-04-YERPHI_PRODDISK": {
      "state": "ACTIVE"
    },
    "AM-04-YERPHI_SCRATCHDISK": {
      "state": "ACTIVE"
    }
  },
  "email": "atlas@grid.am",
  "emailContact": "admin@grid.am",
  "grid_flavour": "LCG",
  "has_notification": true,
  "infoURL": "http://www.grid.am/",
  "is_analysis": true,
  "is_atlas": true,
  "is_direct": false,
  "is_pledged": false,
  "is_production": true,
  "last_modified": "2012-09-27T17:01:44.915190",
  "latitude": 40.100000000000001,
  "longitude": 44.310000000000002,
  "name": "AM-04-YERPHI",
  "presources": {
    "AM-04-YERPHI": {
      "AM-04-YERPHI": {
        "is_cvmfs": true,
        "is_default_analysis": false,
        "is_default_production": false,
        "pandaqueues": [
          {
            "name": "prod-ce-yerphi-cluster-grid-am",
            "type": "production"
          },
          {
            "name": "prod-ce.yerphi-cluster.grid.am",
            "type": "production"
          }
        ]
      },
      "ANALY_AM-04-YERPHI": {
        "is_cvmfs": true,
        "is_default_analysis": false,
        "is_default_production": false,
        "pandaqueues": [
          {
            "name": "ANALY_AM-04-YERPHI",
            "type": "analysis"
          }
        ]
      }
    }
},
...

Retrieving DDMEndpoint data in JSON

The service mirrors the functionality provided by agis.api.AGIS.AGIS.list_sites_ddmendpoints function with additional data exposed. It could accept input filters of list_sites_ddmendpoints function.

Example:

# retrieve all ACTIVE ddmendpoints of *CERN-PROD* ATLAS Site
http://atlas-agis-api-dev.cern.ch/request/ddmendpoint/query/list/?json&site=CERN-PROD&state=ACTIVE

Retrieving PANDA queues data in JSON

Following service allows to retrieve PANDA queue`s related information from AGIS in JSON format.

The service mirrors the functionality provided by agis.api.AGIS.AGIS.list_panda_queues function and could accept related input filters and data output options of list_panda_queues function.

For example, to specify the list of additional data need to be retrieved extra_fields URI option should be passed.

Following example shows how to specify extra_fields and retrieve panda queues info only for AGLT2 ATLAS site:

JSON output:

...
{
    "atlas_site": "AGLT2",
    "ceinfo": "ANALY_AGLT2-condor|gate01.aglt2.org",
    "comment": "HC.Blacklist.set.online",
    "id": 356,
    "name": "ANALY_AGLT2-condor",
    "panda_resource": "ANALY_AGLT2",
    "panda_site": "GreatLakesT2",
    "queue_id": 234,
    "site": "AGLT2",
    "status": "online",
    "status_control": "manual",
    "type": "analysis"
},
...

Special preset option allows to use server-side predefined list of output fields, possible values:

Another example shown how to filter by panda queue name= ANALY_AGLT2-condor:

URL: http://atlas-agis-api-dev.cern.ch/request/pandaqueue/query/list/?json&preset=full&panda_queue=ANALY_AGLT2-condor

JSON output:

[
  {
    "atlas_site": "AGLT2",
    "ce_endpoint": "gate01.aglt2.org:2119",
    "ce_name": "AGLT2-CE-gate01.aglt2.org",
    "ce_queue_name": "AGLT2-CE-gate01.aglt2.org",
    "ceinfo": "ANALY_AGLT2-condor|gate01.aglt2.org",
    "cloud": "US",
    "comment": "HC.Blacklist.set.online",
    "country": "USA",
    "ddm_name": "AGLT2",
    "ddmsite": "AGLT2",
    "emailContact": "smckee@umich.edu",
    "grid_flavour": "OSG",
    "id": 356,
    "infoURL": "https://hep.pa.msu.edu/twiki/bin/view/AGLT2/Tier2Policy",
    "is_analysis": true,
    "is_direct": true,
    "is_pledged": true,
    "is_production": true,
    "last_modified": "2011-12-04T14:04:12",
    "latitude": 42.276189000000002,
    "longitude": -83.740994000000001,
    "name": "ANALY_AGLT2-condor",
    "panda_resource": "ANALY_AGLT2",
    "panda_site": "GreatLakesT2",
    "queue_id": 234,
    "rc": "US-AGLT2",
    "rc_country": "USA",
    "rc_site": "AGLT2",
    "rc_tier_level": 2,
    "site": "AGLT2",
    "state": "ACTIVE",
    "state_comment": "",
    "state_update": null,
    "status": "online",
    "status_control": "manual",
    "tier_level": 2,
    "timezone": "",
    "type": "analysis"
  }
]

Retrieving PANDAResource data in JSON

Following service allows to retrieve PANDA related information on the level of PandaResource in JSON format.