File tree Expand file tree Collapse file tree
Expand file tree Collapse file tree Original file line number Diff line number Diff line change @@ -52,19 +52,22 @@ await lcgNodes.InsertAsync(new LcgNode
5252 return ;
5353 }
5454
55- if ( online . Country != _options . CountryCode )
55+ // TODO: Load reporting
56+ if ( online . Country != _options . CountryCode || online . Environment != _env . EnvironmentName )
5657 {
5758 var changeTracker = _redisConnectionProvider . RedisCollection < LcgNode > ( ) ;
5859 var tracked = await changeTracker . FindByIdAsync ( _options . Fqdn ) ;
5960 if ( tracked is not null )
6061 {
6162 tracked . Country = _options . CountryCode ;
63+ tracked . Environment = _env . EnvironmentName ;
64+
6265 await changeTracker . SaveAsync ( ) ;
63- _logger . LogInformation ( "Updated firmware version of online device" ) ;
66+ _logger . LogInformation ( "Updated keep alive key in redis {@NewKey}" , tracked ) ;
6467 }
6568 else
6669 _logger . LogWarning (
67- "Could not save changed firmware version to redis, device was not found in change tracker, this shouldn't be possible but it somehow was? " ) ;
70+ "Could not save changed firmware version to redis, device was not found in change tracker, this can only happen when our key expired between reads " ) ;
6871 }
6972
7073 await _redisConnectionProvider . Connection . ExecuteAsync ( "EXPIRE" ,
You can’t perform that action at this time.
0 commit comments