Re: Actually using component.

2015-06-08 Thread Atamert Ölçgen
On Tue, Jun 9, 2015 at 6:12 AM, Timothy Baldridge wrote: > Stuart addresses two anti-patterns in your PRs. Perhaps I can help explain > them. > > Let's say we have a system that looks like this: > > (defrecord DBConnection []) > > (defrecord DBLayer [db-connection]) > > (defrecord AppLayer [db-la

Re: Actually using component.

2015-06-08 Thread Timothy Baldridge
Stuart addresses two anti-patterns in your PRs. Perhaps I can help explain them. Let's say we have a system that looks like this: (defrecord DBConnection []) (defrecord DBLayer [db-connection]) (defrecord AppLayer [db-layer]) We can construct a system thusly: {:db-connection (->DBConnection .

Re: Is there a cheet sheet for some of the pure symbolic functions like #'

2015-06-08 Thread Andy Fingerhut
I have just updated the Clojure cheat sheet to add most of the characters described in the "Weird and Wonderful Characters of Clojure" article. Many of them were already in the "Reader Macros" section, but I have renamed that section to "Special Characters" and added most of them. http://jafinger

Re: Actually using component.

2015-06-08 Thread James Reeves
My recommendation is to use a closure. So I'd write your example as: (defn username-endpoint [{:keys [db]}] (routes (GET "/:username" [username] (let [user (users/get-user db username)] (str "Hello " (:name user) "") So you pass your configuration map into the endpoint functi

Re: About transients no longer being safe in 1.7-alpha2

2015-06-08 Thread Ryan Schmitt
Will someone remember to update http://clojure.org/transients once 1.7.0 is released? On Monday, November 3, 2014 at 1:57:58 AM UTC-8, Daniel Marjenburgh wrote: > > Hi, > > I just want to address this issue (CLJ-1498 > ). It was accepted in > 1.7-alp

Re: [ANN] Dominator 0.3.0

2015-06-08 Thread David Sargeant
I imagine that performance should be on par with Elm (that is to say, really fast). I haven't had a chance to verify that however. David -- You received this message because you are subscribed to the Google Groups "Clojure" group. To post to thi

[ANN] Dominator 0.3.0

2015-06-08 Thread Ivan L
Any performance comparisons to refrain reagent? -- 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

Re: Actually using component.

2015-06-08 Thread J Irving
Hey Dru Take a look at Duct: https://github.com/weavejester/duct If you make a new app using that template, you should get some pointers from the boilerplate it generates. cheers, Jonathan On Mon, Jun 8, 2015 at 5:51 PM, Dru Sellers wrote: > So, I guess I am a bit lost, how does someone actual

Actually using component.

2015-06-08 Thread Dru Sellers
So, I guess I am a bit lost, how does someone actually use component? I have an application all set up with it and it seems to be working as I would expect but Stuart seems to be steering me in a different direction. https://github.com/stuartsierra/component/pull/35 https://github.com/stuartsierr

Re: [ANN] unilog 0.7.5: logging should be easy

2015-06-08 Thread David Sargeant
Looks great. Thanks for sharing. David -- 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 unsubscr

[ANN] test.check alpha release (with immutable random number generator)

2015-06-08 Thread Gary Fredericks
I'm excited to announce an important alpha release of test.check, the QuickCheck-inspired property-based testing library[1]. The 0.8.0 release will be the first release with the new immutable splittable random number generator[2], which is not really a user-facing change but is a serious imp

Hiring? Collecting job/hiring descriptions for this weekend’s ClojureBridge

2015-06-08 Thread Tj Gabbour
Hi! This weekend we’ll host a ClojureBridge workshop in Solingen (Cologne/Bonn region of Germany). If you’re interested in potentially hiring participants, please feel free to send the relevant info to me. I’ll happily print and offer your description to those who express interest!

ANN: erinite/template

2015-06-08 Thread Daniel Kersten
Hi everyone, I am working on a collection of web development libraries to accomplish various tasks that I've found myself wanting or needing in recent months. Collectively, I've dubbed them Erinite. The first of these libraries is erinite/template, a Clojure(script) hiccup transformation library

Software Quality video: Douglas Crockford

2015-06-08 Thread Alan Thompson
Hi, I just ran across one the best talks on software quality I've ever seen. Douglas Crockford in a Yahoo talk from 2007: https://youtu.be/t9YLtDJZtPY You have probably heard much of this before, but here it is very distilled to just the core ideas, along with good background information and an

Re: Identifying dependency that's pulling in SLF4J

2015-06-08 Thread Michael Gardner
> On Jun 8, 2015, at 10:30 AM, Stephen Gilardi wrote: > > Does “lein deps :tree” help? Yes, that's very helpful. Thanks. -- 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 f

Re: [ANN] - system : An alternative to Component

2015-06-08 Thread Alan Moore
Given that the primary protocol in the library is called Service you might consider calling your library "service" or "services" or something along those lines to avoid confusion with the other library. Even if the namespace will disambiguate things for coding, in emails, bug reports and other

Re: Identifying dependency that's pulling in SLF4J

2015-06-08 Thread Stephen Gilardi
> On Jun 8, 2015, at 1:26 PM, Michael Gardner wrote: > > I've started to see unwanted SLF4J console messages from one of my projects. > I'm not (directly) using SLF4J, and would like to find out which of my > dependencies is. But the dependency tree is a bit large to search by hand. Is > ther

Identifying dependency that's pulling in SLF4J

2015-06-08 Thread Michael Gardner
I've started to see unwanted SLF4J console messages from one of my projects. I'm not (directly) using SLF4J, and would like to find out which of my dependencies is. But the dependency tree is a bit large to search by hand. Is there a better way? -- You received this message because you are sub

Re: namespace :as vs :require

2015-06-08 Thread Matthew Boston
Here's a great post on the subject by Stuart Sierra: http://stuartsierra.com/2015/05/10/clojure-namespace-aliases - Matthew On Friday, June 5, 2015 at 9:33:32 PM UTC-6, Todd Stout wrote: > > What is considered idiomatic when using :as and :require in your namespace > declarations? I understand

New Functional Programming Job Opportunities

2015-06-08 Thread Functional Jobs
Here are some functional programming job opportunities that were posted recently: Clojure Engineer at MixRadio http://functionaljobs.com/jobs/8832-clojure-engineer-at-mixradio Cheers, Sean Murphy FunctionalJobs.com -- You received this message because you are subscribed to the Google G

Re: [ANN] - system : An alternative to Component

2015-06-08 Thread David Sargeant
Changed to system ns to system.core. Thanks for the suggestion, was meaning to do that. Sorry about the name collision. I just became aware of the other system library a few days ago. Haven't had an opportunity to think of something more clever. I'm open to suggestions. David -- You received

Re: [ANN] - system : An alternative to Component

2015-06-08 Thread Mikhail Malchevskiy
You know about https://github.com/danielsz/system, right? понедельник, 8 июня 2015 г., 17:53:08 UTC+3 пользователь David Sargeant написал: > > Differences from component: > > >1. No need to explicitly define dependencies for a particular service. >Simply order the services in the system

Re: [ANN] - system : An alternative to Component

2015-06-08 Thread James Reeves
You may want to consider the name, as there's already a library called "System" that does something similar: https://github.com/danielsz/system Also you're using single-segment namespaces (i.e. "system" rather than something like "system.core"). Single segment namespaces are generally discouraged,

Re: [ANN] - example : Stop writing unit tests and generate them instead (details inside)

2015-06-08 Thread Atamert Ölçgen
Got it. Thanks! On Mon, Jun 8, 2015 at 6:14 PM, David Sargeant wrote: > I'm not totally sure why you would need to use `provided` with pure > functions, but that is definitely not in scope for this project. example > isn't meant to replace all cases where you would write tests. It's designed > t

Re: [ANN] - example : Stop writing unit tests and generate them instead (details inside)

2015-06-08 Thread David Sargeant
I'm not totally sure why you would need to use `provided` with pure functions, but that is definitely not in scope for this project. example isn't meant to replace all cases where you would write tests. It's designed to streamline the creation of a certain class of tests that come with a lot of

Re: [ANN] - example : Stop writing unit tests and generate them instead (details inside)

2015-06-08 Thread Atamert Ölçgen
I meant (provided), (against-background), etc. On Mon, Jun 8, 2015 at 6:02 PM, David Sargeant wrote: > If I need something more complicated in terms of testing my functions I > usually create a file dev/examples.clj and add dev to the source-paths in > my project's dev profile. I would require t

Re: [ANN] - example : Stop writing unit tests and generate them instead (details inside)

2015-06-08 Thread David Sargeant
If I need something more complicated in terms of testing my functions I usually create a file dev/examples.clj and add dev to the source-paths in my project's dev profile. I would require the namespace with my functions and put the examples in dev/examples.clj. The rest of the process is the s

Re: [ANN] - example : Stop writing unit tests and generate them instead (details inside)

2015-06-08 Thread Atamert Ölçgen
Hi David, How does this integrate prerequisites? Even if my fn is pure, I still mock calls made within. On Mon, Jun 8, 2015 at 5:33 PM, David Sargeant wrote: > Speed up your development cycle using example. Here's the process: > > 1. Write your test code inline with your functions. > 2. Test th

[ANN] - system : An alternative to Component

2015-06-08 Thread David Sargeant
Differences from component: 1. No need to explicitly define dependencies for a particular service. Simply order the services in the system map to facilitate dependency needs. 2. Configuration is first-class. To start the system or a particular service, a config value must be passed.

[ANN] - example : Stop writing unit tests and generate them instead (details inside)

2015-06-08 Thread David Sargeant
Speed up your development cycle using example. Here's the process: 1. Write your test code inline with your functions. 2. Test the output of your functions in the REPL as you code. 3. Generate unit tests when you're satisfied with the behavior of your functions. See https://github.com/dubiousdav