Using this code:
private string GetKeyForId(int idShipmentRequest)
{
return $"{key}:{idShipmentRequest}";
}
public DTO.AnnouncedShipment GetById(int id)
{
using (var client = manager.GetClient())
{
var announcedShipments = client.As<DTO.AnnouncedShipment>();
var key = GetKeyForId(id);
var announcedShipment = announcedShipments.GetValue(key);
logger.Info($"GetById for id: {id}. Key: {key}. Announced: {announcedShipment.Dump()}");
return announcedShipment;
}
}
we sometime see this in our log:
2019-11-05 12:24:46.0095||ShipmentLogger|INFO|GetById for id: 14443493. Key: AnnouncedShipment:14443493. Announced: {
idShipmentRequest: 14443493,
idContact: 65178992,
idCampagne: 1921,
packingDetails:
[
{
idPackingType: 3,
numberOfItems: 2
....
This is correct, since the so called idSHipmentRequest should be identical to the id we get the value for.
But sometimes we see this - the same request, different result:
2019-11-05 14:11:14.1342||ShipmentLogger|INFO|GetById for id: 14443493. Key: AnnouncedShipment:14443493. Announced: {
idShipmentRequest: 14460000,
idContact: 64795584,
idCampagne: 1088,
packingDetails:
[
{
idPackingType: 4,
numberOfItems: 2
...
What can cause this? Is this a REDIS issue? Of could it be ServiceStack?