Asynchronous, pure-Clojure AWS client


License
Unlicense

Documentation

eulalie Build Status

Clojars Project

Eulalie is an asynchronous AWS client supporting Clojure/JVM & Clojurescript/Node, primarily intended as a platform for building higher-level client libraries. With the exception of a couple of utility namespaces, Eulalie exposes a single entrypoint, and uses service-specific transformations to turn maps describing requests into maps describing responses.

Rather than attempt a gaudy looking Clojure API for each service (e.g. type mapping, post-processing multimethods, etc.), Eulalie worries about less savoury details: structural conversions to/from the underlying format, request signing, retry/backoff policies, etc.

Services

  • checkmark Dynamo
  • checkmark Dynamo Streams
  • checkmark SNS
  • checkmark SQS
  • checkmark Lambda (documentation)
  • checkmark Elastic Transcoder
  • checkmark SES
  • checkmark Cognito/Sync, STS

Utilities

  • eulalie.creds - Retrieval/refreshing of instance-specific IAM role credentials, etc.
  • eulalie.instance-data - Utilities for structured retrieval of EC2 instance metadata.

Higher-level Clients

There are a couple of higher-level clients built with Eulalie, both of which also support Clojurescript/Node - if you're interested in Dynamo, Dynamo Streams, SQS, or SNS, it's highly recommended that you rather use either:

Clojurescript

The motivating use-case for Clojurescript support was the ability to write AWS Lambda functions, which is why the initial focus is on Node. That said, supporting in-browser use is a priority for the next release - all of the services currently supported (barring Lambda) can be used from the browser with the offical AWS Javascript SDK. Help would be appreciated.

:optimizations :advanced

In order to enable dead-code elimination, eulalie is happy to run under :optimizations :advanced. It uses cljs-nodejs-externs to extern the Node standard library. Its NPM dependencies are declared via lein-npm:

And, optimization more generally

The implementation works great, though it's likely there are some adjustments particular to its runtime that someone more Node-experienced might make (e.g. tuning Agent construction in platform.cljs for large numbers of concurrent SSL connections to a particular host).

API

Example

(ns ...
  (:require [eulalie.core :as eulalie]
            [eulalie.dynamo]
            ...))

(eulalie/issue-request!
  {:creds {:access-key ... :secret-key ... [:token :region :endpoint]}
   :service :dynamo
   :target :describe-table
   :body {:table-name ...}})
;; => Channel
;; {:response {:body {:table-name ...} ...}
;;  :retries 0
;;  :request ...}

The API for consuming services basically consists of eulalie/issue-request!. Service-specific functionality is incorporated by requiring the appropriate namespace (e.g. eulalie.dynamo, above). There are whole bunch of utilities to make service definition pretty simple, if that's something you're interested in.

License

eulalie is free and unencumbered public domain software. For more information, see http://unlicense.org/ or the accompanying UNLICENSE file.