mirror of
https://github.com/penpot/penpot.git
synced 2026-08-01 19:06:18 +00:00
✨ Increase internal s3 http client limits
Tries to improve performance of accidental spikes/bursts of requests to s3 service. This is not a final solution to all issues caused by unexpected burst, is a simple improvement to the current apprach.
This commit is contained in:
parent
f8c7f84c18
commit
ba3f84fd6c
@ -62,6 +62,16 @@
|
|||||||
"A maximum number of retries on internal operations"
|
"A maximum number of retries on internal operations"
|
||||||
3)
|
3)
|
||||||
|
|
||||||
|
(def ^:private max-concurrency
|
||||||
|
"Maximum concurrent request to S3 service"
|
||||||
|
128)
|
||||||
|
|
||||||
|
(def ^:private max-pending-connection-acquires
|
||||||
|
20000)
|
||||||
|
|
||||||
|
(def default-timeout
|
||||||
|
(dt/duration {:seconds 30}))
|
||||||
|
|
||||||
(declare put-object)
|
(declare put-object)
|
||||||
(declare get-object-bytes)
|
(declare get-object-bytes)
|
||||||
(declare get-object-data)
|
(declare get-object-data)
|
||||||
@ -177,9 +187,6 @@
|
|||||||
|
|
||||||
;; --- HELPERS
|
;; --- HELPERS
|
||||||
|
|
||||||
(def default-timeout
|
|
||||||
(dt/duration {:seconds 30}))
|
|
||||||
|
|
||||||
(defn- lookup-region
|
(defn- lookup-region
|
||||||
^Region
|
^Region
|
||||||
[region]
|
[region]
|
||||||
@ -203,6 +210,8 @@
|
|||||||
(.connectionTimeout default-timeout)
|
(.connectionTimeout default-timeout)
|
||||||
(.readTimeout default-timeout)
|
(.readTimeout default-timeout)
|
||||||
(.writeTimeout default-timeout)
|
(.writeTimeout default-timeout)
|
||||||
|
(.maxConcurrency (int max-concurrency))
|
||||||
|
(.maxPendingConnectionAcquires (int max-pending-connection-acquires))
|
||||||
(.build))
|
(.build))
|
||||||
|
|
||||||
client (let [builder (S3AsyncClient/builder)
|
client (let [builder (S3AsyncClient/builder)
|
||||||
|
|||||||
Loading…
x
Reference in New Issue
Block a user