Re: [zeta-dev] Introducing myself
Hi, On Tue, Nov 23, 2010 at 11:57 PM, Jerome Renard wrote: > As you said, the very first thing to do is to get familiar with Zeta > Components. > But with regards to what you have already done with Midgard, I believe > it will be a piece of cake. Yep. I'll do some experiments today, and start pitching the idea to the rest of our community. >> * Geolocation library: https://github.com/bergie/midgardmvc_helper_location > > This one is really interesting. Another that might fit into Zeta quite easily is the Forms library. This also is a completely standalone package, though it has a helper for autogenerating forms from Midgard2 schemas (which could be adapted to Zeta database schemas too). https://github.com/midgardproject/midgardmvc_helper_forms http://www.qaiku.com/go/6nbc/ As these two have quite minimal external dependencies I guess they would be the first potential contributions from us to Zeta. The other pieces are a bit more interconnected, and some overlap with existing Zeta stuff so probably it is best to work together first on the simpler stuff and tackle those later. > If possible I would prefer getting only one MVC component in order to > avoid confusion > for users if they want to do MVC. This does not meant yours is bad at > all, it just means > that being able to compare differences with MVCTools [3] and your MVC > framework would > be ideal first. And then we could see how to manage with this, maybe > we could integrate > some parts of your system in MVCTools. This needs to be debated actually. Agreed that multiple MVC implementations in Zeta doesn't sound like a good idea. Actually, probably having any full MVC implementation there doesn't make sense. Therefore the term MVCTools is a good choice, as the project can provide common building blocks for different MVC/CMS projects to implement :-) On a quick look at MVCTools, Midgard MVC is conceptually, and in some places also API-wise quite similar. Here's the basic description of how our MVC works: https://github.com/midgardproject/midgardmvc_core/blob/master/documentation/index.markdown Some quick points: * Routes work very similarly, though we use different URL mapping syntax based on URI templates[1]. So this could be just another MvcRoute implementation * We also rely on a Request object, and use it for request isolation (everything related to a request is kept in that object as we have to support multiple requests within one PHP run) * In Midgard MVC we have full subrequest support, so in your template you can for example make a subrequest to display five latest news items * In our case Routing Information would also contain the matched variables from the URL (so URL /news/meego/2 matched to a route /news/{$category}/{$number} would provide array('category' => 'meego', 'number' => 2) * Our routes are also used for generating URLs when applications want to redirect or display links * We do not require controllers to extend any baseclass as the component interface is quite trivial * In our case controller actions are named with pattern _, so you can define separate action methods for handling GET and POST (for example) for a route * Controller's results in our case are just stored to a "data" array in the controller, so actions don't return anything. In cases of errors they're supposed to throw exceptions * We have a concept similar to MvcTools Filters called Injectors. At the moment you have only two of these: ones called after request has been parsed but before controller is called, and ones after controller has been run but before we go to templating * Views is probably the area where our approaches diverge the most. In Midgard the whole thing is run by template composition, where route only provides aliasing information on how to handle element inclusion in the template. We use TAL as the default templating system > Anyway welcome to the Zeta Components community :) Thanks! The Midgard project has always been quite isolated from the rest of the PHP world (though I guess many other similar projects are also quite insular). Hopefully this collaboration can change things :-) > Jérôme Renard /Henri 1: http://tools.ietf.org/html/draft-gregorio-uritemplate-04 -- Henri Bergius Motorcycle Adventures and Free Software http://bergie.iki.fi/ Skype: henribergius Jabber: henri.berg...@gmail.com Microblog: http://www.qaiku.com/home/bergie/
Re: [zeta-dev] Introducing myself
Hi Henri, On Tue, Nov 23, 2010 at 4:43 PM, Henri Bergius wrote: > Hi, > [...] > > So, how to get started? I guess the main thing is to get familiar with > the existing Zeta Components, and then to start thinking of what of > those we could use within our framework, and what parts of our > framework could be contributed back to Zeta. Some low-hanging fruit > could include: As you said, the very first thing to do is to get familiar with Zeta Components. But with regards to what you have already done with Midgard, I believe it will be a piece of cake. You have to start with ezcBase [1] for two reasons : 1. to get the whole idea of the autoload mechanism because can be quite confusing when it comes to add your own classes. 2. because this is the only dependency for any other component. If you need to get a helicopter view in order to understand how ZC are organized you can have a look at at talk Derick gave a while ago [2]. Maybe Tobias and Kore have more recent slides. > > * Geolocation library: https://github.com/bergie/midgardmvc_helper_location This one is really interesting. > * Our MVC framework: https://github.com/midgardproject/midgardmvc_core If possible I would prefer getting only one MVC component in order to avoid confusion for users if they want to do MVC. This does not meant yours is bad at all, it just means that being able to compare differences with MVCTools [3] and your MVC framework would be ideal first. And then we could see how to manage with this, maybe we could integrate some parts of your system in MVCTools. This needs to be debated actually. Anyway welcome to the Zeta Components community :) 1. http://incubator.apache.org/zetacomponents/documentation/trunk/Base/tutorial.html 2. http://derickrethans.nl/talks/ezc-ezconf9.pdf 3. http://incubator.apache.org/zetacomponents/documentation/trunk/MvcTools/tutorial.html -- Jérôme Renard http://39web.fr | http://jrenard.info | http://twitter.com/jeromerenard
[zeta-dev] Introducing myself
Hi, Just to introduce myself, I'm Henri Bergius, one of the core developers of the Midgard framework. Midgard is one of the oldest open source web frameworks / CMSs for PHP. Midgard is a bit unique that in addition to the actual web layer written in PHP we have a content repository[1] that our system uses for all persistent data storage written in C (well, Vala in the next iteration, but C is what Vala anyway generates), with PHP-level access coming from a specific extension. Midgard has always focused on clean URLs, flexible templating, valid mark-up, integration with third party web services and high level of security. Personally I've been frustrated for a long time with the lack of a generic PHP ecosystem. As PEAR has largely stagnated, almost all interesting library and tool work happens either in complete isolation or within more specific ecosystems like Drupal, ZF, Midgard etc. I see the introduction of Zeta Components into Apache as a promising development that might be the beginning of a generic PHP code-sharing ecosystem[2]. As such, this is an area that both myself, and the Midgard Project in general should be interested in. So, how to get started? I guess the main thing is to get familiar with the existing Zeta Components, and then to start thinking of what of those we could use within our framework, and what parts of our framework could be contributed back to Zeta. Some low-hanging fruit could include: * Geolocation library: https://github.com/bergie/midgardmvc_helper_location * Our MVC framework: https://github.com/midgardproject/midgardmvc_core * Midgard provider for the Zeta Database layer * Midgard provider for the Zeta authentication layer * Maybe Alexey's PHP Application Server: https://github.com/indeyets/appserver-in-php If collaboration on some of these would sound good, I'll be happy to start the discussion in the Midgard end of things. 1: http://bergie.iki.fi/blog/what_is_a_content_repository/ 2: http://bergie.iki.fi/blog/php-finally_getting_an_ecosystem/ -- Henri Bergius Motorcycle Adventures and Free Software http://bergie.iki.fi/ Skype: henribergius Jabber: henri.berg...@gmail.com Microblog: http://www.qaiku.com/home/bergie/
[zeta-dev] Published "Status update" [Was: Re: [zeta-dev] Final: "Status update"]
Hi all, I just published the "Status update" article on our website. You can find it on http://incubator.apache.org/zetacomponents/news/002_status_update.html and it is also visible on the home page and the RSS feed. Thanks to everyone for the feedback, cheers, Toby -- Tobias Schlitthttp://schlitt.infoGPG Key: 0xC462BC14 Want to hire me? Need quality assurance?http://qafoo.com eZ Components are Zeta Components now! http://bit.ly/9S7zbn