Re: Feedback on Clojure web development post

2010-07-29 Thread Avram

Hello Mark,

Your post was fantastic and very well-written.  Thank-you for posting
it!

A few thoughts:

- Perhaps adding dynamic graphs from Incanter to the project with
might make a good follow-up post ?

- Is there a reason why you preferred EC2 tools over the elastic-
mapreduce executable or clojure calls of the java  ( see
http://developer.amazonwebservices.com/connect/entry.jspa?externalID=2305categoryID=262)
?

- What are your thoughts on clojure handling the initial EC2 set up
and launching of the node instances as well?

- Does it seem like creating a UI for editing and launching code for
Apache Hive, Pig, or Cascalog seems within reach with this kind of set
up ?


Regards,
~Avram



On Jul 24, 12:30 am, Mark McGranaghan mmcgr...@gmail.com wrote:
 Hi All,

 I recently posted to my blog on the process of developing and
 deploying a simple Clojure web application:

 http://mmcgrana.github.com/2010/07/develop-deploy-clojure-web-applica...

 The purpose of this post is twofold. The first is to provide some
 documentation in the form of a complete, deployable Clojure web app
 and associated commentary and instructions. To that end I hope you
 find the post useful and that you feel free to ask any questions you
 may have.

 The second purpose is to elicit feedback from the community on how
 they would or have approached the problem of developing and deploying
 Clojure web applications.

 I'm particularly interested in the specifics of how people tie
 together and round out entire apps with e.g. logging and exception
 handling, how they develop apps locally, and how they deploy them to
 production. I think the most useful basis for discussing things like
 this is complete working examples of applications and associated
 instructions for how to deploy them. I doubt there are very many such
 open-source apps floating around, but if anyone has one to share I
 would love to see it.

 Even if you don't have a complete app to share, I would love to hear
 your comments and see your code snippets on the specific aspects of
 the development and deployment process that I covered (or perhaps
 omitted) in the post.

 - Mark

-- 
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
Note that posts from new members are moderated - please be patient with your 
first post.
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: Feedback on Clojure web development post

2010-07-29 Thread Mark McGranaghan


On Jul 28, 2:23 pm, Avram aav...@me.com wrote:
 Hello Mark,

 Your post was fantastic and very well-written.  Thank-you for posting
 it!

Hi Avram, thanks for the feedback.

 A few thoughts:

 - Perhaps adding dynamic graphs from Incanter to the project with
 might make a good follow-up post ?

There are several follow up posts planned, but I probably won't cover
this since it is addressed here:
http://data-sorcery.org/2009/11/29/incanter-webapp/

 - Is there a reason why you preferred EC2 tools over the elastic-
 mapreduce executable or clojure calls of the java  ( 
 seehttp://developer.amazonwebservices.com/connect/entry.jspa?externalID=...)
 ?

 - What are your thoughts on clojure handling the initial EC2 set up
 and launching of the node instances as well?

Programatic deployment via Clojure is definitely possible, but for
this simple example the command line tools work well enough I think.

 - Does it seem like creating a UI for editing and launching code for
 Apache Hive, Pig, or Cascalog seems within reach with this kind of set
 up ?


That's a rather harder problem (: I won't be working on it, but let us
know if you end up doing something like that yourself.

- Mark

 Regards,
 ~Avram

 On Jul 24, 12:30 am, Mark McGranaghan mmcgr...@gmail.com wrote:



  Hi All,

  I recently posted to my blog on the process of developing and
  deploying a simple Clojure web application:

 http://mmcgrana.github.com/2010/07/develop-deploy-clojure-web-applica...

  The purpose of this post is twofold. The first is to provide some
  documentation in the form of a complete, deployable Clojure web app
  and associated commentary and instructions. To that end I hope you
  find the post useful and that you feel free to ask any questions you
  may have.

  The second purpose is to elicit feedback from the community on how
  they would or have approached the problem of developing and deploying
  Clojure web applications.

  I'm particularly interested in the specifics of how people tie
  together and round out entire apps with e.g. logging and exception
  handling, how they develop apps locally, and how they deploy them to
  production. I think the most useful basis for discussing things like
  this is complete working examples of applications and associated
  instructions for how to deploy them. I doubt there are very many such
  open-source apps floating around, but if anyone has one to share I
  would love to see it.

  Even if you don't have a complete app to share, I would love to hear
  your comments and see your code snippets on the specific aspects of
  the development and deployment process that I covered (or perhaps
  omitted) in the post.

  - Mark

-- 
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
Note that posts from new members are moderated - please be patient with your 
first post.
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: Feedback on Clojure web development post

2010-07-28 Thread Daniel
Excellent job!  It's great that you're willing to devote the time to
help others learn more quickly  easily!

On Jul 27, 9:42 am, Savanni D'Gerinel sava...@alyra.org wrote:
 I thought this was pretty awesomely informative, including the
 deployment to Amazon Cloud.  I already playing through and doing
 development with Compojure and Hiccup, and I found a lot of new things
 in here for me to investigate and potentially put to good use.

 --
 Savanni



 On Sat, 2010-07-24 at 00:30 -0700, Mark McGranaghan wrote:
  Hi All,

  I recently posted to my blog on the process of developing and
  deploying a simple Clojure web application:

 http://mmcgrana.github.com/2010/07/develop-deploy-clojure-web-applica...

  The purpose of this post is twofold. The first is to provide some
  documentation in the form of a complete, deployable Clojure web app
  and associated commentary and instructions. To that end I hope you
  find the post useful and that you feel free to ask any questions you
  may have.

  The second purpose is to elicit feedback from the community on how
  they would or have approached the problem of developing and deploying
  Clojure web applications.

  I'm particularly interested in the specifics of how people tie
  together and round out entire apps with e.g. logging and exception
  handling, how they develop apps locally, and how they deploy them to
  production. I think the most useful basis for discussing things like
  this is complete working examples of applications and associated
  instructions for how to deploy them. I doubt there are very many such
  open-source apps floating around, but if anyone has one to share I
  would love to see it.

  Even if you don't have a complete app to share, I would love to hear
  your comments and see your code snippets on the specific aspects of
  the development and deployment process that I covered (or perhaps
  omitted) in the post.

  - Mark

-- 
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
Note that posts from new members are moderated - please be patient with your 
first post.
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: Feedback on Clojure web development post

2010-07-27 Thread Savanni D'Gerinel
I thought this was pretty awesomely informative, including the
deployment to Amazon Cloud.  I already playing through and doing
development with Compojure and Hiccup, and I found a lot of new things
in here for me to investigate and potentially put to good use.

--
Savanni

On Sat, 2010-07-24 at 00:30 -0700, Mark McGranaghan wrote:
 Hi All,
 
 I recently posted to my blog on the process of developing and
 deploying a simple Clojure web application:
 
 http://mmcgrana.github.com/2010/07/develop-deploy-clojure-web-applications.html
 
 The purpose of this post is twofold. The first is to provide some
 documentation in the form of a complete, deployable Clojure web app
 and associated commentary and instructions. To that end I hope you
 find the post useful and that you feel free to ask any questions you
 may have.
 
 The second purpose is to elicit feedback from the community on how
 they would or have approached the problem of developing and deploying
 Clojure web applications.
 
 I'm particularly interested in the specifics of how people tie
 together and round out entire apps with e.g. logging and exception
 handling, how they develop apps locally, and how they deploy them to
 production. I think the most useful basis for discussing things like
 this is complete working examples of applications and associated
 instructions for how to deploy them. I doubt there are very many such
 open-source apps floating around, but if anyone has one to share I
 would love to see it.
 
 Even if you don't have a complete app to share, I would love to hear
 your comments and see your code snippets on the specific aspects of
 the development and deployment process that I covered (or perhaps
 omitted) in the post.
 
 - Mark
 


-- 
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
Note that posts from new members are moderated - please be patient with your 
first post.
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: Feedback on Clojure web development post

2010-07-26 Thread ghadi
I really appreciate this article.  Some of the compojure web
development documentation is hard to find or out of date.  I usually
end up reading the source to have a better idea of what's going on.
Clojure makes that pretty easy though.

A couple quick questions:
  1)  Inside (view-input), there are a couple of tuples:value
a and :value b.  a and b don't seem to be declared.
What do they refer to, or are they just not evaluated?

  2)  Inside the POST / route, how does Compojure match a and b with
request parameters?  Does it go based on the query string?
   It doesn't matter in this example since addition is commutative,
but I'm just wondering how it works behind the scenes.

Anyways, congrats on a great tutorial.
Ghadi

On Jul 24, 3:30 am, Mark McGranaghan mmcgr...@gmail.com wrote:
 Hi All,

 I recently posted to my blog on the process of developing and
 deploying a simple Clojure web application:

 http://mmcgrana.github.com/2010/07/develop-deploy-clojure-web-applica...

 The purpose of this post is twofold. The first is to provide some
 documentation in the form of a complete, deployable Clojure web app
 and associated commentary and instructions. To that end I hope you
 find the post useful and that you feel free to ask any questions you
 may have.

 The second purpose is to elicit feedback from the community on how
 they would or have approached the problem of developing and deploying
 Clojure web applications.

 I'm particularly interested in the specifics of how people tie
 together and round out entire apps with e.g. logging and exception
 handling, how they develop apps locally, and how they deploy them to
 production. I think the most useful basis for discussing things like
 this is complete working examples of applications and associated
 instructions for how to deploy them. I doubt there are very many such
 open-source apps floating around, but if anyone has one to share I
 would love to see it.

 Even if you don't have a complete app to share, I would love to hear
 your comments and see your code snippets on the specific aspects of
 the development and deployment process that I covered (or perhaps
 omitted) in the post.

 - Mark

-- 
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
Note that posts from new members are moderated - please be patient with your 
first post.
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: Feedback on Clojure web development post

2010-07-26 Thread Michael Wood
On 26 July 2010 06:42, ghadi gshay...@gmail.com wrote:
 I really appreciate this article.  Some of the compojure web
 development documentation is hard to find or out of date.  I usually
 end up reading the source to have a better idea of what's going on.
 Clojure makes that pretty easy though.

 A couple quick questions:
  1)  Inside (view-input), there are a couple of tuples        :value
 a and :value b.  a and b don't seem to be declared.
 What do they refer to, or are they just not evaluated?

That's a typo/bug.

Further down the page he says you should replace the view-input
definition (in order to implement the error handling) and there he has
the right arglist.  i.e. it should be:

(defn view-input [ [a b]] ...)

Also, I suspect other people just checked out the code from the Git
repository and didn't see this.  I did not and noticed this problem
last night when I read the article.

  2)  Inside the POST / route, how does Compojure match a and b with
 request parameters?  Does it go based on the query string?
   It doesn't matter in this example since addition is commutative,
 but I'm just wondering how it works behind the scenes.

Ah, good point.  I didn't think of that.  I imagine it converts the
symbol name into a string and looks for a field name that matches, but
it's just a guess.

 Anyways, congrats on a great tutorial.

Yes, I agree.

-- 
Michael Wood esiot...@gmail.com

-- 
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
Note that posts from new members are moderated - please be patient with your 
first post.
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: Feedback on Clojure web development post

2010-07-26 Thread Shawn Hoover
On Sat, Jul 24, 2010 at 3:30 AM, Mark McGranaghan mmcgr...@gmail.comwrote:

 Hi All,

 I recently posted to my blog on the process of developing and
 deploying a simple Clojure web application:


 http://mmcgrana.github.com/2010/07/develop-deploy-clojure-web-applications.html

 The purpose of this post is twofold. The first is to provide some
 documentation in the form of a complete, deployable Clojure web app
 and associated commentary and instructions. To that end I hope you
 find the post useful and that you feel free to ask any questions you
 may have.

 The second purpose is to elicit feedback from the community on how
 they would or have approached the problem of developing and deploying
 Clojure web applications.


Mark, thanks for writing this. I can speak to goal one, that the full
writeup is indeed very useful. I'm stumbling my way through local
development of a Compojure/Ring web service, picking off tips from the
source, API docs, and Brian Carper's informative blog source [1] as I go.
Seeing the contents of this tutorial in one place, I learned a lot about
rounding out an entire app, as you say, and making it deployable.

Even though I don't need HTML for my service and I'll be deploying to a
Windows server (relax, let me worry about that feature/bug!), the way you
broke it down makes it trivial to tweak for any environment. The command
line jetty startup approach is a nice complement to Chas Emerick's
maven-style deployment tips [2] for those who don't want or have to plug in
to existing Java server infrastructure (another top to bottom tutorial based
on WAR files would probably be appreciated by folks who are in that camp).

I especially appreciate the middleware demonstrations, as the ability to
whip up a little function to augment or change the behavior of the entire
app is a strength of Ring-based development. I half-assumed
wrap-bounce-favicon was built in, but then you busted out in a few lines
right there and it didn't really matter if it existed or not.

[1] http://github.com/briancarper/cow-blog/
[2] http://muckandbrass.com/web/x/RQBP

-- 
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
Note that posts from new members are moderated - please be patient with your 
first post.
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: Feedback on Clojure web development post

2010-07-26 Thread tguy
When developing a web app, my preference would be to edit files using
SLIME with lein swank like all of my other development. So, I should
be able to start and stop the server from the repl and can reflect my
changes in the browser simply by reloading a function.

I used to be able to develop like this easily with compojure 0.3.2,
but since 0.4 it doesn't seem to provide this functionality anymore.
Is there a modern and easy way to fit this style of development with
jetty?

On Jul 24, 3:30 am, Mark McGranaghan mmcgr...@gmail.com wrote:
 Hi All,

 I recently posted to my blog on the process of developing and
 deploying a simple Clojure web application:

 http://mmcgrana.github.com/2010/07/develop-deploy-clojure-web-applica...

 The purpose of this post is twofold. The first is to provide some
 documentation in the form of a complete, deployable Clojure web app
 and associated commentary and instructions. To that end I hope you
 find the post useful and that you feel free to ask any questions you
 may have.

 The second purpose is to elicit feedback from the community on how
 they would or have approached the problem of developing and deploying
 Clojure web applications.

 I'm particularly interested in the specifics of how people tie
 together and round out entire apps with e.g. logging and exception
 handling, how they develop apps locally, and how they deploy them to
 production. I think the most useful basis for discussing things like
 this is complete working examples of applications and associated
 instructions for how to deploy them. I doubt there are very many such
 open-source apps floating around, but if anyone has one to share I
 would love to see it.

 Even if you don't have a complete app to share, I would love to hear
 your comments and see your code snippets on the specific aspects of
 the development and deployment process that I covered (or perhaps
 omitted) in the post.

 - Mark

-- 
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
Note that posts from new members are moderated - please be patient with your 
first post.
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: Feedback on Clojure web development post

2010-07-26 Thread Steve Purcell
On 26 Jul 2010, at 17:30, tguy wrote:

 When developing a web app, my preference would be to edit files using
 SLIME with lein swank like all of my other development. So, I should
 be able to start and stop the server from the repl and can reflect my
 changes in the browser simply by reloading a function.
 
 I used to be able to develop like this easily with compojure 0.3.2,
 but since 0.4 it doesn't seem to provide this functionality anymore.
 Is there a modern and easy way to fit this style of development with
 jetty?



This *is* possible with Compojure 0.4, but you have to wrap your routes or app 
in a var:

(def my-ring-app
 (- (routes
  (GET / [] (my-index)))
 (ring.middleware.file/wrap-file public)
 (ring.middleware.file-info/wrap-file-info)
 (ring.middleware.lint/wrap-lint)
 (ring.middleware.stacktrace/wrap-stacktrace)))


(defn start-app []
  (ring.adapter.jetty/run-jetty (var my-ring-app) {:port 8080 :join? false}))


Regarding start/stop functionality, see this thread:

  http://groups.google.com/group/compojure/browse_thread/thread/5606760b86cfd49c

-Steve




 
 On Jul 24, 3:30 am, Mark McGranaghan mmcgr...@gmail.com wrote:
 Hi All,
 
 I recently posted to my blog on the process of developing and
 deploying a simple Clojure web application:
 
 http://mmcgrana.github.com/2010/07/develop-deploy-clojure-web-applica...
 
 The purpose of this post is twofold. The first is to provide some
 documentation in the form of a complete, deployable Clojure web app
 and associated commentary and instructions. To that end I hope you
 find the post useful and that you feel free to ask any questions you
 may have.
 
 The second purpose is to elicit feedback from the community on how
 they would or have approached the problem of developing and deploying
 Clojure web applications.
 
 I'm particularly interested in the specifics of how people tie
 together and round out entire apps with e.g. logging and exception
 handling, how they develop apps locally, and how they deploy them to
 production. I think the most useful basis for discussing things like
 this is complete working examples of applications and associated
 instructions for how to deploy them. I doubt there are very many such
 open-source apps floating around, but if anyone has one to share I
 would love to see it.
 
 Even if you don't have a complete app to share, I would love to hear
 your comments and see your code snippets on the specific aspects of
 the development and deployment process that I covered (or perhaps
 omitted) in the post.
 
 - Mark
 
 -- 
 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
 Note that posts from new members are moderated - please be patient with your 
 first post.
 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
 

-- 
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
Note that posts from new members are moderated - please be patient with your 
first post.
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


Feedback on Clojure web development post

2010-07-24 Thread Mark McGranaghan
Hi All,

I recently posted to my blog on the process of developing and
deploying a simple Clojure web application:

http://mmcgrana.github.com/2010/07/develop-deploy-clojure-web-applications.html

The purpose of this post is twofold. The first is to provide some
documentation in the form of a complete, deployable Clojure web app
and associated commentary and instructions. To that end I hope you
find the post useful and that you feel free to ask any questions you
may have.

The second purpose is to elicit feedback from the community on how
they would or have approached the problem of developing and deploying
Clojure web applications.

I'm particularly interested in the specifics of how people tie
together and round out entire apps with e.g. logging and exception
handling, how they develop apps locally, and how they deploy them to
production. I think the most useful basis for discussing things like
this is complete working examples of applications and associated
instructions for how to deploy them. I doubt there are very many such
open-source apps floating around, but if anyone has one to share I
would love to see it.

Even if you don't have a complete app to share, I would love to hear
your comments and see your code snippets on the specific aspects of
the development and deployment process that I covered (or perhaps
omitted) in the post.

- Mark

-- 
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
Note that posts from new members are moderated - please be patient with your 
first post.
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: Feedback on Clojure web development post

2010-07-24 Thread David Nolen
On Sat, Jul 24, 2010 at 3:30 AM, Mark McGranaghan mmcgr...@gmail.comwrote:


 http://mmcgrana.github.com/2010/07/develop-deploy-clojure-web-applications.html


This is great! :)

The tools and libraries have come a long way, now we just need more killer
documentation like this. Thanks for taking the time to do this.

-- 
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
Note that posts from new members are moderated - please be patient with your 
first post.
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: Feedback on Clojure web development post

2010-07-24 Thread Ryan Waters
Thank you, Mark.  It's awesome when someone has the patience, time and
interest in putting something like this together so others may learn
faster.  I know I'll benefit from it.

- Ryan
(irc nick arkh)


On Sat, Jul 24, 2010 at 2:30 AM, Mark McGranaghan mmcgr...@gmail.com wrote:
 Hi All,

 I recently posted to my blog on the process of developing and
 deploying a simple Clojure web application:

 http://mmcgrana.github.com/2010/07/develop-deploy-clojure-web-applications.html

 (more in previous post)

-- 
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
Note that posts from new members are moderated - please be patient with your 
first post.
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