Fork me on GitHub
#aws-lambda
<
2020-01-22
>
jeroenvandijk09:01:19

Some people here?

jsyrjala09:01:06

you can run normal Clojure or ClojureScript in AWS Lambdas

jeroenvandijk09:01:22

That not the same. I want inline Clojure in my Cloudformation 🙂

jeroenvandijk09:01:09

At least I think it's not the same

jeroenvandijk09:01:01

So I need a custom layer that is compatible with the standard node versions and add the sci package. In the inline code i will do something like

sci.eval-string("my-pr-str-ed clojure code")

jeroenvandijk09:01:09

The problem with normal Clojure is that there is no support for inline functions. With a normal Clojurescript layer I'm not sure, but than your layer will become really big to have it support eval

jeroenvandijk09:01:38

@ do you agree or do you have different thoughts?

jsyrjala09:01:55

I have only used normal Clojure in Lambdas. Using sci could be worth a try.

andrewwhitehouse111:01:29

@ Hi Juha, I've been looking at Lambdas in Clojurescript on Node.js. Interested to hear more about your approach.

valtteri12:01:58

@ here’s a small example project with CLJS using shadow-cljs and Serverless framework. https://github.com/vharmain/serverless-healthcheck

valtteri13:01:05

That’s my current ‘goto setup’ with lambda and cljs. It’s relatively simple and I’m most happy with the small bundle sizes.

ghadi17:01:55

@jeroenvandijk I don't think inline code is supported for non node.js/python lambdas

jeroenvandijk08:01:04

@ You are right. Therefore I want to use a node.js lambda with sci 🙂 I've been able to add a Layer to an inline lambda, but I need to figure out how to call the other layer. No success yet. I'll create a normal layer-ed lambda first. In the interface the look the same so I'm still positive

jeroenvandijk08:01:15

If sci works, self-hosted clojurescript would work as well I suppose

jeroenvandijk10:01:06

@ After endless trial and error how to generate an AWS nodejs package... I can confirm this inline idea works! 🎉

mruzekw19:01:40

Has anyone had any success with Lambda + Provisioned Currency and CLJ?

holyjak14:01:47

I guess the story here is the same as for Java? Somebody has surely blogged about that... :)

mruzekw19:01:21

Up until provisioned currency I was thinking CLJS would be the best for high performing lambdas, but with provisioned currency we can just use the JVM