[Question] v5 PgNoticeMessagesPlugin, am I on the right track?
Hi Benjie,

On my v4 deployment I rely on the `opertaions-hook` plugin for several use-cases, one of them is the PgNoticeMessages.
My understanding is that this wasn't ported to v5 yet, so I figured I'd tackle at least the PgNoticeMessages part.
I followed https://github.com/graphile/operation-hooks/blob/main/src/PgNoticeMessagesPlugin.ts and here's what I have so far:

```ts
export const PgMessagesPlugin: GraphileConfig.Plugin = {
  name: 'PgMessagesPlugin',
  description: 'Extract postgres RAISE NOTICE messages',
  version: '0.0.1',

  grafast: {
    middleware: {
      execute(next, event) {
        const ctx = event.args.contextValue as {
          pgSettings: object
          withPgClient: (
            settings: object,
            cb: (args: { rawClient: Client }) => void
          ) => Promise<void>
        }
        const noticeCallback = (notice: NoticeMessage) => {
          console.debug(`PgMessagesPlugin notice: ${JSON.stringify(notice)}`)
        }
        return ctx
          .withPgClient(ctx.pgSettings, (args: { rawClient: Client }) => {
            assert(!('processNotice' in args.rawClient))
            args.rawClient['processNotice'] = noticeCallback
            args.rawClient.on('notice', noticeCallback)
          })
          .then(() => {
            return Promise.resolve(next()).then((v) => {
              ctx.withPgClient(
                ctx.pgSettings,
                (args: { rawClient: Client }) => {
                  args.rawClient.removeListener('notice', noticeCallback)
                  delete args.rawClient['processNotice']
                }
              )
              return v
            })
          })
      },
    },
  },
}
```

Apart for the type hackiness, it seems to work. But I wanted to double check before continuing down this path:

1. Am I on the right track?
2. Is there a better way to extract the type of `withPgClient`?
3. My next step would be to extract the data, and I assume I should add it to `event.args.contextValue`, sounds right? That'll let me access the data further down the line.
4. I'm assuming that this needs to be the very last plugin in my `graphile.config` to make sure any other plugin can read that context, correct?
5. My other next step would be to create a plugin to extract the data from the context to the mutations. The most appropriate one would be makeExtendSchemaPlugin, correct?

P.S. if this all goes well I'd be happy to  open source it, let me know if that would be best done as a PR to this repo.
