Thread

Commits

  1. Rename EVT cache hash to make context name unique

  1. evtcache: EventTriggerCache vs Event Trigger Cache

    Daniel Gustafsson <daniel@yesql.se> — 2023-05-04T11:38:26Z

    When reading a memory contexts log I realized that we have this:
    
    LOG:  level: 2; EventTriggerCache: 8192 total in 1 blocks; 7928 free (4 chunks); 264 used
    LOG:  level: 3; Event Trigger Cache: 8192 total in 1 blocks; 2616 free (0 chunks); 5576 used
    
    The reason is that BuildEventTriggerCache sets up a context "EventTriggerCache"
    which house a hash named "Event Trigger Cache" which in turn creates a context
    with the table name.  I think it makes sense that these share the same name,
    but I think it would be less confusing if they also shared the same spelling
    whitespace-wise.  Any reason to not rename the hash EventTriggerCache to make
    the logging a tiny bit easier to read and grep?
    
    --
    Daniel Gustafsson
    
    
    
    
    
  2. Re: evtcache: EventTriggerCache vs Event Trigger Cache

    Tom Lane <tgl@sss.pgh.pa.us> — 2023-05-04T12:09:12Z

    Daniel Gustafsson <daniel@yesql.se> writes:
    > When reading a memory contexts log I realized that we have this:
    > LOG:  level: 2; EventTriggerCache: 8192 total in 1 blocks; 7928 free (4 chunks); 264 used
    > LOG:  level: 3; Event Trigger Cache: 8192 total in 1 blocks; 2616 free (0 chunks); 5576 used
    
    > The reason is that BuildEventTriggerCache sets up a context "EventTriggerCache"
    > which house a hash named "Event Trigger Cache" which in turn creates a context
    > with the table name.  I think it makes sense that these share the same name,
    > but I think it would be less confusing if they also shared the same spelling
    > whitespace-wise.  Any reason to not rename the hash EventTriggerCache to make
    > the logging a tiny bit easier to read and grep?
    
    Hmm, I'm kinda -1 on them having the same name visible in the
    contexts dump --- that seems very confusing.  How about naming
    the hash "EventTriggerCacheHash" or so?
    
    			regards, tom lane
    
    
    
    
  3. Re: evtcache: EventTriggerCache vs Event Trigger Cache

    Daniel Gustafsson <daniel@yesql.se> — 2023-05-04T12:18:13Z

    > On 4 May 2023, at 14:09, Tom Lane <tgl@sss.pgh.pa.us> wrote:
    > 
    > Daniel Gustafsson <daniel@yesql.se> writes:
    >> When reading a memory contexts log I realized that we have this:
    >> LOG:  level: 2; EventTriggerCache: 8192 total in 1 blocks; 7928 free (4 chunks); 264 used
    >> LOG:  level: 3; Event Trigger Cache: 8192 total in 1 blocks; 2616 free (0 chunks); 5576 used
    > 
    >> The reason is that BuildEventTriggerCache sets up a context "EventTriggerCache"
    >> which house a hash named "Event Trigger Cache" which in turn creates a context
    >> with the table name.  I think it makes sense that these share the same name,
    >> but I think it would be less confusing if they also shared the same spelling
    >> whitespace-wise.  Any reason to not rename the hash EventTriggerCache to make
    >> the logging a tiny bit easier to read and grep?
    > 
    > Hmm, I'm kinda -1 on them having the same name visible in the
    > contexts dump --- that seems very confusing.  How about naming
    > the hash "EventTriggerCacheHash" or so?
    
    I think the level is the indicator here, but I have no strong opinions,
    EventTriggerCacheHash is fine by me.
    
    --
    Daniel Gustafsson
    
    
    
    
    
  4. Re: evtcache: EventTriggerCache vs Event Trigger Cache

    Daniel Gustafsson <daniel@yesql.se> — 2023-05-08T08:39:42Z

    > On 4 May 2023, at 14:18, Daniel Gustafsson <daniel@yesql.se> wrote:
    > 
    >> On 4 May 2023, at 14:09, Tom Lane <tgl@sss.pgh.pa.us> wrote:
    >> 
    >> Daniel Gustafsson <daniel@yesql.se> writes:
    >>> When reading a memory contexts log I realized that we have this:
    >>> LOG:  level: 2; EventTriggerCache: 8192 total in 1 blocks; 7928 free (4 chunks); 264 used
    >>> LOG:  level: 3; Event Trigger Cache: 8192 total in 1 blocks; 2616 free (0 chunks); 5576 used
    >> 
    >>> The reason is that BuildEventTriggerCache sets up a context "EventTriggerCache"
    >>> which house a hash named "Event Trigger Cache" which in turn creates a context
    >>> with the table name.  I think it makes sense that these share the same name,
    >>> but I think it would be less confusing if they also shared the same spelling
    >>> whitespace-wise.  Any reason to not rename the hash EventTriggerCache to make
    >>> the logging a tiny bit easier to read and grep?
    >> 
    >> Hmm, I'm kinda -1 on them having the same name visible in the
    >> contexts dump --- that seems very confusing.  How about naming
    >> the hash "EventTriggerCacheHash" or so?
    > 
    > I think the level is the indicator here, but I have no strong opinions,
    > EventTriggerCacheHash is fine by me.
    
    The attached trivial diff does that, parking this in the next CF.
    
    --
    Daniel Gustafsson
    
    
  5. Re: evtcache: EventTriggerCache vs Event Trigger Cache

    Nathan Bossart <nathandbossart@gmail.com> — 2023-05-08T23:07:33Z

    On Mon, May 08, 2023 at 10:39:42AM +0200, Daniel Gustafsson wrote:
    > On 4 May 2023, at 14:18, Daniel Gustafsson <daniel@yesql.se> wrote:
    >> On 4 May 2023, at 14:09, Tom Lane <tgl@sss.pgh.pa.us> wrote:
    >>> Hmm, I'm kinda -1 on them having the same name visible in the
    >>> contexts dump --- that seems very confusing.  How about naming
    >>> the hash "EventTriggerCacheHash" or so?
    >> 
    >> I think the level is the indicator here, but I have no strong opinions,
    >> EventTriggerCacheHash is fine by me.
    > 
    > The attached trivial diff does that, parking this in the next CF.
    
    +1 for EventTriggerCacheHash
    
    -- 
    Nathan Bossart
    Amazon Web Services: https://aws.amazon.com
    
    
    
    
  6. Re: evtcache: EventTriggerCache vs Event Trigger Cache

    Daniel Gustafsson <daniel@yesql.se> — 2023-07-05T07:18:44Z

    > On 8 May 2023, at 10:39, Daniel Gustafsson <daniel@yesql.se> wrote:
    >> On 4 May 2023, at 14:18, Daniel Gustafsson <daniel@yesql.se> wrote:
    >>> On 4 May 2023, at 14:09, Tom Lane <tgl@sss.pgh.pa.us> wrote:
    
    >>> How about naming
    >>> the hash "EventTriggerCacheHash" or so?
    >> 
    >> I think the level is the indicator here, but I have no strong opinions,
    >> EventTriggerCacheHash is fine by me.
    > 
    > The attached trivial diff does that, parking this in the next CF.
    
    Pushed, thanks!
    
    --
    Daniel Gustafsson