Clojure Web Framework, what I want to add
After many years (decade) of web development, here are the things that I want in a framework, mostly based in clojure: What do you think and what you add. This is ambitious and just a "ideas" of what I would add. What would you want from your ideal framework? 1. Based on Spring Framework for middleware: Reason: there are years and years and years of development spent on spring and there are many things done right. If I were integrating with any other third party libraries, I would use spring. Spring is added to my framework. 2. Based on Hibernate for ORM mapping: Reason: the defacto standard for ORM mapping with Java. And also used by NHibernate. There is a lot of support for most popular databases. 3. Clojure/Lisp based configuration AND default XML configurations. This has become the standard way to configure a J2EE web application including spring and hibernate. But I would like a lisp oriented configuration. 4. Easy mapping to URLs. I like python's approach for URL mapping 5. Clojure based, framework based server pages AND JSPs. I have always hated some aspects of JSP and ASPs, etc, etc. They are just too complicated. I would want to use Clojure code within the framework oriented server page and other predefined tags. 5. Lift like reusable server pages. Lift has an interesting approach for resuing the same page. E.g. you have an if-else statement within the page. If request == GET ...render this if request == POST ...render this. if URL == 'abc.html' .. render this. I want to embed this in my framework. You only touch one page, but you get different outputs depending on the request method or URL, etc, etc. 6. Use of Clojure syntactic sugar -- TO BE DETERMINED. There is the ability to use powerful Clojure constructs with this framework but I haven't figured out how yet. 7. Better integration of CSS, Javascript, HTML. A lot of a web application still resides with the client side. I have yet to see an web framework that addresses client development (besides GWT). Maybe something as simple as server page tags for CSS? Javascript? 8. Additional third party libraries: Lucene, iText, jFreeChart, optional Terracotta integration Other optional/additional thoughts. 9. Clear separation between back-end and front-end layers --~--~-~--~~~---~--~~ You received this message because you are subscribed to the Google Groups "Clojure" group. To post to this group, send email to clojure@googlegroups.com To unsubscribe from this group, send email to clojure+unsubscr...@googlegroups.com For more options, visit this group at http://groups.google.com/group/clojure?hl=en -~--~~~~--~~--~--~---
Re: Clojure Web Framework, what I want to add
Personally, I've been noodling about what a Tapestry/Clojure hybrid might look like. I'd advise that you take a peek at Lift, a functional web framework built on Scala. I have some ideas about what a component based framework would look like in a function world (note: this would be leaving JSPs and the like far in the dust, and moving toward a higher-order solution more like Tapestry). On the output side, I see the templates being represented as nested DOM structures, and components would operate by transforming the DOM (or a subtree of the DOM) according to their own template and code. I think the request handling side of things would be a bit more traditional and action based, with routing functions that would locate handler functions of some form, via some mix of naming conventions and start-up registrations. I can definitely envision areas where the (binding) construct would be awesome for rewiring the processing of a request for specific needs, things that in Tapestry require active filter objects contributed statically into global pipelines. but I've still got a lot of ideas for T5 to work on first :-) Web frameworks are a tricky beast (I'm eight+ years into writing Tapestry) there are aspects that line up beautifully with stateless functions, but when you introduce the benefits of components, you also bring in a lot that benefits from stateful, mutable, internal state. On Mon, Mar 16, 2009 at 4:17 PM, BerlinBrown wrote: > > After many years (decade) of web development, here are the things that > I want in a framework, mostly based in clojure: > > What do you think and what you add. This is ambitious and just a > "ideas" of what I would add. What would you want from your ideal > framework? > > 1. Based on Spring Framework for middleware: > Reason: there are years and years and years of development spent on > spring and there are many things done right. If I were integrating > with any other third party libraries, I would use spring. Spring is > added to my framework. > > 2. Based on Hibernate for ORM mapping: > Reason: the defacto standard for ORM mapping with Java. And also used > by NHibernate. There is a lot of support for most popular databases. > > 3. Clojure/Lisp based configuration AND default XML configurations. > This has become the standard way to configure a J2EE web application > including spring and hibernate. But I would like a lisp oriented > configuration. > > 4. Easy mapping to URLs. I like python's approach for URL mapping > > 5. Clojure based, framework based server pages AND JSPs. I have > always hated some aspects of JSP and ASPs, etc, etc. They are just > too complicated. I would want to use Clojure code within the > framework oriented server page and other predefined tags. > > 5. Lift like reusable server pages. Lift has an interesting approach > for resuing the same page. E.g. you have an if-else statement within > the page. > > If request == GET > ...render this > if request == POST > ...render this. > if URL == 'abc.html' > .. render this. > > I want to embed this in my framework. You only touch one page, but > you get different outputs depending on the request method or URL, etc, > etc. > > 6. Use of Clojure syntactic sugar -- TO BE DETERMINED. There is the > ability to use powerful Clojure constructs with this framework but I > haven't figured out how yet. > > 7. Better integration of CSS, Javascript, HTML. A lot of a web > application still resides with the client side. I have yet to see an > web framework that addresses client development (besides GWT). Maybe > something as simple as server page tags for CSS? Javascript? > > 8. Additional third party libraries: > > Lucene, iText, jFreeChart, optional Terracotta integration > > > Other optional/additional thoughts. > > 9. Clear separation between back-end and front-end layers > > > > > -- Howard M. Lewis Ship Creator Apache Tapestry and Apache HiveMind --~--~-~--~~~---~--~~ You received this message because you are subscribed to the Google Groups "Clojure" group. To post to this group, send email to clojure@googlegroups.com To unsubscribe from this group, send email to clojure+unsubscr...@googlegroups.com For more options, visit this group at http://groups.google.com/group/clojure?hl=en -~--~~~~--~~--~--~---
Re: Clojure Web Framework, what I want to add
I'm not sure if some of the design inputs make sense, specifically Spring and Hibernate. Point 1 - I've found the strength of Spring to be making up for the weaknesses of Java. Once you have first class functions, macros, and multi-methods (to name a few), Spring doesn't bring much to the table any more. Add in a few Unix utilities like cron and others, you remove the rest of the features. Point 2 - As for Hibernate, ORM doesn't make much sense with a functional language either. The SQL library in clojure-contrib lets you load a map, and you can create way more interesting queries with clojure than hibernate. S-expressions are that powerful. Point 3 - I'd follow Rails example and use strong defaults, and resort to XML only when necessary. Point 4 - Sounds good. Point 5 - Have you looked into compojure? It does a really good job of turning s-expressions into HTML. Point 5 (the second one) - See compojure again. Point 6 & 7 - This is where a lot of work is to be done. I'm not sure how to respond right now. I'll think about it. Point 8 - This is why clojure is awesome. I'll leave this as an exercise to the user :) Point 9 - Yeah, this would be a great feature. That's my thoughts. On Mar 16, 7:17 pm, BerlinBrown wrote: > After many years (decade) of web development, here are the things that > I want in a framework, mostly based in clojure: > > What do you think and what you add. This is ambitious and just a > "ideas" of what I would add. What would you want from your ideal > framework? > > 1. Based on Spring Framework for middleware: > Reason: there are years and years and years of development spent on > spring and there are many things done right. If I were integrating > with any other third party libraries, I would use spring. Spring is > added to my framework. > > 2. Based on Hibernate for ORM mapping: > Reason: the defacto standard for ORM mapping with Java. And also used > by NHibernate. There is a lot of support for most popular databases. > > 3. Clojure/Lisp based configuration AND default XML configurations. > This has become the standard way to configure a J2EE web application > including spring and hibernate. But I would like a lisp oriented > configuration. > > 4. Easy mapping to URLs. I like python's approach for URL mapping > > 5. Clojure based, framework based server pages AND JSPs. I have > always hated some aspects of JSP and ASPs, etc, etc. They are just > too complicated. I would want to use Clojure code within the > framework oriented server page and other predefined tags. > > 5. Lift like reusable server pages. Lift has an interesting approach > for resuing the same page. E.g. you have an if-else statement within > the page. > > If request == GET > ...render this > if request == POST > ...render this. > if URL == 'abc.html' > .. render this. > > I want to embed this in my framework. You only touch one page, but > you get different outputs depending on the request method or URL, etc, > etc. > > 6. Use of Clojure syntactic sugar -- TO BE DETERMINED. There is the > ability to use powerful Clojure constructs with this framework but I > haven't figured out how yet. > > 7. Better integration of CSS, Javascript, HTML. A lot of a web > application still resides with the client side. I have yet to see an > web framework that addresses client development (besides GWT). Maybe > something as simple as server page tags for CSS? Javascript? > > 8. Additional third party libraries: > > Lucene, iText, jFreeChart, optional Terracotta integration > > > Other optional/additional thoughts. > > 9. Clear separation between back-end and front-end layers --~--~-~--~~~---~--~~ You received this message because you are subscribed to the Google Groups "Clojure" group. To post to this group, send email to clojure@googlegroups.com To unsubscribe from this group, send email to clojure+unsubscr...@googlegroups.com For more options, visit this group at http://groups.google.com/group/clojure?hl=en -~--~~~~--~~--~--~---
Re: Clojure Web Framework, what I want to add
I'd love to see something built around very-high scalability, using NIO and thread pools and such. On Mon, Mar 16, 2009 at 7:40 PM, Sean wrote: > > I'm not sure if some of the design inputs make sense, specifically > Spring and Hibernate. > > Point 1 - I've found the strength of Spring to be making up for the > weaknesses of Java. Once you have first class functions, macros, and > multi-methods (to name a few), Spring doesn't bring much to the table > any more. Add in a few Unix utilities like cron and others, you > remove the rest of the features. > > Point 2 - As for Hibernate, ORM doesn't make much sense with a > functional language either. The SQL library in clojure-contrib lets > you load a map, and you can create way more interesting queries with > clojure than hibernate. S-expressions are that powerful. > > Point 3 - I'd follow Rails example and use strong defaults, and resort > to XML only when necessary. > > Point 4 - Sounds good. > > Point 5 - Have you looked into compojure? It does a really good job > of turning s-expressions into HTML. > > Point 5 (the second one) - See compojure again. > > Point 6 & 7 - This is where a lot of work is to be done. I'm not sure > how to respond right now. I'll think about it. > > Point 8 - This is why clojure is awesome. I'll leave this as an > exercise to the user :) > > Point 9 - Yeah, this would be a great feature. > > That's my thoughts. > > On Mar 16, 7:17 pm, BerlinBrown wrote: > > After many years (decade) of web development, here are the things that > > I want in a framework, mostly based in clojure: > > > > What do you think and what you add. This is ambitious and just a > > "ideas" of what I would add. What would you want from your ideal > > framework? > > > > 1. Based on Spring Framework for middleware: > > Reason: there are years and years and years of development spent on > > spring and there are many things done right. If I were integrating > > with any other third party libraries, I would use spring. Spring is > > added to my framework. > > > > 2. Based on Hibernate for ORM mapping: > > Reason: the defacto standard for ORM mapping with Java. And also used > > by NHibernate. There is a lot of support for most popular databases. > > > > 3. Clojure/Lisp based configuration AND default XML configurations. > > This has become the standard way to configure a J2EE web application > > including spring and hibernate. But I would like a lisp oriented > > configuration. > > > > 4. Easy mapping to URLs. I like python's approach for URL mapping > > > > 5. Clojure based, framework based server pages AND JSPs. I have > > always hated some aspects of JSP and ASPs, etc, etc. They are just > > too complicated. I would want to use Clojure code within the > > framework oriented server page and other predefined tags. > > > > 5. Lift like reusable server pages. Lift has an interesting approach > > for resuing the same page. E.g. you have an if-else statement within > > the page. > > > > If request == GET > > ...render this > > if request == POST > > ...render this. > > if URL == 'abc.html' > > .. render this. > > > > I want to embed this in my framework. You only touch one page, but > > you get different outputs depending on the request method or URL, etc, > > etc. > > > > 6. Use of Clojure syntactic sugar -- TO BE DETERMINED. There is the > > ability to use powerful Clojure constructs with this framework but I > > haven't figured out how yet. > > > > 7. Better integration of CSS, Javascript, HTML. A lot of a web > > application still resides with the client side. I have yet to see an > > web framework that addresses client development (besides GWT). Maybe > > something as simple as server page tags for CSS? Javascript? > > > > 8. Additional third party libraries: > > > > Lucene, iText, jFreeChart, optional Terracotta integration > > > > > > Other optional/additional thoughts. > > > > 9. Clear separation between back-end and front-end layers > > > --~--~-~--~~~---~--~~ You received this message because you are subscribed to the Google Groups "Clojure" group. To post to this group, send email to clojure@googlegroups.com To unsubscribe from this group, send email to clojure+unsubscr...@googlegroups.com For more options, visit this group at http://groups.google.com/group/clojure?hl=en -~--~~~~--~~--~--~---
Re: Clojure Web Framework, what I want to add
On Mar 16, 7:52 pm, Jeffrey Straszheim wrote: > I'd love to see something built around very-high scalability, using NIO and > thread pools and such. > > On Mon, Mar 16, 2009 at 7:40 PM, Sean wrote: > > > I'm not sure if some of the design inputs make sense, specifically > > Spring and Hibernate. > > > Point 1 - I've found the strength of Spring to be making up for the > > weaknesses of Java. Once you have first class functions, macros, and > > multi-methods (to name a few), Spring doesn't bring much to the table > > any more. Add in a few Unix utilities like cron and others, you > > remove the rest of the features. > > > Point 2 - As for Hibernate, ORM doesn't make much sense with a > > functional language either. The SQL library in clojure-contrib lets > > you load a map, and you can create way more interesting queries with > > clojure than hibernate. S-expressions are that powerful. > > > Point 3 - I'd follow Rails example and use strong defaults, and resort > > to XML only when necessary. > > > Point 4 - Sounds good. > > > Point 5 - Have you looked into compojure? It does a really good job > > of turning s-expressions into HTML. > > > Point 5 (the second one) - See compojure again. > > > Point 6 & 7 - This is where a lot of work is to be done. I'm not sure > > how to respond right now. I'll think about it. > > > Point 8 - This is why clojure is awesome. I'll leave this as an > > exercise to the user :) > > > Point 9 - Yeah, this would be a great feature. > > > That's my thoughts. > > > On Mar 16, 7:17 pm, BerlinBrown wrote: > > > After many years (decade) of web development, here are the things that > > > I want in a framework, mostly based in clojure: > > > > What do you think and what you add. This is ambitious and just a > > > "ideas" of what I would add. What would you want from your ideal > > > framework? > > > > 1. Based on Spring Framework for middleware: > > > Reason: there are years and years and years of development spent on > > > spring and there are many things done right. If I were integrating > > > with any other third party libraries, I would use spring. Spring is > > > added to my framework. > > > > 2. Based on Hibernate for ORM mapping: > > > Reason: the defacto standard for ORM mapping with Java. And also used > > > by NHibernate. There is a lot of support for most popular databases. > > > > 3. Clojure/Lisp based configuration AND default XML configurations. > > > This has become the standard way to configure a J2EE web application > > > including spring and hibernate. But I would like a lisp oriented > > > configuration. > > > > 4. Easy mapping to URLs. I like python's approach for URL mapping > > > > 5. Clojure based, framework based server pages AND JSPs. I have > > > always hated some aspects of JSP and ASPs, etc, etc. They are just > > > too complicated. I would want to use Clojure code within the > > > framework oriented server page and other predefined tags. > > > > 5. Lift like reusable server pages. Lift has an interesting approach > > > for resuing the same page. E.g. you have an if-else statement within > > > the page. > > > > If request == GET > > > ...render this > > > if request == POST > > > ...render this. > > > if URL == 'abc.html' > > > .. render this. > > > > I want to embed this in my framework. You only touch one page, but > > > you get different outputs depending on the request method or URL, etc, > > > etc. > > > > 6. Use of Clojure syntactic sugar -- TO BE DETERMINED. There is the > > > ability to use powerful Clojure constructs with this framework but I > > > haven't figured out how yet. > > > > 7. Better integration of CSS, Javascript, HTML. A lot of a web > > > application still resides with the client side. I have yet to see an > > > web framework that addresses client development (besides GWT). Maybe > > > something as simple as server page tags for CSS? Javascript? > > > > 8. Additional third party libraries: > > > > Lucene, iText, jFreeChart, optional Terracotta integration > > > > > > > Other optional/additional thoughts. > > > > 9. Clear separation between back-end and front-end layers "Point 1 - I've found the strength of Spring to be making up for the weaknesses of Java. Once you have first class functions, macros, and multi-methods (to name a few), Spring doesn't bring much to the table any more. Add in a few Unix utilities like cron and others, you remove the rest of the features." Assuming a person is able to re-engineer what Spring has already done including the simplistic dependency injection oriented web framework. For me, I just to hate to ignore all that work has been done as well as making it easier for integrating 'this' framework with pre-existing code. "Point 2 - As for Hibernate, ORM doesn't make much sense with a functional language either. The SQL library in clojure-contrib lets you load a map, and you can create way more interesting queries with clojure than hibernate. S-e
Re: Clojure Web Framework, what I want to add
Okay, if you have to work with something rpe-existing that makes more sense. My main point is that if I were started from scratch, I'd do it different. On Mar 16, 8:12 pm, Berlin Brown wrote: > On Mar 16, 7:52 pm, Jeffrey Straszheim > wrote: > > > I'd love to see something built around very-high scalability, using NIO and > > thread pools and such. > > > On Mon, Mar 16, 2009 at 7:40 PM, Sean wrote: > > > > I'm not sure if some of the design inputs make sense, specifically > > > Spring and Hibernate. > > > > Point 1 - I've found the strength of Spring to be making up for the > > > weaknesses of Java. Once you have first class functions, macros, and > > > multi-methods (to name a few), Spring doesn't bring much to the table > > > any more. Add in a few Unix utilities like cron and others, you > > > remove the rest of the features. > > > > Point 2 - As for Hibernate, ORM doesn't make much sense with a > > > functional language either. The SQL library in clojure-contrib lets > > > you load a map, and you can create way more interesting queries with > > > clojure than hibernate. S-expressions are that powerful. > > > > Point 3 - I'd follow Rails example and use strong defaults, and resort > > > to XML only when necessary. > > > > Point 4 - Sounds good. > > > > Point 5 - Have you looked into compojure? It does a really good job > > > of turning s-expressions into HTML. > > > > Point 5 (the second one) - See compojure again. > > > > Point 6 & 7 - This is where a lot of work is to be done. I'm not sure > > > how to respond right now. I'll think about it. > > > > Point 8 - This is why clojure is awesome. I'll leave this as an > > > exercise to the user :) > > > > Point 9 - Yeah, this would be a great feature. > > > > That's my thoughts. > > > > On Mar 16, 7:17 pm, BerlinBrown wrote: > > > > After many years (decade) of web development, here are the things that > > > > I want in a framework, mostly based in clojure: > > > > > What do you think and what you add. This is ambitious and just a > > > > "ideas" of what I would add. What would you want from your ideal > > > > framework? > > > > > 1. Based on Spring Framework for middleware: > > > > Reason: there are years and years and years of development spent on > > > > spring and there are many things done right. If I were integrating > > > > with any other third party libraries, I would use spring. Spring is > > > > added to my framework. > > > > > 2. Based on Hibernate for ORM mapping: > > > > Reason: the defacto standard for ORM mapping with Java. And also used > > > > by NHibernate. There is a lot of support for most popular databases. > > > > > 3. Clojure/Lisp based configuration AND default XML configurations. > > > > This has become the standard way to configure a J2EE web application > > > > including spring and hibernate. But I would like a lisp oriented > > > > configuration. > > > > > 4. Easy mapping to URLs. I like python's approach for URL mapping > > > > > 5. Clojure based, framework based server pages AND JSPs. I have > > > > always hated some aspects of JSP and ASPs, etc, etc. They are just > > > > too complicated. I would want to use Clojure code within the > > > > framework oriented server page and other predefined tags. > > > > > 5. Lift like reusable server pages. Lift has an interesting approach > > > > for resuing the same page. E.g. you have an if-else statement within > > > > the page. > > > > > If request == GET > > > > ...render this > > > > if request == POST > > > > ...render this. > > > > if URL == 'abc.html' > > > > .. render this. > > > > > I want to embed this in my framework. You only touch one page, but > > > > you get different outputs depending on the request method or URL, etc, > > > > etc. > > > > > 6. Use of Clojure syntactic sugar -- TO BE DETERMINED. There is the > > > > ability to use powerful Clojure constructs with this framework but I > > > > haven't figured out how yet. > > > > > 7. Better integration of CSS, Javascript, HTML. A lot of a web > > > > application still resides with the client side. I have yet to see an > > > > web framework that addresses client development (besides GWT). Maybe > > > > something as simple as server page tags for CSS? Javascript? > > > > > 8. Additional third party libraries: > > > > > Lucene, iText, jFreeChart, optional Terracotta integration > > > > > > > > > Other optional/additional thoughts. > > > > > 9. Clear separation between back-end and front-end layers > > "Point 1 - I've found the strength of Spring to be making up for the > weaknesses of Java. Once you have first class functions, macros, and > multi-methods (to name a few), Spring doesn't bring much to the table > any more. Add in a few Unix utilities like cron and others, you > remove the rest of the features." > > Assuming a person is able to re-engineer what Spring has already done > including the simplistic dependency injection oriented web framework. > For me, I jus
Re: Clojure Web Framework, what I want to add
I'm mostly a front-end UI person with crazy amounts of JS experience so most of my input will be from that stand point. 1. I agree with Sean on this one. No need to bring in middleware that can't be expressed in 10X-20X less code in pure Clojure. 2. The framework should allow for any backend (even if it means in memory). I'm currently interested in CouchDB. 3. Sure. 4. Yup. Compojure handles this nicely. If I never have to look at an Apache httpd.conf file again I won't shed a tear. 5.1 Hmm I hate templates pages, I think Enlive is a very good start to a real future. Template with CSS selectors. Mixing language into HTML is an atrocity which much be eliminated once and for all. Good HTML fragment manipulation is a must. I see pure HTML+CSS fragments created by a designer. The coder draws up a template which targets where values will go in the HTML via CSS3 selectors. Voila! Synchronizing design and code becomes trivial overnight. 5.2. Compojure 6. This is going to be big, it will demolish what other people are doing. 7. See below. 8. Yup. 9. Agreed. I've been seriously investigating porting cl-cont which is the basis for weblocks (working on it right now fingers crossed). The only truly serious continuation based framework is Seaside and its developers have been able to accomplish truly amazing things. With continuations you can define arbitrarily complex UIs. However, I think Seaside overemphasizes the continuation part. The framework should allow for restful delivery as well as stateful interactions. Also, weblocks got it wrong by auto-generating HTML- designers need to be be able create markup and CSS, not just CSS. Seaside also gets this wrong. JS integration with existing JS Frameworks is a must. The recently uploaded parenscript clone looks like a good start for allowing developers to code JS against widgets using such a continuation based framework. Calling JS suddenly becomes like calling Java from Clojure code. Clojure also has something going for which is BIG that you don't get from many frameworks. You can ssh tunnel into the running application server and debug a live instance. For example, currently I have compojure running on the server, I connect to it from my local emacs and can manipulate the server via the remote REPL. I can recompile functions on the server on the fly. Imagine this whole system hooked up with a Comet server (SymbolicWeb did this first). As you modify the server, changes can be propagated back to the client without refreshing (godsend for debugging). Then imagine this entire UI system hooked up to a robust backend of your choosing ;) --~--~-~--~~~---~--~~ You received this message because you are subscribed to the Google Groups "Clojure" group. To post to this group, send email to clojure@googlegroups.com To unsubscribe from this group, send email to clojure+unsubscr...@googlegroups.com For more options, visit this group at http://groups.google.com/group/clojure?hl=en -~--~~~~--~~--~--~---
Re: Clojure Web Framework, what I want to add
On Mar 16, 7:17 pm, BerlinBrown wrote: > After many years (decade) of web development, here are the things that > I want in a framework, mostly based in clojure: > > What do you think and what you add. This is ambitious and just a > "ideas" of what I would add. What would you want from your ideal > framework? Nothing much to add, but I'm doing well with a combination of Restlet, StringTemplate, Derby, and Solr. After a couple of years with Rails, I felt that I wanted to work "closer to the metal", with the metal, in this case, being HTTP. Javascript/CSS-generation was more trouble than it was worth. -Stuart Sierra --~--~-~--~~~---~--~~ You received this message because you are subscribed to the Google Groups "Clojure" group. To post to this group, send email to clojure@googlegroups.com To unsubscribe from this group, send email to clojure+unsubscr...@googlegroups.com For more options, visit this group at http://groups.google.com/group/clojure?hl=en -~--~~~~--~~--~--~---
Re: Clojure Web Framework, what I want to add
On Mon, Mar 16, 2009 at 9:18 PM, Stuart Sierra wrote: > > On Mar 16, 7:17 pm, BerlinBrown wrote: > > After many years (decade) of web development, here are the things that > > I want in a framework, mostly based in clojure: > > > > What do you think and what you add. This is ambitious and just a > > "ideas" of what I would add. What would you want from your ideal > > framework? > > Nothing much to add, but I'm doing well with a combination of Restlet, > StringTemplate, Derby, and Solr. > > After a couple of years with Rails, I felt that I wanted to work > "closer to the metal", with the metal, in this case, being HTTP. > Javascript/CSS-generation was more trouble than it was worth. > > -Stuart Sierra > Stuart, thanks for mentioning your stack. I've played with StringTemplate from Clojure, but I hadn't seen it in use in a project before. Your implementation is great, and at 88 lines of mainly imports and tests it's a great example of using Java (and clojure-contrib). Stringify the keys and away you go! Shawn --~--~-~--~~~---~--~~ You received this message because you are subscribed to the Google Groups "Clojure" group. To post to this group, send email to clojure@googlegroups.com To unsubscribe from this group, send email to clojure+unsubscr...@googlegroups.com For more options, visit this group at http://groups.google.com/group/clojure?hl=en -~--~~~~--~~--~--~---
Re: Clojure Web Framework, what I want to add
On Mar 16, 10:42 pm, Shawn Hoover wrote: > On Mon, Mar 16, 2009 at 9:18 PM, Stuart Sierra > wrote: > > > > > > > On Mar 16, 7:17 pm, BerlinBrown wrote: > > > After many years (decade) of web development, here are the things that > > > I want in a framework, mostly based in clojure: > > > > What do you think and what you add. This is ambitious and just a > > > "ideas" of what I would add. What would you want from your ideal > > > framework? > > > Nothing much to add, but I'm doing well with a combination of Restlet, > > StringTemplate, Derby, and Solr. > > > After a couple of years with Rails, I felt that I wanted to work > > "closer to the metal", with the metal, in this case, being HTTP. > > Javascript/CSS-generation was more trouble than it was worth. > > > -Stuart Sierra > > Stuart, thanks for mentioning your stack. I've played with StringTemplate > from Clojure, but I hadn't seen it in use in a project before. Your > implementation is great, and at 88 lines of mainly imports and tests it's a > great example of using Java (and clojure-contrib). Stringify the keys and > away you go! > > Shawn Nothing much to add, but I'm doing well with a combination of Restlet, StringTemplate, Derby, and Solr. Derby and Solr are both good. --~--~-~--~~~---~--~~ You received this message because you are subscribed to the Google Groups "Clojure" group. To post to this group, send email to clojure@googlegroups.com To unsubscribe from this group, send email to clojure+unsubscr...@googlegroups.com For more options, visit this group at http://groups.google.com/group/clojure?hl=en -~--~~~~--~~--~--~---
Re: Clojure Web Framework, what I want to add
On Mar 16, 11:17 pm, BerlinBrown wrote: > After many years (decade) of web development, here are the things that > I want in a framework, mostly based in clojure: > > What do you think and what you add. This is ambitious and just a > "ideas" of what I would add. What would you want from your ideal > framework? I suspect what people think of as an ideal web framework will vary greatly. My ideal web framework would contain the following: 1. Bare-bones simplicity 2. Concise, but explicit 3. Functional - little or no side effects 4. Need to know - call functions with only data they need, and no more 5. RESTful HTTP 6. Inline HTML generation - no separate templates 7. Data storage agnostic - not tied to relational DBs 8. Configuration done in Clojure - no XML That's what I'm trying to achieve with Compojure, at least :) - James --~--~-~--~~~---~--~~ You received this message because you are subscribed to the Google Groups "Clojure" group. To post to this group, send email to clojure@googlegroups.com To unsubscribe from this group, send email to clojure+unsubscr...@googlegroups.com For more options, visit this group at http://groups.google.com/group/clojure?hl=en -~--~~~~--~~--~--~---
Re: Clojure Web Framework, what I want to add
Hi Jeffrey, I was recently thinking of adding support for https://grizzly.dev.java.net/ in http://github.com/weavejester/compojure/tree/master. Just need some time to get my head around compojure. Cheers, Hubert. On Tue, Mar 17, 2009 at 12:52 AM, Jeffrey Straszheim < straszheimjeff...@gmail.com> wrote: > I'd love to see something built around very-high scalability, using NIO and > thread pools and such. > > > On Mon, Mar 16, 2009 at 7:40 PM, Sean wrote: > >> >> I'm not sure if some of the design inputs make sense, specifically >> Spring and Hibernate. >> >> Point 1 - I've found the strength of Spring to be making up for the >> weaknesses of Java. Once you have first class functions, macros, and >> multi-methods (to name a few), Spring doesn't bring much to the table >> any more. Add in a few Unix utilities like cron and others, you >> remove the rest of the features. >> >> Point 2 - As for Hibernate, ORM doesn't make much sense with a >> functional language either. The SQL library in clojure-contrib lets >> you load a map, and you can create way more interesting queries with >> clojure than hibernate. S-expressions are that powerful. >> >> Point 3 - I'd follow Rails example and use strong defaults, and resort >> to XML only when necessary. >> >> Point 4 - Sounds good. >> >> Point 5 - Have you looked into compojure? It does a really good job >> of turning s-expressions into HTML. >> >> Point 5 (the second one) - See compojure again. >> >> Point 6 & 7 - This is where a lot of work is to be done. I'm not sure >> how to respond right now. I'll think about it. >> >> Point 8 - This is why clojure is awesome. I'll leave this as an >> exercise to the user :) >> >> Point 9 - Yeah, this would be a great feature. >> >> That's my thoughts. >> >> On Mar 16, 7:17 pm, BerlinBrown wrote: >> > After many years (decade) of web development, here are the things that >> > I want in a framework, mostly based in clojure: >> > >> > What do you think and what you add. This is ambitious and just a >> > "ideas" of what I would add. What would you want from your ideal >> > framework? >> > >> > 1. Based on Spring Framework for middleware: >> > Reason: there are years and years and years of development spent on >> > spring and there are many things done right. If I were integrating >> > with any other third party libraries, I would use spring. Spring is >> > added to my framework. >> > >> > 2. Based on Hibernate for ORM mapping: >> > Reason: the defacto standard for ORM mapping with Java. And also used >> > by NHibernate. There is a lot of support for most popular databases. >> > >> > 3. Clojure/Lisp based configuration AND default XML configurations. >> > This has become the standard way to configure a J2EE web application >> > including spring and hibernate. But I would like a lisp oriented >> > configuration. >> > >> > 4. Easy mapping to URLs. I like python's approach for URL mapping >> > >> > 5. Clojure based, framework based server pages AND JSPs. I have >> > always hated some aspects of JSP and ASPs, etc, etc. They are just >> > too complicated. I would want to use Clojure code within the >> > framework oriented server page and other predefined tags. >> > >> > 5. Lift like reusable server pages. Lift has an interesting approach >> > for resuing the same page. E.g. you have an if-else statement within >> > the page. >> > >> > If request == GET >> > ...render this >> > if request == POST >> > ...render this. >> > if URL == 'abc.html' >> > .. render this. >> > >> > I want to embed this in my framework. You only touch one page, but >> > you get different outputs depending on the request method or URL, etc, >> > etc. >> > >> > 6. Use of Clojure syntactic sugar -- TO BE DETERMINED. There is the >> > ability to use powerful Clojure constructs with this framework but I >> > haven't figured out how yet. >> > >> > 7. Better integration of CSS, Javascript, HTML. A lot of a web >> > application still resides with the client side. I have yet to see an >> > web framework that addresses client development (besides GWT). Maybe >> > something as simple as server page tags for CSS? Javascript? >> > >> > 8. Additional third party libraries: >> > >> > Lucene, iText, jFreeChart, optional Terracotta integration >> > >> > >> > Other optional/additional thoughts. >> > >> > 9. Clear separation between back-end and front-end layers >> >> > > > > --~--~-~--~~~---~--~~ You received this message because you are subscribed to the Google Groups "Clojure" group. To post to this group, send email to clojure@googlegroups.com To unsubscribe from this group, send email to clojure+unsubscr...@googlegroups.com For more options, visit this group at http://groups.google.com/group/clojure?hl=en -~--~~~~--~~--~--~---
Re: Clojure Web Framework, what I want to add
I hadn't heard of Grizzly before. Thanks for the pointer (er..., reference, or whatever we're calling them these days). On Tue, Mar 17, 2009 at 5:31 AM, Hubert Iwaniuk wrote: > Hi Jeffrey, > I was recently thinking of adding support for > https://grizzly.dev.java.net/ in > http://github.com/weavejester/compojure/tree/master. > Just need some time to get my head around compojure. > > Cheers, > Hubert. > > > > On Tue, Mar 17, 2009 at 12:52 AM, Jeffrey Straszheim < > straszheimjeff...@gmail.com> wrote: > >> I'd love to see something built around very-high scalability, using NIO >> and thread pools and such. >> >> >> On Mon, Mar 16, 2009 at 7:40 PM, Sean wrote: >> >>> >>> I'm not sure if some of the design inputs make sense, specifically >>> Spring and Hibernate. >>> >>> Point 1 - I've found the strength of Spring to be making up for the >>> weaknesses of Java. Once you have first class functions, macros, and >>> multi-methods (to name a few), Spring doesn't bring much to the table >>> any more. Add in a few Unix utilities like cron and others, you >>> remove the rest of the features. >>> >>> Point 2 - As for Hibernate, ORM doesn't make much sense with a >>> functional language either. The SQL library in clojure-contrib lets >>> you load a map, and you can create way more interesting queries with >>> clojure than hibernate. S-expressions are that powerful. >>> >>> Point 3 - I'd follow Rails example and use strong defaults, and resort >>> to XML only when necessary. >>> >>> Point 4 - Sounds good. >>> >>> Point 5 - Have you looked into compojure? It does a really good job >>> of turning s-expressions into HTML. >>> >>> Point 5 (the second one) - See compojure again. >>> >>> Point 6 & 7 - This is where a lot of work is to be done. I'm not sure >>> how to respond right now. I'll think about it. >>> >>> Point 8 - This is why clojure is awesome. I'll leave this as an >>> exercise to the user :) >>> >>> Point 9 - Yeah, this would be a great feature. >>> >>> That's my thoughts. >>> >>> On Mar 16, 7:17 pm, BerlinBrown wrote: >>> > After many years (decade) of web development, here are the things that >>> > I want in a framework, mostly based in clojure: >>> > >>> > What do you think and what you add. This is ambitious and just a >>> > "ideas" of what I would add. What would you want from your ideal >>> > framework? >>> > >>> > 1. Based on Spring Framework for middleware: >>> > Reason: there are years and years and years of development spent on >>> > spring and there are many things done right. If I were integrating >>> > with any other third party libraries, I would use spring. Spring is >>> > added to my framework. >>> > >>> > 2. Based on Hibernate for ORM mapping: >>> > Reason: the defacto standard for ORM mapping with Java. And also used >>> > by NHibernate. There is a lot of support for most popular databases. >>> > >>> > 3. Clojure/Lisp based configuration AND default XML configurations. >>> > This has become the standard way to configure a J2EE web application >>> > including spring and hibernate. But I would like a lisp oriented >>> > configuration. >>> > >>> > 4. Easy mapping to URLs. I like python's approach for URL mapping >>> > >>> > 5. Clojure based, framework based server pages AND JSPs. I have >>> > always hated some aspects of JSP and ASPs, etc, etc. They are just >>> > too complicated. I would want to use Clojure code within the >>> > framework oriented server page and other predefined tags. >>> > >>> > 5. Lift like reusable server pages. Lift has an interesting approach >>> > for resuing the same page. E.g. you have an if-else statement within >>> > the page. >>> > >>> > If request == GET >>> > ...render this >>> > if request == POST >>> > ...render this. >>> > if URL == 'abc.html' >>> > .. render this. >>> > >>> > I want to embed this in my framework. You only touch one page, but >>> > you get different outputs depending on the request method or URL, etc, >>> > etc. >>> > >>> > 6. Use of Clojure syntactic sugar -- TO BE DETERMINED. There is the >>> > ability to use powerful Clojure constructs with this framework but I >>> > haven't figured out how yet. >>> > >>> > 7. Better integration of CSS, Javascript, HTML. A lot of a web >>> > application still resides with the client side. I have yet to see an >>> > web framework that addresses client development (besides GWT). Maybe >>> > something as simple as server page tags for CSS? Javascript? >>> > >>> > 8. Additional third party libraries: >>> > >>> > Lucene, iText, jFreeChart, optional Terracotta integration >>> > >>> > >>> > Other optional/additional thoughts. >>> > >>> > 9. Clear separation between back-end and front-end layers >>> >>> >> >> >> > > > > --~--~-~--~~~---~--~~ You received this message because you are subscribed to the Google Groups "Clojure" group. To post to this group, send email to clojure@googlegroups.com To unsubscribe from this group, send