portkey

Portkey: from REPL to Serverless in one call
qqq 2017-10-16T05:43:59.000191Z

@cgrand: I now get a different error git pull; lein install // this works fine restart boot repl (require 'portkey.core) ==>

2. Unhandled clojure.lang.Compiler$CompilerException
   Error compiling cheshire/core.clj at (1:1)

1. Caused by java.lang.Exception
   namespace 'cheshire.factory' not found

                  core.clj:  659  clojure.core/apply
                  core.clj: 5889  clojure.core/load-libs
                  core.clj: 5873  clojure.core/load-libs
               RestFn.java:  137  clojure.lang.RestFn/applyTo
                  core.clj:  659  clojure.core/apply
                  core.clj: 5911  clojure.core/require
                  core.clj: 5911  clojure.core/require
               RestFn.java:  457  clojure.lang.RestFn/invoke
                  core.clj:    1  cheshire.core/eval12329/loading--auto--
                  core.clj:    1  cheshire.core/eval12329
                  core.clj:    1  cheshire.core/eval12329
             Compiler.java: 7005  clojure.lang.Compiler/eval
             Compiler.java: 6994  clojure.lang.Compiler/eval
             Compiler.java: 7457  clojure.lang.Compiler/load
                   RT.java:  374  clojure.lang.RT/loadResourceScript
                   RT.java:  365  clojure.lang.RT/loadResourceScript
                   RT.java:  455  clojure.lang.RT/load
                   RT.java:  421  clojure.lang.RT/load
                  core.clj: 6008  clojure.core/load/fn
                  core.clj: 6007  clojure.core/load
                  core.clj: 5991  clojure.core/load
               RestFn.java:  408  clojure.lang.RestFn/invoke
                  core.clj: 5812  clojure.core/load-one
                  core.clj: 5807  clojure.core/load-one
                  core.clj: 5852  clojure.core/load-lib/fn
                  core.clj: 5851  clojure.core/load-lib
                  core.clj: 5832  clojure.core/load-lib
               RestFn.java:  142  clojure.lang.RestFn/applyTo
                  core.clj:  659  clojure.core/apply
                  core.clj: 5889  clojure.core/load-libs
                  core.clj: 5873  clojure.core/load-libs
               RestFn.java:  137  clojure.lang.RestFn/applyTo
                  core.clj:  659  clojure.core/apply
                  core.clj: 5911  clojure.core/require
                  core.clj: 5911  clojure.core/require
               RestFn.java:  805  clojure.lang.RestFn/invoke
                  core.clj:    1  portkey.core/eval12321/loading--auto--
                  core.clj:    1  portkey.core/eval12321
                  core.clj:    1  portkey.core/eval12321
             Compiler.java: 7005  clojure.lang.Compiler/eval
             Compiler.java: 6994  clojure.lang.Compiler/eval
             Compiler.java: 7457  clojure.lang.Compiler/load
                   RT.java:  374  clojure.lang.RT/loadResourceScript
                   RT.java:  365  clojure.lang.RT/loadResourceScript
                   RT.java:  455  clojure.lang.RT/load
                   RT.java:  421  clojure.lang.RT/load
                  core.clj: 6008  clojure.core/load/fn
                  core.clj: 6007  clojure.core/load
                  core.clj: 5991  clojure.core/load
               RestFn.java:  408  clojure.lang.RestFn/invoke
                  core.clj: 5812  clojure.core/load-one
                  core.clj: 5807  clojure.core/load-one

qqq 2017-10-16T09:11:13.000461Z

@baptiste-from-paris: ping

qqq 2017-10-16T09:11:20.000044Z

any idea how to help with

Unable to find a region via the region provider chain. Must provide
   an explicit region in the builder or setup environment to supply a
   region.


?

qqq 2017-10-16T09:11:26.000013Z

this is from running pk/mount!

qqq 2017-10-16T09:12:11.000333Z

so I believe porkey installed find under boot, and my problem is now AWS AMI issues

qqq 2017-10-16T09:12:41.000418Z

@cgrand: please ignore my last 2 bug reports -- they were all resolved with "update to the latest version of whatever package you're using"

baptiste-from-paris 2017-10-16T10:12:54.000049Z

@qqq I am only in one region, I don’t why it can’t find your region

qqq 2017-10-16T10:13:49.000100Z

actually, that's not the issue

qqq 2017-10-16T10:13:57.000106Z

my problem is: I don't know how to setup AMI, I don't have any config at all

qqq 2017-10-16T10:14:07.000309Z

how do I learn how to setup this up for lambda ?

baptiste-from-paris 2017-10-16T10:14:54.000203Z

I only used my account with a lot of instances in europe

baptiste-from-paris 2017-10-16T10:15:05.000274Z

so pre-configured

qqq 2017-10-16T10:17:46.000177Z

lol, I may have to solve https://github.com/portkey-cloud/portkey/issues/30 then

baptiste-from-paris 2017-10-16T10:18:03.000303Z

lol, yes

baptiste-from-paris 2017-10-16T10:18:12.000236Z

aws is great and there are a lots of resources

viesti 2017-10-16T10:26:04.000405Z

in ~/.aws/config there should be region = xxxx under the profile you use (the section [default] is used if not explicitly selected with say AWS_PROFILE environment variable)

baptiste-from-paris 2017-10-16T10:26:18.000137Z

oh right

baptiste-from-paris 2017-10-16T10:26:20.000217Z

forgot that

baptiste-from-paris 2017-10-16T10:26:39.000008Z

[default]
region = eu-west-1

baptiste-from-paris 2017-10-16T10:26:40.000170Z

for me

viesti 2017-10-16T10:26:42.000313Z

but yeah, a script that checks to necessary config on creates say a IAM user with suitable inline policy for repl use would be neat

viesti 2017-10-16T10:31:46.000008Z

script == (pk/install)

qqq 2017-10-16T11:11:56.000232Z

so I'm readinga book on aws lambda

qqq 2017-10-16T11:12:09.000237Z

is it just me, or is lambda about to completely shake up startup land?

qqq 2017-10-16T11:12:18.000038Z

seems like it's going to cut down # engineers required by atleast 90%

tatut 2017-10-16T11:17:29.000130Z

how do you figure that?

tatut 2017-10-16T11:19:21.000020Z

and if that is the case, that would be very good news indeed… there is currently a shortage of software engineering talent

qqq 2017-10-16T11:23:52.000081Z

the 90% is not a researched number; I'm the Founder of a tiny webapp, and I'm just amazed at the amount of things I don't have to do:

qqq 2017-10-16T11:24:19.000050Z

manage ubuntu installs, manage mysql, manage networking, manage ssl, manage nginx, manage devops, manage backups, scripts for automating jvm deploy, etc ...

qqq 2017-10-16T11:24:40.000256Z

it's basically "treat auroradb / dynamodb as state; write stateless functions [which manip db] in aws lambda", aws takes care of the rest

qqq 2017-10-16T11:25:09.000027Z

this is insane, it basically says: if you can reduce your server side into a bunch of db transactions, aws will auto scale everything for you

tatut 2017-10-16T11:49:14.000264Z

oh, you mean we can drop the “ops” part from devops and just focus on developing our solutions

tatut 2017-10-16T11:50:07.000152Z

but in the long run, with more complex applications, I doubt the ops part is 90% or anywhere near that

qqq 2017-10-16T12:23:49.000381Z

you're right, I should clarify the narrow context I was considering:

qqq 2017-10-16T12:24:11.000422Z

namely, things that would take 10 engineers to do pre-AWS can probably be bootstrapped by a solo engineer in 2017

qqq 2017-10-16T12:24:41.000158Z

I completely agree that "in the limiting case, there may not be much savings", but for founders, this can be the difference between tgettinga company off the ground or not

tatut 2017-10-16T12:50:45.000059Z

that makes sense, it certainly is a lot faster to get something started

viesti 2017-10-16T15:10:04.000304Z

there's some amount of ops work, configuration of the things in AWS but people get better at that

viesti 2017-10-16T15:11:17.000697Z

what's interesting is that there is a corporate story as well, since AWS can delegate auth with say SAML

tatut 2017-10-16T17:08:33.000413Z

is there a good logging story that does not require going to the cloudwatch page in the aws console?

tatut 2017-10-16T17:09:17.000233Z

perhaps not specific to portkey, but for jvm on the aws

viesti 2017-10-16T17:24:29.000425Z

something like https://github.com/jorgebastida/awslogs for tailing while making calls

👍 1
viesti 2017-10-16T17:30:35.000399Z

The good side of CloudWatch and related services is that they are there from get go, although some of them are a bit arcane

cgrand 2017-10-16T17:58:25.000404Z

Just made a commit to powderkeg that should be backported to portkey. Generally I’m leaning towards putting a warning every time a sun.* class is serialized