Better HN
topnewbestaskshowjobs
Log inSign up

Merad

2,800 karma · joined Mar 14, 2015 (11y ago) · 772 submissions

Submissions

comment 3y ago · link · parent

I think many people underestimate the capabilities of SQL databases by a couple orders of magnitude. I once worked on a feature that integrated tightly with a third party service. Their api didn't have any support for aggregate queries, and my company was smaller without real BI or data team, so I ended up writing a tool to dump our account data into a local Postgres db in order to do a some data analysis. By the time I left the company that db was approaching 50 GB, the table holding the primary data had about 40 million rows, and a couple of the supporting tables were over 100 million rows. This was all on a 2018-era Dell dev laptop - a fairly powerful machine (6 core/12 thread, 32 GB RAM, SSD), but certainly no server. It took about 90 seconds to update the materialized views that summarized the data I looked at most frequently. More than acceptable for my use case, and there was a lot of room for improvement in that schema (it was pretty much a straight dump of the api data).

comment 3y ago · link · parent

From what I've read their bar for this being a success was getting off the launch pad. Everything after that was a bonus.

comment 3y ago · link · parent

Japan has Patriot systems and several Aegis equipped ships, and both of those have ABM capability. Ballistic missiles are just much harder to shoot down than normal surface to surface or air launched missiles, especially when you’re using SAM’s like Patriot that are relatively short range. I think there just isn’t a very high confidence level in ABM systems. Even the US’ dedicated ABM system, which consists of long range missiles based in CA and AK, is expected to need four shots to achieve a 97% probability of kill (the system only has 44 missiles).

The US had a test platform [0] that showed that the concept of an airborne laser ABM system was viable. However they concluded that we need an order of magnitude increase in the power of airborne lasers in order for it to have enough range to actually be useful.

0: https://en.wikipedia.org/wiki/Boeing_YAL-1

comment 3y ago · link · parent

To be fair, what transfers is determined by the school you're transferring to. Then on top of that you have to match up the requirements for your major, i.e. you might have a CC science course that is accepted by the university but doesn't meet the science required by your major. I suspect there are a LOT of CC students who only have vague goals of transferring somewhere to finish a four year degree (I was one of them many years ago), and in many cases it's just going to be difficult to give them solid advice.

comment 3y ago · link · parent

High altitude nuclear detonations cause powerful EMP effects over a large area. The US famously discovered this by accident in the 60s with the Starfish Prime nuclear tests, which caused EMP damage in Hawaii almost 1000 miles from the detonation.

comment 3y ago · link · parent

I'm sort of the opposite of GP. Having worked with SQL Server the first 5-6 years I've transitioned to using Postgres more over the last 3-4 years and really prefer it. That said SQL has some nice features, off the top of more head:

* It's pivot/unpivot query syntax is a lot nicer than the comparable Postgres extension.

* The ability to define a clustered index for a table that's maintained automatically.

* The ability to define materialized views that are maintained automatically.

* The db engine can automatically use materialized views to accelerate queries matching the view definition.

* It has some really cool support around temporal tables. Not just defining them, but using them in queries. Like, there's a pretty simple query syntax that lets you join together multiple temporal tables and say, show me what the data looked like at this point in time, or show me how it changed during this time period.

The main problem with SQL Server IMO is that many of the cool features you discover are gated behind a SQL Server Enterprise license, and it's crazy expensive. Upwards of $10k per core per year, IIRC. The last time I looked at RDS instance prices I believe SQL Server Standard was about 4x more expensive than Postgres, and Enterprise about 8x more expensive.

comment 3y ago · link · parent

Modern .Net is pretty focused on web apps. Many of us never need to touch C++, GPU, or the other things you mentioned. I've been using Visual Studio for almost 20 years and IMO Rider is simply a superior C# IDE. It's been my daily driver for going on three years. Of course I keep VS installed because of legacy tools like the WinForms designer that aren't supported in Rider, but that's something I need maybe once a year on average?

comment 3y ago · link · parent

WebApplicationBuilder is the mechanism for configuring the kestrel web server. Kestrel is the foundation of Asp.Net Core, there's no separating the two. But Kestrel is a totally modular system. If you configure your request pipeline with a single custom middleware then that is literally the only thing the server is running. If you use only minimal APIs then the middleware that handles their routing is the only thing running. Asp.Net Core has dozens of bells and whistles but none of them affect your app if they aren't part of your request pipeline.

comment 3y ago · link · parent

Yep, it really just works with key/value pairs, so config overrides happen to individual keys. The config system itself doesn't really have a concept of nested objects or arrays. The config provider that reads the json file takes the path, like JobSettings[0].JobName, and transforms it into into a key like JobSettings:0:JobName (IIRC).

I tend to avoid using arrays in config because of the unexpected behavior, and the risk of overriding something you didn't mean to. Anywhere you'd use an array you can usually use an object and bind it to a Dictionary<string, Whatever>, then ignore the keys.

comment 3y ago · link · parent

It sounds like you want minimal APIs: https://learn.microsoft.com/en-us/aspnet/core/tutorials/min-...

If for some reason you don’t want the framework to handle things like routing or request/response deserialization/serialization then you can go bare bones and implement everything via custom middleware: https://learn.microsoft.com/en-us/aspnet/core/fundamentals/m...

comment 3y ago · link · parent

There was a specific feature in the .Net Framework version of EF called “database first” that would analyze your existing database and generate an xml file describing it that EF would use to generate models on the fly. It was pretty horrible and thankfully isn’t supported by modern EF Core. However the term database first stuck and it’s really come to refer to any any scenario where you manage your database using a tool other than Entity Framework migrations. Could be a dedicated migration tool, Sql Server database project, whatever. Then you either create EF models to match the tables or use a tool to generate them.

comment 3y ago · link · parent

Configuration is applied in layers. If you’re using the default setup you get the following layers applied in this order:

1. appsettings.json

2. appsettings.{env}.json

3. user secrets (only in Development environment)

4. environment variables

5. command line args

You can full customize the setup if you desire, there are packages to support things like external secret stores. If you Google ‘Asp.Net core configuration” there’s a MS page that goes into great detail on all of this.

Anyway, your env vars must match the name as you’d structure it in a json object, but with the periods replace with double underscores. So ConnectionStrings.MyConnection becomes CONNECTIONSTRINGS__MYCONNECTION, FeatureFlags.Product.EnableNewIdFormat becomes FEATUREFLAGS__PRODUCT__ENABLENEWIDFORMAT, etc.

comment 3y ago · link · parent

I'd be willing to bet that GP had a high deductible health plan. They leave you on the hook for 100% of your healthcare costs until you reach your deductible, unless your care is on a narrow list of things that they consider "preventable care." By insurer logic obesity is almost certainly an existing condition, even though treating it can prevent future healthcare complications. HDHP's are pretty perverse IMO.

comment 3y ago · link · parent

I wouldn't call it unhealthy, unless you're of the mindset that red meat is inherently unhealthy. It does retain most of the fat from the ground beef which would cook out of normal burgers or hamburger steak. But it's also more filling than either of those due the fat and the inclusion of bread crumbs or oatmeal as filler.

comment 3y ago · link · parent

Any idea of the suit in the presentation was actually pressurized to represent what wearing it will be like on the moon?

comment 3y ago · link · parent

"Tech bro" isn't just a generic reference to tech founders. It refers to a particular negative stereotype of a person, usually male, who works in tech and subscribes to "bro culture." Bro culture itself usually comes from fraternity culture (as in "frat bro") and it's often associated with misogynist beliefs.

comment 3y ago · link · parent

> My biggest gripe with HelloFresh, et al is that I still need to do the prep, so they don't actually save me much time. It's nothing more than curated grocery delivery.

For me the biggest value add of Hello Fresh is the meal planning aspect. I don't have to spend time every week figuring out what I want to cook for 3-5 different meals, or track down the ingredients to make them, or add up calories to make sure they're health conscious.

comment 3y ago · link · parent

Yep. My experience has been that you can start with a wonderfully simple tool, but you end up jamming in dynamic behavior because users today want it and expect it... even in "simple" internal LOB apps.

comment 3y ago · link · parent

I'm not sure that a majority of adults are actually capable of using social media responsibly. How do we teach kids to use social media when it seems like our entire society is incapable of handling it?

comment 3y ago · link · parent

Do you not run your code locally when testing and evaluating things? I guess in my mind where and how an app is hosted is largely orthogonal to the choice language or framework.

Edit: Assuming a modern framework that can run basically anywhere. Something like old school .Net Framework that is essentially restricted to Windows and IIS would be a different story.

comment 3y ago · link · parent

Pretty sure GP was making a sarcastic comment referencing how floating point is notorious for subtle rounding issues when handling values that have an exact representation in base 10 but a repeating pattern in binary.

comment 3y ago · link · parent

Well bear in mind that Asp.Net is a large framework. The minimal approach I mentioned is for creating APIs [0] which you can use with whatever JS front end you please. If you don't want a JS front end Asp.Net has four different options for building web front ends [1].

The hosting question has me a little confused I guess. You don't need anything special to deploy or run modern .Net code? You can run your app anywhere that the Asp.Net Core runtime is supported [2]. Or bake your app into a container and run it anywhere that understands containers. MS has tutorials for deploying to Azure [3], but I honestly know nothing about it (Azure). Every place I've worked at that had cloud infrastructure has used AWS, and I've never needed to deploy a hobby app.

0: https://learn.microsoft.com/en-us/aspnet/core/tutorials/min-...

1: https://learn.microsoft.com/en-us/aspnet/core/tutorials/choo...

2: https://dotnet.microsoft.com/en-us/download/dotnet/7.0

3: https://learn.microsoft.com/en-us/azure/app-service/quicksta...

comment 3y ago · link · parent

Speaking as a C# dev, IME most people are working off of severely outdated views of the .Net ecosystem. .Net has had first class support for Mac and Linux for a good 6-7 years now. Postgres support is every bit as good as SQL Server, and plenty of other db‘s can be used as well. All of the new projects I’ve started in the past 5 years have used Postgres db’s and deployed on Linux. If you don’t like boilerplate then I have good news, nowadays you can make a fully functional Asp.Net API with about 20 LOC.

comment 3y ago · link · parent

If you buy a dishwasher with that feature. It's not standard. I know because my parents went cheap on their last dishwasher purchase because "they're all the same." About two years later I got to help troubleshoot why their dishwasher wouldn't get anything clean... the bottom of it was basically a solid layer of rotten food particles.

comment 3y ago · link · parent

It doesn't. It's a standalone (static) helper method that uses HttpClient to perform the request and feeds the response body into a json parser. It's an extension method [0] which means that there's syntactic sugar so that you can write client.GetFromJsonAsync() and the compiler transforms it into the actual static method call, HttpClientJsonExtensions.GetFromJsonAsync(client).

0: https://learn.microsoft.com/en-us/dotnet/csharp/programming-...

comment 3y ago · link · parent

Out of curiosity did you go into woodworking with the intent of making a living from it? Or were you in the position where you had enough savings/passive income/whatever to keep the lights on if woodworking didn't provide a steady income?

comment 3y ago · link · parent

> He offered to pay, and they wouldn't take a credit card, PayPal, Venmo, Zelle, wire transfer, or any other modern form of payment. No, he had to go to Western Union.

I'm guessing they told him to get a Western Union money order, as those can't be reversed after they're cashed (AFAIK). Most modern forms of payment offer some level of consumer protection, as in they can be canceled or reversed. TBH a repo business might not even be able to get a merchant account for CC processing due to being a high risk business. Merchants that have high chargeback rates have to pay higher processing fees and can even lose their merchant account if their chargeback rate is too high for too long.

comment 3y ago · link · parent

What you want is a curved ultrawide monitor like the Samsung Odyssey G9. I have one of them (49"). The curve is critical, because it allows the entire surface of the monitor to be basically the same distance from your eyes... meaning you can just glance to the side to use that app you placed in the corner. I have good vision but even for me a non-curved 49" ultrawide is unpleasant to use because the edges and corners are so far from your eyes. The 49" size is also large enough that it almost completely fills your field of view when seated normally.

A 75" TV is going to cost you a lot of money for a very ineffective display. It's so large that you'll probably have to physically move several feet to see the edges, meaning that realistically only about half the screen is usable.

comment 3y ago · link · parent

I was under the impression that SOP for most aircraft was to take off at full power, and if you happen to be lightly loaded you just get into the air faster. Was I wrong, or is this a recent change? If so, it seems like a concerning way for airlines to cut costs. Having excess power available at take off means there's a greater margin for error to handle emergencies (engine failure, bird strike, etc.).
1
789
26