[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: [Handle-info] Batch query handles?



Unfortunately, our RESt implementation only supports creating handles with the basic information, and doesn't support batch import.  However, I shouldn't be to hard to extend the source code to handle that functionality.  I can send you source code if you would like, or maybe if my supervisor allows we could create a git or google project for it.


On Mar 30, 2012, at 1:27 PM, Brian Sheppard wrote:

After a cursory look at these two, I can't tell whether the functionality we need locally is present. So if anyone has suggestions on how to extend either of these, we'd love to hear them. It looks like Nathan's service can handle an xml data file as part of a PUT request. Is that file similar to a "batch" statement that would allow one to specify indexes and type values, for example?

An xml equivlent to this, for example:

CREATE 1711.dl/VMQPXBX2FSXRK8M
100 HS_ADMIN 86400 1110 ADMIN 200:000011110001:1711/someadmins
101 HS_ADMIN 86400 1110 ADMIN 200:111111111111:1711/otheradmins
1 URL 86400 1110 UTF8 http://ourhost.org/path/to/content
2 NAME 86400 1110 UTF8 Deviant Factors in Linguistic Chromatographony


On March 30, at 11:15 AM, Mark Diggory wrote:

Note... For REST services, there is also...

https://github.com/cordmata/handle-service

Mark

On Fri, Mar 30, 2012 at 9:11 AM, Mark Diggory <mdiggory@atmire.com> wrote:

Disregard... I just saw the rest of the thread...


On Fri, Mar 30, 2012 at 9:10 AM, Mark Diggory <mdiggory@atmire.com> wrote:

Hey Nathan, that sounds quite interesting, what is your REST service
implemented in?

Mark


On Fri, Mar 30, 2012 at 8:07 AM, Tim Donnelly <Tim@coalliance.org> wrote:

Thank you both for your ideas.****

** **

After I posted I realized that I was completely over thinking the
processes and that it really was just a matter of bulk modifying the URL’s
in all the affected handles.  It even turns out that I had a script already
written to do just that but had forgotten all about it.****

** **

Funny how Mondays aren’t always the first day of the week.****

** **

*From:* Nathan Stevens [mailto:ns96@nyu.edu]
*Sent:* Friday, March 30, 2012 7:50 AM
*To:* Sean Reilly
*Cc:* Tim Donnelly; handle-info@cnri.reston.va.us
*Subject:* Re: [Handle-info] Batch query handles?****

** **

Hi,****

** **

At NYU we developed a REST interface to our handle servers (allows
creation, running audits etc) which can easily be used, in conjunction with
a perl script/curl to print out the information you need.  If you are
interested let me know and I can send you the code.****

** **

On Mar 29, 2012, at 12:01 PM, Sean Reilly wrote:****



****

Hi Tim,

There is no batch-query mechanism in the handle server, but requesting
each individual handle should be a relatively lightweight operation.  I
assume you'd want to take some action that was different depending upon the
current value(s) in the handle, if it existed, so perhaps using a python
script would be a more flexible way to create your handles?

I've attached a script that might work, but I've only written it from
scratch so there are probably some bugs, but it might give an idea for how
a batch-updater might work.

Thanks,
Sean



<update_handles.sh>


On 28 Mar 2012, at 15:13, Tim Donnelly wrote:


****

Is there a way to batch query handles?****

** **

I need to change the URL of several thousand handles, but can’t be
sure that the URL format is consistent across the entire range.****

** **

For example:****

** **

10176/cogru:1000 currently has a URL of
http://adr.coalliance.org/adrlib/lookup?cogru:1000****

** **

I need to change it to:****

** **

http://digitalunc.coalliance.org/fedora/repository/cogru:1000****

** **

I can, and have, done this in the past using a batch MODIFY but then I
was sure that the original URL was the same for all records.  This time I
can’t be sure.****

** **

I have a list of all the handles generated from the Server Admin menu,
but that doesn’t provide any associated handle data.  And I obviously don’t
want to query each handle individually so is there some way I can generate
a list of all the handles with URLs?****

** **

Thanks****

** **

Tim Donnelly****

System/Network Administrator****

Colorado Alliance of Research Libraries****

(303)759-3399 x106****

** **

P No trees were killed in the sending of this message, but a large
number of electrons were terribly inconvenienced.****

** **

** **

** **

Nathan Stevens
Programmer/Analyst
Digital Library Technology Services
New York University****

1212-998-2653
ns96@nyu.edu****

** **




--
[image: @mire Inc.]
*Mark Diggory *(Schedule a Meeting<https://www.google.com/calendar/selfsched?sstoken=UUdDSzJzTTlOUE1mfGRlZmF1bHR8MzgwMmEwYjk1NDc1NDQ1MGI0NWViYjYzZjExZDI3Mzg>
)
*2888 Loker Avenue East, Suite 305, Carlsbad, CA. 92010*
*Esperantolaan 4, Heverlee 3001, Belgium*
http://www.atmire.com





--
[image: @mire Inc.]
*Mark Diggory *(Schedule a Meeting<https://www.google.com/calendar/selfsched?sstoken=UUdDSzJzTTlOUE1mfGRlZmF1bHR8MzgwMmEwYjk1NDc1NDQ1MGI0NWViYjYzZjExZDI3Mzg>
)
*2888 Loker Avenue East, Suite 305, Carlsbad, CA. 92010*
*Esperantolaan 4, Heverlee 3001, Belgium*
http://www.atmire.com





--
[image: @mire Inc.]
*Mark Diggory *(Schedule a
Meeting<https://www.google.com/calendar/selfsched?sstoken=UUdDSzJzTTlOUE1mfGRlZmF1bHR8MzgwMmEwYjk1NDc1NDQ1MGI0NWViYjYzZjExZDI3Mzg>
)
*2888 Loker Avenue East, Suite 305, Carlsbad, CA. 92010*
*Esperantolaan 4, Heverlee 3001, Belgium*
http://www.atmire.com

--------------------------------------------------
Brian Sheppard
University of Wisconsin Digital Collections Center
bsheppard@library.wisc.edu    (608) 262-3349




_______________________________________________
Handle-Info mailing list
Handle-Info@cnri.reston.va.us
http://www.handle.net/mailman/listinfo/handle-info

Nathan Stevens
Programmer/Analyst
Digital Library Technology Services
New York University
1212-998-2653
ns96@nyu.edu