log☇︎
200900+ entries in 0.125s
asciilifeform: which is why fixes that retain it, seem like total waste of time to me ( i put a good deal of time into experimenting with db configs the last time we had this thread. and it made 0 measurable difference, for instance. )
asciilifeform: trinque: i'd much like to get off it
trinque: asciilifeform: if stuck on python, which I grant is practical, can't really refuse the customary sins to make it go
a111: Logged on 2017-04-07 06:35 CompanionCube: 'An attacker within range may be able to execute arbitrary code on the Wi-Fi chip'
asciilifeform: http://btcbase.org/log/2017-04-07#1639628 << 'put wifi in everything! only an unteasonable terrorist would refuse!!' -- everyone not-tmsr ☝︎
mircea_popescu: are there any known documented and running cl-anythings more or less the size phuctor'd be ?
mircea_popescu: there is that.
trinque: python's slower, and astonishingly so when threading
mircea_popescu: open question whether cl would be fast enough. though i know there's some people itching to answer it.
asciilifeform: if i had insisted, phuctor would still be a waited-for thing ☟︎
asciilifeform: but turns out, the necessary work is gargantuan.
asciilifeform: and yes, originally phuctor front end was to be a cl proggy
mircea_popescu: yeah, fuzz tip
asciilifeform: remember, it also has to handle arbitrary binary garbage without misbehaving.
asciilifeform: trinque: you wanna write gpg parser ? that handles all cases ?
trinque: haha, but hey sbcl is threaded and hunchentoot exists.
asciilifeform: i'd luvvv to know in what to redo this
trinque: oh I proposed nothing for this fractal hell!
asciilifeform: but now it means two wholly separate subsystems
trinque: because GIL or whatever they called the lock
trinque: so... lol. the other insanity people commit here is starting n pythons
mircea_popescu: half the time saves me the wait.
mircea_popescu: yes that's very nice.
asciilifeform: mircea_popescu: not the phuctoring!
trinque: irc could just tell you when done
mircea_popescu: ah i always thought i should consult later
trinque: which is only a thing because www is 'daddy buy me a pony now!'
asciilifeform: trinque: another problem: i thought of having new submissions go to a queue, instead of main db. but! that would nuke the vey valuable 'paste in an unknown pgp key and know ~immediately~' feature.
mircea_popescu: might as well just make a proper cache table.
trinque: no, that is accurate.
Framedragger: (when you query a mat view, data is returned directly from it, without touching the source live table)
Framedragger: mircea_popescu: in materialized view, postgres can persist results of query in table-like form. so it *does* cache them; hence you can't say it's convenience only.
trinque: move the data around
trinque: thing's designed for parallelism yes, but of the same exact data in same spot is a big ask
trinque: and keeps him from reading the same table he's writing
trinque: it's a speedup for someone loading the stats page
mircea_popescu: shinohai you're prolly twitter famous.
asciilifeform: mircea_popescu: i think he was proposing it as an ad hoc parallelism
mircea_popescu: trinque> materialized views are nothing more than a named query which stores its results in a table << this is a convenience not a speed-up
asciilifeform: Framedragger: problem is that the cache gotta expire some time.
trinque: it grew beyond this scope the same reason bash did, or anything else that was originally a user interface
Framedragger: btw, i once screwed around with memoization in flask. iirc something can be done here as well, asciilifeform (it may be as trivial as adding a decorator before the function which handles GET request)
trinque: it's a goddamned spreadsheet; you're supposed to compute elsewhere and then fart your results in there so somebody managerial can ask it questions
trinque: so here's what relational db was supposed to be for, like bash originally had a 'supposed to be for'
Framedragger: ...no, lol, the *results* are 'cached', you still regen html (but this is computationally trivial neh)
trinque: nobody said that
trinque: however it may be saner to completely divorce the algorithmic part from sql
trinque: these as queue tables for stages of work are also useful
asciilifeform: trinque: that sounds potentially useful. i'll have to investigate
trinque: can cron the "refresh materialized view"
shinohai: lol Jason Dreyzehner "Head of Design" at buttpay followed me on twitter. Perhaps staring at T&A will be useful in making UI decisions.
asciilifeform: a very recent one . but i'll have to get back to you Framedragger re : which
trinque: materialized views are nothing more than a named query which stores its results in a table
Framedragger: obtw which postgres version on phuctor asciilifeform? those two features not available in old versions. i don't remember which ver is in debian stable
asciilifeform: so why then is this not standard? why locks exist at all ?! ☟︎
Framedragger: again, no, and as per ACID, no dirty reads (*not a bad thing here*)
asciilifeform: do they create chance of reading liquishit ?
Framedragger: not afaik. these are to do with *reading* only. but trinque may chime in
Framedragger: index-only scans allow to search in a table without 'touching', or 'locking' the actual rows (which may be simultaneously written-to, at the same time)
asciilifeform: do they create risk of data loss ?
asciilifeform: Framedragger: briefly describe what these do ?
Framedragger: asciilifeform: have you tried postgres index-only scans? have you tried materialised views? if not, the "postgres must die" sounds sorta surface-level, imho
mircea_popescu: http://thehill.com/homenews/house/326479-freedom-caucus-member-fires-back-the-swamp-drained-tru does not take you to http://thehill.com/homenews/house/326479-freedom-caucus-member-fires-back-the-swamp-drained-trump
mircea_popescu: asciilifeform re thehill : nah, they are just braindamaged. trilema works by bits, eg, http://trilema.com/2015/a-lunatic-with-a-bloodied-a takes you to article
mircea_popescu: (ftr, at least once in itgs history trilema updated 6.5k times/day
trinque: which is why I interact with it through means that do *not* block as it does
asciilifeform: and yes trinque
asciilifeform: that can actually do things without being prodded.
trinque: this is www born nonsense that communication may only run one way, client can't listen for changes
mircea_popescu: go right ahead, produce a list of 5k rss items, THEN dole them out slowly.
mircea_popescu: no, you don't take my meaning.
asciilifeform: mircea_popescu: trilema doesn't potentially update 100 / day
trinque: yes, send me the bursts as they happen, don't render the RSS each time
mircea_popescu: asciilifeform trilema ~delays~ rss, you udnerstasnd me ?
asciilifeform: mno. i refuse to marry sql db !!!
asciilifeform: what's that do
trinque: could get me a pg connection and I could listen for pg_notify on a trigger of that table
asciilifeform: it would not do to have them all come out at once
asciilifeform: another gotcha is that the process that does the actual crunching is written in c and communicates solely via the db. it spends ~3min a day reading, but then ~all day checking 'do we already have this factor? ' writing it, in short bursts. but each of these bursts must show up in rss.
trinque: on the www
trinque: only way to deal with the nonsense that one "must" respond to allcomers "now"
asciilifeform: and yes trinque is right, it needs multiprocess queues, etc
mircea_popescu: this is ~what trinque said except his is more general.
mircea_popescu: a db write is either insert or update ; finding out things is usually a select. it ~may~ be worthwhile to separate your reads from the writes, because it is technically possible (thopugh i'd hope unlikely) the db is dumb enough to put write locks in for something like "update x on y" even though it should be "select y if z then update x".
trinque: doing all this in the request/response cycle will kill ya eventually
trinque: two thoughts, beyond which a look at the actual thing would be needed. 1) queues and workers, always 2) db acts as your queue, schema reflects the stages of work
asciilifeform: and yes this can be done in bursts, as mircea_popescu described a while ago. but still gotta query whole db for mods
asciilifeform: and for that matter, if key is new at all
asciilifeform: new key entered? must find if we know its mods, any of them, already
mircea_popescu: set a to a*b ?
mircea_popescu: your updates consist of "set a to b" neh ?
asciilifeform: and so is 'set all row to c'
mircea_popescu: table got marked crashed, so all you could load would be the comments, sorta funny half-trilema
mircea_popescu: pretty sure you weren't able to do it after i fucked it
asciilifeform: or was that after
asciilifeform: mircea_popescu: fwiw i was not able to load trilema while this was taking place.
mircea_popescu: these can take minutes, and the site isn't down during, at all.
mircea_popescu: asciilifeform no, i on occasion do multi-row updates. such as (lolz) recently when i made every entry of the 50k items in article db read the same thing.
trinque: can even fire the updates inside the db with triggers, so everything is transactionally accurate
asciilifeform: mircea_popescu: db vacuum is not a sequence of writes for the purpose of subj