Hello I have the following convention.
endpointConfiguration.Conventions().DefiningTimeToBeReceivedAs(t =>
{
if (t == typeof(DepositMoney))
{
return TimeSpan.FromSeconds(90);
}
else if (t == typeof(CompletePaymentRequest))
{
return TimeSpan.FromSeconds(90);
}
return TimeSpan.MaxValue;
//return t switch
//{
// Type c when c == typeof(DepositMoney) => TimeSpan.FromSeconds(90),
// Type c when c == typeof(CompletePaymentRequest) => TimeSpan.FromSeconds(90),
// _ => TimeSpan.MaxValue
//};
});
I am expecting that the command does not get executed after 90 seconds.
The way I am testing is the following
Stop Endpoing
Api gateway send command to Endpoint
Wait past 90 seconds
Start Endpoint… expectation is for message to be discarded… however it does not get discard