diff --git a/src/backend/commands/async.c b/src/backend/commands/async.c new file mode 100644 index 6fcd909..3c14ddc *** a/src/backend/commands/async.c --- b/src/backend/commands/async.c *************** *** 134,139 **** --- 134,141 ---- #include "utils/ps_status.h" #include "utils/timestamp.h" + int JJNOTDUP=0; + /* * Maximum size of a NOTIFY payload, including terminating NULL. This *************** AsyncExistsPendingNotify(const char *cha *** 2168,2174 **** ListCell *p; Notification *n; ! if (pendingNotifies == NIL) return false; if (payload == NULL) --- 2170,2176 ---- ListCell *p; Notification *n; ! if (pendingNotifies == NIL || JJNOTDUP) return false; if (payload == NULL) diff --git a/src/backend/utils/misc/guc.c b/src/backend/utils/misc/guc.c new file mode 100644 index ceca0d5..183085d *** a/src/backend/utils/misc/guc.c --- b/src/backend/utils/misc/guc.c *************** *** 125,130 **** --- 125,133 ---- #define S_PER_D (60 * 60 * 24) #define MS_PER_D (1000 * 60 * 60 * 24) + + extern int JJNOTDUP; + /* XXX these should appear in other modules' header files */ extern bool Log_disconnections; extern int CommitDelay; *************** static struct config_bool ConfigureNames *** 1459,1464 **** --- 1462,1476 ---- static struct config_int ConfigureNamesInt[] = { { + {"JJNOTDUP", PGC_USERSET, RESOURCES_ASYNCHRONOUS, + gettext_noop("Do not remove duplicates for NOTIFY queue"), + NULL + }, + &JJNOTDUP, + 0, 0, INT_MAX, + NULL, NULL, NULL + }, + { {"archive_timeout", PGC_SIGHUP, WAL_ARCHIVING, gettext_noop("Forces a switch to the next xlog file if a " "new file has not been started within N seconds."),