Register a SA Forums Account here!
JOINING THE SA FORUMS WILL REMOVE THIS BIG AD, THE ANNOYING UNDERLINED ADS, AND STUPID INTERSTITIAL ADS!!!

You can: log in, read the tech support FAQ, or request your lost password. This dumb message (and those ads) will appear on every screen until you register! Get rid of this crap by registering your own SA Forums Account and joining roughly 150,000 Goons, for the one-time price of $9.95! We charge money because it costs us money per month for bills, and since we don't believe in showing ads to our users, we try to make the money back through forum registrations.
 
  • Post
  • Reply
Nomnom Cookie
Aug 30, 2009



200 means everything worked and if you disagree i hate you

Adbot
ADBOT LOVES YOU

Nomnom Cookie
Aug 30, 2009



there are two cases i care about

1. it worked
2. it didnt

you want to make that 3 cases

1. it worked
2. it didnt
3. it looks like it worked but actually gently caress you heres an error code in the response

this is wrong

Nomnom Cookie
Aug 30, 2009



Chalks posted:

A search that returns no results "worked" just fine. From a user's perspective it didn't but returning a 4xx error code would be really weird. A client is entirely capable of displaying an appropriate message to the user in this case without needing an error code.

This third state always exists.

well yes if the search was successful you would get 200. your op "is find everything satisfying the search" and you have shown that nothing does. but some knob suggested that failing to create a user might somehow also be appropriate for a 200. thats a straight up failure and the only thing code cares about whether it is retryable, ie 5xx, or not retryable, ie 4xx.

look this is like the only good thing about rest. HTTP provides a wide variety of response codes so fricking use them. of course also the response body has an error description to show the user. there is no sane justification for returning 2xx from an endpoint when the postcondition isn't satisfied

Nomnom Cookie
Aug 30, 2009



i feel like "this endpoint may or may not do anything, have fun" *should* be a bold position to adopt but actually probably everything works like this and i'm just so so so lucky to only have to deal with poo poo like that maybe once a month

Nomnom Cookie
Aug 30, 2009




rust is for brain damaged c++ people whove gotten indoctrinated that their #1 job is making the compiler happy. then "wow memory safety, amazing". meanwhile everyone else is :rolleyes:

Nomnom Cookie
Aug 30, 2009



put a vptr in your struct and now it is a class

i haven't thought about it much but it seems possible that c is a better language to write c++ than c++ is. having to write the features yourself limits the number that get used

Nomnom Cookie
Aug 30, 2009



Soricidus posted:

we’ve learned the hard way that the so-called robustness principle is a terrible idea that inevitably leads to security disasters. eg a different kind of content body not matching content length was literally the bug behind heartbleed. maybe it’s harmless in an http context but it’s better to just force terrible programmers to fix our terrible code and not take the risk.

i'm going to assume that you also think XML parsers should uncontrollably vomit everywhere when encountering \0 so i hate you now

Nomnom Cookie
Aug 30, 2009



Xarn posted:

How can you be so wrong?

years of practice

Nomnom Cookie
Aug 30, 2009



nope vim is the best text editor. love IntelliJ but it doesn’t have :v

Nomnom Cookie
Aug 30, 2009



eschaton posted:

LOL yeah everyone just loves an Amiga clone of a 70s screen editor hack atop a teletype line editor for a rather dumb terminal that lacked independent arrow keys

it’s totally not just cooler-than-thou hipsterism to use vim instead of a modern editor that follows your platform’s human interface conventions

at least emacs users are amenable to modernization

i use vim because :s and :v are useful and i can't be bothered to learn replacements. also vi is everywhere

very good for editing text. totally rear end for writing code

and i think you will find that the hipsters have moved on to neovim, atom and vscode

Nomnom Cookie
Aug 30, 2009



whole lotta people insecure about their greybeardyness itt

look i meant if you got 300 MB of json and need that munged into sql then vim is the tool to use. someone said basically if you use insert mode then you're using it wrong and i agree. vim is no good for writing stuff

i use it to write stuff sometimes but my excuse is that i've been using it for 13 years now

eschaton posted:

heck, people sometimes seem amazed that I use an almost default Xcode config

they don’t seem to realize that you don’t have to customize the world to get work done, especially if you spend your time getting work done instead of config janitoring

i spent a lot of time when i was younger messing with intelij settings and now i have to constantly remap stuff to match what i expect which is not the default. pure waste of time

Nomnom Cookie
Aug 30, 2009



DONT THREAD ON ME posted:

thanks for this.

i am pretty sure that i have never had illusions about working in the game industry; if i didn't i'd be working in it already. i can very easily imagine slaving away on some feature just to find out that the producer didn't communicate their needs and having to rewrite the whole thing only to have them change their mind again. this is probably 90% of what making a game is. it sounds really frustrating.

thats everywhere if your product manager is bad. i rewrote the entire purchasing model of an ecommerce site 3 times once. left all the old stuff in so I could switch stuff around real easily when he changed his mind, which happened about a half dozen times

in the end he went with flat fee for perpetual access and six months of work could have been 1 post handler

Nomnom Cookie
Aug 30, 2009



can an enum impl a trait

Nomnom Cookie
Aug 30, 2009



mystes posted:

Big corporations may license java for now, and milking them is probably the goal, but it's going to turn into a thing like React before the license change where everyone is trying to switch away from it as fast as possible regardless of whether that's actually a massive overreaction.

everyone will switch to openjdk except for companies that are also ok with paying for things like oracle db

if openjdk goes to poo poo for whatever reason then idk google will fork it or something

Nomnom Cookie
Aug 30, 2009



also spending an entire day looking at JVM class loading logs to figure out why the loving entity classes aren't getting woven

Nomnom Cookie
Aug 30, 2009



the architecture confluent wants you to adopt is more-or-less put all your binlogs in the cloud. then all you have to do is recover and tada fully functional whatever. no its not insane, we promise! only the latest version of each row is retained

interesting as something that could possibly work given unlimited money

Nomnom Cookie
Aug 30, 2009



jit bull transpile posted:

true story, our infrastructure is so weird that I frequently have to use Apache Hive to import hdfs paths full of protobufs as a single column table of json, query them with jsonpath expressions inside sql statements, and convert the results to strings to print to the console to get an idea of wtf is happening with our data.

Apache Hive is literally sql implemented on top of map reduce and they try to pitch it as the enterprise data store of the future. it's nuts.

partition the protobufs by type and then make regular tables???

from where i sit the enterprise data store of the future is csv in s3. with embedded newlines

Nomnom Cookie
Aug 30, 2009



Shaggar posted:

com being insanely flexible and easy to use is both an incredible strength and kind of doom for applications based on it.

the mirror universe sounds like a good place to live

Nomnom Cookie
Aug 30, 2009



i actually have used com and my experience was 100% the opposite of your post. hence the mirror universe comment

Nomnom Cookie
Aug 30, 2009



Janitor Prime posted:

Like why are smart quotes a thing, I've never read a rational discussion about why ' and " need to have those loving ligatures for any reason

ah ok are you sure that you know what a ligature is

Nomnom Cookie
Aug 30, 2009



Janitor Prime posted:

I can never talk straight when it comes to loving fonts and Unicode terms. I thought ligatures were the modifiers and poo poo you put on the basic symbols. like � is the the letter e with a right accent on top.

you're probably thinking of unicode combining characters, which is how zalgo is made. ligatures are a typesetting thing, extra glyphs in a font

Nomnom Cookie
Aug 30, 2009



implicitly converts int to remote code execution, that’s even more impressively cracked than c++

Nomnom Cookie
Aug 30, 2009



Main Paineframe posted:

basically every javascript tool these days requires it

thats a really good argument against ever touching npm

Nomnom Cookie
Aug 30, 2009



I like clion it’s IntelliJ for c++. cmake only tho

Nomnom Cookie
Aug 30, 2009



Star War Sex Parrot posted:

CLion's integrated code analysis by clang-tidy is nice, though it chugs on analyzing complex projects that bring in like TBB or Boost (it might have improved a bit with the 2018 releases). the UIs they wrap around LLDB/GDB and AddressSanitizer are nice too

I have used clion with boost successfully. only a little bit of boost tho

Nomnom Cookie
Aug 30, 2009



Jabor posted:

c++ operator overloading is some horribly abused poo poo

and it started right at the beginning when some genius decided that the left and right shift operators would be perfect to use for i/o

at least c++ doesn't let you make new operators like haskell and scala

(fart <+>>> butt <<<+> poop) _+_ (boners <^> otherButt)

Nomnom Cookie
Aug 30, 2009



VikingofRock posted:

I'm actually fine with that. In the context of paths, it's pretty clear that / doesn't refer to division, so overloading it adds convenience without hurting readability (personally I'd say it improves readability). Also I think overloading / for paths is pretty common in languages with operator overloading; for example python's pathlib does it too.

well you picked the right thread for this post at least

Nomnom Cookie
Aug 30, 2009



Chalks posted:

People generally don't want to install random poo poo that could just be on a web page.

discord is basically this though? i remember a discord dev going on about how they got REAL CROSS PLATFORM with react or some poo poo so i assume the discord app on my iphone is more or less the same as osx as windows 10 as in the browser. it works ok in all those places which is what i care about

same as slack. i expect i could use them in iphone safari or desktop firefox but why would id o that when i can install app and have a special taskbar button to be obnoxious on the internet

Nomnom Cookie
Aug 30, 2009



yeah hell no i'm not gonna gently caress with an imgur app. iwas mainly trying to say that if its an app i want to use and it works good then idgaf if it's just a webview with a webshit in it. works good being the big caveat there obv

Nomnom Cookie
Aug 30, 2009



galenanorth posted:

The worst thing about web scraping is having to wait as long as 20 hours to see if a program collected all the records so that the number of records matches up with what it should be. I'm waiting for it to finish so I can see if my fix for the "no address exists for a latitude-longitude coordinate in the ocean" problem works

I guess I could have told the program to collect all the locations in a boxed area bounding the borders of Maine instead of the entire U.S., but it's been long enough I might as well finish it now

i hope you are rate limiting

Nomnom Cookie
Aug 30, 2009



xslt is a really cool idea with the worst syntax ever created for anything

edit: like somebody read about correspondences between sexps and xml and thought woah that means xml is code :2bong:

Nomnom Cookie
Aug 30, 2009



Shaggar posted:

attributes are unique so you can only have 0 or 1 attribute with the same name on an element. you can have 0 to N elements with the same name under an element.

realistically you just enforce it all with schemas so who really cares

realistically, as someone who consumes XML, there are three cases

1. there is no schema
2. there is a schema but it is wrong
3. the xml is generated by serialization and the schema is redundant

the correct approach in all three cases is "read it into a tree and grab what you need with xpath"

Nomnom Cookie
Aug 30, 2009



NihilCredo posted:

case 2 means being able to say 'hey, we have objective evidence that the problem isn't on our side and it wasn't a case of miscommunication, it's *your* software that is not respecting the specs' which saves a crazy amount of time and therefore money

yeah if that's an option then have at it i guess. in our case if we try to tell data providers their data is poo poo their response is gonna be "lol buy a spoon then" and possibly referring us to other people who have purchased spoons to eat their poo poo with. or maybe they just have nfk and couldn't fix it if they wanted to

Nomnom Cookie
Aug 30, 2009



or as a conscientious library author, make sure to bundle and rename Jackson

Nomnom Cookie
Aug 30, 2009



pull parsing only matters for big boy datasets so I doubt any js devs have ever needed it

Nomnom Cookie
Aug 30, 2009



Arcsech posted:

i feel seen



last panel is fun times

also flashback to arguing for months that the patch removing fsync was a bad idea and getting ignored until corruption took down a diy-AZ

Nomnom Cookie
Aug 30, 2009



saves branches, makes programmers feel like they're writing fast code

Nomnom Cookie
Aug 30, 2009



intellij generates all my compareTos, toStrings, and hashCodes

Nomnom Cookie
Aug 30, 2009



you can do a lot of things with Kafka but only a few of them are a good idea. I blame confluent pushing it for every use case possible

Adbot
ADBOT LOVES YOU

Nomnom Cookie
Aug 30, 2009



bob dobbs is dead posted:

you gotta say how big it is in rds, you don't in aurora. you also get better graphs. they say its faster but it's mostly a lie. for this you pay a solid chunk more

if you have "hundreds of users" its not worth it

aurora can be 64tb vs 6tb for rds. yes, this mattered. replication is totally different and better than what you can do with rds (drbd for ha and binlog replication for read replicas)

upgrades on rds are not bulletproof so have fun with your ticket if it busts. np if you have enterprise support and get the good response time

I would not touch rds, if possible, because of the upgrade problems. if you have a dba already then consider ec2 otherwise shell out for aurora. or just don’t do major upgrades in place if that is feasible

  • 1
  • 2
  • 3
  • 4
  • 5
  • Post
  • Reply