git.iko.soy/typeable/bloodhound
on master help sign in
purdy
e1cf109Chris Allen
bloodhound.cabal+3−8
@@ -24,7 +24,7 @@ library
24 Database.Bloodhound.Types.Class
24 Database.Bloodhound.Types.Class
25 hs-source-dirs: src
25 hs-source-dirs: src
26 build-depends: base >= 4.3 && <5,
26 build-depends: base >= 4.3 && <5,
27− bytestring >= 0.10.2 && <0.11,
27+ bytestring >= 0.10.0 && <0.11,
28 containers >= 0.5.0.0 && <0.6,
28 containers >= 0.5.0.0 && <0.6,
29 aeson >= 0.7 && <0.9,
29 aeson >= 0.7 && <0.9,
30 conduit >= 1.0 && <1.3,
30 conduit >= 1.0 && <1.3,
@@ -37,7 +37,7 @@ library
37 default-language: Haskell2010
37 default-language: Haskell2010
38
38
39test-suite tests
39test-suite tests
40− ghc-options: -Wall
40+ ghc-options: -Wall -fno-warn-orphans
41 type: exitcode-stdio-1.0
41 type: exitcode-stdio-1.0
42 main-is: tests.hs
42 main-is: tests.hs
43 hs-source-dirs: tests
43 hs-source-dirs: tests
@@ -62,12 +62,7 @@ test-suite doctests
62 main-is: doctests.hs
62 main-is: doctests.hs
63 hs-source-dirs: tests
63 hs-source-dirs: tests
64 build-depends: base,
64 build-depends: base,
65+ directory,
65 doctest,
66 doctest,
66 doctest-prop,
67 doctest-prop,
67 filepath
68 filepath
68− if impl(ghc >= 7.8)
69− build-depends: directory >= 1.1 && < 1.2.2,
70− process >= 1.1 && < 1.3
71− else:
72− build-depends: directory >= 1.1 && < 1.2.0,
73− process >= 1.1 && < 1.2
src/Database/Bloodhound/Client.hs+2−2
@@ -50,7 +50,7 @@ module Database.Bloodhound.Client
50 where
50 where
51
51
52import Data.Aeson
52import Data.Aeson
53−import Data.ByteString.Builder
53+import Data.ByteString.Lazy.Builder
54import qualified Data.ByteString.Lazy.Char8 as L
54import qualified Data.ByteString.Lazy.Char8 as L
55import Data.List (intercalate)
55import Data.List (intercalate)
56import Data.Maybe (fromMaybe)
56import Data.Maybe (fromMaybe)
@@ -309,7 +309,7 @@ encodeBulkOperations stream = collapsed where
309 collapsed = toLazyByteString $ mappend mashedTaters (byteString "\n")
309 collapsed = toLazyByteString $ mappend mashedTaters (byteString "\n")
310
310
311mash :: Builder -> V.Vector L.ByteString -> Builder
311mash :: Builder -> V.Vector L.ByteString -> Builder
312−mash = V.foldl' (\b x -> b `mappend` "\n" `mappend` (lazyByteString x))
312+mash = V.foldl' (\b x -> b `mappend` (byteString "\n") `mappend` (lazyByteString x))
313
313
314mkBulkStreamValue :: Text -> String -> String -> String -> Value
314mkBulkStreamValue :: Text -> String -> String -> String -> Value
315mkBulkStreamValue operation indexName mappingName docId =
315mkBulkStreamValue operation indexName mappingName docId =