4 ms·
The Functional Database [video]
- juskrey 13y agoVideo quality sucks hard. Is the source code from presentation available anywhere?
- 616c 13y agoInfoQ is a pain in the ass, but if you open an account with their crappy site, as mentioned by others, you can download the presentation slides at the least. Not sure if the code mentioned will be clear, or even copy-pasteable. I know this is probably not what you are looking for, but that is probably the best you can do.
- nawitus 13y agoCan someone provide a one paragraph definition of the functional database?
- joshguthrie 13y agoI expect it to be like this: (SELECT ("id", "login", "first_name", "last_name") FROM (users) (WHERE (and (or (eq "login" login) (eq "email" email) ) (eq "password" (bcrypt password)) ) ) ) (Sorry, couldn't fit more parentheses in this)
- the1 13y ago> Summary > Rich Hickey discusses how a functional database can impact the programming model, using Datomic as an example, but the principles apply to other systems using an immutable database. It's just an advert of Datomic.
- enoch_r 13y agoIs three ok? Using my limited experience playing with Datomic: A functional DB replaces a "row" that only holds the current state of the world with a list of timestamped "facts" that can represent either the present or any point in the past. Instead of simply recording "Bob's favorite food is pizza," we record that "'Bob's favorite food is pizza' was added at Time X." If Bob decides his favorite food is now ice cream, we record that "'Bob's favorite food is ice cream' was added at Time Y." At any time, we can query Datomic to get the current state of the world--"Bob's favorite food is ice cream." But note that we can also query Datomic to get any past state of the world. If our query is "what was Bob's favorite food 10 minutes before Time Y?" the response will be "pizza." A regular database is like a sheet of paper that is continually erased and drawn over with a new world-state. Datomic, as a "functional database," is like a flipbook with an updated state on every page.
- TheLoneWolfling 13y agoDoesn't that mean that the database continually grows in size?
- jeremiep 13y agoIt does the same way a git repository does, by accreting deltas with enough metadata to reconstruct the full data at any point in time.
- ExpiredLink 13y ago> A functional DB replaces a "row" that only holds the current state of the world with a list of timestamped "facts" that can represent either the present or any point in the past. ... which isn't 'functional' in any sense. It seems that Hickey just reinvented time series and tries to sell those as database.
- enoch_r 13y ago> ... which isn't 'functional' in any sense. Functional programming is very closely tied to the notion of immutable data. "Don't modify data in place" is one of the pillars of the functional model. > It seems that Hickey just reinvented time series and tries to sell those as database. Datomic is much more than a time-series, although that's the aspect that arguably makes it "functional." For example, it provides a datalog query interface and has a pretty fascinating and unique architecture that provides extremely high scalability for queries. If you don't like Datomic, or if it doesn't suit your purposes, or if you think it's overpriced for its value-added (I do), that's cool, but don't dismiss it based on a malformed understanding of what it is.
- ExpiredLink 13y ago> Functional programming is very closely tied to the notion of immutable data. "Don't modify data in place" is one of the pillars of the functional model. I don't think the Lisp fans here at HN agree. > Datomic is much more than a time-series, although that's the aspect that arguably makes it "functional." Not really. Time-series are not 'functional' by any stretch of the imagination. BTW, an add-on to Hibernate, the (in)famous OR-mapper, tries to do something similar: http://docs.jboss.org/envers/docs/index.html http://docs.jboss.org/envers/docs/index.html
- jonase 13y agoIt means that you can write pure functions (in the functional programming sense) where one (or more) of the arguments to your function is a _database value_. In haskell the types to a query function would perhaps look like this: query :: Query -> DBValue -> Result instead of performQuery :: Query -> IO DBConn -> IO Result
- peterwiese 13y agowow, i want this!!!
- willvarfar 13y agoEverything Rich says and does is gold! It surprises and disappoints me that he is not as well known nor revered as the agile craftsmanship peddlers.
- tazjin 13y agoI know very well who Rich is, but I don't know (and don't want to know) any of the "agile" proponents.
- pasbesoin 13y agoEarly on in the movement, one of the big names who also had some fairly close corporate associations came to speak at a user group meeting hosted at my then BigCo location. I even passed news of the event around so that interested parties in our local shop could head down after hours and have a listen. I felt rather bad afterwards for having done so. One of the more useless talks I've attended. Very superficially prescriptive (you should do X; Y has seen benefit Z), with no meat to the description (or prescription, as it were). Agile may well have its place. But its intersection with BigCo life, as anecdotally exemplified in this fellow, seemed to be just more of the "same old same old". New words, same shit.
- jeremiep 13y agoThat's because agile provides hype to everyone in the company, not just developers. Every single agile consultant I've met was a mediocre programmer at best. What rich says, on the other hand, is pure gold as you said. But it needs to be understood before its value is seen. It's hard to sell to the manager who has no clue what all of this means, even harder to compare the tradeoffs with their current approach.
- pjmlp 13y ago> It surprises and disappoints me that he is not as well known nor revered as the agile craftsmanship peddlers. Actually, he is better known than all those guys selling snake oil.
- sanityinc 13y agoSuch a shame about InfoQ. Seems like they've got lots of interesting content, but the user experience is abysmal to the point where I now avoid the site. Would it be so bad to just let us flick through the slides?
- corysama 13y agoWhen I'm in a rush for a tldr, I want to flick through a few slides and move on with browsing something else. But, there are a lot of times that I'm not in a rush. When I'm taking a walk or riding the bus, an MP3 of a presentation is a great way to have someone slowly explain an idea that I'm interested in -but not enough to actively concentrate on researching. Relaxing at home on the couch is another time that I'm not in a rush. I've largely replaced evening TV time with watching presentations on various topics. InfoQ is perfect for that. I get to have an expert take an hour to carefully explain a topic that I'm only tangentially interested in while I semi-nap on my couch after dinner with a beer. This has become a low-effort means for me to gain a high-level understanding of a broad range of topics that I wouldn't otherwise have the time or willpower to sit down and actively study.
- presty 13y agoif you create an account on infoq, you're able to download the slides.
- olmo 13y agoFAT -> GIT SQL -> Datomic?
- bokchoi 13y agoThe code in the video is impossible to read. Are there higher-quality versions of this video anywhere?
- kriro 13y agoHas anyone here used the PostgreSQL package for temporal database support? Would be interested in thoughts :) http://temporal.projects.pgfoundry.org/reference.html http://temporal.projects.pgfoundry.org/reference.html