switch (distribution) {
case IdTagDistribution.RANDOM:
return this.getRandomIdTag(hashId, idTagsFile);
switch (distribution) {
case IdTagDistribution.RANDOM:
return this.getRandomIdTag(hashId, idTagsFile);
private getRandomIdTag(hashId: string, file: string): string {
const idTags = this.getIdTags(file);
private getRandomIdTag(hashId: string, file: string): string {
const idTags = this.getIdTags(file);
private getRoundRobinIdTag(hashId: string, file: string): string {
const idTags = this.getIdTags(file);
private getRoundRobinIdTag(hashId: string, file: string): string {
const idTags = this.getIdTags(file);
const idTagIndex = this.idTagsCachesAddressableIndexes.get(addressableKey) ?? 0;
const idTag = idTags[idTagIndex];
this.idTagsCachesAddressableIndexes.set(
const idTagIndex = this.idTagsCachesAddressableIndexes.get(addressableKey) ?? 0;
const idTag = idTags[idTagIndex];
this.idTagsCachesAddressableIndexes.set(
this.idTagsCachesAddressableIndexes.set(
addressableKey,
(chargingStation.index - 1 + (connectorId - 1)) % idTags.length
this.idTagsCachesAddressableIndexes.set(
addressableKey,
(chargingStation.index - 1 + (connectorId - 1)) % idTags.length