[exim] Re: event_action and "retry timeout exceeded"

Kezdőlap
Üzenet törlése
Válasz az üzenetre
Szerző: Viktor Ustiuhov
Dátum:  
Címzett: Jasen Betts via Exim-users
Tárgy: [exim] Re: event_action and "retry timeout exceeded"
Jasen Betts via Exim-users wrote on 16.06.2024 0:59:
>> Please tell me how can I log "retry timeout exceeded" using event_action?


> msg complete is the wrong place to check for that, because messages
> can have multiple recipients.  unfortunatley stock exim doesn't
> provide an event for this.
> 
> 
> I modify retry.c to get that capability.
> 
> 
> $  diff -C10   original/retry.c  patched/retry.c 
> *** original/retry.c    2023-11-05 01:55:49.000000000 +1300
> --- patched/retry.c    2024-06-16 09:51:15.934608692 +1200
> ***************
> *** 894,913 ****
> --- 894,917 ----
>           : US"retry timeout exceeded";
>             addr->user_message = addr->user_message
>           ? string_sprintf("%s: retry timeout exceeded", addr->user_message)
>           : US"retry timeout exceeded";
>             log_write(0, LOG_MAIN, "** %s%s%s%s: retry timeout exceeded",
>               addr->address,
>               addr->parent ? US" <" : US"",
>               addr->parent ? addr->parent->address : US"",
>               addr->parent ? US">" : US"");
>   
> + #ifndef DISABLE_EVENT     
> +           msg_event_raise(US"msg:rcpt:retry:timeout",addr);
> + #endif
> + 
>             if (addr == endaddr) break;
>             }
>   
>           continue;                       /* Restart from changed *paddr */
>           }
>   
>         /* This address is to remain on the defer chain. If it has a "first"
>         pointer, save the pointer to it in case we want to fail the set of
>         addresses when we get to the first one. */


The patch works as expected. Thank you.


> If you choose to open a bug request for this feature you can attach
> the above as a patch.



> -- Jasen.
> 🇺🇦 Слава Україні


Героям слава!


--
Best wishes Viktor Ustiuhov
mailto:victor@corvax.kiev.ua
public GnuPG/PGP key: https://victor.corvax.kiev.ua/corvax.asc

--
## subscription configuration (requires account):
## https://lists.exim.org/mailman3/postorius/lists/exim-users.lists.exim.org/
## unsubscribe (doesn't require an account):
## exim-users-unsubscribe@???
## Exim details at http://www.exim.org/
## Please use the Wiki with this list - http://wiki.exim.org/