Geolix v0.17.0 Geolix.Adapter.MMDB2 View Source

Adapter for Geolix to work with MMDB2 databases.

Link to this section Summary

Functions

Returns the children to be supervised by Geolix.Database.Supervisor

Loads a given database into Geolix

Looks up IP information

Unloads a given database from Geolix

Link to this section Functions

Returns the children to be supervised by Geolix.Database.Supervisor.

If no automatic supervision should take place or it is intended to use a adapter specific supervisor (e.g. using the application config) this callback should be either unimplemented or return an empty list.

Callback implementation for Geolix.Adapter.database_workers/0.

Loads a given database into Geolix.

Requires at least the fields :id and :adapter. Any other required fields depend on the adapter’s requirements.

Callback implementation for Geolix.Adapter.load_database/1.

Looks up IP information.

The passed opts are expected to contain a key :where to define which database should be queried. If that key is not set then nil should be returned instead.

Callback implementation for Geolix.Adapter.lookup/2.

Link to this function unload_database(database) View Source

Unloads a given database from Geolix.

Receives the configuration used when initially loading the database.

Callback implementation for Geolix.Adapter.unload_database/1.