This page is not created by, affiliated with, or supported by Slack Technologies, Inc.
2018-02-16
Channels
- # aleph (2)
- # beginners (68)
- # boot (25)
- # bristol-clojurians (5)
- # cider (10)
- # cljs-dev (60)
- # cljsrn (1)
- # clojure (138)
- # clojure-austin (1)
- # clojure-france (2)
- # clojure-greece (11)
- # clojure-italy (4)
- # clojure-russia (16)
- # clojure-spec (4)
- # clojure-uk (75)
- # clojurescript (26)
- # core-async (28)
- # cursive (25)
- # data-science (4)
- # datomic (16)
- # defnpodcast (2)
- # devops (2)
- # docs (10)
- # duct (11)
- # emacs (1)
- # events (1)
- # figwheel (8)
- # fulcro (61)
- # garden (2)
- # hoplon (6)
- # java (6)
- # jobs-discuss (1)
- # lein-figwheel (14)
- # leiningen (86)
- # luminus (11)
- # off-topic (8)
- # parinfer (9)
- # pedestal (2)
- # re-frame (19)
- # reagent (1)
- # ring (3)
- # ring-swagger (8)
- # shadow-cljs (278)
- # spacemacs (13)
- # sql (5)
- # testing (7)
- # unrepl (8)
- # yada (25)
@seancorfield Sorry i wasn’t being clear, i’m taking about boiler plate in java: We have this code everywhere. its not a huge deal but when you pile it on top of all the other things we can’t compose or dry up it adds up fast:
Type fun(Some param) {
final String sql = "some sql stmt";
try (Connection conn = dataSource.getConnection();
PreparedStatement stmt = conn.prepareStatement(sql)) {
stmt.setSomeType(n, value)
stmt.setSomeType(n, value)
stmt.setSomeType(n, value)
try (ResultSet resultSet = stmt.executeQuery()) {
if (resultSet.next()) {
return resultSet.getInt("number_of_children_with_that_name");
}
}
} catch (SQLException e) {
throw new DataAccessException(
"some error msg", e);
}
}
Haha... yeah, that's like the internals of clojure.java.jdbc
only worse... I'm surprised your team hasn't already wrapped that in some sort of abstraction...
Our CTO put together something in like 3 hours that were supposed to be using now. I’m worried its going to have lots of holes in it, but i really have no idea. I was hoping to jump on to JDBI as its trying to do the same thing as what he put together. Apprently they tried that 3 years ago and thought it wasn’t helping.
It's been years since I've used Java itself in anger and pretty much every time I have to read through Java library source code or examples, I weep over the incidental complexity. It reminds me every time why I moved on to Groovy (then Scala, then Clojure).
And the irony is that I moved to Java from C++ and initially loved the cleanliness and simplicity that Java seemed to have...