magellan_microservice v0.3.0 MagellanMicroservice.AppStatus

This module handles the overall app-status. One can register a function which gets invoked when getStatus/0 is called to build the app-status.

Link to this section Summary

Functions

Returns a simple status represented by OK. Still hacked

Retrieve all results of the stored status functions

This function returns the App-Status.get_status result endcoded in json

Use this function to store a function under a name. The function will be invoked when the app-status or health are requested. Return :ok

The App-Status consists of an Agent which stores the registered status function. Refer to Agent.start_link documentation

Link to this section Functions

Link to this function get_health()
get_health() :: binary

Returns a simple status represented by OK. Still hacked.

Link to this function get_status()
get_status() :: map

Retrieve all results of the stored status functions.

Link to this function get_status_json()
get_status_json() :: term

This function returns the App-Status.get_status result endcoded in json.

Link to this function register_status_fun(appName, fun)
register_status_fun(atom, any) :: atom

Use this function to store a function under a name. The function will be invoked when the app-status or health are requested. Return :ok.

Link to this function start_link()
start_link() :: any

The App-Status consists of an Agent which stores the registered status function. Refer to Agent.start_link documentation.