FreeBSD Bugzilla – Attachment 225058 Details for
Bug 255969
www/hs-postgrest: Added an option for support database connection poolers and small cleanup
Home
|
New
|
Browse
|
Search
|
[?]
|
Reports
|
Help
|
New Account
|
Log In
Remember
[x]
|
Forgot Password
Login:
[x]
[patch]
hs-postgrest.diff
hs-postgrest.diff (text/plain), 3.78 KB, created by
Dmitry Wagin
on 2021-05-18 09:38:56 UTC
(
hide
)
Description:
hs-postgrest.diff
Filename:
MIME Type:
Creator:
Dmitry Wagin
Created:
2021-05-18 09:38:56 UTC
Size:
3.78 KB
patch
obsolete
>diff --git a/www/hs-postgrest/Makefile b/www/hs-postgrest/Makefile >index d61a89e1d6a8..1c14fbc9573a 100644 >--- a/www/hs-postgrest/Makefile >+++ b/www/hs-postgrest/Makefile >@@ -1,6 +1,6 @@ > PORTNAME= postgrest > PORTVERSION= 7.0.1 >-PORTREVISION= 3 >+PORTREVISION= 4 > CATEGORIES= www databases haskell > > MAINTAINER= dmitry.wagin@ya.ru >@@ -14,6 +14,7 @@ ONLY_FOR_ARCHS= amd64 i386 > BUILD_DEPENDS= pg_config:databases/postgresql${PGSQL_DEFAULT}-client > > USES= cabal pgsql >+USE_RC_SUBR= postgrest > > USE_CABAL= HTTP-4000.3.14_1 \ > HUnit-1.6.0.0 \ >@@ -82,6 +83,7 @@ USE_CABAL= HTTP-4000.3.14_1 \ > free-5.1.3 \ > generics-sop-0.5.1.0 \ > gitrev-1.3.1 \ >+ happy-1.19.12 \ > hashable-1.3.0.0_1 \ > hashtables-1.2.3.4 \ > haskell-src-exts-1.23.0 \ >@@ -91,6 +93,7 @@ USE_CABAL= HTTP-4000.3.14_1 \ > hasql-transaction-1.0.0.1 \ > heredoc-0.2.0.0 \ > hourglass-0.2.12 \ >+ hsc2hs-0.68.7 \ > http-date-0.0.8 \ > http-media-0.8.0.0_3 \ > http-types-0.12.3 \ >@@ -191,29 +194,33 @@ USE_CABAL= HTTP-4000.3.14_1 \ > warp-3.3.11 \ > word8-0.1.3 \ > x509-1.7.5_1 \ >- zlib-0.6.2.1_1 \ >- \ >- happy-1.19.12 \ >- hsc2hs-0.68.7 >+ zlib-0.6.2.1_1 >+ >+SKIP_CABAL_PLIST= yes > > POSTGREST_USER?= postgrest > POSTGREST_GROUP?= postgrest > >+SUB_FILES= default.conf >+SUB_LIST= ETCDIR=${ETCDIR} \ >+ POSTGREST_GROUP=${POSTGREST_GROUP} \ >+ POSTGREST_USER=${POSTGREST_USER} >+ > USERS= ${POSTGREST_USER} > GROUPS= ${POSTGREST_GROUP} > >-SUB_FILES= default.conf >-SUB_LIST= ETCDIR=${ETCDIR} \ >- POSTGREST_USER=${POSTGREST_USER} \ >- POSTGREST_GROUP=${POSTGREST_GROUP} >+PLIST_FILES= "@sample ${ETCDIR}/default.conf.sample" \ >+ sbin/postgrest > > PLIST_SUB= ETCDIR=${ETCDIR} \ >- POSTGREST_USER=${POSTGREST_USER} \ >- POSTGREST_GROUP=${POSTGREST_GROUP} >+ POSTGREST_GROUP=${POSTGREST_GROUP} \ >+ POSTGREST_USER=${POSTGREST_USER} > >-USE_RC_SUBR= postgrest >+OPTIONS_DEFINE= POOLER >+OPTIONS_DEFAULT= POOLER > >-SKIP_CABAL_PLIST= yes >+POOLER_DESC= Connection pooler support (disable usage of prepared statements) >+POOLER_EXTRA_PATCHES= ${PATCHDIR}/extra-patch-hasql-1.4.2_library_Hasql_Private_IO.hs > > do-install: > @${MKDIR} ${STAGEDIR}${ETCDIR} >diff --git a/www/hs-postgrest/files/extra-patch-hasql-1.4.2_library_Hasql_Private_IO.hs b/www/hs-postgrest/files/extra-patch-hasql-1.4.2_library_Hasql_Private_IO.hs >new file mode 100644 >index 000000000000..3a05edf13ee1 >--- /dev/null >+++ b/www/hs-postgrest/files/extra-patch-hasql-1.4.2_library_Hasql_Private_IO.hs >@@ -0,0 +1,13 @@ >+--- hasql-1.4.2/library/Hasql/Private/IO.hs.orig 2020-03-21 17:55:07 UTC >++++ hasql-1.4.2/library/Hasql/Private/IO.hs >+@@ -157,9 +157,7 @@ sendParametricStatement :: >+ IO (Either CommandError ()) >+ sendParametricStatement connection integerDatetimes registry template encoder prepared params = >+ {-# SCC "sendParametricStatement" #-} >+- if prepared >+- then sendPreparedParametricStatement connection registry integerDatetimes template encoder params >+- else sendUnpreparedParametricStatement connection integerDatetimes template encoder params >++ sendUnpreparedParametricStatement connection integerDatetimes template encoder params >+ >+ {-# INLINE sendNonparametricStatement #-} >+ sendNonparametricStatement :: LibPQ.Connection -> ByteString -> IO (Either CommandError ()) >diff --git a/www/hs-postgrest/files/postgrest.in b/www/hs-postgrest/files/postgrest.in >index 7dac382dd80a..7ad89ce8615a 100644 >--- a/www/hs-postgrest/files/postgrest.in >+++ b/www/hs-postgrest/files/postgrest.in >@@ -2,6 +2,7 @@ > > # PROVIDE: postgrest > # REQUIRE: LOGIN >+# BEFORE: nginx > # KEYWORD: shutdown > # > # Add postgrest_enable="YES" to /etc/rc.conf to enable PostgREST: >diff --git a/www/hs-postgrest/pkg-plist b/www/hs-postgrest/pkg-plist >deleted file mode 100644 >index 57a62545511d..000000000000 >--- a/www/hs-postgrest/pkg-plist >+++ /dev/null >@@ -1,2 +0,0 @@ >-sbin/postgrest >-@sample %%ETCDIR%%/default.conf.sample
You cannot view the attachment while viewing its details because your browser does not support IFRAMEs.
View the attachment on a separate page
.
View Attachment As Diff
View Attachment As Raw
Flags:
dmitry.wagin
:
maintainer-approval+
Actions:
View
|
Diff
Attachments on
bug 255969
:
225058
|
225498