Skip to content
  • Joal's avatar
    Refactor geo-coding function and add ISP · c0b39abe
    Joal authored and Ottomata's avatar Ottomata committed
    Geocoding functions using MaxMind-Country and MaxMind-City
    databases were bundled into a single class. Now there are
    two classes, one per usage of database, preventing to load
    unneeded data, as well as a utility class for usage of
    Locale to convert country-code to country name.
    Also, the code now doesn't try to find data for internal IPs.
    The MaxMind-ISP database functions have also been added. They
    mimic the behavior of MaxMind-City ones.
    Finally, a refresh of internal network IPs have been done in
    refinery-core IpUtils.
    
    Refactor tried to follow MaxMind naming and separated classes
    that read the DBs (Readers) from actual representation of
    results (Responses)
    
    We have also consolidated exception handling to Java 8 more
    friendly syntax.
    
    Bug: T167907
    Change-Id: I602b04847d6083d8ba4a4de3c6614d8952d83608
    c0b39abe
This project is licensed under the Apache License 2.0. Learn more