File tree Expand file tree Collapse file tree 5 files changed +32
-3
lines changed Expand file tree Collapse file tree 5 files changed +32
-3
lines changed Original file line number Diff line number Diff line change 1+ { compiler ? "ghc863" , pkgs ? import <nixpkgs> { } } :
2+
3+ let
4+
5+ haskellPackages = pkgs . haskell . packages . ${ compiler } . extend ( self : super : {
6+ } ) ;
7+
8+ runtime = haskellPackages . callCabal2nix "aws-lambda-haskell-runtime" ./. { } ;
9+
10+ in
11+ {
12+ aws-lambda-haskell-runtime = runtime ;
13+ aws-lambda-haskell-runtime-shell = haskellPackages . shellFor {
14+ packages = p : [ runtime ] ;
15+ buildInputs = with pkgs ; [
16+ cabal-install
17+ hlint
18+ stack
19+ haskellPackages . ghcid
20+ haskellPackages . weeder
21+ zlib
22+ ] ;
23+ } ;
24+ }
Original file line number Diff line number Diff line change 11name : aws-lambda-haskell-runtime
2- version : 1.0.9
2+ version : 1.0.10
33github : " theam/aws-lambda-haskell-runtime"
44license : Apache-2.0
55author : Nikita Tchayka
@@ -26,6 +26,7 @@ library:
2626 - conduit
2727 - directory
2828 - filepath
29+ - http-client
2930 - microlens-platform
3031 - optparse-generic
3132 - process
Original file line number Diff line number Diff line change 1+ ( import ./. { } ) . aws-lambda-haskell-runtime-shell
Original file line number Diff line number Diff line change @@ -20,6 +20,7 @@ import Data.Monoid ((<>))
2020import qualified Data.CaseInsensitive as CI
2121import Lens.Micro.Platform hiding ((.=) )
2222import qualified Network.Wreq as Wreq
23+ import qualified Network.HTTP.Client as Http
2324import qualified System.Environment as Environment
2425import qualified System.Process as Process
2526import qualified Data.UUID as UUID
@@ -132,8 +133,10 @@ readFunctionMemory = do
132133
133134getApiData :: Text -> App (Wreq. Response LByteString )
134135getApiData endpoint =
135- keepRetrying (Wreq. get $ nextInvocationEndpoint endpoint)
136+ keepRetrying (Wreq. getWith opts $ nextInvocationEndpoint endpoint)
136137 where
138+ opts = Wreq. defaults
139+ & Wreq. manager .~ Left (Http. defaultManagerSettings { Http. managerResponseTimeout = Http. responseTimeoutNone })
137140 keepRetrying :: IO (Wreq. Response LByteString ) -> App (Wreq. Response LByteString )
138141 keepRetrying f = do
139142 result <- (liftIO $ try f) :: App (Either IOException (Wreq. Response LByteString ))
Original file line number Diff line number Diff line change 1717#
1818# resolver: ./custom-snapshot.yaml
1919# resolver: https://example.com/snapshots/2018-01-01.yaml
20- resolver : lts-12.13
20+ resolver : lts-13.0
2121
2222# User packages to be built.
2323# Various formats can be used as shown in the example below.
You can’t perform that action at this time.
0 commit comments