Liking cljdoc? Tell your friends :D

s4.core


aleph-async-ring-adapterclj

(aleph-async-ring-adapter async-handler)
source

bucket-get-opsclj

(bucket-get-ops bucket
                request
                {:keys [konserve cost-tracker] :as system}
                request-id)
source

bucket-put-opsclj

(bucket-put-ops bucket request {:keys [konserve]} request-id)
source

get-objectclj

(get-object bucket
            object
            request
            {:keys [konserve cost-tracker]}
            request-id
            with-body?)
source

list-objectsclj

(list-objects bucket bucket-meta request system request-id)
source

list-objects-v2clj

(list-objects-v2 bucket bucket-meta request {:keys [konserve]} request-id)
source

list-versionsclj

(list-versions bucket bucket-meta request {:keys [konserve]} request-id)
source

make-handlerclj

(make-handler system)
source

make-reloadable-handlerclj

(make-reloadable-handler system)

Create an S3 handler that will rebuild the handler functions on every request; this way you can reload the namespace in between calls via a REPL. System is an atom containing a system map.

Create an S3 handler that will rebuild the handler functions on
every request; this way you can reload the namespace in between
calls via a REPL. System is an atom containing a system map.
sourceraw docstring

make-server!clj

(make-server! {:keys [bind-address port konserve cost-tracker reloadable?
                      auth-store hostname request-id-prefix]
               :or {bind-address "127.0.0.1" port 0 hostname "localhost"}})

Launch a HTTP server that serves the S3 HTTP API.

Arguments include:

  • bind-address A string, or an InetAddress; the address to bind to. Defaults to "127.0.0.1".
  • port A port number to bind to. Defaults to 0, which will bind to a random available port.
  • konserve An instance satisfying konserve.protocols/PEDNAsyncKeyValueStore. Will default to a in-memory store if not supplied.
  • cost-tracker A s4.$$$$/ICostTracker instance. Defaults to one that simulates default usage in us-west-2.
  • reloadable? If truthy, creates the HTTP handler such that if you reload namespaces s4.core or s4.auth, the changes are reflected in the running server. Default false.
  • auth-store An instance satisfying s4.auth.protocols/AuthStore. Defaults to a s4.auth/AtomAuthStore instance.
  • hostname The hostname to assign the server, default "localhost".
  • request-id-prefix A string to prepend to request IDs. Default nil.

Return value is an atom, containing a map of keys:

  • server The aleph HTTP server.
  • bind-address The InetSocketAddress that was bound, including the port that was selected, if a random port was used.
  • konserve The konserve store instance.
  • cost-tracker The cost tracker instance.
  • auth-store The auth store instance. If you let this create the default store, you likely want to assoc your fake access keys into the atom contained by the AtomAuthStore.
Launch a HTTP server that serves the S3 HTTP API.

Arguments include:

* `bind-address` A string, or an InetAddress; the address to bind
  to. Defaults to "127.0.0.1".
* `port` A port number to bind to. Defaults to 0, which will bind
  to a random available port.
* `konserve` An instance satisfying konserve.protocols/PEDNAsyncKeyValueStore.
  Will default to a in-memory store if not supplied.
* `cost-tracker` A `s4.$$$$/ICostTracker` instance. Defaults to
  one that simulates default usage in us-west-2.
* `reloadable?` If truthy, creates the HTTP handler such that if
  you reload namespaces s4.core or s4.auth, the changes are reflected
  in the running server. Default false.
* `auth-store` An instance satisfying s4.auth.protocols/AuthStore.
  Defaults to a `s4.auth/AtomAuthStore` instance.
* `hostname` The hostname to assign the server, default "localhost".
* `request-id-prefix` A string to prepend to request IDs. Default nil.

Return value is an atom, containing a map of keys:

* `server` The aleph HTTP server.
* `bind-address` The InetSocketAddress that was bound, including
  the port that was selected, if a random port was used.
* `konserve` The konserve store instance.
* `cost-tracker` The cost tracker instance.
* `auth-store` The auth store instance. If you let this create the
  default store, you likely want to assoc your fake access keys into
  the atom contained by the AtomAuthStore.
sourceraw docstring

parse-date-headerclj

(parse-date-header d)
source

parse-rangeclj

(parse-range r)
source

put-objectclj

(put-object bucket object request {:keys [konserve cost-tracker]} request-id)
source

randomclj

source

read-handlersclj

source

s3-handlerclj

(s3-handler {:keys [konserve hostname request-id-prefix request-counter
                    cost-tracker]
             :as system})
source

s3-xmlnsclj

source

write-handlersclj

source

xml-content-typeclj

source

cljdoc is a website building & hosting documentation for Clojure/Script libraries

× close