summaryrefslogtreecommitdiff
path: root/gateways.go
AgeCommit message (Collapse)Author
2022-02-13add log for json errorkali kaneko (leap communications)
2021-11-16use logkali kaneko (leap communications)
2021-11-09[feat] make api configurablekali kaneko (leap communications)
2018-12-13add license informationkali kaneko
2018-12-13geolocate gateways and kd-treeKali Kaneko
during initialization, we fetch the eip-config.json file from the configured provider. we geolocate the gateways (using a golang package that has some cities missing, hence the workaround) and initialize a KD-Tree with the gateways. using the KD-Tree, it is very cheap to calculate the nearest gateway for every request, which is provider as a filed in the json to the client - as a suggestion to be used or not in the gateway selection process.