Re: coverage increase for worker_spi

2019-06-01 Thread Alvaro Herrera
On 2019-Jun-01, Tom Lane wrote: > Alvaro Herrera writes: > > I ended up with these two patches. I'm not sure about pushing > > separately. It seems pointless to backport the "fix" to back branches > > anyway. > > Patch passes the eyeball test, though I did not try to run it. > I concur with

Re: coverage increase for worker_spi

2019-06-01 Thread Tom Lane
Alvaro Herrera writes: > I ended up with these two patches. I'm not sure about pushing > separately. It seems pointless to backport the "fix" to back branches > anyway. Patch passes the eyeball test, though I did not try to run it. I concur with squashing into one commit and applying to HEAD

Re: coverage increase for worker_spi

2019-05-31 Thread Alvaro Herrera
On 2019-May-30, Alvaro Herrera wrote: > One thing I noticed while writing it, though, is that worker_spi uses > the postgres database, instead of the contrib_regression database that > was created for it. And we create a schema and a table there. This is > going to get some eyebrows raised, I

Re: coverage increase for worker_spi

2019-05-30 Thread Tom Lane
Alvaro Herrera writes: > On 2019-May-30, Tom Lane wrote: >> Hm, I don't understand how this works at all: >> >> +PERFORM pg_sleep(CASE WHEN count(*) = 0 THEN 0 ELSE 0.1 >> END) >> +FROM schema1.counted WHERE type = 'delta'; >> +GET

Re: coverage increase for worker_spi

2019-05-30 Thread Alvaro Herrera
On 2019-May-30, Tom Lane wrote: > Alvaro Herrera writes: > > On 2019-May-29, Tom Lane wrote: > >> I'm not opposed to adding a new test case at this point in the cycle, > >> but as written this one seems more or less guaranteed to fail under > >> load. > > > True. Here's a version that should

Re: coverage increase for worker_spi

2019-05-30 Thread Tom Lane
Alvaro Herrera writes: > On 2019-May-29, Tom Lane wrote: >> I'm not opposed to adding a new test case at this point in the cycle, >> but as written this one seems more or less guaranteed to fail under >> load. > True. Here's a version that should be more resilient. Hm, I don't understand how

Re: coverage increase for worker_spi

2019-05-30 Thread Alvaro Herrera
On 2019-May-29, Tom Lane wrote: > Alvaro Herrera writes: > > Tom pointed out that coverage for worker_spi is 0%. For a module that > > only exists to provide coverage, that's pretty stupid. This patch > > increases coverage to 90.9% line-wise and 100% function-wise, which > > seems like a

Re: coverage increase for worker_spi

2019-05-29 Thread Tom Lane
Alvaro Herrera writes: > Tom pointed out that coverage for worker_spi is 0%. For a module that > only exists to provide coverage, that's pretty stupid. This patch > increases coverage to 90.9% line-wise and 100% function-wise, which > seems like a sufficient starting point. > How would people

coverage increase for worker_spi

2019-05-29 Thread Alvaro Herrera
Tom pointed out that coverage for worker_spi is 0%. For a module that only exists to provide coverage, that's pretty stupid. This patch increases coverage to 90.9% line-wise and 100% function-wise, which seems like a sufficient starting point. How would people feel about me getting this in