Beefy Boxes and Bandwidth Generously Provided by pair Networks
"be consistent"
 
PerlMonks  

Re: Looking for REST equivalent to WWW::Mechanize

by markjugg (Curate)
on Sep 12, 2006 at 18:08 UTC ( #572590=note: print w/ replies, xml ) Need Help??


in reply to Looking for REST equivalent to WWW::Mechanize

I find this post confusing. I understand REST to be centered around clean URLs. In that case, maybe CGI::Application::Dispatch is what you are looking for. It works well for me. You mentioned delivering XML, but that's not technically part of REST.

On the other hand, WWW::Mechanize should have little trouble retrieving XML. Your application just needs to serve it.

It would be helpful to see some more concrete examples or description of the problem you are running into.


Comment on Re: Looking for REST equivalent to WWW::Mechanize
Re^2: Looking for REST equivalent to WWW::Mechanize
by talexb (Canon) on Sep 12, 2006 at 20:31 UTC

    It may be that my post is confusing .. I'm still trying to understand how it all works, and what tools to use from CPAN.

    I'm working from the REST definition in the REST article:

      REST strictly refers to a collection of architectural principles (described below). The term is also often used in a looser sense to describe any simple interface that uses XML (or YAML, JSON, plain text) over HTTP without an additional messaging layer such as SOAP.
    I'm trying to emit XML in response to clean URLs with a view towards providing a simple interface for the web application that I'm writing.

    My plan is that I'll provide clients with Perl or shell scripts to upload/download files, without having to worry about providing something that needs to parse XHTML web pages -- instead, they'll be able to talk XML, which will be strictly data, no ornamentation. This is a follow-on to my previous post on the same topic.

    Alex / talexb / Toronto

    "Groklaw is the open-source mentality applied to legal research" ~ Linus Torvalds

Re^2: Looking for REST equivalent to WWW::Mechanize
by talexb (Canon) on Sep 13, 2006 at 20:47 UTC

    After fiddling a bit with XML, I decided to take an easier approach, and decided to use YAML instead of XML. I now have a working test suite that tests against both the XHTML and the REST/YAML interfaces, using the same test data. I ended up just using LWP::UserAgent for that -- WWW::Mechanize wasn't necessary for testing of the REST/YAML side.

    And I need to thank you for that -- you stated that XML wasn't necessarily part of REST, and you're right. Once again, Perlmonks provides great feedback, something that I rely on, since I'm the only Perl developer at my employer who is focussing on the web.

    Alex / talexb / Toronto

    "Groklaw is the open-source mentality applied to legal research" ~ Linus Torvalds

Log In?
Username:
Password:

What's my password?
Create A New User
Node Status?
node history
Node Type: note [id://572590]
help
Chatterbox?
and the web crawler heard nothing...

How do I use this? | Other CB clients
Other Users?
Others wandering the Monastery: (4)
As of 2014-10-24 07:21 GMT
Sections?
Information?
Find Nodes?
Leftovers?
    Voting Booth?

    For retirement, I am banking on:










    Results (130 votes), past polls