Better HN
topnewbestaskshowjobs
Log inSign up

dtech

8,715 karma · joined Feb 25, 2014 (12y ago) · 2,256 submissions

Submissions

comment 3y ago · link · parent

People were creative back then too. Most of it just wasn't captured other than orally and we have lost the vast, vast majority of that.

comment 3y ago · link · parent

Likely because it's inconsistent with all other parts of the language where trailing commas are not allowed

comment 3y ago · link · parent

Probably due to deadlines for inclusion, while for normal release they had more time.

comment 3y ago · link · parent

This isn't particularly relevant. Java has been very conservative with language changes since at least 8 (2014) but I'd argue 5 (2004) so for the past decade or 2 it has been a conservative language.

comment 3y ago · link · parent

It's been a while since I read the GDPR so I could misremember, but I don't remember anything similar to this assertion.

While I don't think it will work on the scale FAANG wants (see e.g. Youtube premium), what is the legal roadblock to let users chose between tracking or paying for the service?

comment 3y ago · link · parent

I assume that was also the most common book in the 16th century, so as a % of preserved books the statement might still be true.

comment 3y ago · link · parent

Wouldn't this have the same problem as other non-sugar sweeteners? I think one of the main arguments against Aspartame is that it still invokes an insulin response, so still has a lot of the negative side effects of sugar intake, even if it doesn't have calories.

comment 3y ago · link · parent

Avro makes that case slightly better because you can default value for a missing field in one of the two schemas and then it works.

It's not worth the boatload of problems it bring in all other and normal use cases though. Having the default value in the app or specified by the protocol is good enough.

comment 3y ago · link · parent

I do not think its unfair at all. Schema registry needs to add a wrapper and UUID to an Avro payload for it to work, so at the very least Avro as-is is unsuitable for a MQ like Kafka since you cannot use it efficiently without some out-of-band communication channel.

comment 3y ago · link · parent

If a n+1 version producer sends a message to the message queue with a new optional field, how do the n version consumers have the right schema without relying on some external store?

In Protobuf or JSON this is not a problem at all, the new field is ignored. With Avro you cannot read the message.

comment 3y ago · link · parent

If by "solving" you mean "refuse to do anything at all unless you have the exact schema version of the message you're trying to read" then yes. In a RPC context that might even be fine, but in a message queue...

I will never use Avro again on a MQ. I also found the schema resolution mechanism anemic.

Avro was (is?) popular on Kafka, but it is such a bad fit that Confluent created a whole additional piece of infra called Schema Registry [1] to make it work. For Protobuf and JSON schema, it's 90% useless and sometimes actively harmful.

I think you can also embed the schema in an Avro message to solve this, but then you add a massive amount of overhead if you send individual messages.

[1] https://docs.confluent.io/platform/current/schema-registry/i...

comment 3y ago · link · parent

While I never used Cap'n Proto, I want to thank kentonv for the extremely informative FAQ answer [1] on why required fields are problematic in a protocol

I link it to people all the time, especially when they ask why protobuf 3 doesn't have required fields.

[1] https://capnproto.org/faq.html#how-do-i-make-a-field-require...

comment 3y ago · link · parent

Protobuf is very widely used, I just had to Google flatbuffers...

comment 3y ago · link · parent

They don't have to. Building a semiconductor fab is such an enormous investment and requires so much specific knowledge that it's not an attractive option, orders of magnitude harder than copying some software.

A similar question would be how Airbus prevents airlines from building their own airplanes.

comment 3y ago · link · parent

Heating for ICE vehicles is free because it redirects engine heat.

If your engine is overheating, one of the things you should do is turn the heater on max.

comment 3y ago · link · parent

The exact issue you describe was a problem in a recent urban fire in the Netherlands though [1], the fire could not be properly extinguished under the embedded solar panels in the roof and spread further than it would have otherwise.

Having these corner case be an over-focus of an overall better technology is a bad human habit though [2]

[1] https://www.rtlnieuws.nl/nieuws/nederland/artikel/5391449/zo...

[2] https://www.youtube.com/watch?v=GiYO1TObNz8

comment 3y ago · link · parent

But they were, economic rational actors behave in their own self-interest

comment 3y ago · link · parent

Option is an union type

comment 3y ago · link · parent

This feels like a lot of decisions of Musk w.r.t. Twitter have been, impulsive and hastily implemented.

comment 3y ago · link · parent

Given that a lot of non-niche modern languages disagree with you and you provide no rationale, I remain unconvinced.

Swift, Kotlin, Javascript/Typescript along with some older languages (PHP, C#, probably more) have special null-handling in the language. Go and Rust do it differently, but do have an extremely strong opinion on how missing values should be handled.

comment 3y ago · link · parent

NULL/missing is so common that it makes sense to provide special language support, even if you don't have full unions. See e.g. Kotlin and Typescript.

What doesn't make sense is to treat a nullable type the same as non-nullable type causing errors everywhere (Java), or make it so special that it basically has completely separate logic and operators attached (SQL)

comment 3y ago · link · parent

This isn't security through obscurity at all, the links contain a random secret and aren't public. You might as well say a password is security through obscurity because it can be guessed...

comment 3y ago · link · parent

It explicitly states the passengers will be killed

comment 3y ago · link · parent

Extremely convenient the end was determined during the race.

comment 3y ago · link · parent

It's not uncommon to provide a way how to do it in standards because it will happen whether you want it or not. See e.g. HTTP headers starting with X- or MIME types in application/vnd.

comment 3y ago · link · parent

I wonder how much of that is innate and how much of that is because we're not used to fake pictures on a scale AI will allow yet

comment 3y ago · link · parent

I do feel 74 bits per second is enough though. That would require 2^(74/2) = 137 billion UUIDs generated in a single second for a 50% chance of a single collision.

comment 3y ago · link · parent

Lucky for you, they also define UUIDv8 as a free-for-all where you can do whatever you want, and nanosecond precision is one of the examples given in the RFC.

comment 3y ago · link · parent

But then you have 2 identifiers which complicates everything.

comment 3y ago · link · parent

I feel like v7 is almost a strictly better v4. Assuming you can generate a v7 (you have a time source), what are the disadvantages?
1
121314
76