mirror of
https://github.com/commercialhaskell/stackage-server.git
synced 2026-01-25 10:21:55 +01:00
Workaround for manager issues
This commit is contained in:
parent
2e1a5d3cf9
commit
65ee3c42aa
@ -116,11 +116,15 @@ cachedS3Store cache creds bucket prefix manager =
|
|||||||
len <- getZipSink $ ZipSink (sinkHandle h) *> ZipSink lengthCE
|
len <- getZipSink $ ZipSink (sinkHandle h) *> ZipSink lengthCE
|
||||||
liftIO $ hClose h
|
liftIO $ hClose h
|
||||||
liftIO $ IO.withFile fp IO.ReadMode $ \inH -> runResourceT $ do
|
liftIO $ IO.withFile fp IO.ReadMode $ \inH -> runResourceT $ do
|
||||||
|
-- FIXME the need for this separate manager
|
||||||
|
-- indicates a serious bug in either aws or (more
|
||||||
|
-- likely) http-client, must investigate!
|
||||||
|
manager' <- newManager
|
||||||
res <- Aws.aws
|
res <- Aws.aws
|
||||||
(Aws.Configuration Aws.Timestamp creds
|
(Aws.Configuration Aws.Timestamp creds
|
||||||
$ Aws.defaultLog Aws.Error)
|
$ Aws.defaultLog Aws.Error)
|
||||||
Aws.defServiceConfig
|
Aws.defServiceConfig
|
||||||
manager
|
manager'
|
||||||
(Aws.putObject bucket (toS3Path key)
|
(Aws.putObject bucket (toS3Path key)
|
||||||
$ requestBodySource len
|
$ requestBodySource len
|
||||||
$ sourceHandle inH)
|
$ sourceHandle inH)
|
||||||
|
|||||||
Loading…
Reference in New Issue
Block a user