chore: increase columns length in .stylish-haskell.yaml
This gives the import statements more space, essentially, it collectively removes 90+ unneeded lines in the imports statements. Signed-off-by: Taimoor Zaeem <taimoorzaeem@gmail.com>
This commit is contained in:
@@ -200,7 +200,7 @@ steps:
|
|||||||
|
|
||||||
# A common setting is the number of columns (parts of) code will be wrapped
|
# A common setting is the number of columns (parts of) code will be wrapped
|
||||||
# to. Different steps take this into account. Default: 80.
|
# to. Different steps take this into account. Default: 80.
|
||||||
columns: 70
|
columns: 80
|
||||||
|
|
||||||
# By default, line endings are converted according to the OS. You can override
|
# By default, line endings are converted according to the OS. You can override
|
||||||
# preferred format here.
|
# preferred format here.
|
||||||
|
|||||||
+1
-2
@@ -37,8 +37,7 @@ import Data.Text (Text)
|
|||||||
import GHC.Driver.Errors.Types (GhcMessage)
|
import GHC.Driver.Errors.Types (GhcMessage)
|
||||||
import GHC.Generics (Generic)
|
import GHC.Generics (Generic)
|
||||||
import GHC.Hs.Extension (GhcPs)
|
import GHC.Hs.Extension (GhcPs)
|
||||||
import GHC.Types.Error (Messages, defaultDiagnosticOpts,
|
import GHC.Types.Error (Messages, defaultDiagnosticOpts, getMessages)
|
||||||
getMessages)
|
|
||||||
import GHC.Types.Name.Occurrence (occNameString)
|
import GHC.Types.Name.Occurrence (occNameString)
|
||||||
import GHC.Types.Name.Reader (rdrNameOcc)
|
import GHC.Types.Name.Reader (rdrNameOcc)
|
||||||
import GHC.Unit.Module (moduleNameString)
|
import GHC.Unit.Module (moduleNameString)
|
||||||
|
|||||||
@@ -20,8 +20,7 @@ import qualified Data.Text.Encoding as T
|
|||||||
import Data.List (lookup)
|
import Data.List (lookup)
|
||||||
import Data.Ranged.Ranges (emptyRange, rangeIntersection,
|
import Data.Ranged.Ranges (emptyRange, rangeIntersection,
|
||||||
rangeIsEmpty)
|
rangeIsEmpty)
|
||||||
import Network.HTTP.Types.Header (RequestHeaders,
|
import Network.HTTP.Types.Header (RequestHeaders, hAuthorization, hCookie)
|
||||||
hAuthorization, hCookie)
|
|
||||||
import Network.Wai (Request (..))
|
import Network.Wai (Request (..))
|
||||||
import Network.Wai.Middleware.HttpAuth (extractBearerAuth)
|
import Network.Wai.Middleware.HttpAuth (extractBearerAuth)
|
||||||
import Network.Wai.Parse (parseHttpAccept)
|
import Network.Wai.Parse (parseHttpAccept)
|
||||||
@@ -30,21 +29,17 @@ import Web.Cookie (parseCookies)
|
|||||||
import PostgREST.ApiRequest.Payload (getPayload)
|
import PostgREST.ApiRequest.Payload (getPayload)
|
||||||
import PostgREST.ApiRequest.QueryParams (QueryParams (..))
|
import PostgREST.ApiRequest.QueryParams (QueryParams (..))
|
||||||
import PostgREST.ApiRequest.Types (Action (..), DbAction (..),
|
import PostgREST.ApiRequest.Types (Action (..), DbAction (..),
|
||||||
InvokeMethod (..),
|
InvokeMethod (..), Mutation (..),
|
||||||
Mutation (..), Payload (..),
|
Payload (..), RequestBody,
|
||||||
RequestBody, Resource (..))
|
Resource (..))
|
||||||
import PostgREST.Config (AppConfig (..),
|
import PostgREST.Config (AppConfig (..), OpenAPIMode (..))
|
||||||
OpenAPIMode (..))
|
|
||||||
import PostgREST.Config.Database (TimezoneNames)
|
import PostgREST.Config.Database (TimezoneNames)
|
||||||
import PostgREST.Error (ApiRequestError (..),
|
import PostgREST.Error (ApiRequestError (..), RangeError (..))
|
||||||
RangeError (..))
|
|
||||||
import PostgREST.MediaType (MediaType (..))
|
import PostgREST.MediaType (MediaType (..))
|
||||||
import PostgREST.RangeQuery (NonnegRange, allRange,
|
import PostgREST.RangeQuery (NonnegRange, allRange,
|
||||||
convertToLimitZeroRange,
|
convertToLimitZeroRange, hasLimitZero,
|
||||||
hasLimitZero,
|
|
||||||
rangeRequested)
|
rangeRequested)
|
||||||
import PostgREST.SchemaCache.Identifiers (FieldName,
|
import PostgREST.SchemaCache.Identifiers (FieldName, QualifiedIdentifier (..),
|
||||||
QualifiedIdentifier (..),
|
|
||||||
Schema)
|
Schema)
|
||||||
|
|
||||||
import qualified PostgREST.ApiRequest.Preferences as Preferences
|
import qualified PostgREST.ApiRequest.Preferences as Preferences
|
||||||
|
|||||||
@@ -39,34 +39,28 @@ import Data.List (init, last)
|
|||||||
import Data.Ranged.Boundaries (Boundary (..))
|
import Data.Ranged.Boundaries (Boundary (..))
|
||||||
import Data.Ranged.Ranges (Range (..))
|
import Data.Ranged.Ranges (Range (..))
|
||||||
import Data.Tree (Tree (..))
|
import Data.Tree (Tree (..))
|
||||||
import Text.Parsec.Error (errorMessages,
|
import Text.Parsec.Error (errorMessages, showErrorMessages)
|
||||||
showErrorMessages)
|
import Text.ParserCombinators.Parsec (GenParser, ParseError, Parser, anyChar,
|
||||||
import Text.ParserCombinators.Parsec (GenParser, ParseError, Parser,
|
between, char, choice, digit, eof,
|
||||||
anyChar, between, char, choice,
|
errorPos, letter, lookAhead, many1,
|
||||||
digit, eof, errorPos, letter,
|
noneOf, notFollowedBy, oneOf, optionMaybe,
|
||||||
lookAhead, many1, noneOf,
|
sepBy, sepBy1, string, try, (<?>))
|
||||||
notFollowedBy, oneOf,
|
|
||||||
optionMaybe, sepBy, sepBy1,
|
|
||||||
string, try, (<?>))
|
|
||||||
|
|
||||||
import PostgREST.RangeQuery (NonnegRange, allRange,
|
import PostgREST.RangeQuery (NonnegRange, allRange, rangeGeq,
|
||||||
rangeGeq, rangeLimit,
|
rangeLimit, rangeOffset,
|
||||||
rangeOffset, restrictRange)
|
restrictRange)
|
||||||
import PostgREST.SchemaCache.Identifiers (FieldName)
|
import PostgREST.SchemaCache.Identifiers (FieldName)
|
||||||
|
|
||||||
import PostgREST.ApiRequest.Types (AggregateFunction (..),
|
import PostgREST.ApiRequest.Types (AggregateFunction (..), EmbedParam (..),
|
||||||
EmbedParam (..), EmbedPath, Field,
|
EmbedPath, Field, Filter (..),
|
||||||
Filter (..), FtsOperator (..),
|
FtsOperator (..), Hint, IsVal (..),
|
||||||
Hint, IsVal (..), JoinType (..),
|
JoinType (..), JsonOperand (..),
|
||||||
JsonOperand (..),
|
JsonOperation (..), JsonPath, ListVal,
|
||||||
JsonOperation (..), JsonPath,
|
LogicOperator (..), LogicTree (..),
|
||||||
ListVal, LogicOperator (..),
|
OpExpr (..), OpQuantifier (..),
|
||||||
LogicTree (..), OpExpr (..),
|
Operation (..), OrderDirection (..),
|
||||||
OpQuantifier (..), Operation (..),
|
|
||||||
OrderDirection (..),
|
|
||||||
OrderNulls (..), OrderTerm (..),
|
OrderNulls (..), OrderTerm (..),
|
||||||
QuantOperator (..),
|
QuantOperator (..), SelectItem (..),
|
||||||
SelectItem (..),
|
|
||||||
SimpleOperator (..), SingleVal)
|
SimpleOperator (..), SingleVal)
|
||||||
|
|
||||||
import PostgREST.Error (QPError (..))
|
import PostgREST.Error (QPError (..))
|
||||||
|
|||||||
@@ -42,8 +42,7 @@ module PostgREST.ApiRequest.Types
|
|||||||
import qualified Data.ByteString.Lazy as LBS
|
import qualified Data.ByteString.Lazy as LBS
|
||||||
import qualified Data.Set as S
|
import qualified Data.Set as S
|
||||||
|
|
||||||
import PostgREST.SchemaCache.Identifiers (FieldName,
|
import PostgREST.SchemaCache.Identifiers (FieldName, QualifiedIdentifier (..),
|
||||||
QualifiedIdentifier (..),
|
|
||||||
Schema)
|
Schema)
|
||||||
|
|
||||||
import Protolude
|
import Protolude
|
||||||
|
|||||||
@@ -27,12 +27,10 @@ import System.IO.Error (ioeGetErrorType)
|
|||||||
|
|
||||||
import Control.Monad.Except (liftEither)
|
import Control.Monad.Except (liftEither)
|
||||||
import Data.Either.Combinators (mapLeft, whenLeft)
|
import Data.Either.Combinators (mapLeft, whenLeft)
|
||||||
import Data.IORef (atomicWriteIORef, newIORef,
|
import Data.IORef (atomicWriteIORef, newIORef, readIORef)
|
||||||
readIORef)
|
|
||||||
import Data.String (IsString (..), String)
|
import Data.String (IsString (..), String)
|
||||||
import Network.Wai.Handler.Warp (defaultSettings, setBeforeMainLoop,
|
import Network.Wai.Handler.Warp (defaultSettings, setBeforeMainLoop, setHost,
|
||||||
setHost, setOnException, setPort,
|
setOnException, setPort, setServerName)
|
||||||
setServerName)
|
|
||||||
|
|
||||||
import qualified Data.Text.Encoding as T
|
import qualified Data.Text.Encoding as T
|
||||||
import qualified Network.Wai as Wai
|
import qualified Network.Wai as Wai
|
||||||
@@ -59,8 +57,7 @@ import PostgREST.Config (AppConfig (..))
|
|||||||
import PostgREST.Error (Error)
|
import PostgREST.Error (Error)
|
||||||
import PostgREST.Network (resolveSocketToAddress)
|
import PostgREST.Network (resolveSocketToAddress)
|
||||||
import PostgREST.Observation (Observation (..))
|
import PostgREST.Observation (Observation (..))
|
||||||
import PostgREST.Response.Performance (ServerTiming (..),
|
import PostgREST.Response.Performance (ServerTiming (..), serverTimingHeader)
|
||||||
serverTimingHeader)
|
|
||||||
import PostgREST.SchemaCache (SchemaCache (..))
|
import PostgREST.SchemaCache (SchemaCache (..))
|
||||||
import PostgREST.TimeIt (timeItT)
|
import PostgREST.TimeIt (timeItT)
|
||||||
import PostgREST.Version (docsVersion, prettyVersion)
|
import PostgREST.Version (docsVersion, prettyVersion)
|
||||||
@@ -68,8 +65,7 @@ import PostgREST.Version (docsVersion, prettyVersion)
|
|||||||
import Control.Monad.Writer
|
import Control.Monad.Writer
|
||||||
import qualified Data.ByteString.Char8 as BS
|
import qualified Data.ByteString.Char8 as BS
|
||||||
import qualified Data.List as L
|
import qualified Data.List as L
|
||||||
import Data.Streaming.Network (HostPreference,
|
import Data.Streaming.Network (HostPreference, bindPortGenEx,
|
||||||
bindPortGenEx,
|
|
||||||
bindPortTCP)
|
bindPortTCP)
|
||||||
import qualified Data.Text as T
|
import qualified Data.Text as T
|
||||||
import qualified Network.HTTP.Types as HTTP
|
import qualified Network.HTTP.Types as HTTP
|
||||||
|
|||||||
@@ -44,30 +44,22 @@ import PostgREST.Observation
|
|||||||
import PostgREST.TimeIt (timeItT)
|
import PostgREST.TimeIt (timeItT)
|
||||||
import PostgREST.Version (prettyVersion)
|
import PostgREST.Version (prettyVersion)
|
||||||
|
|
||||||
import Control.AutoUpdate (defaultUpdateSettings, mkAutoUpdate,
|
import Control.AutoUpdate (defaultUpdateSettings, mkAutoUpdate, updateAction)
|
||||||
updateAction)
|
|
||||||
import Control.Retry (RetryPolicy, RetryStatus (..), capDelay,
|
import Control.Retry (RetryPolicy, RetryStatus (..), capDelay,
|
||||||
exponentialBackoff, retrying,
|
exponentialBackoff, retrying, rsPreviousDelay)
|
||||||
rsPreviousDelay)
|
import Data.IORef (IORef, atomicWriteIORef, newIORef, readIORef)
|
||||||
import Data.IORef (IORef, atomicWriteIORef, newIORef,
|
|
||||||
readIORef)
|
|
||||||
import Data.Time.Clock (UTCTime, getCurrentTime)
|
import Data.Time.Clock (UTCTime, getCurrentTime)
|
||||||
|
|
||||||
import Control.Concurrent.STM (TMVar, newEmptyTMVarIO,
|
import Control.Concurrent.STM (TMVar, newEmptyTMVarIO, putTMVar,
|
||||||
putTMVar, readTMVar,
|
readTMVar, tryReadTMVar, tryTakeTMVar)
|
||||||
tryReadTMVar, tryTakeTMVar)
|
|
||||||
import PostgREST.Auth.JwtCache (JwtCacheState, update)
|
import PostgREST.Auth.JwtCache (JwtCacheState, update)
|
||||||
import PostgREST.Config (AppConfig (..),
|
import PostgREST.Config (AppConfig (..), readAppConfig,
|
||||||
readAppConfig,
|
|
||||||
toConnectionSettings)
|
toConnectionSettings)
|
||||||
import PostgREST.Config.Database (queryDbSettings,
|
import PostgREST.Config.Database (queryDbSettings, queryPgVersion,
|
||||||
queryPgVersion,
|
|
||||||
queryRoleSettings)
|
queryRoleSettings)
|
||||||
import PostgREST.Config.PgVersion (PgVersion (..),
|
import PostgREST.Config.PgVersion (PgVersion (..), minimumPgVersion)
|
||||||
minimumPgVersion)
|
|
||||||
import PostgREST.Debounce (makeDebouncer)
|
import PostgREST.Debounce (makeDebouncer)
|
||||||
import PostgREST.SchemaCache (SchemaCache (..),
|
import PostgREST.SchemaCache (SchemaCache (..), querySchemaCache,
|
||||||
querySchemaCache,
|
|
||||||
showSummary)
|
showSummary)
|
||||||
import PostgREST.SchemaCache.Identifiers (quoteQi)
|
import PostgREST.SchemaCache.Identifiers (quoteQi)
|
||||||
|
|
||||||
|
|||||||
@@ -15,8 +15,7 @@ module PostgREST.Auth
|
|||||||
( getAuthResult )
|
( getAuthResult )
|
||||||
where
|
where
|
||||||
|
|
||||||
import PostgREST.AppState (AppState, getConfig, getJwtCacheState,
|
import PostgREST.AppState (AppState, getConfig, getJwtCacheState, getTime)
|
||||||
getTime)
|
|
||||||
import PostgREST.Auth.Jwt (parseClaims)
|
import PostgREST.Auth.Jwt (parseClaims)
|
||||||
import PostgREST.Auth.JwtCache (lookupJwtCache)
|
import PostgREST.Auth.JwtCache (lookupJwtCache)
|
||||||
import PostgREST.Auth.Types (AuthResult)
|
import PostgREST.Auth.Types (AuthResult)
|
||||||
|
|||||||
@@ -24,13 +24,12 @@ import qualified Data.Aeson.KeyMap as KM
|
|||||||
|
|
||||||
import PostgREST.Error (Error (..), JwtError (JwtSecretMissing))
|
import PostgREST.Error (Error (..), JwtError (JwtSecretMissing))
|
||||||
|
|
||||||
import Control.Concurrent.STM (newTVarIO, readTVar,
|
import Control.Concurrent.STM (newTVarIO, readTVar, writeTVar)
|
||||||
writeTVar)
|
|
||||||
import Control.Concurrent.STM.TVar (TVar)
|
import Control.Concurrent.STM.TVar (TVar)
|
||||||
import Control.Monad.Error.Class (liftEither)
|
import Control.Monad.Error.Class (liftEither)
|
||||||
import Data.ByteString hiding (all, init)
|
import Data.ByteString hiding (all, init)
|
||||||
import Data.IORef (IORef, newIORef,
|
import Data.IORef (IORef, newIORef, readIORef,
|
||||||
readIORef, writeIORef)
|
writeIORef)
|
||||||
import Jose.Jwk (JwkSet)
|
import Jose.Jwk (JwkSet)
|
||||||
import PostgREST.Auth.Jwt (parseAndDecodeClaims)
|
import PostgREST.Auth.Jwt (parseAndDecodeClaims)
|
||||||
import PostgREST.Cache.Sieve (alwaysValid)
|
import PostgREST.Cache.Sieve (alwaysValid)
|
||||||
|
|||||||
@@ -60,15 +60,12 @@ import Numeric (readOct, showOct)
|
|||||||
import System.Environment (getEnvironment)
|
import System.Environment (getEnvironment)
|
||||||
import System.Posix.Types (FileMode)
|
import System.Posix.Types (FileMode)
|
||||||
|
|
||||||
import PostgREST.Config.Database (RoleIsolationLvl,
|
import PostgREST.Config.Database (RoleIsolationLvl, RoleSettings)
|
||||||
RoleSettings)
|
import PostgREST.Config.JSPath (JSPath (..), defaultRoleJSPathKey,
|
||||||
import PostgREST.Config.JSPath (JSPath (..),
|
|
||||||
defaultRoleJSPathKey,
|
|
||||||
dumpJSPath, pRoleClaimKey)
|
dumpJSPath, pRoleClaimKey)
|
||||||
import PostgREST.Config.Proxy (Proxy (..),
|
import PostgREST.Config.Proxy (Proxy (..), isMalformedProxyUri,
|
||||||
isMalformedProxyUri, toURI)
|
toURI)
|
||||||
import PostgREST.SchemaCache.Identifiers (QualifiedIdentifier (..),
|
import PostgREST.SchemaCache.Identifiers (QualifiedIdentifier (..), toQi)
|
||||||
toQi)
|
|
||||||
|
|
||||||
import PostgREST.Version (prettyVersion)
|
import PostgREST.Version (prettyVersion)
|
||||||
import Protolude hiding (Proxy, toList)
|
import Protolude hiding (Proxy, toList)
|
||||||
|
|||||||
@@ -46,14 +46,10 @@ import qualified PostgREST.MediaType as MediaType
|
|||||||
|
|
||||||
import PostgREST.Config (Verbosity (..))
|
import PostgREST.Config (Verbosity (..))
|
||||||
import PostgREST.SchemaCache (SchemaCache (SchemaCache, dbTablesFuzzyIndex))
|
import PostgREST.SchemaCache (SchemaCache (SchemaCache, dbTablesFuzzyIndex))
|
||||||
import PostgREST.SchemaCache.Identifiers (QualifiedIdentifier (..),
|
import PostgREST.SchemaCache.Identifiers (QualifiedIdentifier (..), Schema)
|
||||||
Schema)
|
import PostgREST.SchemaCache.Relationship (Cardinality (..), Junction (..),
|
||||||
import PostgREST.SchemaCache.Relationship (Cardinality (..),
|
Relationship (..), RelationshipsMap)
|
||||||
Junction (..),
|
import PostgREST.SchemaCache.Routine (Routine (..), RoutineParam (..))
|
||||||
Relationship (..),
|
|
||||||
RelationshipsMap)
|
|
||||||
import PostgREST.SchemaCache.Routine (Routine (..),
|
|
||||||
RoutineParam (..))
|
|
||||||
|
|
||||||
import PostgREST.Error.Types
|
import PostgREST.Error.Types
|
||||||
|
|
||||||
|
|||||||
@@ -22,8 +22,7 @@ import qualified Hasql.Pool as SQL
|
|||||||
import PostgREST.MediaType (MediaType (..))
|
import PostgREST.MediaType (MediaType (..))
|
||||||
import PostgREST.SchemaCache (SchemaCache (..))
|
import PostgREST.SchemaCache (SchemaCache (..))
|
||||||
import PostgREST.SchemaCache.Identifiers (QualifiedIdentifier (..))
|
import PostgREST.SchemaCache.Identifiers (QualifiedIdentifier (..))
|
||||||
import PostgREST.SchemaCache.Relationship (Relationship (..),
|
import PostgREST.SchemaCache.Relationship (Relationship (..), RelationshipsMap)
|
||||||
RelationshipsMap)
|
|
||||||
import PostgREST.SchemaCache.Routine (Routine (..))
|
import PostgREST.SchemaCache.Routine (Routine (..))
|
||||||
import Protolude
|
import Protolude
|
||||||
|
|
||||||
|
|||||||
@@ -18,8 +18,8 @@ import qualified PostgREST.Config as Config
|
|||||||
import Control.Arrow ((&&&))
|
import Control.Arrow ((&&&))
|
||||||
import Data.Bitraversable (bisequence)
|
import Data.Bitraversable (bisequence)
|
||||||
import Data.Either.Combinators (whenRight)
|
import Data.Either.Combinators (whenRight)
|
||||||
import Data.IORef (IORef, newIORef,
|
import Data.IORef (IORef, newIORef, readIORef,
|
||||||
readIORef, writeIORef)
|
writeIORef)
|
||||||
import qualified Data.Text as T
|
import qualified Data.Text as T
|
||||||
import qualified Database.PostgreSQL.LibPQ as LibPQ
|
import qualified Database.PostgreSQL.LibPQ as LibPQ
|
||||||
import qualified Hasql.Session as SQL
|
import qualified Hasql.Session as SQL
|
||||||
|
|||||||
@@ -13,8 +13,7 @@ module PostgREST.Logger
|
|||||||
) where
|
) where
|
||||||
|
|
||||||
import Control.AutoUpdate (defaultUpdateSettings,
|
import Control.AutoUpdate (defaultUpdateSettings,
|
||||||
mkAutoUpdate,
|
mkAutoUpdate, updateAction)
|
||||||
updateAction)
|
|
||||||
import qualified Data.ByteString.Char8 as BS
|
import qualified Data.ByteString.Char8 as BS
|
||||||
import qualified Data.Text.Encoding as T
|
import qualified Data.Text.Encoding as T
|
||||||
import qualified Hasql.Decoders as HD
|
import qualified Hasql.Decoders as HD
|
||||||
@@ -22,8 +21,7 @@ import qualified Hasql.DynamicStatements.Snippet as SQL hiding (sql)
|
|||||||
import qualified Hasql.DynamicStatements.Statement as SQL
|
import qualified Hasql.DynamicStatements.Statement as SQL
|
||||||
import qualified Hasql.Statement as SQL
|
import qualified Hasql.Statement as SQL
|
||||||
|
|
||||||
import Data.Time (ZonedTime, defaultTimeLocale, formatTime,
|
import Data.Time (ZonedTime, defaultTimeLocale, formatTime, getZonedTime)
|
||||||
getZonedTime)
|
|
||||||
|
|
||||||
import Network.HTTP.Types.Status (Status, status400, status500)
|
import Network.HTTP.Types.Status (Status, status400, status500)
|
||||||
|
|
||||||
|
|||||||
@@ -16,8 +16,7 @@ module PostgREST.MainTx
|
|||||||
import Control.Lens ((^?))
|
import Control.Lens ((^?))
|
||||||
import Control.Monad.Extra (whenJust)
|
import Control.Monad.Extra (whenJust)
|
||||||
import qualified Data.Aeson.Lens as L
|
import qualified Data.Aeson.Lens as L
|
||||||
import qualified Data.ByteString as BS hiding
|
import qualified Data.ByteString as BS hiding (break)
|
||||||
(break)
|
|
||||||
import qualified Data.ByteString.Char8 as BS
|
import qualified Data.ByteString.Char8 as BS
|
||||||
import qualified Data.HashMap.Strict as HM
|
import qualified Data.HashMap.Strict as HM
|
||||||
import qualified Data.Set as S
|
import qualified Data.Set as S
|
||||||
@@ -32,21 +31,17 @@ import qualified PostgREST.SchemaCache as SchemaCache
|
|||||||
|
|
||||||
|
|
||||||
import PostgREST.ApiRequest (ApiRequest (..))
|
import PostgREST.ApiRequest (ApiRequest (..))
|
||||||
import PostgREST.ApiRequest.Preferences (PreferCount (..),
|
import PostgREST.ApiRequest.Preferences (PreferCount (..), PreferHandling (..),
|
||||||
PreferHandling (..),
|
|
||||||
PreferMaxAffected (..),
|
PreferMaxAffected (..),
|
||||||
PreferTransaction (..),
|
PreferTransaction (..),
|
||||||
Preferences (..))
|
Preferences (..))
|
||||||
import PostgREST.ApiRequest.Types (Mutation (..))
|
import PostgREST.ApiRequest.Types (Mutation (..))
|
||||||
import PostgREST.Auth.Types (AuthResult (..))
|
import PostgREST.Auth.Types (AuthResult (..))
|
||||||
import PostgREST.Config (AppConfig (..),
|
import PostgREST.Config (AppConfig (..), OpenAPIMode (..))
|
||||||
OpenAPIMode (..))
|
|
||||||
import PostgREST.Error (Error)
|
import PostgREST.Error (Error)
|
||||||
import PostgREST.MediaType (MediaType (..))
|
import PostgREST.MediaType (MediaType (..))
|
||||||
import PostgREST.Plan (ActionPlan (..),
|
import PostgREST.Plan (ActionPlan (..), CrudPlan (..),
|
||||||
CrudPlan (..),
|
DbActionPlan (..), InfoPlan (..),
|
||||||
DbActionPlan (..),
|
|
||||||
InfoPlan (..),
|
|
||||||
InspectPlan (..))
|
InspectPlan (..))
|
||||||
import PostgREST.Query (MainQuery (..))
|
import PostgREST.Query (MainQuery (..))
|
||||||
import PostgREST.SchemaCache (SchemaCache (..))
|
import PostgREST.SchemaCache (SchemaCache (..))
|
||||||
|
|||||||
@@ -41,8 +41,7 @@ import Data.Tree (Tree (..))
|
|||||||
|
|
||||||
import PostgREST.ApiRequest (ApiRequest (..))
|
import PostgREST.ApiRequest (ApiRequest (..))
|
||||||
import PostgREST.Config (AppConfig (..))
|
import PostgREST.Config (AppConfig (..))
|
||||||
import PostgREST.Error (ApiRequestError (..),
|
import PostgREST.Error (ApiRequestError (..), Error (..),
|
||||||
Error (..),
|
|
||||||
SchemaCacheError (..))
|
SchemaCacheError (..))
|
||||||
import PostgREST.MediaType (MediaType (..))
|
import PostgREST.MediaType (MediaType (..))
|
||||||
import PostgREST.Plan.Negotiate (negotiateContent)
|
import PostgREST.Plan.Negotiate (negotiateContent)
|
||||||
@@ -52,25 +51,19 @@ import PostgREST.RangeQuery (NonnegRange, allRange,
|
|||||||
restrictRange)
|
restrictRange)
|
||||||
import PostgREST.SchemaCache (SchemaCache (..))
|
import PostgREST.SchemaCache (SchemaCache (..))
|
||||||
import PostgREST.SchemaCache.Identifiers (FieldName,
|
import PostgREST.SchemaCache.Identifiers (FieldName,
|
||||||
QualifiedIdentifier (..),
|
QualifiedIdentifier (..), Schema)
|
||||||
Schema)
|
import PostgREST.SchemaCache.Relationship (Cardinality (..), Junction (..),
|
||||||
import PostgREST.SchemaCache.Relationship (Cardinality (..),
|
|
||||||
Junction (..),
|
|
||||||
Relationship (..),
|
Relationship (..),
|
||||||
RelationshipsMap,
|
RelationshipsMap, relIsToOne)
|
||||||
relIsToOne)
|
|
||||||
import PostgREST.SchemaCache.Representations (DataRepresentation (..),
|
import PostgREST.SchemaCache.Representations (DataRepresentation (..),
|
||||||
RepresentationsMap)
|
RepresentationsMap)
|
||||||
import PostgREST.SchemaCache.Routine (MediaHandler (..),
|
import PostgREST.SchemaCache.Routine (MediaHandler (..), Routine (..),
|
||||||
Routine (..),
|
RoutineMap, RoutineParam (..),
|
||||||
RoutineMap,
|
|
||||||
RoutineParam (..),
|
|
||||||
funcReturnsScalar,
|
funcReturnsScalar,
|
||||||
funcReturnsSetOfScalar,
|
funcReturnsSetOfScalar,
|
||||||
funcReturnsSingle)
|
funcReturnsSingle)
|
||||||
import PostgREST.SchemaCache.Table (Column (..), Table (..),
|
import PostgREST.SchemaCache.Table (Column (..), Table (..),
|
||||||
TablesMap,
|
TablesMap, tableColumnsList,
|
||||||
tableColumnsList,
|
|
||||||
tablePKCols)
|
tablePKCols)
|
||||||
|
|
||||||
import PostgREST.ApiRequest.Preferences
|
import PostgREST.ApiRequest.Preferences
|
||||||
|
|||||||
@@ -6,10 +6,8 @@ where
|
|||||||
import qualified Data.ByteString.Lazy as LBS
|
import qualified Data.ByteString.Lazy as LBS
|
||||||
|
|
||||||
import PostgREST.ApiRequest.Preferences (PreferResolution)
|
import PostgREST.ApiRequest.Preferences (PreferResolution)
|
||||||
import PostgREST.Plan.Types (CoercibleField,
|
import PostgREST.Plan.Types (CoercibleField, CoercibleLogicTree)
|
||||||
CoercibleLogicTree)
|
import PostgREST.SchemaCache.Identifiers (FieldName, QualifiedIdentifier)
|
||||||
import PostgREST.SchemaCache.Identifiers (FieldName,
|
|
||||||
QualifiedIdentifier)
|
|
||||||
|
|
||||||
|
|
||||||
import Protolude
|
import Protolude
|
||||||
|
|||||||
@@ -18,8 +18,7 @@ import PostgREST.Error (ApiRequestError (..))
|
|||||||
import PostgREST.MediaType (MediaType (..))
|
import PostgREST.MediaType (MediaType (..))
|
||||||
import PostgREST.SchemaCache.Identifiers (QualifiedIdentifier (..),
|
import PostgREST.SchemaCache.Identifiers (QualifiedIdentifier (..),
|
||||||
RelIdentifier (..))
|
RelIdentifier (..))
|
||||||
import PostgREST.SchemaCache.Routine (MediaHandler (..),
|
import PostgREST.SchemaCache.Routine (MediaHandler (..), MediaHandlerMap,
|
||||||
MediaHandlerMap,
|
|
||||||
ResolvedHandler)
|
ResolvedHandler)
|
||||||
|
|
||||||
import PostgREST.ApiRequest.Preferences
|
import PostgREST.ApiRequest.Preferences
|
||||||
|
|||||||
@@ -7,16 +7,14 @@ module PostgREST.Plan.ReadPlan
|
|||||||
|
|
||||||
import Data.Tree (Tree (..))
|
import Data.Tree (Tree (..))
|
||||||
|
|
||||||
import PostgREST.ApiRequest.Types (Alias, Depth, Hint,
|
import PostgREST.ApiRequest.Types (Alias, Depth, Hint, JoinType,
|
||||||
JoinType, NodeName)
|
NodeName)
|
||||||
import PostgREST.Plan.Types (CoercibleLogicTree,
|
import PostgREST.Plan.Types (CoercibleLogicTree,
|
||||||
CoercibleOrderTerm,
|
CoercibleOrderTerm,
|
||||||
CoercibleSelectField (..),
|
CoercibleSelectField (..),
|
||||||
RelSelectField (..),
|
RelSelectField (..), SpreadType (..))
|
||||||
SpreadType (..))
|
|
||||||
import PostgREST.RangeQuery (NonnegRange)
|
import PostgREST.RangeQuery (NonnegRange)
|
||||||
import PostgREST.SchemaCache.Identifiers (FieldName,
|
import PostgREST.SchemaCache.Identifiers (FieldName, QualifiedIdentifier)
|
||||||
QualifiedIdentifier)
|
|
||||||
import PostgREST.SchemaCache.Relationship (Relationship)
|
import PostgREST.SchemaCache.Relationship (Relationship)
|
||||||
|
|
||||||
|
|
||||||
|
|||||||
@@ -13,9 +13,8 @@ module PostgREST.Plan.Types
|
|||||||
, SpreadType(..)
|
, SpreadType(..)
|
||||||
) where
|
) where
|
||||||
|
|
||||||
import PostgREST.ApiRequest.Types (AggregateFunction, Alias, Cast,
|
import PostgREST.ApiRequest.Types (AggregateFunction, Alias, Cast, Field,
|
||||||
Field, JsonPath, Language,
|
JsonPath, Language, LogicOperator, OpExpr,
|
||||||
LogicOperator, OpExpr,
|
|
||||||
OrderDirection, OrderNulls)
|
OrderDirection, OrderNulls)
|
||||||
|
|
||||||
import PostgREST.SchemaCache.Identifiers (FieldName)
|
import PostgREST.SchemaCache.Identifiers (FieldName)
|
||||||
|
|||||||
@@ -19,14 +19,11 @@ import qualified PostgREST.Query.Statements as Statements
|
|||||||
|
|
||||||
|
|
||||||
import PostgREST.ApiRequest (ApiRequest (..))
|
import PostgREST.ApiRequest (ApiRequest (..))
|
||||||
import PostgREST.ApiRequest.Preferences (Preferences (..),
|
import PostgREST.ApiRequest.Preferences (Preferences (..), shouldExplainCount)
|
||||||
shouldExplainCount)
|
|
||||||
import PostgREST.Auth.Types (AuthResult (..))
|
import PostgREST.Auth.Types (AuthResult (..))
|
||||||
import PostgREST.Config (AppConfig (..))
|
import PostgREST.Config (AppConfig (..))
|
||||||
import PostgREST.Plan (ActionPlan (..),
|
import PostgREST.Plan (ActionPlan (..), CrudPlan (..),
|
||||||
CrudPlan (..),
|
DbActionPlan (..), InspectPlan (..))
|
||||||
DbActionPlan (..),
|
|
||||||
InspectPlan (..))
|
|
||||||
import PostgREST.SchemaCache.Identifiers (QualifiedIdentifier (..))
|
import PostgREST.SchemaCache.Identifiers (QualifiedIdentifier (..))
|
||||||
|
|
||||||
import Protolude hiding (Handler)
|
import Protolude hiding (Handler)
|
||||||
|
|||||||
@@ -18,12 +18,10 @@ import qualified Hasql.DynamicStatements.Snippet as SQL hiding (sql)
|
|||||||
|
|
||||||
|
|
||||||
import PostgREST.ApiRequest (ApiRequest (..))
|
import PostgREST.ApiRequest (ApiRequest (..))
|
||||||
import PostgREST.ApiRequest.Preferences (PreferTimezone (..),
|
import PostgREST.ApiRequest.Preferences (PreferTimezone (..), Preferences (..))
|
||||||
Preferences (..))
|
|
||||||
import PostgREST.Auth.Types (AuthResult (..))
|
import PostgREST.Auth.Types (AuthResult (..))
|
||||||
import PostgREST.Config (AppConfig (..))
|
import PostgREST.Config (AppConfig (..))
|
||||||
import PostgREST.Plan (CrudPlan (..),
|
import PostgREST.Plan (CrudPlan (..), DbActionPlan (..))
|
||||||
DbActionPlan (..))
|
|
||||||
import PostgREST.Query.SqlFragment (escapeIdentList, fromQi,
|
import PostgREST.Query.SqlFragment (escapeIdentList, fromQi,
|
||||||
intercalateSnippet,
|
intercalateSnippet,
|
||||||
setConfigWithConstantName,
|
setConfigWithConstantName,
|
||||||
|
|||||||
@@ -29,8 +29,7 @@ import Data.Tree (Tree (..))
|
|||||||
|
|
||||||
import PostgREST.ApiRequest.Preferences (PreferResolution (..))
|
import PostgREST.ApiRequest.Preferences (PreferResolution (..))
|
||||||
import PostgREST.SchemaCache.Identifiers (QualifiedIdentifier (..))
|
import PostgREST.SchemaCache.Identifiers (QualifiedIdentifier (..))
|
||||||
import PostgREST.SchemaCache.Relationship (Cardinality (..),
|
import PostgREST.SchemaCache.Relationship (Cardinality (..), Junction (..),
|
||||||
Junction (..),
|
|
||||||
Relationship (..))
|
Relationship (..))
|
||||||
import PostgREST.SchemaCache.Routine (RoutineParam (..))
|
import PostgREST.SchemaCache.Routine (RoutineParam (..))
|
||||||
|
|
||||||
|
|||||||
@@ -60,20 +60,13 @@ import Control.Arrow ((***))
|
|||||||
import Data.Foldable (foldr1)
|
import Data.Foldable (foldr1)
|
||||||
import NeatInterpolation (trimming)
|
import NeatInterpolation (trimming)
|
||||||
|
|
||||||
import PostgREST.ApiRequest.Types (AggregateFunction (..),
|
import PostgREST.ApiRequest.Types (AggregateFunction (..), Alias, Cast,
|
||||||
Alias, Cast,
|
FtsOperator (..), IsVal (..),
|
||||||
FtsOperator (..),
|
JsonOperand (..), JsonOperation (..),
|
||||||
IsVal (..),
|
JsonPath, LogicOperator (..),
|
||||||
JsonOperand (..),
|
OpExpr (..), OpQuantifier (..),
|
||||||
JsonOperation (..),
|
Operation (..), OrderDirection (..),
|
||||||
JsonPath,
|
OrderNulls (..), QuantOperator (..),
|
||||||
LogicOperator (..),
|
|
||||||
OpExpr (..),
|
|
||||||
OpQuantifier (..),
|
|
||||||
Operation (..),
|
|
||||||
OrderDirection (..),
|
|
||||||
OrderNulls (..),
|
|
||||||
QuantOperator (..),
|
|
||||||
SimpleOperator (..))
|
SimpleOperator (..))
|
||||||
import PostgREST.MediaType (MTVndPlanFormat (..),
|
import PostgREST.MediaType (MTVndPlanFormat (..),
|
||||||
MTVndPlanOption (..))
|
MTVndPlanOption (..))
|
||||||
@@ -85,16 +78,13 @@ import PostgREST.Plan.Types (CoercibleField (..),
|
|||||||
CoercibleSelectField (..),
|
CoercibleSelectField (..),
|
||||||
RelSelectField (..),
|
RelSelectField (..),
|
||||||
SpreadSelectField (..),
|
SpreadSelectField (..),
|
||||||
ToTsVector (..),
|
ToTsVector (..), unknownField)
|
||||||
unknownField)
|
import PostgREST.RangeQuery (NonnegRange, allRange, rangeLimit,
|
||||||
import PostgREST.RangeQuery (NonnegRange, allRange,
|
rangeOffset)
|
||||||
rangeLimit, rangeOffset)
|
import PostgREST.SchemaCache.Identifiers (FieldName, QualifiedIdentifier (..),
|
||||||
import PostgREST.SchemaCache.Identifiers (FieldName,
|
RelIdentifier (..), escapeIdent,
|
||||||
QualifiedIdentifier (..),
|
trimNullChars)
|
||||||
RelIdentifier (..),
|
import PostgREST.SchemaCache.Routine (MediaHandler (..), Routine (..),
|
||||||
escapeIdent, trimNullChars)
|
|
||||||
import PostgREST.SchemaCache.Routine (MediaHandler (..),
|
|
||||||
Routine (..),
|
|
||||||
funcReturnsScalar,
|
funcReturnsScalar,
|
||||||
funcReturnsSetOfScalar,
|
funcReturnsSetOfScalar,
|
||||||
funcReturnsSingle,
|
funcReturnsSingle,
|
||||||
|
|||||||
@@ -13,8 +13,7 @@ module PostgREST.Query.Statements
|
|||||||
import qualified Hasql.DynamicStatements.Snippet as SQL
|
import qualified Hasql.DynamicStatements.Snippet as SQL
|
||||||
|
|
||||||
import PostgREST.ApiRequest.Preferences
|
import PostgREST.ApiRequest.Preferences
|
||||||
import PostgREST.MediaType (MTVndPlanFormat (..),
|
import PostgREST.MediaType (MTVndPlanFormat (..), MediaType (..))
|
||||||
MediaType (..))
|
|
||||||
import PostgREST.Plan.CallPlan
|
import PostgREST.Plan.CallPlan
|
||||||
import PostgREST.Plan.MutatePlan as MTPlan
|
import PostgREST.Plan.MutatePlan as MTPlan
|
||||||
import PostgREST.Plan.ReadPlan
|
import PostgREST.Plan.ReadPlan
|
||||||
|
|||||||
@@ -27,26 +27,20 @@ import qualified PostgREST.Response.OpenAPI as OpenAPI
|
|||||||
import PostgREST.ApiRequest (ApiRequest (..))
|
import PostgREST.ApiRequest (ApiRequest (..))
|
||||||
import PostgREST.ApiRequest.Preferences (PreferRepresentation (..),
|
import PostgREST.ApiRequest.Preferences (PreferRepresentation (..),
|
||||||
PreferResolution (..),
|
PreferResolution (..),
|
||||||
Preferences (..),
|
Preferences (..), prefAppliedHeader,
|
||||||
prefAppliedHeader,
|
|
||||||
shouldCount)
|
shouldCount)
|
||||||
import PostgREST.ApiRequest.QueryParams (QueryParams (..))
|
import PostgREST.ApiRequest.QueryParams (QueryParams (..))
|
||||||
import PostgREST.ApiRequest.Types (InvokeMethod (..),
|
import PostgREST.ApiRequest.Types (InvokeMethod (..), Mutation (..))
|
||||||
Mutation (..))
|
|
||||||
import PostgREST.Config (AppConfig (..))
|
import PostgREST.Config (AppConfig (..))
|
||||||
import PostgREST.MainTx (DbResult (..),
|
import PostgREST.MainTx (DbResult (..), ResultSet (..))
|
||||||
ResultSet (..))
|
|
||||||
import PostgREST.MediaType (MediaType (..))
|
import PostgREST.MediaType (MediaType (..))
|
||||||
import PostgREST.Plan (CrudPlan (..),
|
import PostgREST.Plan (CrudPlan (..), InfoPlan (..),
|
||||||
InfoPlan (..),
|
|
||||||
InspectPlan (..))
|
InspectPlan (..))
|
||||||
import PostgREST.Plan.MutatePlan (MutatePlan (..))
|
import PostgREST.Plan.MutatePlan (MutatePlan (..))
|
||||||
import PostgREST.Response.GucHeader (GucHeader, unwrapGucHeader)
|
import PostgREST.Response.GucHeader (GucHeader, unwrapGucHeader)
|
||||||
import PostgREST.SchemaCache (SchemaCache (..))
|
import PostgREST.SchemaCache (SchemaCache (..))
|
||||||
import PostgREST.SchemaCache.Identifiers (QualifiedIdentifier (..),
|
import PostgREST.SchemaCache.Identifiers (QualifiedIdentifier (..), Schema)
|
||||||
Schema)
|
import PostgREST.SchemaCache.Routine (FuncVolatility (..), Routine (..))
|
||||||
import PostgREST.SchemaCache.Routine (FuncVolatility (..),
|
|
||||||
Routine (..))
|
|
||||||
import PostgREST.SchemaCache.Table (Table (..))
|
import PostgREST.SchemaCache.Table (Table (..))
|
||||||
|
|
||||||
import qualified PostgREST.SchemaCache.Routine as Routine
|
import qualified PostgREST.SchemaCache.Routine as Routine
|
||||||
|
|||||||
@@ -29,14 +29,11 @@ import PostgREST.MediaType
|
|||||||
import PostgREST.Network (escapeHostName)
|
import PostgREST.Network (escapeHostName)
|
||||||
import PostgREST.SchemaCache (SchemaCache (..))
|
import PostgREST.SchemaCache (SchemaCache (..))
|
||||||
import PostgREST.SchemaCache.Identifiers (QualifiedIdentifier (..))
|
import PostgREST.SchemaCache.Identifiers (QualifiedIdentifier (..))
|
||||||
import PostgREST.SchemaCache.Relationship (Cardinality (..),
|
import PostgREST.SchemaCache.Relationship (Cardinality (..), Relationship (..),
|
||||||
Relationship (..),
|
|
||||||
RelationshipsMap)
|
RelationshipsMap)
|
||||||
import PostgREST.SchemaCache.Routine (FuncVolatility (..),
|
import PostgREST.SchemaCache.Routine (FuncVolatility (..), Routine (..),
|
||||||
Routine (..),
|
|
||||||
RoutineParam (..))
|
RoutineParam (..))
|
||||||
import PostgREST.SchemaCache.Table (Column (..), Table (..),
|
import PostgREST.SchemaCache.Table (Column (..), Table (..), TablesMap,
|
||||||
TablesMap,
|
|
||||||
tableColumnsList)
|
tableColumnsList)
|
||||||
|
|
||||||
import Protolude hiding (Proxy, get)
|
import Protolude hiding (Proxy, get)
|
||||||
|
|||||||
@@ -44,29 +44,22 @@ import qualified Hasql.Transaction as SQL
|
|||||||
import Data.Functor.Contravariant ((>$<))
|
import Data.Functor.Contravariant ((>$<))
|
||||||
import NeatInterpolation (trimming)
|
import NeatInterpolation (trimming)
|
||||||
|
|
||||||
import PostgREST.Config (AppConfig (..),
|
import PostgREST.Config (AppConfig (..), LogLevel (..))
|
||||||
LogLevel (..))
|
import PostgREST.Config.Database (TimezoneNames, toIsolationLevel)
|
||||||
import PostgREST.Config.Database (TimezoneNames,
|
|
||||||
toIsolationLevel)
|
|
||||||
import PostgREST.SchemaCache.Identifiers (FieldName,
|
import PostgREST.SchemaCache.Identifiers (FieldName,
|
||||||
QualifiedIdentifier (..),
|
QualifiedIdentifier (..),
|
||||||
RelIdentifier (..),
|
RelIdentifier (..), Schema,
|
||||||
Schema, escapeIdent,
|
escapeIdent, isAnyElement)
|
||||||
isAnyElement)
|
import PostgREST.SchemaCache.Relationship (Cardinality (..), Junction (..),
|
||||||
import PostgREST.SchemaCache.Relationship (Cardinality (..),
|
|
||||||
Junction (..),
|
|
||||||
Relationship (..),
|
Relationship (..),
|
||||||
RelationshipsMap)
|
RelationshipsMap)
|
||||||
import PostgREST.SchemaCache.Representations (DataRepresentation (..),
|
import PostgREST.SchemaCache.Representations (DataRepresentation (..),
|
||||||
RepresentationsMap)
|
RepresentationsMap)
|
||||||
import PostgREST.SchemaCache.Routine (FuncVolatility (..),
|
import PostgREST.SchemaCache.Routine (FuncVolatility (..),
|
||||||
MediaHandler (..),
|
MediaHandler (..),
|
||||||
MediaHandlerMap,
|
MediaHandlerMap, PgType (..),
|
||||||
PgType (..),
|
RetType (..), Routine (..),
|
||||||
RetType (..),
|
RoutineMap, RoutineParam (..))
|
||||||
Routine (..),
|
|
||||||
RoutineMap,
|
|
||||||
RoutineParam (..))
|
|
||||||
import PostgREST.SchemaCache.Table (Column (..), ColumnMap,
|
import PostgREST.SchemaCache.Table (Column (..), ColumnMap,
|
||||||
Table (..), TablesMap)
|
Table (..), TablesMap)
|
||||||
|
|
||||||
|
|||||||
@@ -12,8 +12,8 @@ module PostgREST.SchemaCache.Relationship
|
|||||||
import qualified Data.Aeson as JSON
|
import qualified Data.Aeson as JSON
|
||||||
import qualified Data.HashMap.Strict as HM
|
import qualified Data.HashMap.Strict as HM
|
||||||
|
|
||||||
import PostgREST.SchemaCache.Identifiers (FieldName,
|
import PostgREST.SchemaCache.Identifiers (FieldName, QualifiedIdentifier,
|
||||||
QualifiedIdentifier, Schema)
|
Schema)
|
||||||
|
|
||||||
import Protolude
|
import Protolude
|
||||||
|
|
||||||
|
|||||||
@@ -28,8 +28,7 @@ import qualified Hasql.Transaction.Sessions as SQL
|
|||||||
import qualified PostgREST.MediaType as MediaType
|
import qualified PostgREST.MediaType as MediaType
|
||||||
|
|
||||||
import PostgREST.SchemaCache.Identifiers (QualifiedIdentifier (..),
|
import PostgREST.SchemaCache.Identifiers (QualifiedIdentifier (..),
|
||||||
RelIdentifier (..), Schema,
|
RelIdentifier (..), Schema, TableName)
|
||||||
TableName)
|
|
||||||
|
|
||||||
import Protolude
|
import Protolude
|
||||||
|
|
||||||
|
|||||||
@@ -14,8 +14,7 @@ import qualified Data.Aeson as JSON
|
|||||||
import qualified Data.HashMap.Strict as HM
|
import qualified Data.HashMap.Strict as HM
|
||||||
import qualified Data.HashMap.Strict.InsOrd as HMI
|
import qualified Data.HashMap.Strict.InsOrd as HMI
|
||||||
|
|
||||||
import PostgREST.SchemaCache.Identifiers (FieldName,
|
import PostgREST.SchemaCache.Identifiers (FieldName, QualifiedIdentifier (..),
|
||||||
QualifiedIdentifier (..),
|
|
||||||
Schema, TableName)
|
Schema, TableName)
|
||||||
|
|
||||||
import Protolude
|
import Protolude
|
||||||
|
|||||||
@@ -23,8 +23,7 @@ import qualified Jose.Jws as JWT
|
|||||||
import qualified Jose.Jwt as JWT
|
import qualified Jose.Jwt as JWT
|
||||||
import Network.HTTP.Types
|
import Network.HTTP.Types
|
||||||
import qualified PostgREST.AppState as AppState
|
import qualified PostgREST.AppState as AppState
|
||||||
import PostgREST.Config (AppConfig (..),
|
import PostgREST.Config (AppConfig (..), LogLevel (..),
|
||||||
LogLevel (..),
|
|
||||||
OpenAPIMode (..),
|
OpenAPIMode (..),
|
||||||
Verbosity (..),
|
Verbosity (..),
|
||||||
defaultRoleJSPathKey,
|
defaultRoleJSPathKey,
|
||||||
|
|||||||
@@ -12,8 +12,7 @@ import Network.Wai (Application)
|
|||||||
import ObsHelper
|
import ObsHelper
|
||||||
import qualified PostgREST.AppState as AppState
|
import qualified PostgREST.AppState as AppState
|
||||||
import PostgREST.Config (AppConfig (configDbSchemas))
|
import PostgREST.Config (AppConfig (configDbSchemas))
|
||||||
import PostgREST.Metrics (ConnStats (..),
|
import PostgREST.Metrics (ConnStats (..), MetricsState (..),
|
||||||
MetricsState (..),
|
|
||||||
connectionCounts)
|
connectionCounts)
|
||||||
import PostgREST.Observation
|
import PostgREST.Observation
|
||||||
import Prometheus (getCounter, getVectorWith)
|
import Prometheus (getCounter, getVectorWith)
|
||||||
|
|||||||
+1
-2
@@ -9,8 +9,7 @@ import Data.Function (id)
|
|||||||
import Test.Hspec
|
import Test.Hspec
|
||||||
|
|
||||||
import PostgREST.App (postgrest)
|
import PostgREST.App (postgrest)
|
||||||
import PostgREST.Config (AppConfig (..),
|
import PostgREST.Config (AppConfig (..), toConnectionSettings)
|
||||||
toConnectionSettings)
|
|
||||||
import PostgREST.Config.Database (queryPgVersion)
|
import PostgREST.Config.Database (queryPgVersion)
|
||||||
import PostgREST.SchemaCache (querySchemaCache)
|
import PostgREST.SchemaCache (querySchemaCache)
|
||||||
import Protolude hiding (toList, toS)
|
import Protolude hiding (toList, toS)
|
||||||
|
|||||||
@@ -24,12 +24,9 @@ import Network.Wai.Test (SResponse (simpleBody, simpleHeaders, simpleStatus
|
|||||||
import System.IO.Unsafe (unsafePerformIO)
|
import System.IO.Unsafe (unsafePerformIO)
|
||||||
import Text.Regex.TDFA ((=~))
|
import Text.Regex.TDFA ((=~))
|
||||||
|
|
||||||
import PostgREST.Config (AppConfig (..),
|
import PostgREST.Config (AppConfig (..), LogLevel (..),
|
||||||
LogLevel (..),
|
OpenAPIMode (..), Verbosity (..),
|
||||||
OpenAPIMode (..),
|
defaultRoleJSPathKey, parseSecret)
|
||||||
Verbosity (..),
|
|
||||||
defaultRoleJSPathKey,
|
|
||||||
parseSecret)
|
|
||||||
import PostgREST.SchemaCache.Identifiers (QualifiedIdentifier (..))
|
import PostgREST.SchemaCache.Identifiers (QualifiedIdentifier (..))
|
||||||
|
|
||||||
import Data.Aeson.Lens
|
import Data.Aeson.Lens
|
||||||
|
|||||||
Reference in New Issue
Block a user