dmwm / PHEDEX

CMS data-placement suite
8 stars 18 forks source link

fixes for the namespace gfal plugin #1020

Closed sartiran closed 8 years ago

sartiran commented 8 years ago

At GRIF LLR we are testing the gfal namespace plugin for transfers validation using both srm ad gsiftp urls. Here are a couple of fixes from these tests.

nikmagini commented 8 years ago

Ciao Andrea,

two comments on your proposed fixes:

1) in delete.pm you use as base the dpm::Common module. I think you wanted to use gfal::Common instead?

2) in stat.pm you change the parsing of the output. But AFAICT the old parsing was correct with gfal2 2.9,1, see [*] Did gfal2 change output format in the version you're testing?

[*] -bash-4.1$ gfal-ls --version gfal2-util version 1.2.1 (gfal2 2.9.1) dcap-2.9.1 file-2.9.1 gridftp-2.9.1 http-2.9.1 lfc-2.9.1 rfio-2.9.1 srm-2.9.1 -bash-4.1$ gfal-ls -l gsiftp://llrpp01.in2p3.fr:2811//dpm/in2p3.fr/home/cms/trivcat/store/xrootd.test.llrpp.root.1 -rw-r--r-- 0 0 0 Jun 21 2014 1987285 gsiftp://llrpp01.in2p3.fr:2811//dpm/in2p3.fr/home/cms/trivcat/store/xrootd.test.llrpp.root.1

sartiran commented 8 years ago

Ciao Nicolo',

1) of course, sorry. Corrected in a new commit

2) apparently the output changed between 2.9 and 2.10 (which is the one I'm running on the PhEDEx UI)

[phedex@llrphedex PHEDEX]$ gfal-ls -l srm://llrpp01.in2p3.fr:8446/srm/managerv2?SFN=/dpm/in2p3.fr/home/cms/trivcat/store/xrootd.test.root -rw-r--r-- 1 44 43 1987285 Jun 21 2014 srm://llrpp01.in2p3.fr:8446/srm/managerv2?SFN=/dpm/in2p3.fr/home/cms/trivcat/store/xrootd.test.root [phedex@llrphedex PHEDEX]$ gfal-ls -V gfal2-util version 1.3.1 (gfal2 2.10.3) dcap-2.10.3 file-2.10.3 gridftp-2.10.3 http-2.10.3 lfc-2.10.3 rfio-2.10.3 srm-2.10.3

nikmagini commented 8 years ago

Hi Andrea,

thanks for checking. Well, the new output looks more consistent with the 'ls -l' output, so I suppose that the change is intentional. However, this means that we have to do a special-case depending on the gfal2-util version... Let's ask Andrea Manzi

Thanks! N.

nikmagini commented 8 years ago

Ciao Andrea,

simple proposal:

1) for the 'gfal' Namespace directory you just send the fix for delete.pm and we keep stat.pm as it is.

2) you create a new 'gfal210' Namespace directory containing your version of the gfal Namespace including the new stat.pm

3) you add a --version option in PHEDEX/perl_lib/PHEDEX/Namespace/gfal.pm to select the correct Namespace directory. Default is to use the old directory. As an example of how to load different plugins based on an option you can see PHEDEX/perl_lib/PHEDEX/Namespace/srm.pm which has 3 different plugins behind

How does it sound?

Thanks! Nicolò

sartiran commented 8 years ago

Hi Nicolo',

sounds good to me. I'll have a look at it asap and commit the changes.

Thanks, a.