Yeah, it's hard to deny the convenience of Clojure's keyword lookups and
standard assoc mechanism for getting and setting stored values, but I think
Bertrand Meyer's Uniform Access Principle reflects some pretty deep
thinking about the kinds of complications that arise in maintaining large
Hi folks,
I added code that lets you call your clojure functions via JMX operations.
https://github.com/henrik42/spring-break#jmxmbeans
Cheers Henrik
--
You received this message because you are subscribed to the Google
Groups Clojure group.
To post to this group, send email to
You are right!
If, say, a file write, fails the data would reside only in your memory refs.
One way to make sure the two thing are always in sync is to be able to
rollback the in-memory state (and replaying all subsequent actions) by
holding on to the old version until the agent could be derefed
While this discussing has taken a slight tangent from my original question,
it's been a very interesting read. Thanks for all your thoughts everyone.
You guys rock!
On 18 October 2014 08:28, Mark Engelberg mark.engelb...@gmail.com wrote:
Yeah, it's hard to deny the convenience of Clojure's
On 18 October 2014 08:28, Mark Engelberg mark.engelb...@gmail.com wrote:
Yeah, it's hard to deny the convenience of Clojure's keyword lookups and
standard assoc mechanism for getting and setting stored values, but I think
Bertrand Meyer's Uniform Access Principle reflects some pretty deep
I'm happy to announce the release of Om 0.8.0-alpha1. This release
includes the single biggest conceptual enhancement since its initial
release - Reference Cursors.
As we begin to build larger and larger applications with Om, we
often run afoul of the need to organize our application around a
James might be too modest to mention this as an exemplar as he's the
maintainer, but for me, Ring https://github.com/ring-clojure/ring is a
great example of the success of data-as-API. HTTP requests are represented
as a nested map with well-known keys, and middleware works with these
fields or
Fantastic work, David! Thank you for all your hard work on Om!
This is definitely an exciting release and I look forward to playing with
it over the coming days. I'll be sure to report back on my experience with
it.
On 18 October 2014 16:53, David Nolen dnolen.li...@gmail.com wrote:
I'm happy
+1.
Two years ago we went all data driven here. We stripped the code size and
complexity by
a huge factor. All data encapsulation code was sent to the trash can.
Our processing is driven by data more than by code. We ended up with a
significant
increase in generic code not linked to the
Greeting everyone,
It might be stupid question but I expect
(first (map (fn [_] (println executed)) [1 2 3 4]))
prints only once (realizing only first element in lazy seq returned by map)
but it prints four times.
Can some one shed a light why?
Thanks in advance
Best regards
Shahrdda
--
Some lazy lists are chunked for efficiency, which means Clojure will
read-ahead and evaluate a number of elements in advance. Often the outputs
from the various list handling functions are chunked (e.g. map, range,
etc.), while creating a seq explicitly with lazy-seq will not be chunked.
- James
You can try in you repl with
(take 1 (map (fn [_] (println executed)) (vec (range 100
(take 32 (map (fn [_] (println executed)) (vec (range 100
(take 33 (map (fn [_] (println executed)) (vec (range 100
you will observe the 32 sized chunks.
On Sat, Oct 18, 2014 at 7:36 PM,
Thanks a lot for your explanation, the thing that confuses me was the same
function used with repeatedly only prints once:
(first (repeatedly 4 #(do (println executed!) (inc 1
I guess because Clojure does not read-ahead in this scenario. Am I right?
On Sat, Oct 18, 2014 at 1:41 PM, Jonathan
Phil,
I've used scp uploads in the past. They're much easier when e.g. you wanna
upload a java library you've forked. Without scp uploads (or an easy
copy/paste curl alternative), you have to go through getting the project to
build with lein by itself. It's not *too* difficult to get a maven
(def map-entry (first {1 2}))
(empty map-entry)
= nil
Up until now my understanding was that map entries are completely
interchangeable with vectors, in that you can conj and assoc just like
vectors, and you can even call them like functions. I figured that calling
empty on a map entry would
I think all of James' points about the proven value of structuring an
application primarily around data rather than a complex API are right on
point. It is one of the things I love about the Clojure philosophy.
But there's nothing about the value of data-driven development that
requires data
See this thread:
https://groups.google.com/forum/#!searchin/clojure/unexpected$20behavior$20of$20clojure.core$2Fempty/clojure/z4GiyxvFEqg/zxwTklPa2mEJ
--
You received this message because you are subscribed to the Google
Groups Clojure group.
To post to this group, send email to
Hi there,
If you're looking for books, I don't know of any. But my Intro to Clojure
videos have lots of exercises and start from the beginning.
http://www.purelyfunctional.tv/intro-to-clojure
In terms of exercises, I cut my Clojure teeth on Project
Euler. https://projecteuler.net/ Once you
Hi Arkadiusz,
You're right: you should leverage on the existing functionality from
Leiningen itself as much as possible. I think you'd want to follow an
approach like this:
- Create your Clojure-based web application, include Leiningen itself as a
runtime dependency
- Generate a project
Maybe we need some sort of lazy map where:
(def m (assoc-computed {:first-name Robert :last-name Plankton}
:full-name #(str (:first-name %) (:last-name
%
;; will call the function to compute the value and will memoize it:
(:full-name m)
;; now the memoized value is
Brilliant! Looking forward to digging into it.
P.S I was wondering when that Advanced tutorial was going to be written,
looks like its up!
Don't know how you find the time but glad that you do!
On Saturday, October 18, 2014 5:53:57 PM UTC+2, David Nolen wrote:
I'm happy to announce the
On 18 October 2014 21:02, Mark Engelberg mark.engelb...@gmail.com wrote:
I think all of James' points about the proven value of structuring an
application primarily around data rather than a complex API are right on
point. It is one of the things I love about the Clojure philosophy.
But
I don't know who is the outlier. The point is that Scala, for instance,
has explicit support to hide the distinction between accessing a value
and computing a value. The point is to support the uniform access
principle.
http://en.wikipedia.org/wiki/Uniform_access_principle
In one
Last week, I ran into Leiningen issue 1702, lein
self-install/upgrade/downgrade is broken in lein.bat (2.5.0)[1]. Here's
how it happened: I emailed a Windows user a pointer to leiningen.org. I
got an email back saying -- doesn't work.
We worked around it by editing lein.bat in Notepad and
Hi
Interesting work as usual! One quick question: What is the difference between
(let [xs (om/observe owner (items))]
...)
as seen in the sub-view component versus the one in main-view which doesn't use
`om/observe`:
(let [xs (items)]
...)
/Jonas
On Saturday, October
25 matches
Mail list logo