Re: style question on tightly coupled functions

2014-11-20 Thread dm3
I guess the question is - why do the extracted functions look ugly or lack cohesion if they still accomplish part of the task previously done by `x`? If they are very general - you can consider moving them somewhere else and making them public, otherwise they should stay in the same namespace,

Re: Writing tests for a live trading API?

2014-03-27 Thread dm3
I would strongly recommend against doing tests against a live exchange, because there are just too many failure modes (network down, exchange down, exchange hostname changed, etc.) as well as the possibility to execute trades and lose money. What I usually do is this: * create stub

Re: ANN simple-time

2014-03-22 Thread dm3
Hey, this looks really simple and nice. So, to map Joda concepts to simple-time - a *timespan* is a standard Period (1 day is always 24 hours) and a *datetime* doesn't have a timezone, so more akin to LocalDateTime, right? There's also https://github.com/dm3/clojure.joda-time, in case you

Re: [ANN] Clojure.Joda-Time 0.1.0

2013-12-26 Thread dm3
It looks good, though can you explain the rationale for having a separate library? It seems from my perspective as if the objective of exposing all the good Joda functionality for Clojure consumption would be more readily achieved by extending the existing clj-time library. I chose to

[ANN] Clojure.Joda-Time 0.1.0

2013-12-25 Thread dm3
Hello, I would like to announce the first release of Clojure.Joda-Timehttps://github.com/dm3/clojure.joda-time - an ambitiously named wrapper for the Joda-Time date and time library. Main goals of Clojure.Joda-Time: * Provide a consistent API for common operations with instants, date-times

Re: [ANN] Clojure.Joda-Time 0.1.0

2013-12-25 Thread dm3
Oops, sorry about that... Fixed now. On Wednesday, 25 December 2013 13:53:10 UTC+2, Michael Klishin wrote: 2013/12/25 dm3 dead...@gmail.com javascript: There's quite a comprehensive README on github: https://github.com/dm3/clojure.joda-time which could use some very visible dependency

Type hints inside generated code

2013-12-04 Thread dm3
Hello, I've been having a little problem when trying to generate java interop code and avoid reflection warnings. I have to generate a bunch of functions which delegate to java constructors, like this: (defn mk-a [x y z] (A. x y z)) (defn mk-b [x y z] (B. x y z)) The main reason here is to be

Re: Type hints inside generated code

2013-12-04 Thread dm3
] ...)) - James On 4 December 2013 19:55, dm3 dead...@gmail.com javascript: wrote: Hello, I've been having a little problem when trying to generate java interop code and avoid reflection warnings. I have to generate a bunch of functions which delegate to java constructors, like this: (defn mk

Re: Type hints inside generated code

2013-12-04 Thread dm3
23:22:36 UTC+2, dm3 wrote: This would work if I knew the type of the function arguments. It doesn't seem to work when type-hinting on the constructor call. On Wednesday, 4 December 2013 22:31:53 UTC+2, James Reeves wrote: Try something like: (let [x (with-meta (gen-sym) {:tag String

Design question - dependencies and function discovery

2013-11-18 Thread dm3
Hello, Looking for opinions :) I'm currently building an event-driven service which consumes events using handlers. Now, the idea is to define a set of handlers (functions of type Event-Unit) in different parts of the service, which are then invoked when an event comes into the system. The

[ANN] Pocheshiro 0.1.1 (wrapper for Apache Shiro)

2013-11-12 Thread dm3
Pocheshiro (https://github.com/inventiLT/Pocheshiro) is a Clojure wrapper for the Apache Shiro[1] security library tailored for use with Ring/Compojure. Pocheshiro is a viable alternative for Friend if you're running in a servlet container and/or already know Apache Shiro. It's a thin wrapper

Re: [ANN] Narrator: expressive, composable stream analysis

2013-11-10 Thread dm3
I've read about Lamina and Narrator, watched the linked videos and I think I understand how it all fits together: 1) Instrument the applications using Lamina's `instrument` or `trace` 2) Probe the instrumented code somehow by channeling the traces to some endpoint (how do you do this? do you

Re: uberjar problem with Leiningen 2.3.3 (works with 2.3.2)

2013-10-19 Thread dm3
As I was the one who caused this by fixing `lein uberjar` :), I've submitted a pull request to ring which should fix improper `resource-response` behaviour: https://github.com/ring-clojure/ring/pull/97 2013 m. spalis 19 d., šeštadienis 04:02:06 UTC+3, xavi rašė: It seems it's this problem