JLab Lattice Portal – Data Grid Web Service Ying Chen, Chip Watson Thomas Jefferson National...

19
JLab Lattice Portal JLab Lattice Portal Data Grid Web Data Grid Web Service Service Ying Chen, Chip Watson Thomas Jefferson National Accelerator Facility

Transcript of JLab Lattice Portal – Data Grid Web Service Ying Chen, Chip Watson Thomas Jefferson National...

Page 1: JLab Lattice Portal – Data Grid Web Service Ying Chen, Chip Watson Thomas Jefferson National Accelerator Facility.

JLab Lattice Portal – JLab Lattice Portal – Data Grid Web ServiceData Grid Web Service

Ying Chen, Chip WatsonThomas Jefferson National Accelerator Facility

Page 2: JLab Lattice Portal – Data Grid Web Service Ying Chen, Chip Watson Thomas Jefferson National Accelerator Facility.

Jlab Lattice PortalJlab Lattice Portal

Jefferson Lab (JLab) and its collaborators at MIT are in the process of developing a web portal for the Lattice Hadron Physics Collaboration.

This portal will eventually provide access to Linux clusters, disk caches, and tertiary storage located at JLab, MIT, and other universities.

Page 3: JLab Lattice Portal – Data Grid Web Service Ying Chen, Chip Watson Thomas Jefferson National Accelerator Facility.

Jlab Lattice PortalJlab Lattice Portal

Jlab Lattice Web Portal infrastructure capabilities:

- Publish/locate a data set.

- Submit/monitor/control a batch job.

- Move a data set to/from the compute resource.

- Authenticate/authorize and track the use of the resources.

- ...

Page 4: JLab Lattice Portal – Data Grid Web Service Ying Chen, Chip Watson Thomas Jefferson National Accelerator Facility.

Why Grid Web Service ?Why Grid Web Service ?

Disk Mgr

Tape Mgrusers

Managed diskUnmanaged disk

tertiary storageusers

users

login

login

login

Data Grid Node

Fire wall

Page 5: JLab Lattice Portal – Data Grid Web Service Ying Chen, Chip Watson Thomas Jefferson National Accelerator Facility.

Data Grid Web ServiceData Grid Web Service

Hides the complexity of the underlying systemusers don’t have to deal with the disk manager or tape manager etc.

Provides the service on the webusers don’t have to login to do the work

Page 6: JLab Lattice Portal – Data Grid Web Service Ying Chen, Chip Watson Thomas Jefferson National Accelerator Facility.

System Architecture OverviewSystem Architecture Overview

Grid Service

Disk Mgr

Tape Mgr

users

Managed disk

Unmanaged disk

tertiary storage

users

users

Web browser

web browser

Fire wall

Page 7: JLab Lattice Portal – Data Grid Web Service Ying Chen, Chip Watson Thomas Jefferson National Accelerator Facility.

Web Based Grid ServiceWeb Based Grid ServiceJlab Data Grid Web Service - a java

servlet

- uses apache with model-ssl as secure web server and tomcat as servlet engine

- service request is an xml format string

- the result/response is also in xml format

- a certificate is required for the privileged services

Page 8: JLab Lattice Portal – Data Grid Web Service Ying Chen, Chip Watson Thomas Jefferson National Accelerator Facility.

Service Request/ResponseService Request/ResponseRequest:

<info name="version“ />

Response:<grid name="LQCD at Jlab“ url="lqcd.jlab.org/servlet/grid.data.Service">

<info name="version"> <info>jlab data grid version '0.1'</info>

</info></grid> ---------------------- or -------------------<grid name=“LQCD at Jlab” url=“lqcd.jlab.org/servlet/grid.data.Service”>

<info nam=“version”> <error>Attribute “name” missing</error></info>

</grid>

Page 9: JLab Lattice Portal – Data Grid Web Service Ying Chen, Chip Watson Thomas Jefferson National Accelerator Facility.

Why xml ?Why xml ? Self-describe (easy to understand) Language independent easy to assemble from multiple source Interchange of data among application Focus upon the data structure (can easily

convert to different presentation) Many free or commercial tools available to

process xml data

Page 10: JLab Lattice Portal – Data Grid Web Service Ying Chen, Chip Watson Thomas Jefferson National Accelerator Facility.

http://lqcd.jlab.org/pbs/

Page 11: JLab Lattice Portal – Data Grid Web Service Ying Chen, Chip Watson Thomas Jefferson National Accelerator Facility.

Jlab Web Based Grid ServiceJlab Web Based Grid Service

The grid service includes: - provides node information and status

- lists the contents of the grid node - moving files within the node

- performs file operations (delete, pin/unpin, mkdir, mkdirs etc.)

The URL of the service: http://lqcd.jlab.org/servlet/grid.data.GridService

Page 12: JLab Lattice Portal – Data Grid Web Service Ying Chen, Chip Watson Thomas Jefferson National Accelerator Facility.
Page 13: JLab Lattice Portal – Data Grid Web Service Ying Chen, Chip Watson Thomas Jefferson National Accelerator Facility.

Use the Service - directlyUse the Service - directly

Enter the url in a web browser:http://lqcd.jlab.org/servlet/grid.data.GridService

?service=<list+name='$CACHE/ychen'/>

or

https://lqcd.jlab.org/servlet/grid.data.GridService?service=<file-operation+type=‘delete’+ name=‘$DATA/foo'/>

Page 14: JLab Lattice Portal – Data Grid Web Service Ying Chen, Chip Watson Thomas Jefferson National Accelerator Facility.

Use the Service - Grid APIUse the Service - Grid API

A grid interface API is designed for using this Data Grid web service.

A java implementation of this API is being developed to encapsulate this xml service.

Using this API to obtain the service, the xml input and output are hidden by the implementation.

Page 15: JLab Lattice Portal – Data Grid Web Service Ying Chen, Chip Watson Thomas Jefferson National Accelerator Facility.

Grid API - GridFactoryGrid API - GridFactorypublic class GridFactory– provides an

interface to access the GridNode object using static methods.

public static GridNode getGridNode (String url)

public static GridNode getGridNode ()public static GridNode getReplica ()

interface GridNode – Is a grid node or replica catalog object that can be obtained from the GridFactory class.

Page 16: JLab Lattice Portal – Data Grid Web Service Ying Chen, Chip Watson Thomas Jefferson National Accelerator Facility.

Grid API - GridNodeGrid API - GridNodepublic interface GridNode {

public String getURL ();

public String getName();

public GridDirectory getDirectory (String path);

public GridFile[] list(String path);

public String[] listNames (String path);

public boolean isExist (String path);

public boolean isDirectory (String path);

public boolean isFile (String path);

}

Page 17: JLab Lattice Portal – Data Grid Web Service Ying Chen, Chip Watson Thomas Jefferson National Accelerator Facility.

Use the Grid APIUse the Grid APIpublic class GridAPIDemo { public static void main (String[] args) { try { GridNode jlab = GridFactory.getGridNode(); NodeDirectory dir = (NodeDirectory)

jlab.getDirectory(args[0]); String[] names = dir.listNames();

System.out.println(args[0]+“ directory contains:”);for (int i=0; i<names.length; i++) System.out.println(names[i]);

} catch (Exception e) { System.out.println(e.getMessage()); } }}

Page 18: JLab Lattice Portal – Data Grid Web Service Ying Chen, Chip Watson Thomas Jefferson National Accelerator Facility.

Future DevelopmentsFuture Developments

Standardize the xml request and response. Add additional web technology (SOUP,

WSDL, and UDDI) to build dynamic web-based system

Extend the batch web interface/service. Add third party file transfer capability using

remote web services (web server to web server)

Page 19: JLab Lattice Portal – Data Grid Web Service Ying Chen, Chip Watson Thomas Jefferson National Accelerator Facility.

Questions ?Questions ?