Thread: [Pas-dev] Re: PAS?
Status: Beta
Brought to you by:
mortis
From: Kyle R . B. <mo...@vo...> - 2002-03-04 23:48:54
|
> I looked again, somehow I overlooked that there *is* a mailing list > (with only one item in it). I did manage to get it working, and so far > I'm impressed. I also see that you have started doing a small amount of > work on it again, so that looks promising... I'll send comments from now > on to the list. I've CC'd this on the pas-dev mailing list (the only list with any activiy at this time). The SourceForge link to the mailing lists is: http://sourceforge.net/mail/?group_id=19226 The Geocrawler link for the dev list archive is here: http://www.geocrawler.com/lists/3/SourceForge/9231/0/ There should be about 9 messages from this month. How did the installation and configuraiton go? Were there any issues with the software? Also, are you using a 'release', or the current CVS tree? There has been some significant development since the last release. Thanks for taking a look. Any feedback at all is welcome. Best Regards, Kyle R. Burton -- ------------------------------------------------------------------------------ Wisdom and Compassion are inseparable. -- Christmas Humphreys mo...@vo... http://www.voicenet.com/~mortis ------------------------------------------------------------------------------ |
From: Bob S. <bo...@or...> - 2002-03-05 01:19:10
|
> I've CC'd this on the pas-dev mailing list (the only list with any activiy at > this time). The SourceForge link to the mailing lists is: > > http://sourceforge.net/mail/?group_id=19226 > > The Geocrawler link for the dev list archive is here: > > http://www.geocrawler.com/lists/3/SourceForge/9231/0/ > > There should be about 9 messages from this month. For some reason the sourceforge list (which comes first) shows only 1 message (the geocrawler archive does show the right number). > > How did the installation and configuraiton go? Were there any issues > with the software? It installed and ran quite easily. The only small glitch was your use of 00INDEX.HTML files, rather than index.html. I'm not sure where the form you use comes from, but index.html seems fairly standard on most apache servers, I think. One thing I was puzzled about was that in the pas.conf file, there are these lines: pas.pages.test=TestPage pas.pages.foobar.quzbaz=TestPage pas.pages.examples.therm.Conv=Therm::ThermPage pas.pages.examples.Redirect=Redirect pas.pages.examples.dbExplorer.Explorer=DbExplorer::Explorer I don't understand how these relate to the following URL, which brings up the test example #1: http://localhost/pas/examples/test.psp > Also, are you using a 'release', or the current CVS tree? There has been > some significant development since the last release. I've so far tried just the latest release. It wasn't clear what was in the CVS. > Thanks for taking a look. Any feedback at all is welcome. There's a lot about it that I like. I like the simplicity of your templating language, and that it maps directly into a Perl class. I'm not sure I'm totally comfortable with your page object model. I would like to be able to abstract out pieces of the page, and then fit them back together, in the template. Really each piece (component?) needs to have its own implementation object, and a separate rendering object. I'd like to be able fit the results back together dynamically. Your work on database connectivity looks interesting, but I haven't checked it out yet. I am definitely interested in reducing the amount of work I have to do when I implement yet-another-table in the database (I want to factor out much of the fetch/store/search/list/modify functionality). I'm thinking that in order to understand what I *really* need to re-implement my website so it's maintainable, is to build the framework myself. So my current plan is to see what the most minimalist system I can possibly build is. I'm thinking of doing it in Ruby. Thanks, Bob |
From: Kyle R . B. <mo...@vo...> - 2002-03-05 03:27:38
|
> For some reason the sourceforge list (which comes first) shows only 1 > message (the geocrawler archive does show the right number). I'm not sure why it's there. The fact that it's listed as: pas-dev Archives 1 messages (SF Mail Archive beta) makes me think that they're looking at servicing their own mailing lists but haven't yet gotten all the way there. > It installed and ran quite easily. The only small glitch was your use of > 00INDEX.HTML files, rather than index.html. I'm not sure where the form > you use comes from, but index.html seems fairly standard on most apache > servers, I think. 00INDEX.HTML was used because with Apache's default sorting order it will nearly always show up as the first file in the list. We didn't want to use an index.html because Apache would have shown that page instead of the directory listing. We purposly wanted to show the directory listing so users could see all of the examples and files from a web brwoser. > One thing I was puzzled about was that in the pas.conf file, there are > these lines: > > pas.pages.test=TestPage > pas.pages.foobar.quzbaz=TestPage > > pas.pages.examples.therm.Conv=Therm::ThermPage > pas.pages.examples.Redirect=Redirect > pas.pages.examples.dbExplorer.Explorer=DbExplorer::Explorer > > I don't understand how these relate to the following URL, which brings > up the test example #1: > > http://localhost/pas/examples/test.psp They are 'registerd' urls. What they do is map a url to a page object which will handle the request for the url. Similarly to Java Servlets. If you have Pas configured as per the INSTALL instructions, then the line: pas.pages.examples.therm.Conv=Therm::ThermPage Registers the url: http://your.host.tld/pas/examples/therm/Conv to be handled by a Therm::ThermPage object (which is derived from Org::Bgw::Pas::SessionPage). When an HTTP request is made to http://your.host.tld/pas/examples/therm/Conv, a Therm::ThermPage object is constructed, and it's execute() method is invoked to handle the request. Therm::ThermPage's execute looks like this: sub execute { my $self = shift; $self->set_default_temperature(); $self->convert_temperatures(); $self->save_values() if($self->temperatures_are_valid()); $self->clear_values() if($self->query()->param('clear')); return $self->forward_request('/examples/therm/therm.psp'); } It sets up a few defaults, performs any requested computations, saves valid computations to a history [a stack] in the session (and clears the stack if requested), and then forwards the request (which contains the results of the computation) to the psp page: '/examples/therm/therm.psp', which renders the results in HTML. > I've so far tried just the latest release. It wasn't clear what was in > the CVS. The current source tree in CVS should be stable enough for use. In fact right now I'm running an intranet website on the current HEAD. > > Thanks for taking a look. Any feedback at all is welcome. > > There's a lot about it that I like. I like the simplicity of your > templating language, and that it maps directly into a Perl class. The model is directly analogous to JSP and Java Servlets. The templating language isn't actauly a language, that's one of the ways in which PSPs are different from the templating languages. The PSP tag's aren't really Perl embedded into HTML, it's easier to understand if you think of it the other way around -- it's mark up [HTML] embedded in a Perl object. One of the easiest things you can do to see what I mean is to go into your psp-cache directory and look at the compiled page object that results from a PSP page. It's straight Perl, a bit noisy, but none the less its just standard Perl syntax. So there is no interpretation on the fly, in fact with Apache/mod_perl, once a PSP is compiled, Apache will keep the compiled page object in memory. > I'm not sure I'm totally comfortable with your page object model. I > would like to be able to abstract out pieces of the page, and then fit > them back together, in the template. Really each piece (component?) > needs to have its own implementation object, and a separate rendering > object. I'd like to be able fit the results back together dynamically. Actualy that's one of the main points of the page object model. As with the temprature conversion example, the idea is to implement all of the application's core functionality in normal Perl objects, use them within a page object (think servlet) to perform the business logic for the application, and then make the data available to the presentation layer (by placing data into the request and forwarding to a PSP page). Between using inheritence, using objects [that you write] outside of the Pas inheritence hierarchy, and choosing a stragety for the presentation layoer, you can work completely within, or nearly completely outside of the page object model. The page object modle is largely there to provide standard support services. Including session support, request processing, response buffering, and basic exception handeling. If you work within the architecture, you don't need to worry about any of those issues, they're all handled for you implicitly. > Your work on database connectivity looks interesting, but I haven't > checked it out yet. I am definitely interested in reducing the amount of > work I have to do when I implement yet-another-table in the database (I > want to factor out much of the fetch/store/search/list/modify > functionality). It's a good thing you brought that up, there have been some changes to that that need to be checked in to CVS. It's not connectivity so much as object generation. I personaly preferr using methods on objects to accessing hash or array elements. It is easier to remember that '$userProfile->firstName()' is the first_name field from the user_profile table, if it's a method than it is to try to remember that '$ar->[3]' is the first_name. So instead of having to write all of these objects to represent records from the database, we generate them. Saves time and makes for cleaner code (in my opinion). > I'm thinking that in order to understand what I *really* need to > re-implement my website so it's maintainable, is to build the framework > myself. So my current plan is to see what the most minimalist system I > can possibly build is. I'm thinking of doing it in Ruby. Well, the JSP/Servlet design is a good one to follow regardless of the language. Thank you again for your feedback. Best Regards, Kyle R. Burton -- ------------------------------------------------------------------------------ Wisdom and Compassion are inseparable. -- Christmas Humphreys mo...@vo... http://www.voicenet.com/~mortis ------------------------------------------------------------------------------ |