The overall concept behind the development of Erlang/OTP solutions for BINETIX® AGE™ is to keep your existing implementation untouched and to extend the Erlang's App specifications to support the AGE API. You should take into consideration that AGE's node configuration is also Erlang/OTP compliant and provides powerful functionality to centralize and maintain the configuration of your App (solution). Consequently, you can "inherit" these benefits just by starting the AGE's node as standard Erlang application automatically with your own App into the same BEAM virtual machine. But first things first! We shall use the MAKE_APP Toolset to (re)configure your Erlang's Solution in order to automate the compilation and the integration with AGE's node using one single make_app.config file. The "Prerequisites" section below explains how to prepare the development environment to use external libraries, like AGE application. |
1)Your new or existing Erlang solution is deployed into one root directory named "trunk". 2)Your Erlang solution has to have directory structure for development environment compliant with Erlang/OTP design principles; 3)Your make_app.config file is deployed in the root of this directory structure; 4)The MAKE_APP Toolset is installed and ready for use; 5)All external libraries and applications are installed into a dedicated directory named "lib". This directory could hold AGE Node App, Plug-in applications and other external libraries. This directory could be shared with other Erlang Apps, however for this description it shall be positioned on the same level of your current solution. |
Your Erlang solution has to have make_app.config aligned with the following instructions: a)The Erlang extension should be activated. It is recommended to activate also the Files extension in order to secure the required directory structure. b)The libs section of solution configuration element should refer as minimum to the latest AGE node distribution package. In this section you could add more AGE plug-ins or other external libraries. c)The spec section of solution configuration element should include the following standard configuration options of your Erlang app - id, vsn, description. Note: Take into consideration that MAKE_APP tool-set is generating automatically the Erlang's application resource file and the configuration options modules and applications will be completely overwritten, so it is not recommended to apply these options into your spec section. d)The solution configuration element has to have as minimum one software project. e)You could organize your software project at your discretion, however, it is recommended the directory structure to be aligned with Erlang/OTP best practices. Therefore, we're considering that the source code of your application is stored into src sub-directory. f)To perform compilation, deployment and execution activities you have to define tasks in accordance with your particular needs. In order to help you get started we've provided some commonly used predefined tasks into the following template of make_app.config file. |
Template for AGE/Erlang Solution Configuration file (make_app.config)