Bug 241116 - net/asterisk16: fix cdr_pgsql for PostgreSQL 12
Summary: net/asterisk16: fix cdr_pgsql for PostgreSQL 12
Status: Closed FIXED
Alias: None
Product: Ports & Packages
Classification: Unclassified
Component: Individual Port(s) (show other bugs)
Version: Latest
Hardware: Any Any
: --- Affects Only Me
Assignee: Guido Falsi
URL: https://issues.asterisk.org/jira/brow...
Keywords: easy, patch, patch-ready
Depends on:
Blocks:
 
Reported: 2019-10-07 14:31 UTC by Christoph Moench-Tegeder
Modified: 2019-10-09 18:02 UTC (History)
0 users

See Also:
madpilot: maintainer-feedback+
madpilot: merge-quarterly+


Attachments
fix cdr_pgsql to work with all modern PostgreSQL versions (>8.0) (1.54 KB, patch)
2019-10-07 14:31 UTC, Christoph Moench-Tegeder
no flags Details | Diff

Note You need to log in before you can comment on or make changes to this bug.
Description Christoph Moench-Tegeder freebsd_committer freebsd_triage 2019-10-07 14:31:04 UTC
Created attachment 208153 [details]
fix cdr_pgsql to work with all modern PostgreSQL versions (>8.0)

The SQL statement for discovering the cdr table tries to access a column which has been obsolteted for a long time and was removed in PostgreSQL 12 (see upstream bug for full discussion).

Attached patch (to be dropped in files/) makes sure cdr_pgsql works with all supported (and much more) versions of PostgreSQL. It should work with net/asterisk13 as well (I'm not filing another, redundant PR for that).
Comment 1 Guido Falsi freebsd_committer freebsd_triage 2019-10-07 14:48:52 UTC
Hi,

Thanks for the patch.

I'll test it and add it to the port.

BTW this patch should be sent upstream so it can be included in the official asterisk sources.

Do you allow me to report your name and email as the original source for the patch upstream?
Comment 2 Christoph Moench-Tegeder freebsd_committer freebsd_triage 2019-10-07 14:54:03 UTC
I've already reported this upstream, including patch (despite all their efforts to deter reporters...) - see "URL" link (ASTERISK-28571)
Comment 3 Guido Falsi freebsd_committer freebsd_triage 2019-10-07 15:10:36 UTC
(In reply to Christoph Moench-Tegeder from comment #2)

> I've already reported this upstream, including patch 
> (despite all their efforts to deter reporters...)
> - see "URL" link (ASTERISK-28571)

Yes, getting patches into their systems is not straightforward, I agree.

Since patches sent though their ticketing system are really slow in getting into their tree and I've already proposed a few code reviews in their gerrit thing, I'll make your patch into a proper code review so it can proceed there. (will do this later since it requires a little time to do properly)

Thanks!
Comment 4 Christoph Moench-Tegeder freebsd_committer freebsd_triage 2019-10-08 19:34:07 UTC
(In reply to Guido Falsi from comment #3)
I think I got that gerrit covered now.
Comment 5 commit-hook freebsd_committer freebsd_triage 2019-10-09 14:28:31 UTC
A commit references this bug:

Author: madpilot
Date: Wed Oct  9 14:27:31 UTC 2019
New revision: 514158
URL: https://svnweb.freebsd.org/changeset/ports/514158

Log:
  Fix CDR with PostgreSQL 12

  PR:		241116
  Submitted by:	cmt
  MFH:		2019Q4

Changes:
  head/net/asterisk13/Makefile
  head/net/asterisk13/files/patch-cdr_cdr__pgsql.c
Comment 6 commit-hook freebsd_committer freebsd_triage 2019-10-09 14:28:32 UTC
A commit references this bug:

Author: madpilot
Date: Wed Oct  9 14:27:52 UTC 2019
New revision: 514159
URL: https://svnweb.freebsd.org/changeset/ports/514159

Log:
  Fix CDR with PostgreSQL 12

  PR:		241116
  Submitted by:	cmt
  MFH:		2019Q4

Changes:
  head/net/asterisk16/Makefile
  head/net/asterisk16/files/patch-cdr_cdr__pgsql.c
Comment 7 Guido Falsi freebsd_committer freebsd_triage 2019-10-09 14:36:27 UTC
I added your patch to the port, and will also merge it to quarterly.

Will close this bug report once merged.

Thanks!
Comment 8 commit-hook freebsd_committer freebsd_triage 2019-10-09 17:45:57 UTC
A commit references this bug:

Author: madpilot
Date: Wed Oct  9 17:45:43 UTC 2019
New revision: 514176
URL: https://svnweb.freebsd.org/changeset/ports/514176

Log:
  MFH: r514158 r514160

  Fix CDR with PostgreSQL 12

  PR:		241116
  Submitted by:	cmt

  Fix typo.

  Approved by:	ports-secteam (miwi)

Changes:
_U  branches/2019Q4/
  branches/2019Q4/net/asterisk13/Makefile
  branches/2019Q4/net/asterisk13/files/patch-cdr_cdr__pgsql.c
Comment 9 commit-hook freebsd_committer freebsd_triage 2019-10-09 17:47:58 UTC
A commit references this bug:

Author: madpilot
Date: Wed Oct  9 17:46:57 UTC 2019
New revision: 514177
URL: https://svnweb.freebsd.org/changeset/ports/514177

Log:
  MFH: r514159

  Fix CDR with PostgreSQL 12

  PR:		241116
  Submitted by:	cmt

  Approved by:	ports-secteam (miwi)

Changes:
_U  branches/2019Q4/
  branches/2019Q4/net/asterisk16/Makefile
  branches/2019Q4/net/asterisk16/files/patch-cdr_cdr__pgsql.c
Comment 10 Guido Falsi freebsd_committer freebsd_triage 2019-10-09 18:02:31 UTC
Merged. Thanks!