ibmfl.connection
¶
FL Connection¶
Flask Connection¶
Connection class which uses flask and request libraries to create a server client combo.
-
class
ibmfl.connection.flask_connection.
FlaskConnection
(config)[source]¶ -
__init__
(config)[source]¶ Initialized the connection object and validates the config provided to this connection instance
- Parameters
config (dict) – Dictionary of configuration provided to connection
-
get_connection_config
()[source]¶ Provide a connection information such that a node can communicate to other nodes on how to communicate with it.
- Returns
settings
- Return type
dict
-
get_ssl_config
(config)[source]¶ Loads tls config from connection config. Returns None when no config is provided :param config: Configuraiton sent from application :type config: dict
- Returns
ssl config
- Return type
dict
-
initialize_receiver
(router=None)[source]¶ Initialize flask server using the settings and handler.
- Parameters
router (Router) – Router object describing the routes for each request which are passed down to PH
-
initialize_sender
()[source]¶ Initialize simple http client using the settings provided during connection creation
-