Fork me on GitHub

the function passed to .requestAnimationFrame -- is it guaranteed to be called exactly once, or does it have to be indempotent (i.e. called multiple times = called once)


with kafka, is there a normal recipe for having multiple clients using the same ID - I’m finding that a second parallel client gets no messages until the other one disconnects - is this because I need to set up my partitions differently?


looks like I want something other than kafka - it does not have the dispatch behavior I need


@qqq, I can’t imagine .requestAnimationFrame requiring an idempotent function as that’s where you’re supposed to make changes before a repaint


if you make two requests to requestAnimationFrame before a repaint with the same function, it will call the same function twice though


@quang It was some free Mac app I think...


oh for some reason, I thought you lived in your mindmap app... (like have a mindmap for everything) 🙂


... MindNode Lite, apparently.


Hah, I used to... but I got out of the habit.


really? why's that? The interview mindmap is bad ass.


I'm not sure why I stopped using mindmaps... I guess I was just working on stuff where I didn't need them as much... well, I haven't spoken at a conference for nearly five years and I always used them for sketching out talks.


I'm due to give a talk about Clojure at a user group early next year so I might get back into the habit 🙂


@smith.adriane: if requestAnimationFrame guarantess: * each callback is called exactly once * callbacks are claled in order * callbacks happen before next frame then life would be easy. Is this explicitly stated anywhere ?


which is always my goto reference for these types of things


the exactly once and called in order are both explicitly mentioned


I think it’s guaranteed to run before the next frame,, but my brain is a little tired to read through that whole thing


@smith.adriane: thanks! that page is amazing!

Let callbacks be a list of the entries in doc's list of animation frame callbacks, in the order in which they were added to the list.

Set doc's list of animation frame callbacks to the empty list.

For each entry in callbacks, in order: invoke the callback, passing now as the only argument, and if an exception is thrown, report the exception. [WEBIDL]
guarantees what I nee


Wonder what you folks think. Is upgrading from 24" Full HD to 27" 4k worth it? Anyone using such a monitor under MacOS?


@borkdude i upgraded recently and i am very happy with the extra real estate 🙂


@jmayaalv do you use it under MacOS?


I think the bump in resolution itself is worth it


@chris I’ve upgraded once to a 25" 2540x1440 p monitor, but I had to sell it second hand months later, because I found the fonts too small in MacOS on that resolution. This is what I’m most concerned about with buying a new monitor


MacOS doesn’t have font scaling like Windows which is annoying


Several years ago I went with more space over more resolution, so I have 3x 24" monitors connected to my MBP in addition to the laptop screen.


Hard to go back to one screen after that. IMO screen space is more important than resolution


@tbaldridge Cool. What kind of monitors if I may ask?


They were whatever was cheap and had good ratings on NewEgg. VG2439m-LED


@tbaldridge I have a Dell 24" monitor, but I’m a bit worried about pulse width modulation that may or not be in it. I looked up your monitor: > ViewSonic flicker-free monitors deliver a more comfortable viewing experience. Rather than using Pulse Width Modulation that continuously turns the LED backlight on and off, ViewSonic flicker-free monitors use DC modulation backlights that maintain a steady stream of direct current power - nearly eliminating screen flickering at all brightness levels by providing a constant LED light source.


Dell is unclear about whether my monitor contains it, that’s why I think of upgrading maybe


When does that come into play? I'm not sure I've experienced problems with LCD flicker


Well, you don’t really notice it, but it can cause eyestrain after some hours


Reminds me of when I used to help people that were running a 50hz CRT refresh on a monitor that sat under a fluorescent running at 60hz. My eyes would hurt after 2 minutes of looking at those screens 😄


I've had these monitors for 4+ years though, so I'd probably go back to Newegg and look up something else


I’d want to test a new monitor before I bought one…


ah well, everyone knows volatile! by now I guess


Not everyone, not quite.


Before that maybe people used one sized mutable arrays? 😉

New To Clojure16:12:38

From your experience, what are advantages of using Clojure for enterprise applications?

New To Clojure16:12:25

Hiring must be difficult (there are not a lot of Clojure people around).


@borkdude yes, i have the screen connected to a mbp. I prefer one big screen than multiple screens. I didn’t have problem with the small letter but i guess that’s relative


@ghsgd2 a few things 1) Clojure is based on the JVM. A lot (most?) enterprises use a lot of Java, and Clojure interops with those systems quite well. Using Node or Erlang in these same places introduces a lot of friction.


2) Clojure has a "data first" view of the world, a lot of enterprise apps are simple the transformation and moving around of data. Clojure works quite well for this


3) Clojure has an excellent concurrency story. I haven't had a dead-lock in my code for years. And IIRC the only time I've gotten one in Clojure was when I was debugging the internals of core.async (something most people shouldn't do 🙂 )


@ghsgd2 There’s also a benefit of only/mostly having to master one language + one core library for a full stack development experience

New To Clojure17:12:09

@borkdude But there will be 2 or even 4 languages: Clojure and Java (because of the libraries), and probably also ClojureScript and JavaScript too.


@ghsgd2 Yes, it surely helps to understand a bit of the hosting platforms you’re working with. But usually people already have some knowledge of that prior to Clojure. I did know some Java, but only the language, not the ecosystem. I’ve avoided JS/front end for a long time but started doing that because of Clojure(Script).

New To Clojure17:12:00

@borkdude Currently Clojure seems to be the language for those who don't have any more space for professional growth as a Java programmers and so need some "Java on steroids" to be even more productive. I'm learning Clojure and people say that I should become architect first and then go for bells and whistles. And that I will depend too much on my employer and won't have alternatives.


@ghsgd2 I was already a grumpy tired Java programmer before I even started using it professionally. Clojure just made sense to me from the start. And don’t let people discourage you from doing x by saying you have to do y first.


the clojure interface to java libs via interop is more consistent and has fewer cases than using it from java

New To Clojure17:12:46

@noisesmith could you please provide some simple example? I'm not very familiar with it except for things like (Integer. (str a b))


it’s a small sublanguage, but it has fewer ambiguities compared to java syntax


@ghsgd2 If you haven't already run across it, I blogged some thoughts about Clojure and the Enterprise: (three years ago -- but still true today, I believe)


I think "don't have any more space for professional growth as a Java programmer" is not the way to look at this. Many folks who jumped into Clojure early have been polyglots for a long time and are always looking for "better tools" and "new ideas".


My arc was C/assembler (and some COBOL), to C++, to Java, to Groovy, to Scala, to Clojure -- but I also try to learn a new language (almost) every year...


(and, because I worked at Macromedia when they bought Allaire, there was CFML in there too, alongside the Java/Groovy/Scala/Clojure arc)

New To Clojure17:12:03

@seancorfield Wow! But you could've earned more more money by becoming, say, C expert.


@ghsgd2 More money doesn’t always mean more happiness.

New To Clojure18:12:55

@borkdude But there are mortgage, health insurance and bills to pay. After all, life not= work.


@ghsgd2 Sure, but “you could have earned more money” is not always necessary. Nothing wrong with it of course, if that is your priority.


I saw some report where Clojure was one of the highest paid technology. Not sure where I saw it (maybe Stackoverflow?) and how true that is in practice.

New To Clojure18:12:23

@borkdude I guess it's because people start using Clojure mostly after becoming experts in Java or close to it. And so already have high salary.


I learned java after / via learning clojure


Same for me, except some minor Java during some classes, but neglectible


and C might pay well / be well understood by the business world, but most startups doing web stuff don’t want the defect rate and development time and refactoring costs that usually come with C


Most functional languages tend to pay well.


I learned C before learning clojure, nobody has wanted me to use it at work though


In my experience/ personal research, PHP, Ruby, Python tend to be on the lower end. Java, C and C# are in the middle tier, and then stuff like Haskell, Erlang, OCaml, Clojure tend to be some of the highest paying jobs.


A lot of that is driven by the industry, location, and supply/demand however.


At one point Madison had some really good C# jobs available because for some reason all the companies started using C# but there weren't enough developers in the area.


I'm also not sure how much of all that is driven by supply/demand. There are a lot of PHP devs, but not that many Erlang developers (at least here in the states)


yeah - one real advantage of clojure is it can leverage java network effects with a language that can be much more pleasant to use


it’s easy to add clojure code to a java project

New To Clojure19:12:38

@tbaldridge When Java architect starts using Haskell he will be still paid like an architect. I don't think if senior PHP ditches it and learns Haskell he will automatically become one of the top paid programmers without say 10 years of experience in Haskell, finance and a lot of other stuff relevant for that company.


language and experience are two different parameters - I started using clojure early in my professional dev career (coming out of personal hobby stuff) and started getting paid clojure salaries


That has not been my experience at all


Experience matters, of course. But languages are tied pretty closely to a salary bracket.

New To Clojure19:12:09

You may be living in SF bay area where there's an ambundance of everything

New To Clojure19:12:40

I searched for Haskell jobs locally and found just one job in different city


Yeah SF is a strange fairy land where nothing is "normal" 😄


@ghsgd2 Silicon Valley may pay more, but life is also expensive there I guess


Also startup culture tends to value different types of applications. They will pay more for a Ruby dev who can crank out a MVP over a dev who will take longer but create a scalable product


I've probably spent about 2/3rds of my past 5 years reworking apps that were written in such a culture, and then they couldn't get the app to scale.


yeah - I’ve seen “this ruby code got us our first round of funding but doesn’t scale, now write some clojure” more than a couple of times


(in Portland OR, not silicon valley)


@ghsgd2 Re: salary -- it depends what you want from life. I get a constant stream of recruiters pinging me about FinTech roles (either in SF or NY) for either Clojure or Scala (primarily) and I'm just not interested. Those jobs advertise compensation in the $350-400K range. shrug

New To Clojure20:12:15

@seancorfield I'm had not yet reached the limit after which higher salary makes no difference. By the way I've found 3 local functional language vacancies. First is a company which aims to be something like a local Google and requires living the work (read as "work 15 hours a day" and be available round the clock in 10 minutes). Second advertises that they could give offer to anyone who solves task in their office using any functional language (without tech interview). But then you would have to code using their own functional language. Third one is a company which takes 2 years to find a Java programmer. Guess their requirements level. Strangely, I'm also not interested in those 3.


I have not yet reached a limit after which higher salary makes no difference -- but there are jobs / environments / locations that I just don't want, no matter how much someone offers to pay me.


I've worked almost 100% remote for about ten years at this point -- and I live in the SF Bay Area so it's not like there aren't plenty of local jobs.


Location certainly matters. If you want to work in Clojure, you'll either need to live somewhere that has a high density of companies that use Clojure (usually polyglot companies) or find Clojure companies that offer 100% remote work.


Or, if you have the authority wherever you work, introduce Clojure (which I did at my company).

New To Clojure20:12:37

@seancorfield >I've worked almost 100% remote for about ten years at this point You're a hero! 🙂 I thought about working remotely, but then I will miss office, coworkers, company events and so on. Also it's hard to be productive when you sleep and work at the same place (I live in a studio and don't have a separate room for work).

New To Clojure20:12:44

I totally agree with you that there are jobs/environments/locations which might be not suitable no matter how much someone pays.

New To Clojure20:12:37

I can introduce Clojure at work but then I would need to deal with "happy client not= you are working good" and "no experts to rate skils = no career raise".

New To Clojure20:12:04

I'm going to use Clojure for pet projects and ad hoc tasks and see how it will go. Also it's a good functional programming practice (that'll make my Java code better).


Remote isn't that bad, I've been doing it for about 5 years now. It takes a bit of discipline, and care to make sure you get out of the house and do other things. But it's a bit of a wash, honestly.


When I worked on-site I'd get interrupted every 45min by someone with a question. At home there's the risk that I won't get as much done, but in the end it works out quite well


One year remote here. Works well for me and our team.

New To Clojure21:12:51

After 1 year remote I was feeling I was Robinson Crusoe. After 2 years my boss said that I've changed and I'd better go to the office.

New To Clojure21:12:41

Productivity wasn't bad actually and it was just harder to work.

New To Clojure21:12:14

On the good side, I saved a lot of commute time.


My commute is "turn right out of the bedroom" 🙂 I agree about discipline. You need an "office space" that is separate from your "living space". You also need a routine, and you need to take breaks (at least move to a different room for a bit, preferably go outside and walk or whatever). And you need to ensure your social needs are met (interacting with others). Our whole company is remote so we use Slack and Skype heavily. It definitely has both pros and cons.


For me it helps to go out once or twice a day to a coffee/tea place

New To Clojure21:12:19

Meeting social needs working remotely is a bit difficult. When there is no office you are going to interact mostly with strangers. Conferences take place not that often. I don't like clubs, parties and bars much. Can't get from unknown people at coffee places more than a few phrases so the only viable option seems to be some hackerspace.


Yeah, I met some people at the coffee places I go to, so my social needs are met almost every day.


I can imagine that remote working from a deserted place can be pretty lonely, especially when you’re single.


I always have my cats to talk to ... 🐱 🐈 😾