/making-sure-a-web-page-is-not-cached-across-all-browsers),
or if this is just for development, then Chrome at least has a checkbox in
the developer tools for disabling caching.
- James
On 19 June 2015 at 10:00, Colin Yates colin.ya...@gmail.com
mailto:colin.ya...@gmail.com wrote:
Hi all
Hi all, is there a quick way to disable caching for everything or
alternatively hash based on the contents of the resource. I am talking
specifically about CSS and javascript issues served from the JAR's class
path?
--
You received this message because you are subscribed to the Google
Groups
/leiningen/blob/master/src/leiningen/test.clj#L137
https://github.com/technomancy/leiningen/blob/master/src/leiningen/test.clj#L137
On Friday, June 19, 2015 at 8:41:49 AM UTC-5, Colin Yates wrote:
First - cljc is (for me) a huge upgrade over cljx, which was a great
solution. Not having to run
/leiningen/test.clj#L137
On Friday, June 19, 2015 at 8:41:49 AM UTC-5, Colin Yates wrote:
First - cljc is (for me) a huge upgrade over cljx, which was a great
solution. Not having to run lein clix auto every time I do a clean is far
more useful than I realised.
The problem I am having
I name all of my protocols as active very in the first tense/descriptions of
what they do. Rather than ‘Find’ I would have ‘IFindThings’. It takes a bit of
getting used to and it was a suggestion in something I read a while ago (one of
Steve Yeggies’ posts maybe?) but it really makes you think,
Lesson learned here for me is that only use java array when absolutely
necessary. I always thought since it's primitive array, it should be the
fastest. Apparently not!
This bears repeating. I often find it hit-and-miss to know when idiomatic
Clojure will be faster than turning to Java. Are
Will guess in the dark but would boxing come into play here?
On 10 Jun 2015, at 21:03, Ritchie Cai ritchie...@gmail.com wrote:
I'm working on a java array of double with 128 elements. I need the max
and min values of the array. So I initially tried areduce and loop, both
gives runs
I recall seeing that from a while ago - weren’t they planning on rewriting
emacs effectively?
On 1 Jun 2015, at 15:55, Mikhail Malchevskiy malch...@gmail.com wrote:
https://github.com/syl20bnr/spacemacs =)
понедельник, 1 июня 2015 г., 17:05:35 UTC+3 пользователь Colin Yates написал:
Hi
ride using
nginx as reverse proxy and running the uberjar inside tmux. No other
special sauce needed, plus you get the benefit of using nginx to serve
your static assets (if there're not on a CDN already)...
On 1 June 2015 at 14:40, Colin Yates colin.ya...@gmail.com wrote:
Thanks Daniel, I
is a Unix classic (as in an outstanding example of a particular
style), and Boot is quickly becoming a Clojure classic.
More examples here:
https://github.com/danielsz/system/blob/master/examples/boot/build.boot
On Tuesday, May 26, 2015 at 2:38:30 PM UTC+3, Colin Yates wrote:
Hi,
I am
.
https://github.com/Skinney/oslo-programmene/blob/development/project.clj
fredag 29. mai 2015 11.17.25 UTC+2 skrev Colin Yates følgende:
In the vein of there are no stupid questions :), how does one structure a
combined clj and cljs project that uses reader conditionals? At the moment I
am
In the vein of there are no stupid questions :), how does one structure a
combined clj and cljs project that uses reader conditionals? At the moment
I am using cljx and have:
- src/clj for clojure files
- src/cljs for clojurescript files
- src/cljx for cljx
- target/cljx/clj for clojure
Thanks Stuart.
On 27 May 2015, at 08:53, Stuart Sierra the.stuart.sie...@gmail.com wrote:
JSVC (Apache Commons daemon for Unix) is excellent for this sort of thing.
There's a Windows Services version too.
–S
On Tuesday, May 26, 2015 at 12:38:30 PM UTC+1, Colin Yates wrote:
Hi,
I am
Hi,
I am venturing into new territory using http-kit, as I usually use a
'managed' web server container like tomcat and have a few questions about
packing and running a JAR file:
- are there are convenient service wrappers for windows and/or Linux
- any best practice around managing class
This looks similar to https://github.com/lynaghk/cljx/issues/60 but I am
running 0.6.0.
I have tried lein do clean, cljx once, garden once, cljsbuild once,
uberjar but uberjar seems to clear the target directory thus making the
previous tasks pointless.
Any suggestions or pointers which are
with little fuss.
I use InnoSetup to create a windows installer.
For the runtime class path, I just use something like, java -cp
conf;myuberjar.jar mypackage.main
On Tue, May 26, 2015 at 12:38 PM, Colin Yates colin.ya...@gmail.com wrote:
Hi,
I am venturing into new territory using http-kit, as I
experience, I am
relatively new to Clojure, but I read a lot of Clojure code at this point.
On Saturday, May 23, 2015 at 6:16:15 AM UTC-4, Colin Yates wrote:
Hi,
My use-case is that I need to have a bunch of state which differs for each
(web) request but is accessible via a var. Specifically
/configuration.html
http://logback.qos.ch/manual/configuration.html.
BR
--
Henrik
On Tue, May 26, 2015 at 1:38 PM, Colin Yates colin.ya...@gmail.com
mailto:colin.ya...@gmail.com wrote:
Hi,
I am venturing into new territory using http-kit, as I usually use a
'managed' web server
Hi,
My use-case is that I need to have a bunch of state which differs for each
(web) request but is accessible via a var. Specifically I need to allow
code to access the current transaction and register one or callbacks that
are executed if/after that transaction is committed.
In Java I would
Yes, exactly. In my previous email I incorrectly said '() was a set.
On 21 May 2015 01:07, Pierre Thibault pierre.thibau...@gmail.com wrote:
No:
(type '())
clojure.lang.PersistentList$EmptyList
It a list just like it should be.
Le mercredi 20 mai 2015 20:02:22 UTC-4, Colin Yates a écrit
@my-atom is the same as (deref my-atom), is that what you mean?
On 20 May 2015 23:35, Pierre Thibault pierre.thibau...@gmail.com wrote:
Is possible to use the operator '@' alone? In the Joy Of Clojure book it
is presented as '~@'. I would like an example.
--
You received this message because
construct.
On 20 May 2015 23:43, Pierre Thibault pierre.thibau...@gmail.com wrote:
For example:
(def foo '(1 2 3))
(+ @foo)
Does not work. I am expecting 6.
Le mercredi 20 mai 2015 18:37:05 UTC-4, Colin Yates a écrit :
@my-atom is the same as (deref my-atom), is that what you mean?
On 20 May
a temperal construct.
On 20 May 2015 23:43, Pierre Thibault pierre.t...@gmail.com wrote:
For example:
(def foo '(1 2 3))
(+ @foo)
Does not work. I am expecting 6.
Le mercredi 20 mai 2015 18:37:05 UTC-4, Colin Yates a écrit :
@my-atom is the same as (deref my-atom), is that what you mean
As stated in the article, I find the extra context of using :as aids
maintenance more than you might expect. The only time I use refer is
if the referred vars are conceptually owned, or the context is
implicit by the name space using them. For me it is about
responsibility and ignorance. :as
I guess a related concern is abstraction. I notice I often have functions
which work at different levels of abstraction in the same ns which makes me
uncomfortable. In OO land they would be package level or even instance
classes. I haven't yet found a way to solve this in clojure land.
To be
Probably not helpful, but I tend to rely on the jvm optimisations and just
-server. I figured this is an area where a little knowledge is a dangerous
thing.
At the very least I would have a realistic benchmark suite to prove to
myself that these gains were worth it. In my experience the
it was a non-issue at this point.
Is that incorrect?
On Thu, May 14, 2015 at 1:54 PM, Colin Yates colin.ya...@gmail.com
wrote:
Probably not helpful, but I tend to rely on the jvm optimisations and
just -server. I figured this is an area where a little knowledge is a
dangerous thing
That assumes the intermediate functions are reusable. I guess with all
these things asthetics come into play, and there is of course the option of
letfn as well.
On 14 May 2015 18:40, Sean Corfield s...@corfield.org wrote:
On May 14, 2015, at 10:28 AM, Colin Yates colin.ya...@gmail.com wrote
Is there a lib that will allow me to have my sql defined in a file which I
can reference from Clojure? I cannot use one of the existing migration
libraries as I need to do more than just manipulate SQL on a version
upgrade.
I am aware of yesql which would be great but it didn't work out for
, Colin Yates colin.ya...@gmail.com wrote:
Is there a lib that will allow me to have my sql defined in a file which I
can reference from Clojure? I cannot use one of the existing migration
libraries as I need to do more than just manipulate SQL on a version upgrade.
I am aware of yesql which
Have you tried with-meta?
On 7 May 2015 15:13, Stig Brautaset sbrauta...@gmail.com wrote:
Is it because the def form can also be ^:dynamic?
At any rate, I did an attempt at my first macro to create a (def- ...)
form, but it doesn't seem to work. Can you not attach metadata in a macro?
Clojure + developer's skill + existing libraries + custom code is the
framework.
On 3 May 2015 15:27, Fluid Dynamics a2093...@trbvm.com wrote:
On Sunday, May 3, 2015 at 2:12:02 AM UTC-4, Sven Richter wrote:
Hi,
Reading through all the discussion I don't get which features you are
actually
Ok, thanks Mark.
On 13 Apr 2015 06:37, Mark Derricutt m...@talios.com wrote:
On 3 Apr 2015, at 3:14, Colin Yates wrote:
Do you have any references to OSGi and Clojure?
My fork of clojure.osgi is updated for 1.6 and in Maven Central:
https://github.com/talios/clojure.osgi
and a simple
Lein-test-refresh works well
On 9 Apr 2015 14:55, Denis L sad.ho...@gmail.com wrote:
I use Rspec/Guard to watch changed files and automatic run test for for
Ruby/Rails application.
How can I repeat similar scenario for Clojure-app?
--
You received this message because you are subscribed to
Well done- just purchased and looking forward to read this tonight.
Sent from my iPhone
On 8 Apr 2015, at 14:27, Alex Miller a...@puredanger.com wrote:
Hey all,
I'm very happy to announce that Clojure Applied is now available in beta:
https://pragprog.com/book/vmclojeco/clojure-applied
Hi,
I have a common library which I want to use in both Clojure and
ClojureScript. The project uses cljx and works a treat and the generated
clj and cljs are available to use alongside the hard coded clj and cljs.
However, when I add that project (after doing the initial lein install) to
the
Do you have any references to OSGi and Clojure?
On 2 April 2015 at 15:11, Alex Miller a...@puredanger.com wrote:
It's possible we could make use of Java's module system if it ever actually
gets released in Java 9. While I followed it pretty extensively when they
first started discussing it (7
Ha! Genius.
On 30 March 2015 at 19:47, danle...@gmail.com danle...@gmail.com wrote:
http://www.scribd.com/doc/30605092/Saturn-v-Flight-Manual
I have tracked down the flight manual of the Saturn-V rocket so we can
objectively decide whether emacs is more, or less, difficult.
--
You
me own emacs-based-editor - sure :). I
had better stop thinking about emacs as it is feeding my ever-present
'grass is greener' gene
On 31 March 2015 at 10:54, Phillip Lord phillip.l...@newcastle.ac.uk wrote:
Alexis flexibe...@gmail.com writes:
Colin Yates colin.ya...@gmail.com writes:
I
This. I am amazed it isn't more widely shouted about.
On Sunday, 29 March 2015 12:34:23 UTC+1, Jony Hudson wrote:
First, let me shamelessly plug Gorilla REPL http://gorilla-repl.org .
It's a notebook type REPL, which I think works well as an environment for
the sort exploratory programming
For me personally, I absolutely admire emacs - I really do. I used it
a few years back when I first started in Clojure before Cursive was
around and when it was configured correctly it was absolutely great.
From an engineering POV, yeah, it rocks.
I am sure that for anything I can do in IDE-X I
I assumed his reference to emacs covered CIDER - don't be so sensitive :).
On 29 March 2015 at 15:14, Bozhidar Batsov bozhi...@batsov.com wrote:
And CIDER isn't, right? I find this pretty insulting...
On 29 March 2015 at 13:47, Colin Yates colin.ya...@gmail.com wrote:
Cursive Clojure
Cursive Clojure, LightTable and CounterClockwise are all good Clojure IDEs.
On 29 March 2015 at 09:54, Sayth Renshaw flebber.c...@gmail.com wrote:
Hi
I last learned clojure in 1.2. Just curious why Clojure hasn't developed as a
go to for data science?
It never seems to get a mention
Luc, you are missing the point: this isn't the forum for that
discussion regardless of how valid the points in that discussion are.
This is a _Clojure_ forum, not a 'what's wrong with the (technology)
world' forum, I would suggest this isn't even a 'how can Clojure fix
the world' forum.
Luc,
Hi Leonardo, I haven't read it yet but I am very much looking forward
to it based on other people's responses :).
On 26 March 2015 at 15:52, Leonardo Borges leonardoborges...@gmail.com wrote:
Thanks everyone for the kind words!
It makes it all worth it :)
Cheers,
Leonardo
On Thursday,
No - he is right, we just don't say it! Obviously I am kidding :).
On 25 March 2015 at 11:51, Hildeberto Mendonça m...@hildeberto.com wrote:
On Wed, Mar 25, 2015 at 12:14 PM, Colin Yates colin.ya...@gmail.com wrote:
Hi Shahrdad, just a point of etiquette, inferring that an architect
to be that hard.
Clojure is the first real try in opposite direction (touch of genius)
Thanks a lot
Best regards
Shahrdad
On Wed, Mar 25, 2015 at 8:06 AM, Colin Yates colin.ya...@gmail.com wrote:
No - he is right, we just don't say it! Obviously I am kidding :).
On 25 March 2015 at 11:51
Hi Shahrdad, just a point of etiquette, inferring that an architect is
ignorant because they chose Java8, Akka and play is full of assumptions.
Calling those technologies pathetic is very bad poor.
As I like to quote Any intelligent fool can make things bigger and more
complex... It takes rude
If there are enough optional args that they need to be named then I
choose a map, every time. That said, I do must multi-arity fns quite a
bunch as well (with the options map going on the end if applicable).
I also depend quite heavily on prismatic's schema, and to a lesser
extent core.typed and
http://stuartsierra.com/2013/03/29/perils-of-dynamic-scope is a good
read around this subject.
On 21 March 2015 at 21:47, coco clasesparticulares...@gmail.com wrote:
Hi guys, I'm curious about how work some codes with binding and dynamics
vars, for instance, in sqlkorma you define your db
I don't have the answer (as I too am in the still-going-blind phase)
but the following might help:
- deref symbols to get their value
- http://learnxinyminutes.com/docs/clojure-macros/ (short and very helpful)
- http://www.braveclojure.com/writing-macros/ (long and very helpful)
-
Hi James,
Do you have a code fragment/gist for the glue?
On 17 March 2015 at 17:47, James Gatannah james.gatan...@gmail.com wrote:
On Thursday, March 12, 2015 at 10:16:10 AM UTC-5, Stuart Sierra wrote:
On Wednesday, March 11, 2015, Colin Yates wrote:
Nested systems don't really work
help,
Torsten.
Am Sonntag, 15. März 2015 19:15:04 UTC+1 schrieb Colin Yates:
If you haven't already then you might want to watch:
https://www.youtube.com/watch?v=13cmHf_kt-Q
If it helps:
(defn a-real-worker [db]
...)
(defrecord ARealWorkerComponent [db registry]
components
Hi Torsten,
It works best when it is all-or-nothing, so the caller of get-user
would itself be a component that is dependant upon the db component.
The way I visualise it is that the components are a very thin layer at
the outer edge of the system that delegate to actual worker functions.
Those
In OO we tend to solve the 'copy and paste' problem with abstract
classes. In Clojure we also have macros, easily overused, sure, but
worth knowing about. They turn the problem on its head and allow truly
composable functionality. I am not stating they _are_ appropriate
here, only that you might
itself. The big weakness is that it would require using
a custom start-system stop-system function rather than the standard one.
Andrew Oberstar
On Sun, Mar 15, 2015 at 11:32 AM Colin Yates colin.ya...@gmail.com wrote:
In OO we tend to solve the 'copy and paste' problem with abstract
classes
If you haven't already then you might want to watch:
https://www.youtube.com/watch?v=13cmHf_kt-Q
If it helps:
(defn a-real-worker [db]
...)
(defrecord ARealWorkerComponent [db registry]
components/Lifecycle
(start [this]
(registry-api/register registry (partial a-real-worker-fn db))
. I'll give that a go along with a few other ideas,
and see what works out best. Thanks for the help!
Andrew Oberstar
On Sun, Mar 15, 2015 at 1:22 PM Colin Yates colin.ya...@gmail.com
wrote:
I don't have one at hand (as I literally wrote my first macro last
week ;)) but the way it could
Hi,
I am wiring up a bunch of CRUD command handlers for different aggregates
using prismatic schema to validate and it is screaming out for a macro, but
my ignorance is screaming even louder :).
The form I want to emit is something like (for a 'Location' for example):
(s/defn
?
On Friday, 13 March 2015 12:27:02 UTC, Colin Yates wrote:
Hi,
I am wiring up a bunch of CRUD command handlers for different aggregates
using prismatic schema to validate and it is screaming out for a macro, but
my ignorance is screaming even louder :).
The form I want to emit is something like
OK, so ~(symbol create) was what I needed to do but that now loses the
^:always-validate meta :)..
On Friday, 13 March 2015 12:42:36 UTC, Colin Yates wrote:
Nope, never mind - it was a dirty REPL. It works fine-ish.
My next problem is that it works fine, but only if I call
Thanks Tobias. The complete macro body is now:
(let [{:keys [hierarchy-key
cascade-keys
define-command-schema
defined-event-schema
define-command-key
defined-event-key]} (default-options aggregate)]
`(do
at 3:01 PM, Colin Yates colin...@gmail.com
javascript: wrote:
merge won't help as there will be name space clashes.
I wonder if a more elegant approach would be to construct the 'inner'
system and then assoc onto it the external dependencies it needs
before calling start.
On 11 March 2015
misunderstood your question; I didn't realize it was system (as
opposed to any general component) specific. I think systems can be merged
together (via 'merge'). Would that help?
On Wednesday, March 11, 2015 at 2:40:14 PM UTC-4, Colin Yates wrote:
Hi Adrian - I don't follow how that helps integrate two
...@gmail.com wrote:
On Wednesday, March 11, 2015, Colin Yates wrote:
I can't merge the two systems because the reusable
component is chocka full of very fine grained command
handlers and both the internal and external systems will
have their own 'bus' for example. I could namespace the
keys
as a value.
On Wednesday, March 11, 2015 at 2:17:12 PM UTC-4, Colin Yates wrote:
I have a non-trivial component which requires a bunch of internal and
external collaborators to work. This component is itself re-usable.
What I really want to do is have ReusableComponent be a component
I have a non-trivial component which requires a bunch of internal and
external collaborators to work. This component is itself re-usable.
What I really want to do is have ReusableComponent be a component in a
system so it can pull its external collaborators. However,
ReusableComponent
I know this is a different direction than a lot of people but I store
everything in the app-state and so far it has worked well. There are a
hundred reasons why this (storing everything in app-state) is a
terrible idea, but I haven't run into any of them.
The main driver for this was for bug
You could build something on top memory mapped files. I did this to solve
similar requirements with good effect.
On 6 Mar 2015 18:55, JPatrick Davenport virmu...@gmail.com wrote:
Hello,
I'm been thinking about an idea for a cache layer. It's driven by two
trends.
Most caches are in memory.
the problems you raised that points in
the direction of modeling and then executing the data flow, rather than
relying solely on the call stack.
On Thu, Mar 5, 2015 at 9:39 AM, Colin Yates colin.ya...@gmail.com wrote:
Sounds interesting - are there are instances that I can look at?
On 5 March
, rather to
share another thought process around the problems you raised that points in
the direction of modeling and then executing the data flow, rather than
relying solely on the call stack.
On Thu, Mar 5, 2015 at 9:39 AM, Colin Yates colin.ya...@gmail.com wrote:
Sounds interesting
Isn't this exactly what defrecord does?
On 5 March 2015 at 07:42, Xiangtao Zhou tao...@gmail.com wrote:
hi all,
is there some library or simple way to do it like the function map-to-pojo
in the following code ?
java code
class A{
public int a;
public String b;
}
clojure code
(def
, Colin Yates colin.ya...@gmail.com wrote:
Hi,
I am looking for the Clojure equivalent of:
class Whatever {
@Transactional
void doSomething(IDoSomething one, IDoSomethingElse two) {
one.doSomething()
two.doSomething()
}
}
where both one and two are dependency
, while functions
that deal with edge resources take those resources along with other
parameters more explicitly, so the data flow can run in an insulated
fashion.
On Thu, Mar 5, 2015 at 8:55 AM, Colin Yates colin.ya...@gmail.com wrote:
Hi Jonah,
This sounds very much like the model layer
Hi,
I am looking for the Clojure equivalent of:
class Whatever {
@Transactional
void doSomething(IDoSomething one, IDoSomethingElse two) {
one.doSomething()
two.doSomething()
}
}
where both one and two are dependency injected with a proxy which resolves
to a thread
March 2015 17:58:58 UTC, Colin Yates wrote:
Hi,
I am looking for the Clojure equivalent of:
class Whatever {
@Transactional
void doSomething(IDoSomething one, IDoSomethingElse two) {
one.doSomething()
two.doSomething()
}
}
where both one and two are dependency
Only if you promise to move up to Leicester :).
On 4 March 2015 at 13:14, John Kane j...@kanej.me wrote:
Hello Stephen,
There is a small group of us based around Exeter and we are trying to get a
group off the ground, is that close enough to be of interest?
John
On Tuesday, 3 March 2015
, possibly composed with other
functions, and invoked elsewhere), I usually have a convention where I pass
a map of options as an argument to the handler, and make the database a
value in that map.
On Wednesday, March 4, 2015 at 12:58:58 PM UTC-5, Colin Yates wrote:
Hi,
I am looking
of
your transaction.
On Wednesday, March 4, 2015 at 1:15:02 PM UTC-5, Colin Yates wrote:
Hi Adrian, and thanks for replying.
I understand your point, but the subtlety is that a transactional
connection is per function invocation where as the database component
is per Component lifecycle
Are v1 as unique as randomUUID()?
On 3 Mar 2015 20:08, danle...@gmail.com danle...@gmail.com wrote:
PS. We are now TEN TIMES faster, so it is a lot easier to compute that
percentage:
#'uuid/v1:201 nanoseconds
#'java.util.UUID/randomUUID: 2012 nanoseconds
Best,
Dan
, 2015 at 3:11:23 PM UTC-5, Colin Yates wrote:
Are v1 as unique as randomUUID()?
On 3 Mar 2015 20:08, danl...@gmail.com danl...@gmail.com wrote:
PS. We are now TEN TIMES faster, so it is a lot easier to compute that
percentage:
#'uuid/v1:201 nanoseconds
#'java.util.UUID
Ha - the irony of you and I posting a message about uniqueness at pretty
much the same time :).
On 3 Mar 2015 20:11, Lucas Bradstreet lucasbradstr...@gmail.com wrote:
Hi,
Nice work!
I wanted to clarify something: it seems to me that the v1 uuids clj-uuid
generate are not exactly equivalent
And an example of its output would be nice :). The project is
https://github.com/tsdh/lein-html5-docs I think.
On 2 March 2015 at 20:49, Jeremy Heiler jeremyhei...@gmail.com wrote:
Do you have a link to the project? :-)
On Mon, Mar 2, 2015 at 3:26 PM, Tassilo Horn t...@gnu.org wrote:
Hi all,
AM UTC-5, Colin Yates wrote:
If I have a stateful thing with a lifecycle then is the system component
the instance of the thing or a wrapper that contains the thing.
For example, let's say I have a registry of clients that want to be
polled then I might have the following:
(defrecord Registry
Note - at least in chrome on OS X the link is broken as it terminates at
the hype (http://danlentz.github.io/clj-).
Great work despite the chrome breaking project name ;).
On Monday, 2 March 2015 00:35:16 UTC, danl...@gmail.com wrote:
Ok, for anyone following my adventures optimizing
I would replace it with loop/recur or a while, with both checking a
termination flag (probably an atom) which is set by the user.
An alternative approach would be core.async with a stop channel and then
use alt! to check them both simultaneously.
On 1 Mar 2015 10:30, Cecil Westerhof
to be a mess of unnecessary code.
As Dr Eli Goldratt/TOC states: never say I know :). For example, I
meant 'for/while' not 'while' :).
On 1 March 2015 at 10:52, Cecil Westerhof cldwester...@gmail.com wrote:
2015-03-01 11:33 GMT+01:00 Colin Yates colin.ya...@gmail.com:
I would replace it with loop/recur
are invaluable.
On Sunday, 1 March 2015 10:53:05 UTC, Cecil Westerhof wrote:
2015-03-01 11:33 GMT+01:00 Colin Yates colin...@gmail.com javascript::
I would replace it with loop/recur or a while, with both checking a
termination flag (probably an atom) which is set by the user.
I was just going
If I have a stateful thing with a lifecycle then is the system component
the instance of the thing or a wrapper that contains the thing.
For example, let's say I have a registry of clients that want to be polled
then I might have the following:
(defrecord Registry [state])
(defn register-with
http://www.compoundtheory.com/clojure-edn-walkthrough/ is a nice read
around this as well.
On Tuesday, 24 February 2015 21:40:14 UTC, Colin Yates wrote:
I am sending instances of defrecords from clojurescript via transmit/edn
and getting:
2015-Feb-24 19:23:52 + dev-os-mbp.local DEBUG
Hi Cecil - have you looked at hiccup?
On 26 February 2015 at 19:39, Cecil Westerhof cldwester...@gmail.com wrote:
At the moment I have the following code:
(str html
table border='1' cellpadding='10'
style='font-family:Arial; font-size:16px; margin:
10px;width:100%'
16px :margin 10px :width 100%}}
[:tr
(for [header headers]
[:th {:bgcolor black :color white} header])]]))
HTH.
On Thursday, 26 February 2015 20:23:59 UTC, Cecil Westerhof wrote:
2015-02-26 20:46 GMT+01:00 Colin Yates colin...@gmail.com javascript::
Hi Cecil - have you
Hi,
I ran into a bit of a brick wall when thinking about how to register to and
dispatch to multiple micro-services and it made me realise the underlying
tension came from not having peace about a fundamental design decision; how
do you access your collaborators. Note: I am specifically
). I'm using component a lot and I never had the need for
this.
Maybe you can elaborate on why you think you need a multimethod inside the
component? Maybe a full example?
Cheers,
Jeroen
On Wed, Feb 25, 2015 at 12:08 PM, Colin Yates colin.ya...@gmail.com wrote:
Hi,
I have a number
). So:
(defmulti handle-command(fn [component command] (first command)))
(defmethod handle-command :add-customer [{:keys [db eventstore} [[_
customer]]]
... )
Isn't something like this enough?
Jeroen
On Wed, Feb 25, 2015 at 1:34 PM, Colin Yates colin.ya...@gmail.com wrote:
Hi Jeroen
,
Jeroen
On Wed, Feb 25, 2015 at 2:01 PM, Colin Yates colin.ya...@gmail.com wrote:
Yes, I did consider that but didn't like the idea of passing the
system around. Also handle-command would need access to the system as
well.
I am wondering whether simply having a 'registry' component which
export-query [db pdf-generator]
...)
; Convenience function that pulls system from an atom
(defn export-query []
(export-query (@system :db) (@system :pdf-generator)))
(defmethod handle-command :export-query [[_]]
(export-query))
marc
On Wed, Feb 25, 2015 at 8:23 AM, Colin Yates
the
lifecycle idea from Stuart Sierra's component (maybe define IStoppable) for
things that need shutdown, such as custom thread-pools.
Shantanu
On Wednesday, 25 February 2015 18:52:28 UTC+5:30, Colin Yates wrote:
Hi,
I ran into a bit of a brick wall when thinking about how to register
; you can just change the queue/push
function into a method on a protocol. Any code that uses queue/push will act
the same, but now we have different behaviour depending on the
configuration.
- James
On 25 February 2015 at 13:22, Colin Yates colin.ya...@gmail.com wrote:
Hi,
I ran
as a tagged literal (for edn compatibility). It’s only for
the Clojure side at the moment, but I imagine it wouldn’t be hard to port
to CLJS. However, I suggest that you use transit.
https://github.com/miner/tagged
On Feb 24, 2015, at 4:40 PM, Colin Yates colin...@gmail.com javascript:
wrote
201 - 300 of 551 matches
Mail list logo