Better HN
topnewbestaskshowjobs
Log inSign up

grogs

79 karma · joined Mar 28, 2010 (16y ago) · 83 submissions

Scala developer in London

http://gregd.me

[ my public key: https://keybase.io/grogs; my proof: https://keybase.io/grogs/sigs/hlxfkKYLz7Lr8RKBGHsGaqpnugofrm61MpDRddt6LAY ]

Submissions

comment 5y ago · link · parent

Scala 3 somewhat simplies implicits by the way. Especially w.r.t to extension methods, which are now a first class construct in the language: https://docs.scala-lang.org/scala3/reference/contextual/exte...

comment 8y ago · link · parent

Kotlin is a better Java, or simpler Scala. Simpler can be better for plenty of teams, especially for those coming from Java. But I'll not be switching any time soon.

comment 9y ago · link · parent

Sounds like PJAX.

comment 9y ago · link · parent

https://github.com/vmunier/play-with-scalajs-example

comment 9y ago · link · parent

Sidenote: Mindfulness (AKA vipassana or insight) meditation can give you that gap between feeling something, an emotion in this case, and responding to it. It's potentially useful for a lot of usecases - the NHS have been offering mindfulness-based cognitive therapy for a while now - but what you're talking about sounds very relevant!

comment 9y ago · link · parent

Can I use this to run Scala Native apps in the browser? Making Scala.js redundant. :P

comment 10y ago · link · parent

Also deis and flynn. http://deis.io/ https://flynn.io/

There's quite a few options in this area. I've recently started using dokku for personal projects. My current plan is to migrate to deis in future if/when I want multiple nodes.

comment 10y ago · link · parent

Which is what Dotty is attempting to do, but hopefully with minimal codebase breakage.

There's a tradeoff between breakage and improvement, but I'd like not to wait 10 years before I can use dotty (like python 2 to python 3). We can always have another dotty in 5 years time for another round of rationalisation/simplification.

comment 10y ago · link · parent

I think Scala is doing a decent job at bringing these concepts together. Scala ticks all the OOP points you made - even more than Java does (Java has special primitives for int/booleans etc, in Scala that's more hidden, really everything in an object). FP also likes Encapsulation as you decided it - pure functions, that don't do side effects (even logging) without it being explicit in the type signature.

FP can model relationships/interactions OK. They just have new tools/techniques to do it. For example, instead of mutating things, you create a copy with the change. You then push the actual state/mutation to the edges of your system (e.g. the database), and thus hopefully make it easier to reason about. But it can be slower or hard to change things deep in an object graph. For slowness - we have persistent collections which re-use unchanged parts of the collection and implement performant "copying". For deep structures, Haskell & Scala have lenses.

It's still an ongoing exploration, with people borrowing/discovering new techniques, but I think it's working quite well and I'm happy to keep exploring.

In the other direction, I've been following Rust. I find it very interesting that it's got a very good type system, but still has mutation. Instead of avoiding mutation, they track ownership in the type system, and thus keep it easier to reason about. By doing this, they make the the performance/memory management easier to reason about, without making it too hard to reason about where effects are happening.

comment 10y ago · link · parent

Yep, or drop the dependency. E.g. For joda specifically, you should probably move to Java 8 date API, which is more likely to be ported.

Bare in mind that scalajs has the same issue and a lot of work has already been done!

comment 10y ago · link · parent

When did you try it out? What didn't you like?

I ported a site written in vanilla Javascript. I decided to faithfully port it without any changes before introducing scala specific libraries. That was pretty painful. A bunch of manual casting for UndefOr and js.Function.

Since then I've started using some of the scalajs libraries/frameworks straight away on projects. It has been a much more pleasant experience!

comment 10y ago · link · parent

I believe that works against jvm bytecode, which you don't get for scalajs. Instead the compiler has a JS specific intermediate representation which the optimizations occur on.

comment 10y ago · link · parent

Your correct that it probably doesn't use scala.reflect, but it still uses reflection.

Jackson works using reflection. Play JSON therefore at least depends on reflection transatively.

comment 10y ago · link · parent

The comments on MongoDB JIRA ticket pretty much sum it up. A hard arbitrary limit sucks. They say the real limit would be RAM, maybe they should change to that. If there's a threshold which will impact performance, then just warn..

15.

Someone copied our site (again) but it's OK(domcomp.com ↗)

10 points · by grogs · 12y ago · 2 comments

comment 12y ago · link · parent

1&1 are just as bad as GoDaddy, in that they advertise $1.99 domains... Where you have to buy for 2 years and the second year price is much higher.

I take your point though, I should add them anyway, even if they're not the cheapest.

Are there any other providers that you think are worth adding?

comment 12y ago · link · parent

It's automated. With around 500 TLDs and 7 providers, manually maintaining it would be a nightmare.

comment 12y ago · link · parent

If you've ever bought a domain then you'll know that there are a number of providers, each with their own prices and pricing structures. I was surprised to find there isn't a price comparison website for domains, so I built one.

Hopefully it's something that would be useful to people on HN. Whilst building it, I realised I could have saved $20 on the .io domain I bought recently.

Any feedback would be much appreciated. The immediate plan is to show the prices for domain renew and transfer.

19.

Show HN: Domcomp, a price comparison site for domain registrars(domcomp.com ↗)

4 points · by grogs · 12y ago · 7 comments

comment 12y ago · link · parent

IntelliJ (by JetBrains, the company behind Resharper) has similar functionality, for all the VCSs it supports. Very nice feature!

comment 12y ago · link · parent

Odd, I'm doing that daily at work without any issue. (tmux 1.8.x, putty, screen-256colors I believe)

comment 12y ago · link · parent

Takipi may be of interest. It's only for JVM languages though - I'm not sure if equivalents exist for other languages.

Otherwise, look at building (or find existing) tooling on top of Log stash.

comment 13y ago · link · parent

Try gradle. It's written in groovy, but surprisingly nice to use with Scala & Java.

comment 13y ago · link · parent

IBM WebSphere MQ

comment 13y ago · link · parent

Women often consume different erotica, which is less video/hardcore based. Romance/erotic romance novels seems to be a growing market.

I do think more women avoid porn/erotica due to this 'disgust' towards porn in society.

Any remaining gap, I would assume is genuinely due to women having a lower libido.

comment 13y ago · link · parent

Install Batarang for debugging scope issues. Don't be afraid of looking at the source, it's a great way to learn. Write some directives and then look at the ones provided by angular - and realise they're not cryptic.

comment 13y ago · link · parent

Limit the total local storage space at a browser level. E.g. 1GB. Just like you might limit the total size of temporary internet files/cache.

Beyond that, just provide a good (simple) UI for deleting stuff. Which could suggest candidates for deletion based on heuristics like you suggest. E.g. iframes shouldn't need so much. Hopefully less visited sites would be suggested for deletion too.

comment 13y ago · link · parent

It was only announced this month that spotify would add Metallica's back catalogue. They hardly have a complete library of music.

comment 13y ago · link · parent

Planet Scala: http://www.planetscala.com/
123