Better HN
topnewbestaskshowjobs
Log inSign up

dustingetz

7,912 karma · joined Sep 11, 2009 (17y ago) · 3,625 submissions

Founder Electric Clojure https://github.com/hyperfiddle/electric

https://twitter.com/dustingetz

Submissions

comment 13y ago · link · parent

umm, how big is your codebase?

The OP describes more or less the way Linux uses git.

comment 13y ago · link · parent

"no cultural fit" is a HR euphemism for either "you aren't good enough" or "you're fired" at facebook, at least according to a few HN comments. Similarly, at google, "performance improvement plan" means "we don't want to get sued, but please find a new job"

comment 13y ago · link · parent

Think about why we build browser apps instead of native apps today. All those reasons apply.

comment 13y ago · link · parent

the quote is "maybe speeding up your development a little"

comment 13y ago · link · parent

Const correctness is the essence of all functional languages; RAII is in functional languages too and even java has an interface for it

comment 13y ago · link · parent

Nah, I think its just because they result in really nested types which is hard to keep track of without a really good type system. Using a single monad by itself like error or continuation is straightforward in Clojure; there are smart & vocal people who do this. But the super awesome OMFG of monads is that they can be combined (e.g. parser = error + state), and this more or less requires abstracting in the type system to keep track of all the lambdas.

comment 13y ago · link · parent

indexes and chunks of data that are used often remain cached in each application instance, and new changes are streamed to the application cache.

It means that reads from a hot cache do not touch network. Reads are very fast and scale "out". You can write code that does a lot of reads without caring much about performance. (SQL reads only scale "up" and you care very much about their performance.)

Datomic is like Git (distributed reads, central writes); Postgres is like CVS/SVN (centralized reads and writes). This is made possible by immutable history.

comment 13y ago · link · parent

TLDR: Datomic is like Git.

In traditional ACID databases (SQL), all queries (read and write) mostly only scale UP (beefier db machine), not OUT (lots of db machines is very hard). Datomic is an ACID database where writes still scale UP, but reads can scale OUT.

Consequences of this separation of read and write means that datomic reads scale practically arbitrarily for both query load and for dataset size. Writes do not.

This is a lot like Git, where you have to push to a central place which orders and rejects commits, but you can make useful reads from your local machine without touching network. Datomic is a lot like Git + realtime secret sauce.

That's only half the value though - Datomic also doesn't have an object relational impedance mismatch. This means Datomic doesn't need ORMs; Datomic's programming model is simpler than SQL for a competitive set of features. So you code faster with less bugs.

comment 13y ago · link · parent

"a language that...allowed far, far less flexibility in the way ideas are expressed"

that is a design goal of Java, and it turns out that "everything is a class" is a really expensive way to write software. As in large systems take thousands of man-years and $100MM and contain AbstractFactoryFactoryProviders. Not because the engineers are bad, but because that's what you end up with when everything is a class.

Sometimes, Scala codebases are criticized because they use monads or have too many arcane unicode symbols in them. But I'll take scalaz over AbstractFactoryFactoryProviders any day. At least scalaz makes sense.

2770.

Javascript dubstep generator(mazbox.com ↗)

2 points · by dustingetz · 13y ago · discuss

comment 13y ago · link · parent

im pretty sure he means the standard library, e.g. data structures. Sharing Scala and Clojure code means converting your data structures at the boundaries.

comment 13y ago · link · parent

https://sigil.cupcake.io/dustingetz

took me a very long time to realize that the thing that gets hashed is the URL's path.

comment 13y ago · link · parent

bigco websites are generally bad not due to technical incompetence, but because it is difficult to organize collaboration between hundreds of teams, each with their own incentives and requirements.

2774.

Promises are function composition(dustingetz.com ↗)

1 points · by dustingetz · 13y ago · discuss

comment 13y ago · link · parent

Todo lists do have business logic, but the logic is so simple that one might not notice when it gets coupled to the views. so you can get away with coupling things like "MV-whatever" or MVVM for apps up to a certain threshold. Facebook is an example of an app well past that threshold, so we should probably listen to them when they talk about their new DOM management library, Facebook React.

comment 13y ago · link · parent

exactly, and the application specific-ness is what makes them hard or poorly understood. General DOM management libraries can't provide a controller. For one thing, it needs to interface with your backend.

comment 13y ago · link · parent

Model change listeners are the anti-pattern, not events. Mouse and key events are essential complexity.

--

MVVM: model change listeners on each state mutation: response to state mutation is immediate, never batch multiple listeners, requires dependency tracking (if the collection changed, then the count also changed). change listeners fire immediately and can trigger more change listeners. Lots of callbacks to keep track of and easy for things to get out of whack. (Backbone, Knockout, Knockback)

Angular ("MV-whatever"): state changes detected by dirty checking, but changes are immediate (digest loop), never needs dependency tracking. Digest loop runs until the state settles (no more change listeners fire) to ensure consistent views. Magic data binding.

Facebook React: state w/ dirty checking: state changes are always batched, views are a pure function, reconciliation step to merge desired view with existing view, no events or change listeners. Render process is a lot like a 3D game - draw the buffer, whack the buffer, loop. No magic. Facebook doesn't call it MVC but in my eyes it is.

--

The more complex your view and state, the more events/mutations/callbacks, the more you need React.

2778.

Promises are for function composition(gist.github.com ↗)

1 points · by dustingetz · 13y ago · discuss

comment 13y ago · link · parent

"You have models, which are nice self-contained bits of state, views which are nice self-contained bits of UI, and controllers which are nice self-contained bits of...What?"

Business logic

comment 13y ago · link · parent

Except scala has achieved traction and clojure is hot on its tail

comment 13y ago · link · parent

Pick Go if: your only other option is C

Pick Scala if: all other things

comment 13y ago · link · parent

I feel your argument against just using Scala was weak, but you guys are obviously smart and feel building Schema was the right choice. So could you elaborate a bit on the decision to stick with Clojure when your problem domain lends itself to types?

comment 13y ago · link · parent

Coming from a functional programming perspective on code quality, I think new code written with a modern understanding of software engineering generally is better quality than old code backed by tech written with last decade's understanding.

comment 13y ago · link · parent

"if you read the source code and have been subscribed to the mailing list for a year"

Not only do I read the source and daily newsgroup digests to my preferred javascript stack, I read the source and newsgroups of the other popular choices. If I didn't know all the answers, i wouldn't be a very good tech lead, would I?

The ecosystem is moving at high velocity and that is a good thing.

comment 13y ago · link · parent

these articles are what happens when a 24 year old peon engineer criticizes the industry accepted best practices of the time as determined by veteran architects with eight times the experience

edit to add some anecdotes: scalac and javac are written by the same person. The founder of Relevance, the company that funds Clojure development, wrote a book in 2006 about spring and hibernate.

comment 13y ago · link · parent

i think it's the opposite

readable code is more likely to be correct, but correct matters a whole lot more than readable. How many times have you had to hack on JSON serializer internals or HTTP layer implementation details or database drivers or filesystem I/O. Probably never, and if you did take a peek, you would not be thrilled, because a lot of that stuff was written 15+ years ago.

readable code is a tool that good engineers use to arrive at correct code, especially in cases where we haven't iterated with the product owners enough to know what the correct logic is, or domains where the requirements are not well defined. But correct code is the goal.

This can also explain why some of the very best programmers insist on using category theory and monads even though it is infamously difficult for untrained programmers to read.

FWIW my perspective is large enterprise webapps implementing complex and poorly-defined business rules. Not like I'm doing linear algebra or device drivers.

comment 13y ago · link · parent

if you are exceptionally talented at something valuable, and have a decent understanding of what a business owner values, i believe you can double the glassdoors average in any city.

A lot of people don't believe in "10x-ers", but perhaps they just haven't met one. I am not one but I know several. They make a lot of money. It's not something that they like to talk about.

comment 13y ago · link · parent

I have also maintained or architected two large JS applications (100k+ lines of javascript) in ExtJS, Knockout, Kendo and React and I couldn't imagine not having requirejs, for the benefits of enforcing modularity and sane dependency structure, just as much as the sane approach to an optimized build and the plugin system.

The pain point you describe is not a pain point for my team, and even if it was a pain point, it is perfectly possible to abstract the repetition[1], which you are of course aware of since you use Angular. FWIW, we have not felt the need to have any modules with 20 includes.

[1] http://www.dustingetz.com/2013/05/13/javascript-dependency-i...

comment 13y ago · link · parent

Mythical man month outlines why 14 hour days are often better than the alternatives.
1
929394
121