portkey

Portkey: from REPL to Serverless in one call
viesti 2018-11-30T13:22:42.000600Z

just listened to Stuart Hallowayโ€™s talk

viesti 2018-11-30T13:23:24.001200Z

and now really excited about todays โ€œAWS, meet Clojureโ€ talk ๐Ÿ™‚

viesti 2018-11-30T13:23:32.001500Z

which starts in an hour I guess

baptiste-from-paris 2018-11-30T13:23:49.002Z

sad also

baptiste-from-paris 2018-11-30T13:23:50.002200Z

lol

baptiste-from-paris 2018-11-30T13:23:58.002500Z

mixed feelings

viesti 2018-11-30T13:23:59.002700Z

yeah well, really a teaser

viesti 2018-11-30T13:24:22.003200Z

the lately added Datafy protocol is a center part of the mix

baptiste-from-paris 2018-11-30T13:24:51.003800Z

datafy = ?

viesti 2018-11-30T13:26:29.004200Z

(defprotocol Datafiable
  (datafy [o] "return a representation of o as data (default identity)"))

baptiste-from-paris 2018-11-30T13:26:52.004700Z

ok

viesti 2018-11-30T13:27:22.005200Z

not sure yet, but with that one could make the java stuff more data-like

viesti 2018-11-30T13:28:07.006100Z

if the idea with aws-clj-sdk is to go and make aws http apiโ€™s more like data, then Datafiable can just benifit from that work

viesti 2018-11-30T13:28:22.006400Z

thereโ€™s the concept of Navigable too

viesti 2018-11-30T13:28:58.006900Z

which would allow seeking (might allow paging too)

viesti 2018-11-30T13:29:31.007100Z

anyway, quite exciting

viesti 2018-11-30T13:30:25.008100Z

not yet sure if their idea is to work on operating on the pure material (xml/json etc.) of the http apiโ€™s though

viesti 2018-11-30T13:30:56.008800Z

well anyway, have to watch the presentation at some point in near future ๐Ÿ™‚

baptiste-from-paris 2018-11-30T13:31:16.009Z

lol

baptiste-from-paris 2018-11-30T13:31:19.009200Z

great

baptiste-from-paris 2018-11-30T13:32:00.010Z

iโ€™ll have at least 4 weeks off, just tell me if I finish the project or not ๐Ÿ˜…

cgrand 2018-11-30T14:33:27.011Z

if @viesti is right on the money then it means they use datafy over AWS java libs

cgrand 2018-11-30T14:33:51.011600Z

so axs-clj-sdk has still value proposition of being pure clojure and cljs

viesti 2018-11-30T14:40:45.011900Z

yes

viesti 2018-11-30T14:41:55.013Z

I was a bit wary of saying that, but the java libs have quite much stuff in them which is valuable and aws-clj-sdk still has itโ€™s value proposition

viesti 2018-11-30T14:42:10.013400Z

so if that is the case, there is just novel work, no losers here

baptiste-from-paris 2018-11-30T16:57:26.013600Z

๐Ÿ˜ญ๐Ÿ˜ญ๐Ÿ˜ญ๐Ÿ˜ญ๐Ÿ˜ญ๐Ÿ˜ญ๐Ÿ˜ญ

baptiste-from-paris 2018-11-30T16:57:27.013700Z

viesti 2018-11-30T17:31:06.014100Z

:D

viesti 2018-11-30T17:32:16.015900Z

hmm so traveling back from company little Christmas party still today, can I bear watching the presentation in train? :)

baptiste-from-paris 2018-11-30T17:32:35.016100Z

๐Ÿ˜‚

baptiste-from-paris 2018-11-30T17:32:44.016400Z

Must be interesting anyway

viesti 2018-11-30T17:36:16.019800Z

hmm so Datafy on ClojureScript, there's the question on amount of work bridging JS to Datafy

viesti 2018-11-30T17:37:12.020500Z

thinking that one artifact is an upside too

viesti 2018-11-30T17:37:23.020900Z

anyways we hit a spot :)

baptiste-from-paris 2018-11-30T17:39:19.021200Z

Datafy is on cljs ?

viesti 2018-11-30T17:41:34.021900Z

well the protocol is in a clj file

viesti 2018-11-30T17:42:09.022400Z

don't know the story of cljc in core actually

baptiste-from-paris 2018-11-30T17:42:15.022600Z

Ok

baptiste-from-paris 2018-11-30T17:42:37.023300Z

Didnโ€™t watched aws, I think Iโ€™ll wait after London ^^

viesti 2018-11-30T20:05:56.023800Z

hmm, didnโ€™t yet find Davidโ€™s recording

viesti 2018-11-30T20:06:11.024200Z

ah there

viesti 2018-11-30T20:10:37.024500Z

viesti 2018-11-30T20:10:40.024800Z

โ€ฆ.

viesti 2018-11-30T20:11:14.025200Z

next slide is the one that @baptiste-from-paris referenced

viesti 2018-11-30T20:11:46.025500Z

anyway we got onto a slide in the Conj ๐Ÿ™‚

viesti 2018-11-30T20:12:49.025900Z

hmm, this isnโ€™t just Datafy over Java classesโ€ฆ I hopeโ€ฆ

baptiste-from-paris 2018-11-30T20:13:14.026100Z

Lol

viesti 2018-11-30T20:13:45.026600Z

ahaa, David found js, ruby and go sdkโ€™s with service descs

baptiste-from-paris 2018-11-30T20:14:20.026800Z

?

viesti 2018-11-30T20:14:36.027100Z

you did not watch the whole talk? ๐Ÿ™‚

viesti 2018-11-30T20:15:11.027600Z

Iโ€™m progressing slide by slide

baptiste-from-paris 2018-11-30T20:15:20.027900Z

Nope

baptiste-from-paris 2018-11-30T20:15:27.028300Z

Having a drink with friends

baptiste-from-paris 2018-11-30T20:15:34.028700Z

I geeked all week ;-)

viesti 2018-11-30T20:15:35.028800Z

you not dare? ๐Ÿ™‚

baptiste-from-paris 2018-11-30T20:15:40.029100Z

Lol

viesti 2018-11-30T20:16:30.029900Z

in a train back to home, have to decide if I drink something to my misery or get enlightened after this ๐Ÿ™‚

viesti 2018-11-30T20:19:33.030200Z

they (Cognitect) started in 2015

viesti 2018-11-30T20:19:46.030400Z

11 people involved

viesti 2018-11-30T20:19:55.030600Z

Rich himself

viesti 2018-11-30T20:20:59.031Z

damn!

baptiste-from-paris 2018-11-30T20:22:06.032Z

Lol

cgrand 2018-11-30T20:22:27.032700Z

I havenโ€™t watched it but I guess you (@viesti and @baptiste-from-paris) can be proud.

viesti 2018-11-30T20:22:29.032800Z

com.cognitect.aws/api

viesti 2018-11-30T20:22:40.033Z

you too ๐Ÿ™‚

viesti 2018-11-30T20:22:47.033300Z

Christophe ๐Ÿ™‚

viesti 2018-11-30T20:23:53.033800Z

they too use the other sdkโ€™s for models to generate clojure artifacts

viesti 2018-11-30T20:25:04.035100Z

man oh man, If Iโ€™d just had really promoted this in my company, thereโ€™s so many people getting betting on AWS, just that not that many on particularly on Clojure

baptiste-from-paris 2018-11-30T20:25:25.035400Z

Real question is : can we be better at it

viesti 2018-11-30T20:25:44.036Z

Iโ€™m 16min in the presentation still

viesti 2018-11-30T20:26:25.036100Z

baptiste-from-paris 2018-11-30T20:27:25.037300Z

Humm, seems our lib is better ^_^

viesti 2018-11-30T20:27:59.037800Z

(api/ops s3-client) is like (amazonica/show-functions)

viesti 2018-11-30T20:28:03.038100Z

we have specs

viesti 2018-11-30T20:28:31.038500Z

cider-browse-specs rules here

viesti 2018-11-30T20:28:46.038800Z

we even have docstrings

viesti 2018-11-30T20:28:58.039100Z

(ok, not for all apiโ€™s but anyway)

viesti 2018-11-30T20:29:21.039300Z

ah, but they have specs

viesti 2018-11-30T20:29:41.039600Z

(me: interlude, where are spec dosctrings)

viesti 2018-11-30T20:30:29.040300Z

they have pay-as-you-go, docs/specs get loaded during call, not on require

viesti 2018-11-30T20:32:55.040400Z

viesti 2018-11-30T20:33:46.041Z

lower-level response in metadata, it seems

viesti 2018-11-30T20:34:25.041500Z

not streaming, since the client they use (same http client as datomic uses)

baptiste-from-paris 2018-11-30T20:34:34.041800Z

๐Ÿ‘Œ

baptiste-from-paris 2018-11-30T20:34:41.042100Z

Thanks kimmo

baptiste-from-paris 2018-11-30T20:34:52.042600Z

Keep going with news ^^

viesti 2018-11-30T20:35:06.042900Z

yeah, not live but anyway ๐Ÿ™‚

viesti 2018-11-30T20:35:50.043500Z

retryable? predicate, can retry requests via throttling

viesti 2018-11-30T20:36:47.044100Z

(thinking that this is a โ€œRelease itโ€ book like addition)

viesti 2018-11-30T20:37:18.044700Z

seems there are more backpressure things, backoff retry

viesti 2018-11-30T20:37:51.044800Z

viesti 2018-11-30T20:38:25.045900Z

credential chain as normal, maybe nothing interesthing here, but for completeness sake, works in EC2 and containers

viesti 2018-11-30T20:39:20.046400Z

ok but for testing one can provide a :credentials-provider

viesti 2018-11-30T20:39:38.046700Z

(aws.async/invoke) gives back a channel

viesti 2018-11-30T20:40:16.047200Z

(now Christophe could chime in for async support :))

viesti 2018-11-30T20:40:22.047400Z

Demo!

viesti 2018-11-30T20:40:38.047600Z

REBL!

viesti 2018-11-30T20:41:36.048200Z

(def ddb (aws/client {:api :dynamodb}))

viesti 2018-11-30T20:41:48.048400Z

demo effect

viesti 2018-11-30T20:42:17.048700Z

clojure -A:rebl...

viesti 2018-11-30T20:42:42.049200Z

(almost like clojure -A:rebel for Bruceโ€™s work)

viesti 2018-11-30T20:42:57.049500Z

wifi problems, demo effect continues

viesti 2018-11-30T20:43:17.049800Z

oh damn! wifi fails demo

viesti 2018-11-30T20:43:51.050300Z

would have demoed documentation navigation

viesti 2018-11-30T20:44:05.050600Z

library state is alpha

viesti 2018-11-30T20:45:14.051Z

designed for dealing with services, no helpers (like aws-clj-sdk)

viesti 2018-11-30T20:45:43.051700Z

meaning that lacks stuff like the TransferManger in the Java S3 api which does multipart download in parallel

viesti 2018-11-30T20:45:52.051900Z

try it out! feedback!

viesti 2018-11-30T20:46:45.052100Z

it lives here: https://github.com/cognitect-labs/aws-api

viesti 2018-11-30T20:47:11.052500Z

jars in maven central

viesti 2018-11-30T20:48:03.052700Z

questions?

viesti 2018-11-30T20:48:19.053100Z

(I would have but Iโ€™m no there)

viesti 2018-11-30T20:48:43.053500Z

ack, he didnโ€™t repeat the questions

viesti 2018-11-30T20:49:10.053800Z

ahh, someone asked about versioning the apis

viesti 2018-11-30T20:50:15.054Z

they generate clojure specs

viesti 2018-11-30T20:50:47.054300Z

Stu comes with a laptop

viesti 2018-11-30T20:50:50.054500Z

demo time!

viesti 2018-11-30T20:51:04.054800Z

(Stu says this is supercool)

viesti 2018-11-30T20:51:12.055Z

Stu takes the stage

viesti 2018-11-30T20:51:39.055400Z

comedy style of Stu finding a connnector for his laptop ๐Ÿ™‚

viesti 2018-11-30T20:52:51.056100Z

okay, he demoes the thing that I demoed with Emacs cider-browse-spec gif

viesti 2018-11-30T20:53:01.056500Z

caps lock remapped confuses David!

viesti 2018-11-30T20:53:03.056700Z

๐Ÿ˜„

viesti 2018-11-30T20:54:26.057300Z

html as html (hrm, we have html to nice string)

viesti 2018-11-30T20:55:17.057800Z

ok, list tables in dymanodb, then get arn, Datafy the arn, turn that into table describe

viesti 2018-11-30T20:55:19.058Z

(neat!)

viesti 2018-11-30T20:55:48.058400Z

Datafy the resouce, Nav throught it

viesti 2018-11-30T20:56:06.058800Z

(i.e. jump through all the AWS api)

viesti 2018-11-30T20:56:12.059200Z

TALK FIN

viesti 2018-11-30T20:56:15.059400Z

there, phew

baptiste-from-paris 2018-11-30T20:56:25.059600Z

So

baptiste-from-paris 2018-11-30T20:56:32.059900Z

Pros & cons

baptiste-from-paris 2018-11-30T20:56:43.060100Z

?

viesti 2018-11-30T21:01:23.060400Z

well the spec generation struct me

viesti 2018-11-30T21:01:37.060800Z

Datafy is something that didnโ€™t exist just until now

viesti 2018-11-30T21:01:52.061100Z

obviously we didnโ€™t know about it

viesti 2018-11-30T21:02:25.061700Z

I think David mentioned that this lib is in experimental use

viesti 2018-11-30T21:02:41.062100Z

but odds are that this will get more eyes on it than ours

viesti 2018-11-30T21:03:21.062400Z

didnโ€™t catch how many APIโ€™s they actually support

viesti 2018-11-30T21:03:45.063Z

thinking that probably not API Gateway, for which Cristophe did a fair amount of work

viesti 2018-11-30T21:05:06.063400Z

0% tree src/cognitect/aws/protocols
src/cognitect/aws/protocols
โ”œโ”€โ”€ common.clj
โ”œโ”€โ”€ ec2.clj
โ”œโ”€โ”€ json.clj
โ”œโ”€โ”€ query.clj
โ”œโ”€โ”€ rest.clj
โ”œโ”€โ”€ rest_json.clj
โ””โ”€โ”€ rest_xml.clj

viesti 2018-11-30T21:05:15.063800Z

right off the bat, more protocols than we support

viesti 2018-11-30T21:06:20.064200Z

and since they release to maven, this lib has immediate user base

viesti 2018-11-30T21:08:37.064400Z

0% tree test/resources/aws-sig-v4-test-suite
test/resources/aws-sig-v4-test-suite
โ”œโ”€โ”€ get-header-key-duplicate
โ”‚   โ”œโ”€โ”€ get-header-key-duplicate.authz
โ”‚   โ”œโ”€โ”€ get-header-key-duplicate.creq
โ”‚   โ”œโ”€โ”€ get-header-key-duplicate.req
โ”‚   โ”œโ”€โ”€ get-header-key-duplicate.sreq
โ”‚   โ””โ”€โ”€ get-header-key-duplicate.sts

viesti 2018-11-30T21:08:58.065Z

test suite might look familiar to Baptiste? ๐Ÿ™‚

baptiste-from-paris 2018-11-30T21:09:30.065200Z

Lol

baptiste-from-paris 2018-11-30T21:09:33.065400Z

Yep

baptiste-from-paris 2018-11-30T21:11:13.067200Z

But itโ€™s all good, the journey does count, not the destination and if I feel that I can bring something new with finishing the last protocol during Xmas Iโ€™ll do it

baptiste-from-paris 2018-11-30T21:11:31.067900Z

If not, fuck it, it was awesome anyway

viesti 2018-11-30T21:11:50.068200Z

my thoughts exactly, awesome anyway ๐Ÿ™‚

๐Ÿ‘Œ 1
viesti 2018-11-30T21:12:53.068600Z

I donโ€™t see HAL in the lib

viesti 2018-11-30T21:13:06.069Z

wiggle that in to make the thing better

viesti 2018-11-30T21:14:17.069400Z

glad that this wasnโ€™t just glue over Java artifacts

viesti 2018-11-30T21:14:27.069700Z

but a proper datafying

viesti 2018-11-30T21:16:24.070400Z

I say we pat ourselves on the back in London, and continue the Clojure journey, wherever it leads us ๐Ÿ™‚

baptiste-from-paris 2018-11-30T21:17:03.070700Z

Amen

baptiste-from-paris 2018-11-30T21:17:06.070900Z

๐Ÿ™

baptiste-from-paris 2018-11-30T21:20:02.071200Z

Lol