Thread: a web framework for postgresql?
Hi, Most of the web applications I work on are nothing more than front-ends to postgresql. I have used Perl (CGI), Java, C# and am now looking at Django. Each generation of frameworks lessens the pain of donig web-apps, but it still seems redundant. Does any one know of a framework where the database server (or a web/app server integrated with a DB server) serves web pages? The database contains the data-model; names of tables, names of attributes, their types, foreign key relationships among tables...that's A LOT of information. Sql query, views or stored procs could serve as 'reports' served off the data. Perhaps the only thing that needs to be outside a database is something that describes how the data is to be displayed (CSS). There could be some java/c#/python/ruby/whatever engine which takes all the information provided in the database and generate html/xhtml, default css, javascript validation, etc....but all that should be invisible to the user. Any one know of such a framework? (I'm asking this in pgsql because such a framework will have to be fairly closely linked to a database...and I mainly use pgsql).
On 01.03.2006, at 19:39 Uhr, falcon wrote: > Any one know of such a framework? > > (I'm asking this in pgsql because such a framework will have to be > fairly closely linked to a database...and I mainly use pgsql). Hmm. No. I don't think you can have this combined with what is often called "business logic". A lot of stuff is described in the db model, but that's only one thing. What about process flows, permissions, login handling, session handling, design, performance optimization and so on? I use WebObjects (http://www.apple.com/webobjects) as my main development environment and I found that every application is unique in a good percentage of its features. For "administration" application the included DirectToWeb-Framwork in combination with a powerful community based framework ("ProjectWonder") is a VERY powerful tool when it comes to rapid development. It saves me days and weeks of work - I just couldn't do my job anymore without it and developing applications in a "standard way". But it has a very steep learning curve and is sometimes hard to handle and often frustration - until you learn how not to fight the tool. Frontend applications like online shops, portals and so on are then developed in a more conventional way with components and handwritten xhtml/css. If you have a Mac for development it's worth a look. Deployment can go anywhere (in theory - we have only used Linux and Mac OS X Server so far) as long as a Java runtime is installed. cug -- PharmaLine, Essen, GERMANY Software and Database Development
Attachment
falcon wrote: > Hi, > Most of the web applications I work on are nothing more than front-ends > to postgresql. I have used Perl (CGI), Java, C# and am now looking at > Django. Each generation of frameworks lessens the pain of donig > web-apps, but it still seems redundant. > > Does any one know of a framework where the database server (or a > web/app server integrated with a DB server) serves web pages? The > database contains the data-model; names of tables, names of attributes, > their types, foreign key relationships among tables...that's A LOT of > information. Sql query, views or stored procs could serve as 'reports' > served off the data. Perhaps the only thing that needs to be outside a > database is something that describes how the data is to be displayed > (CSS). There could be some java/c#/python/ruby/whatever engine which > takes all the information provided in the database and generate > html/xhtml, default css, javascript validation, etc....but all that > should be invisible to the user. > > Any one know of such a framework? > > (I'm asking this in pgsql because such a framework will have to be > fairly closely linked to a database...and I mainly use pgsql). > I don't know of one - I think I'd be a little uneasy with that kind of model to be honest on several levels. Complex web applications involve a lot of complex logic, which tends to be very processor intensive. It's good to be ableto scale such sites by adding more processing engines and so partitioning the logic from the database is a good idea. We use (and wrote) Whitebeam which goes some of the way to providing a framework. It cuts down the amount of database knowledgeyou need by having a defined schema that represents data in a very flexible way (although you are free to develop SQL level applications if youwant to). Whitebeam uses Postgres to model arbitrary things and the relationships between those things. The things can be CMS web pages or productcatalogues. JavaScript (server side) is then used to add the semantic meaning to those things for each application. The Whitebeam abstraction is higher than SQL (for example it represents arbitrarily deep directories of information and providesmechanisms for searching those) while at the same time being flexible enough to allow a wide range of data-driven applications (CMS, discussionforums, surveys, document repositories etc). The programme files that drive the application are still stored in the standard file system. You could store those in thedatabase as well if you wanted to but you'd be adding more contention for a central resource. To get the best performance you have to have a pragmaticapproach to building your system. Most applications also of course have to use other services such as sendmail, spell checkers, image tools. The datbase isonly one part of the solution, although admittedly one you have to get right! Pete -- Whitebeam : (http://www.whitebeam.org) YellowHawk : (http://www.yellowhawk.co.uk)
Pete, I agree with you about websites containing lots of complex logic. It is an interesting excercise to extract out this logic from the day to day business of web app development. In any case, as I think more about various if/else claues or business specific computations, I get even more convinced that either many of our daily routines can be abstracted away, or partitioned (I guess the way the MVC model keeps people like me from putting everything together in a complex mess). It is interesting that much of the software packages specifically marketed for 'business logic' (various rules engines) are, at their most fundamental, not very different from relational DBs. I am also fairly certain that whole programming languages (their semantics and their syntax) can be defined within relational DBs. So why not attempt to use databases as more than just data stores? P.S. I actually don't think the kind of framework I am looking for exists (oracle has html db, but I haven't been able to study it yet). And I should add that I realize theoretical Relational Dbs are different from modern implementations, but we still have a base to work on.
falcon schrieb: > Pete, ... > So why not attempt to use databases as more than just data stores? > > P.S. I actually don't think the kind of framework I am looking for > exists (oracle has html db, but I haven't been able to study it yet). > And I should add that I realize theoretical Relational Dbs are > different from modern implementations, but we still have a base to work > on. Well, strip the relational part from the db and you already have it. We call it Zope :-) (http://www.zope.org ) Regards Tino
On Wednesday 01 March 2006 14:54, falcon wrote: > P.S. I actually don't think the kind of framework I am looking for > exists (oracle has html db, but I haven't been able to study it yet). > And I should add that I realize theoretical Relational Dbs are > different from modern implementations, but we still have a base to work > on. If your up to doing experimentation, you could see about combining one of the pl langs and tie them into one of the various web application frameworks. I'm thinking you could try making plruby functions that use rails, or possibly rigg something up in plpython with django or turbogears. It's all very handwavy, but since you can use gems inside of plruby, who knows... you'd have to figure out how to actually server web requests back and forth from within the db... really it doesnt seem worth it to me, but you might be able to get something together. -- Robert Treat Build A Brighter Lamp :: Linux Apache {middleware} PostgreSQL
Robert, As soon as I have some time, I'll be checking out pl-python in more detail. Tino, I don't know anything about zope, I'll have a look see :)
Drupal is really nice extensible web framework written in PHP. http://drupal.org John DeSoi, Ph.D. http://pgedit.com/ Power Tools for PostgreSQL
falcon wrote: > Hi, > Most of the web applications I work on are nothing more than front-ends > to postgresql. I have used Perl (CGI), Java, C# and am now looking at > Django. Each generation of frameworks lessens the pain of donig > web-apps, but it still seems redundant. > > Does any one know of a framework where the database server (or a > web/app server integrated with a DB server) serves web pages? The > database contains the data-model; names of tables, names of attributes, > their types, foreign key relationships among tables...that's A LOT of > information. Sql query, views or stored procs could serve as 'reports' > served off the data. Perhaps the only thing that needs to be outside a > database is something that describes how the data is to be displayed > (CSS). There could be some java/c#/python/ruby/whatever engine which > takes all the information provided in the database and generate > html/xhtml, default css, javascript validation, etc....but all that > should be invisible to the user. > > Any one know of such a framework? > > (I'm asking this in pgsql because such a framework will have to be > fairly closely linked to a database...and I mainly use pgsql). > > > ---------------------------(end of broadcast)--------------------------- > TIP 5: don't forget to increase your free space map settings > You could probably do put together a single executable with ZILD http://zild.org/index.csp and a DB libraray (sqlite, other embeddable DB) or package ZILD linked to libpq along with a PostgreSQL installation.
We also use WebObjects with PostgreSQL and it's awesome as a web development framework. We have it deployed on Solaris and OS X Server. ____________________________________________________________________ Brendan Duddridge | CTO | 403-277-5591 x24 | brendan@clickspace.com ClickSpace Interactive Inc. Suite L100, 239 - 10th Ave. SE Calgary, AB T2G 0V9 http://www.clickspace.com On Mar 1, 2006, at 11:58 AM, Guido Neitzer wrote: > On 01.03.2006, at 19:39 Uhr, falcon wrote: > >> Any one know of such a framework? >> >> (I'm asking this in pgsql because such a framework will have to be >> fairly closely linked to a database...and I mainly use pgsql). > > Hmm. No. I don't think you can have this combined with what is > often called "business logic". A lot of stuff is described in the > db model, but that's only one thing. > > What about process flows, permissions, login handling, session > handling, design, performance optimization and so on? > > I use WebObjects (http://www.apple.com/webobjects) as my main > development environment and I found that every application is > unique in a good percentage of its features. > > For "administration" application the included DirectToWeb-Framwork > in combination with a powerful community based framework > ("ProjectWonder") is a VERY powerful tool when it comes to rapid > development. It saves me days and weeks of work - I just couldn't > do my job anymore without it and developing applications in a > "standard way". But it has a very steep learning curve and is > sometimes hard to handle and often frustration - until you learn > how not to fight the tool. > > Frontend applications like online shops, portals and so on are then > developed in a more conventional way with components and > handwritten xhtml/css. > > If you have a Mac for development it's worth a look. Deployment can > go anywhere (in theory - we have only used Linux and Mac OS X > Server so far) as long as a Java runtime is installed. > > cug > > -- > PharmaLine, Essen, GERMANY > Software and Database Development > >