Re: [Dspace-tech] LNI/WebDAV : GET returns 501

2008-06-03 Thread Rick Runyan
Thanks a million.  I got lookup and get working today after fooling
around with wget.  I'm glad you told me about not following the
redirects, or I'd have been scratching my head over 400 errors still.

I'm not using PERL; I am using C#.

- Rick

-Original Message-
From: Larry Stone [mailto:[EMAIL PROTECTED] 
Sent: Tuesday, June 03, 2008 1:00 AM
To: Rick Runyan
Cc: dspace-tech@lists.sourceforge.net
Subject: RE: [Dspace-tech] LNI/WebDAV : GET returns 501

You can see how the lookup feature works by using a simple HTTP client
like the GNU "wget" application to do a GET, and reading its diagnostic
output.. for example, this does a lookup of handle 123456789/1
using HTTP Basic authentication to login (assuming you have
username/password
login on your server):

wget [EMAIL PROTECTED] --http-password=PASSWORD -S
http://MYDSPACE.mit.edu:8080/lni/dav/lookup/handle/123456789/1

Now, watch the headers -- the request as a whole will fail because
"wget"
is aggressive about responding to the HTTP 302 status with another GET
on
the real resource, but that GET probably isn't allowed or is missing
some
option.  Anyway, just look for the Location: header in the first
response:

Connecting to rotarran.mit.edu|18.42.4.43|:8080... connected.
HTTP request sent, awaiting response...
  HTTP/1.1 302 These are not the droids you are looking for.
  Set-Cookie:
DSpaceDavAuth=1212468843785!1!18.42.4.8!ac52bf780d4bb6eb486b810a7d
5c4f24; Path=/lni
  Location: http://rotarran.mit.edu:8080/lni/dav/dso_123456789%241
  ^^

  Content-Length: 0
  Date: Tue, 03 Jun 2008 04:54:03 GMT
  Server: Apache-Coyote/1.1
  Connection: Keep-Alive

{Here's the second try, which fails.. ignore it, we've got what we
need.}

Location: http://rotarran.mit.edu:8080/lni/dav/dso_123456789%241
[following]
--00:54:03--  http://rotarran.mit.edu:8080/lni/dav/dso_123456789%241
   => `dso_123456789$1'
Reusing existing connection to rotarran.mit.edu:8080.
HTTP request sent, awaiting response...
  HTTP/1.1 501 GET method not implemented for Community.
  Content-Type: text/html;charset=utf-8
  Content-Length: 1112
  Date: Tue, 03 Jun 2008 04:54:03 GMT
  Server: Apache-Coyote/1.1
  Connection: close
00:54:03 ERROR 501: GET method not implemented for Community..

This ought to show how to implement what you need with Apache HTTPClient
or something like that.

You're not using Perl, are you?  The WebDAV library on CPAN was horribly
broken last I looked, not really usable for this at all.

Also, note that you don't *need* to go through the hierarchy to get at
any Handle in the archive.  If you already have the Handle of the
resource
you're looking for, just do a "lookup" to get its URL and use that.
Traversing the hierarchy is just for exploring, and because it's the
model of HTTP and WebDAV.

-- Larry

> Thanks for the helpful response.  I've still been unable to do a
lookup
> or a get, but I'm concentrating right now on walking through the
> hierarchy to learn what turns up and what kind of properties I'll
find.
> When I get comfortable with that, I'll re-read your message and try
> again.
>
> - Rick
>


-
This SF.net email is sponsored by: Microsoft
Defy all challenges. Microsoft(R) Visual Studio 2008.
http://clk.atdmt.com/MRT/go/vse012070mrt/direct/01/
___
DSpace-tech mailing list
DSpace-tech@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/dspace-tech


Re: [Dspace-tech] LNI/WebDAV : GET returns 501

2008-06-02 Thread Rick Runyan
Larry -

Thanks for the helpful response.  I've still been unable to do a lookup
or a get, but I'm concentrating right now on walking through the
hierarchy to learn what turns up and what kind of properties I'll find.
When I get comfortable with that, I'll re-read your message and try
again.

- Rick

-Original Message-
From: Larry Stone [mailto:[EMAIL PROTECTED] 
Sent: Thursday, May 29, 2008 4:54 PM
To: Rick Runyan
Cc: dspace-tech@lists.sourceforge.net
Subject: Re: [Dspace-tech] LNI/WebDAV : GET returns 501

GET only works on Items and Bitstreams, so if you get the resource path
to a Bitstream from PROPFIND (depth=1) on an Item, then you ought to be
able
to do a GET on it and receive its contents.

This path looks like you've traversed some communities and collections:

>
http://[server]:8080/lni/dav/dso_123456789%241/dso_123456789%242/dso_123
456789%243

You can also get a resource URL by doing a "lookup" on a Handle, e.g.
GET
on http://[server]:8080/lni/dav/lookup/handle/123456789/42
returns a Location: header with the URL.  I don't think it works on
Bitstreams, though.

Anyway, if you do a PROPFIND on that resource you're trying to GET, look
at the value for "type" (in the "http://www.dspace.org/xmlns/dspace";
namespace).
It'll be an empty element for the DSpace object type, either
,
, , 

Typically, the Bitstream resources have a path ending in
  /bitstream_{n}.{suffix}, e.g.  .../bitstream_3.pdf

So, I think the problem here is that you've got a resource for which
GET isn't implemented.

For some sketchy doc which is unfortunately the best available, see
http://web.mit.edu/lcs/www/lni/

-- Larry

> I've finally figured out how to hook up a .NET app to LNI and am
running
> some exploratory tests, using straight HTTP/DAV rather than SOAP. =20
>
> Alas, GET doesn't seem to work.  I've done a propfind call to get URIs
> for the bitstreams in a collection, but when I try to GET one of them,
I
> get
>
> =20
>
> System.ApplicationException: Error trying to GET
>
http://[server]:8080/lni/dav/dso_123456789%241/dso_123456789%242/dso_123
> 456789%243 --->=20
>
> System.Net.WebException: The remote server returned an error: (501)
Not
> Implemented.
>
>  at System.Net.HttpWebRequest.GetResponse()
>
> =20
>
> I am unfamiliar with Axis web services, so I'm having to learn
> everything as I go, which slows me down a lot.
>
> This entry in server-config.wsdd listing "allowedMethods" looks
> suspicious to me
>
>  
>
>  lookup
> copy"/>
>
>  value=3D"org.dspace.app.dav.LNISoapServlet"/>
>
>  
>
> But the web.xml file has a different class
> (org.dspace.app.dav.DAVServlet) set up to respond to /dav URIs, so I
> suspect that's not my problem.
>
> =20
>
> - Rick
>
> =20
>
> =20
>
>
> --_=_NextPart_001_01C8C190.AFE31B16
> Content-Type: text/html;
>   charset="us-ascii"
> Content-Transfer-Encoding: quoted-printable
>
>  xmlns:w=3D"urn:schemas-microsoft-com:office:word" =
> xmlns=3D"http://www.w3.org/TR/REC-html40";>
>
> 
>  charset=3Dus-ascii">
> 
> 
> <!--
>  /* Font Definitions */
>  @font-face
>   {font-family:"Californian FB";
>   panose-1:2 7 4 3 6 8 11 3 2 4;}
>  /* Style Definitions */
>  p.MsoNormal, li.MsoNormal, div.MsoNormal
>   {margin:0in;
>   margin-bottom:.0001pt;
>   font-size:12.0pt;
>   font-family:"Times New Roman";}
> a:link, span.MsoHyperlink
>   {color:blue;
>   text-decoration:underline;}
> a:visited, span.MsoHyperlinkFollowed
>   {color:purple;
>   text-decoration:underline;}
> span.EmailStyle17
>   {mso-style-type:personal-compose;
>   font-family:"Californian FB";
>   color:windowtext;
>   font-weight:normal;
>   font-style:normal;
>   text-decoration:none none;}
> @page Section1
>   {size:8.5in 11.0in;
>   margin:1.0in 1.25in 1.0in 1.25in;}
> div.Section1
>   {page:Section1;}
> -->
> 
>
> 
>
> 
>
> 
>
>  style=3D'font-size:
> 11.0pt;font-family:"Californian FB"'>I’ve finally figured out
how =
> to hook
> up a .NET app to LNI and am running some exploratory tests, using =
> straight
> HTTP/DAV rather than SOAP.  
>
>  style=3D'font-size:
> 11.0pt;font-family:"Californian FB"'>Alas, GET doesn’t seem to
> work.  I’ve done a propfind call to get URIs for the =
> bitstreams in a
> collection, but when I try to GET one of them, I =
> get
>
>  style=3D'font-size:
> 11.0pt;font-family:"C

[Dspace-tech] LNI/WebDAV : GET returns 501

2008-05-29 Thread Rick Runyan
I've finally figured out how to hook up a .NET app to LNI and am running
some exploratory tests, using straight HTTP/DAV rather than SOAP.  

Alas, GET doesn't seem to work.  I've done a propfind call to get URIs
for the bitstreams in a collection, but when I try to GET one of them, I
get

 

System.ApplicationException: Error trying to GET
http://[server]:8080/lni/dav/dso_123456789%241/dso_123456789%242/dso_123
456789%243 ---> 

System.Net.WebException: The remote server returned an error: (501) Not
Implemented.

 at System.Net.HttpWebRequest.GetResponse()

 

I am unfamiliar with Axis web services, so I'm having to learn
everything as I go, which slows me down a lot.

This entry in server-config.wsdd listing "allowedMethods" looks
suspicious to me

 





 

But the web.xml file has a different class
(org.dspace.app.dav.DAVServlet) set up to respond to /dav URIs, so I
suspect that's not my problem.

 

- Rick

 

 

-
This SF.net email is sponsored by: Microsoft
Defy all challenges. Microsoft(R) Visual Studio 2008.
http://clk.atdmt.com/MRT/go/vse012070mrt/direct/01/___
DSpace-tech mailing list
DSpace-tech@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/dspace-tech


[Dspace-tech] Creating a WSDL file for LNI

2008-05-22 Thread Rick Runyan
Hi -

 

I have been fighting with this for about three days now, so I'm giving
up the thought that I can figure it out on my own.

 

I want to call LNI from a .NET client, so I need a WSDL file (at least,
I think I do).  I've been trying to create one using the Axis JAVA2WSDL
command, but I'm always getting a "Class not found" error.  Speaking of
which, I assume that the class I'd want to do this to is
LNISoapServlet.java...

 

Has anybody done this successfully and, if so, can you tell me how you
did it?

 

- Rick

 

 

-
This SF.net email is sponsored by: Microsoft
Defy all challenges. Microsoft(R) Visual Studio 2008.
http://clk.atdmt.com/MRT/go/vse012070mrt/direct/01/___
DSpace-tech mailing list
DSpace-tech@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/dspace-tech


[Dspace-tech] LNI - no index.html; "The requested resource (/lni/) is not available"

2008-05-16 Thread Rick Runyan
lni is right there in the Tomcat webapps folder right beside xmlui,
which works like a champ.  I'm not experienced with web apps, and even
less so with java web apps, so I'm at something of a loss here.  I've
spent a while reading and trying to figure out the problem, with not
much success.  Mostly, it seems like there should be an index.html file
in the WEB-INF directory, but there's not one.

 

Anybody got lni working who'd like to give me a hint?

 

- Rick

 

 

-
This SF.net email is sponsored by: Microsoft 
Defy all challenges. Microsoft(R) Visual Studio 2008. 
http://clk.atdmt.com/MRT/go/vse012070mrt/direct/01/___
DSpace-tech mailing list
DSpace-tech@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/dspace-tech


[Dspace-tech] xmlui: "The requested resource (/dspace/forgot) is not available" - [also, (/dspace/register) is not available]

2008-03-27 Thread Rick Runyan
Hi -

 

I'm trying to create some non-administrator  users in DSpace 1.5, which
goes OK until they try to follow the link in the email.  Then they get a
404 error, whose description is "The requested resource (/dspace/forgot)
is not available."  I have more or less the same problem when a user
tries to self-register, but the message is "The requested resource
(/dspace/register) is not available."

 

I found a message
<http://mailman.mit.edu/pipermail/dspace-general/2006-November/001160.ht
ml>  from Nov 2006 on DSpace-general, where somebody had a similar
problem, but that seemed to be a path issue, which I don't think is my
problem.  I also saw bug 1606456 in the KNOWN_BUGS file, but I can't
tell whether that's really it, either.

 

I searched for files with "register" in their names in my
[dspace-source] directory, and found a dozen or so of them in
directories with jspui somewhere in the path, but none where xmlui was
in the path.

I'm using the xmlui and just for the hell of right now, the Kubrick
theme.  I did find some Java code in eperson under xmlui, but that
wouldn't have anything to do with a path problem.  I think.

 

Is the solution to my problem obvious to anyone?

 

Thanks

- Rick Runyan

 

-
Check out the new SourceForge.net Marketplace.
It's the best place to buy or sell services for
just about anything Open Source.
http://ad.doubleclick.net/clk;164216239;13503038;w?http://sf.net/marketplace___
DSpace-tech mailing list
DSpace-tech@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/dspace-tech


Re: [Dspace-tech] Oracle and DSpace 1.5 and "ILIKE"

2008-03-25 Thread Rick Runyan
Cool.  A fix *and* and explanation!  How can you beat that?

By the way, if you're actually fixing the real code, there are more
ILIKEs in 
public static EPerson[] search(Context context, String query, int
offset, int limit)

Thanks,
- Rick

-Original Message-
From: Greg McClellan [mailto:[EMAIL PROTECTED] 
Sent: Tuesday, March 25, 2008 4:31 PM
To: Rick Runyan
Cc: dspace-tech@lists.sourceforge.net
Subject: Re: [Dspace-tech] Oracle and DSpace 1.5 and "ILIKE"

Hi,

I think it worked in 1.4.2 only if you used the default jspui interface 
(it doesn't call searchResultCount). Manakin/xmlui on the other hand 
does call it, so it breaks.

I altered the code to be oracle friendly:

TableRow row = DatabaseManager.querySingle(context,
"SELECT count(*) as count FROM eperson WHERE eperson_id = ? OR " +
"lower(firstname) LIKE ? OR lower(lastname) LIKE ? OR lower(email) LIKE
?",
new Object[] {int_param,dbquery,dbquery,dbquery});

I assume that would work in postgres as well, but I haven't tested it. 
You would also have to make a similar change in Group.java as well.

I haven't looked too closely at 1.5, but it works in 1.4.2.

Hope this helps.

-Greg

Rick Runyan wrote:
>
> Hi -
>
> I'm trying to install DSpace 1.5 using Oracle. It wasn't until 
> yesterday that I saw this in the KNOWN_BUGS file:
>
> "Oracle compatibility: this release does not support Oracle. Check for

> patches or updates to this release to restore Oracle compatibility."
>
> But nevertheless, I thought I had read that people had done successful

> installs using Oracle, and I wound up also getting it installed OK, 
> but now I'm running into a problem in the eperson code when I click 
> the "People" link under "Access Control."
>
> Specifically, I get this exception:
>
> java.sql.SQLException: ORA-00920: invalid relational operator
>
> and looking through the stack trace, it appears to be coming from
>
> org.dspace.eperson.EPerson.searchResultCount(EPerson.java:326)
>
> where it says
>
> TableRow row = DatabaseManager.querySingle(context,
>
> "SELECT count(*) as count FROM eperson WHERE eperson_id = ? OR " +
>
> "firstname ILIKE ? OR lastname ILIKE ? OR email ILIKE ?",
>
> new Object[] {int_param,dbquery,dbquery,dbquery});
>
> I'm pretty sure "ILIKE" doesn't work in Oracle, but I see this in the 
> 1.4.2 code and I'm pretty sure I was able t create some users in that.

> Does anybody have any idea about what's wrong here?
>
> Thanks,
>
> Rick Runyan
>
>

>
>

-
> This SF.net email is sponsored by: Microsoft
> Defy all challenges. Microsoft(R) Visual Studio 2008.
> http://clk.atdmt.com/MRT/go/vse012070mrt/direct/01/
>

>
> ___
> DSpace-tech mailing list
> DSpace-tech@lists.sourceforge.net
> https://lists.sourceforge.net/lists/listinfo/dspace-tech
>   


-
This SF.net email is sponsored by: Microsoft
Defy all challenges. Microsoft(R) Visual Studio 2008.
http://clk.atdmt.com/MRT/go/vse012070mrt/direct/01/
___
DSpace-tech mailing list
DSpace-tech@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/dspace-tech


[Dspace-tech] Oracle and DSpace 1.5 and "ILIKE"

2008-03-25 Thread Rick Runyan
Hi -

 

I'm trying to install DSpace 1.5 using Oracle.  It wasn't until
yesterday that I saw this in the KNOWN_BUGS file:

"Oracle compatibility: this release does not support Oracle. Check for
patches or updates to this release to restore Oracle compatibility."

 

But nevertheless, I thought I had read that people had done successful
installs using Oracle, and I wound up also getting it installed OK, but
now I'm running into a problem in the eperson code when I click the
"People" link under "Access Control."  

 

Specifically, I get this exception:

java.sql.SQLException: ORA-00920: invalid relational operator

and looking through the stack trace, it appears to be coming from 

org.dspace.eperson.EPerson.searchResultCount(EPerson.java:326)

where it says 

TableRow row = DatabaseManager.querySingle(context,

"SELECT count(*) as count FROM eperson WHERE
eperson_id = ? OR " + 

"firstname ILIKE ? OR lastname ILIKE ? OR email
ILIKE ?",

new Object[]
{int_param,dbquery,dbquery,dbquery});

 

I'm pretty sure "ILIKE" doesn't work in Oracle, but I see this in the
1.4.2 code and I'm pretty sure I was able t create some users in that.
Does anybody have any idea about what's wrong here?

 

Thanks,

Rick Runyan

-
This SF.net email is sponsored by: Microsoft
Defy all challenges. Microsoft(R) Visual Studio 2008.
http://clk.atdmt.com/MRT/go/vse012070mrt/direct/01/___
DSpace-tech mailing list
DSpace-tech@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/dspace-tech


Re: [Dspace-tech] Pluggable Storage Question(s)

2008-03-07 Thread Rick Runyan
Richard -

Thanks for your reply.  I actually posted something on the discussion
page of the Pluggable Storage wiki last August, but apparently it hasn't
garnered many glances
(http://wiki.dspace.org/index.php/Talk:PluggableStorage).  I considered
those same possibilities, but they all led to other cans of worms,
particularly since we're expecting to see some really big files (well,
too big for memory, anyway).

I'd be happy to have you look at my code.  I have no experience in the
open-source world, and I wasn't sure how I could contribute what I'd
done in case anybody might be interested, but maybe this is how.

What would be the best thing to do (after I give it the once-over to
remove any obvious stupidisms and lazy hacks)?  Send it to you?

- Rick

-Original Message-
From: Richard Rodgers [mailto:[EMAIL PROTECTED] 
Sent: Friday, March 07, 2008 3:42 PM
To: Rick Runyan
Cc: dspace-tech@lists.sourceforge.net
Subject: Re: [Dspace-tech] Pluggable Storage Question(s)

Hi Rick:

Pluggable Storage is definitely on near horizon, but it isn't part of
the 1.5 distribution. I had been waiting for a few other adopters to
insure that it was adequate. I believe we will see a Sun Honeycomb
implementation soon. There are indeed issues with DB connection
management - which is why I didn't add a RDBMS implementation at the
outset. I'm not sure what the optimal solution is, but there might be
possibilites in writing to a temporary memory or disk cache, where the
usual read semantics would apply. If you want to send your code (or post
to the wiki), I'd be glad to kibbitz...

Thanks,

Richard 

On Fri, 2008-03-07 at 14:50 -0500, Rick Runyan wrote:
> Hi -
> 
>  
> 
> I used the Pluggable Storage interface to modify a 1.4.2 test
> installation to store bitstreams as blobs in an Oracle database.  I'm
> curious as to whether anybody has moved a working PS implementation to
> 1.5.
> 
>  
> 
> Also, about my implementation - I had to modify the interface so that
> the bitstore methods' callers would pass in their Context.  
> 
>  
> 
> Strictly speaking, this was necessary only for the 'get' method.  The
> problem I had is that when those methods manage their own connections,
> they have to close them before they return.  That meant the connection
> to the blob stream was closed before get's caller could begin reading
> it.  Has anybody encountered a similar problem?  Am I overlooking some
> painfully simple solution?
> 
>  
> 
> - Rick Runyan
> 
>  
> 
> 
>

-
> This SF.net email is sponsored by: Microsoft
> Defy all challenges. Microsoft(R) Visual Studio 2008.
> http://clk.atdmt.com/MRT/go/vse012070mrt/direct/01/
> ___ DSpace-tech mailing
list DSpace-tech@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/dspace-tech


-
This SF.net email is sponsored by: Microsoft
Defy all challenges. Microsoft(R) Visual Studio 2008.
http://clk.atdmt.com/MRT/go/vse012070mrt/direct/01/
___
DSpace-tech mailing list
DSpace-tech@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/dspace-tech


[Dspace-tech] Pluggable Storage Question(s)

2008-03-07 Thread Rick Runyan
Hi -

 

I used the Pluggable Storage interface to modify a 1.4.2 test
installation to store bitstreams as blobs in an Oracle database.  I'm
curious as to whether anybody has moved a working PS implementation to
1.5.

 

Also, about my implementation - I had to modify the interface so that
the bitstore methods' callers would pass in their Context.  

 

Strictly speaking, this was necessary only for the 'get' method.  The
problem I had is that when those methods manage their own connections,
they have to close them before they return.  That meant the connection
to the blob stream was closed before get's caller could begin reading
it.  Has anybody encountered a similar problem?  Am I overlooking some
painfully simple solution?

 

- Rick Runyan

 

-
This SF.net email is sponsored by: Microsoft
Defy all challenges. Microsoft(R) Visual Studio 2008.
http://clk.atdmt.com/MRT/go/vse012070mrt/direct/01/___
DSpace-tech mailing list
DSpace-tech@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/dspace-tech