Better HN
topnewbestaskshowjobs
Log inSign up

randomdata

8,634 karma · joined Jun 23, 2011 (15y ago) · 7,679 submissions

Submissions

comment 3y ago · link · parent

> Whether it's your HTTP API interface changing

Interfaces don't change under microservices. Communication by contract enshrines a contract. You must ensure that your API does not break legacy users no matter what changes you want to make going forward. You have committed to behaviour forevermore once you submit the contract to other teams.

This may be another reason why IPC is often preferred over straight function calls as some languages, particularly those with static types, make extending functionality without breakage quite hard. An HTTP API can more easily resort to tricks to return different results to different callers.

> I think the red-green-refactor loop of TDD doesn't bring much.

You find little value in writing a specification for your work or you find little value in automatic validation that the program works according to your spec?

"Red-green-refactor" is a little more specific in that it says that you should write a spec only for the work you know you are going to work on in the short term, whereas TDD in general leaves room for things like writing the entire application's spec before getting down to business. I think this is most practical in the real world, generally speaking. Often you don't know what your entire application should do in the beginning, making writing a full spec unrealistic.

> I've never seen it applied well on a statically typed codebase

Interesting, as I have only ever seen specifications (be it TDD or "Word documents") written for work that is done in statically typed languages. In my experience, the dynamic programming languages tend to attract the cowboy coders who don't understand why other (future) developers need more complete documentation or why specs are important and have no care to see that those things are done.

comment 3y ago · link · parent

> I personally do not believe it is old fashioned to have your business reachable by phone

You can reach them by phone, but it's not the way things are commonly done, so you're going to get suboptimal results. You can also mail them a letter (the snail mail kind), but I expect you'll receive even poorer results than by phone doing so given that it is even less common to conduct business by mail. For better or worse there is only so much time in the day so you have to focus on what works for the 90% common case and just try your best for the remaining 10%.

> Because I am a paying customer. That is why.

You're paying for something, but apparently not phone support, else you would not be a paying customer anymore when they failed to provide what you thought you were paying for. What is in it for them to provide you something that you're not paying for?

comment 3y ago · link · parent

> Why can't the teams work on the same codebase and the same database?

The same database is tricky because one team might want to change the schema, breaking another team's work. You then need to have meetings to discuss the changes that will work for all parties and you've broken "communicate only by contract", and therefore no longer doing microservices. If you can ensure that there is no way for teams to trample over each other then you could use the same database.

The same codebase is more feasible as long as the team boundary separation is clear. You are likely already doing microservices with other teams when you import third-party libraries. In practice, though, much like the database problem maintaining boundary separation is difficult if you can easily reach into other team's code, so often each team's work will be parted into distinct codebases using IPC between them to ensure that the separation is unbreakable. This certainly isn't a requirement, though, just one way to keep people in line.

> Testing is certainly a way to provide a self-verifying application. TDD is a toxic, hype-driven, mess

Testing is a development tool to help test the functionality of a feature. If you are faced with a dynamic language you very well might write tests to ensure that types are handled correctly. Static types can, indeed, relieve the need for some tests.

TDD, on the other hand, is a documentation tool to relay to other developers what functionality is intended to provide and how it is meant to be used. It is strange to think that documentation is toxic. Before TDD we wrote "Word documents" containing the same information, but often found that the code didn't do what the documentation said it did. What TDD realized is if the documentation is also executable then you can have the machine prove that the application behaves according to spec. It's not exactly magic.

comment 3y ago · link · parent

Last time I had to speak to my telecom operator, which granted has been a while, Twitter was clearly where business took place. Interactions were always pleasant meeting them in the right place.

Isn't calling them by phone, as if you're still stuck in the 1950s, like showing up at the back door at a restaurant and wondering why you weren't greeted by the host and seated promptly? Maybe the surly dishwasher will eventually notice you standing there, but why would their 'A team' be there waiting for you?

comment 3y ago · link · parent

Not to mention that before TDD the same documentation was provided as plain text. TDD simply realized that if the documentation was also executable that the implementation could be automatically validated for compliance against the documentation. The idea that you are reconstructing the compiler doesn't even track on the surface.

It is true that one may use testing to stand in for the lack of static typing, which is no dobut what the parent is talking about, but TDD != Testing. Testing long predates TDD.

comment 3y ago · link · parent

Microservices has little to do with tech. It is a way of organizing teams of people, funnelling all communication between teams through well defined specifications instead of ad-hoc meetings. It is not clear where static typing, or lack thereof, comes into play here.

TDD is a method of documenting your application in a way that happens to be self-verifying. You could use a Word document instead, but lose the ability for the machine to verify that the application does what the documentation claims that it should. Static typing does provide some level of documentation as well, but even if you have static typing available static typing isn't sufficient to convey the full intent that your documentation needs to convey to other developers.

comment 3y ago · link · parent

The generalist’s solution to income is to have multiple jobs. If done correctly, the sum of those, even if individually lower paying, jobs should exceed a specialist role.

comment 3y ago · link · parent

I'm not surprised. Software is an attractive hobby to the miserly because it requires little investment. And eventually those hobbies become careers.

If spending was our thing perhaps we'd have gotten into woodworking, or photography, or whatever it is that can take a good chunk of change to get into deeply instead.

comment 3y ago · link · parent

Given the scenario, why would someone pay even a month's rent to take on a larger monthly expense going forward?

More concretely, let's say it costs $1,000 per month to the landlord and the tenant pays $500 per month. The landlord is losing $500 a month and wants to unload the place, so he offers the property to you, the tenant, for $500. But now you have to assume the $1,000 per month cost. What's in it for you to double your expenses?

That is unless the landlord continues to carry the $500 per month shortfall even after the sale. That would be a good deal for the tenant, but why would the landlord sell under that scenario? If you're paying $500 per month out of pocket either way, you may as well ride it out and hope things improve someday.

comment 3y ago · link · parent

> Someone will almost assuredly buy it at a low enough rate.

Let's examine that. If you were selling it to yourself you would charge yourself $0. We have established, for the sake of argument, that you can't turn a profit renting out the place. Which means that even $0 is too high. Are you suggesting that the rate is negative? i.e. You will pay someone to take it off your hands? I think at that point you may as well just disappear into the night and never come back.

I mean, maybe you're thinking that this hypothetical person is trying to heat the place with $100 bills and the next guy to come along can cut costs dramatically by switching to natural gas, but I think for the purposes of discussion we can assume that the costs are already reasonably minimized. Are there small gains to be made with economies of scale? Sure, but I don't know if they are significant enough here.

> Are you saying that you believe people will, month after month, take a loss for years so that someone can live more cheaply in a house

I'm saying losses in business are the norm. It's not done out of the goodness of one's heart, it's just the nature of business being largely unpredictable and hard. I expect if you are discerning in your choices you can also continually eat at restaurants that see the restauranteur pay out of their own pocket for you to eat there. Even most software never turns a profit.

comment 3y ago · link · parent

> If it wasn't profitable on average it would be sold asap.

To who? If it can't be profitable, why would anyone else want to buy it? Maybe you'll get lucky and find another sucker, but then you're just pushing the same problem onto the next guy.

Outside of that, about all you can do is disappear as if you never existed and let the fate of the property land where it may. But as humans tend to be strongly loss averse, more likely you'll keep plugging along in hopes that one day things will turn around.

comment 3y ago · link · parent

> I mean, isn't that the same thing?

Not at all. The claim about not being stumped was made in response to criticism that Go is unusable without generics. Said criticism was probably made up, but I guess it was still interesting enough to garner the response that ultimately brought us here.

> That would be blub the other way around.

Seems like blub the same way around. Indeed, the blub paradox itself is paradoxical.

> the more languages (that are actually different) you have used, the more unhappy you are with every single existing language.

And the more you really appreciate just what Go has done by taking an engineering approach and not an academic approach.

comment 3y ago · link · parent

Very much so.

comment 3y ago · link · parent

To be fair, a lot of those concepts were invented, at very least popularized, by the members of the Go team 30+ years ago. Go is their chance to carefully bundle those ideas together, not just throw every random idea they can think of into a language and end up with a big ball of mud like so many others want to do. There are already plenty of ball of mud languages, if that's what you're looking for.

comment 3y ago · link · parent

> what appears to be, very profitable venture for many corporations.

It no doubt can be quite profitable where the tenants are willing to pay more than your costs. There are unquestionably markets where that is the case. I'm not sure it holds universally, though. Not everyone is a landlord in San Francisco renting out to software developers with the capability to pay almost anything to be there and a competitiveness to be willing to do so.

Do you really think the landlord in a dwindling town is profitable? As the town dwindles costs rise, and at the same time what incentive is there for the renters to pay more? It is not like there is a lineup behind them champing at the bit to rent the place when they leave.

comment 3y ago · link · parent

> but you will be homeless if your landlord continually loses money.

Or you will find yourself continually cycling through landlords as each one eventually gives up and sells to the next sucker. Assuming the next sucker comes along. The landlord might be stuck with the property. Real estate has been an easy sell of late, but that hasn’t been true historically.

> and increase your rent

To which you can say, "no thanks". Sure, they can kick you out[1], but with no rental income their losses will be even higher. What landlord worried about profitability wants to reduce profitability even further? The landlord is beholden to what the renter is willing to pay. The renter couldn't care less about the expenses involved in running a rental property. That doesn't factor into how much they are willing to pay at all.

[1] If your jurisdiction has liberal enough laws. Where I live it is essentially impossible to evict tenants. Even in egregious cases, like the tenant who stopped paying rent, there is currently a year+ backlog in the government signing off on the eviction.

comment 3y ago · link · parent

He didn't express a lack of pain, just that he was never in a situation where he was stumped by not having them. Generics aren't exactly magic. They can improve code, but you can live without them if you really have to.

Although I think you are on to something per the original question about the appeal of Go. For all its faults, Go also gets a lot of things very right that aren't obvious until you have gained the necessary level of familiarity.

Once you rise above 'blub', it is indeed hard to go back. While I spend most of my days in other languages full of all kinds of fanciful features, I did a short stint on a Go project and now especially hate not having blocking functions everywhere (async/await is one of those fanciful features I have to deal with) and sensible error handling.

comment 3y ago · link · parent

> But let's not forget - you're paying for everything your landlord is, plus profit. Always.

Definitely not always. Loss is common in business.

Doubly so here when asset values are appreciating. If the landlord thinks they're making bank simply holding property, any rental income on top that helps minimize costs is just gravy. There isn't tremendous pressure for costs to be fully recouped.

In reality, you're paying the least amount you can that still beats the alternatives. That doesn't guarantee profitability for the landlord. The landlord recognizing lack of profits and selling the property is an alternative, but may not even be a tenable one in some circumstances (e.g. a market downturn that leaves potential buyers weary) without taking even greater losses.

comment 3y ago · link · parent

Rails puts testing front and centre. Testing exists to document how features are intended to function and intended to be used (with the added bonus of enabling machine validation of the documentation).

If a function accepts an arbitrary type, as is the case for all inputs in a dynamic language, one needs to document how the function is expected to behave when given x type. This is ultimately the same as type checking in a typed language. It just moves where the documentation is located.

In that move, it is true that you often lose some strictness in the quality of the documentation. The developers who have an active hatred towards their co-workers may even forgo writing documentation entirely. But if you reach that point you've really got people problems, not technical problems.

comment 3y ago · link · parent

That's not how anyone else defines shortage, though. It literally contradicts the meaning of shortage. So, when the message is spread to the people they are going to take from it that they aren't charging enough, even if that wasn't the original intent of the message. And, indeed, claims of a labour shortage do end up met with higher labour prices.

comment 3y ago · link · parent

Because of lazy evaluation or because the developers aren't properly documenting their work? A language with a formal type system essentially forces you to provide type documentation, but there is an expectation with dynamically typed languages that you will still document the types (probably in your test suite). Rails in particular makes this a core function of the framework to really push you to do so.

comment 3y ago · link · parent

A shortage occurs when the buyer (in the case of labour, the employer) is prevented from paying more. While there are certain labour segments, healthcare in particular, where government often prevents buyers from paying more, there is no real constraint on the general labour pool in this regard.

This means that the only reason there is a shortage is because labour is choosing to not charge higher rates for their work. When the media/government states that there is a labour shortage they are saying: "Hey workers, charge more already!" If that's not pro-labour, I don't know what is.

comment 3y ago · link · parent

Seems the market is already met, then? It is unlikely these alternative grains will ever see mass appeal. While such history is hard to validate, legend has it that wheat tortillas became popular soon after wheat became available in the Americas because a lot of people preferred it. I think there is little question that wheat tortillas are the preferred form in modern times.

comment 3y ago · link · parent

You don't need more workers, though. Supply and demand. As prices rise, demand wanes, not requiring as many workers.

When labour is free the amount of work is infinite, but with a higher price some work is no longer worth doing and workers get reallocated into the jobs that are still viable.

comment 3y ago · link · parent

Are you currently producing these at home for personal consumption?

comment 3y ago · link · parent

What do you need to get yourself positioned? I am in the food production business, both as a farmer and as an operator of a commercial kitchen, so if you have something compelling here I am listening.

comment 3y ago · link · parent

Same as we've always done? Sample loads as they come off the field. Downgrade as needed. It is not like this is something new.

comment 3y ago · link · parent

> Wheat is sold by weight not nutrient density

Not exactly. Weight is used as a price multiplier, but nutrient density is one of the factors that goes into establishing the per unit price. I grow wheat in a climate that struggles to produce high protein content and absolutely see a reduced price when my product doesn't meet the grade.

1
126127128
256