> Thanks. Can you please have a look at what I suggested down toward the > bottom of > http://postgr.es/m/ca+tgmoap2wefsktmcgwt9lxuz7y99hnduyshpk7qnfuqb98...@mail.gmail.com ?
Implemented the above approach and verified the patch. Kindly have a look and share your thoughts. Thanks & Regards, Nitin Jadhav On Fri, Jul 30, 2021 at 10:40 AM Nitin Jadhav <nitinjadhavpostg...@gmail.com> wrote: > > > Thanks. Can you please have a look at what I suggested down toward the > > bottom of > > http://postgr.es/m/ca+tgmoap2wefsktmcgwt9lxuz7y99hnduyshpk7qnfuqb98...@mail.gmail.com > > ? > > > > If we're going to go the route of combining the functions, I agree > > that a Boolean is the way to go; I think we have some existing > > precedent for 'bool finished' rather than 'bool done'. > > > > But I kind of wonder if we should have an enum in the first place. It > > feels like we've got code in a bunch of places that just exists to > > decide which enum value to use, and then code someplace else that > > turns around and decides which message to produce. That would be > > sensible if we were using the same enum values in lots of places, but > > that's not the case here. So suppose we just moved the messages to the > > places where we're now calling LogStartupProgress() or > > LogStartupProgressComplete()? So something like this: > > Sorry. I thought it is related to the discussion of deciding whether > LogStartupProgress() and LogStartupProgressComplete() should be > combined or not. I feel it's a really nice design. With this we avoid > a "action at a distance" issue and its easy to use. If we are > reporting the same kind of msgs at multiple places then the current > approach of using enum will be more suitable since we don't have to > worry about matching the log msg string. But in the current scenario, > we are not using the same kind of msgs at multiple places (I feel such > scenario will not occur in future also. Even if there is similar > operation, it can be distinguished like resetting unlogged relations > is distinguished by init and clean. Kindly mention if you can oversee > any such scenario), hence the approach you are suggesting will be a > best suit. > > Thanks & Regards, > Nitin Jadhav > > On Thu, Jul 29, 2021 at 9:48 PM Robert Haas <robertmh...@gmail.com> wrote: > > > > On Thu, Jul 29, 2021 at 4:56 AM Nitin Jadhav > > <nitinjadhavpostg...@gmail.com> wrote: > > > Thanks for sharing the information. I have done the necessary changes > > > to show the logs during the latter case (postgres --single) and > > > verified the log messages. > > > > Thanks. Can you please have a look at what I suggested down toward the > > bottom of > > http://postgr.es/m/ca+tgmoap2wefsktmcgwt9lxuz7y99hnduyshpk7qnfuqb98...@mail.gmail.com > > ? > > > > -- > > Robert Haas > > EDB: http://www.enterprisedb.com
v9-0001-startup-process-progress.patch
Description: Binary data