Projects:Heartbeat/Technical Documentation
Contents |
Heartbeat Technical Documentation
Heartbeat Configuration Component
Purpose
The purpose of the heartbeat configuration component is to allow the system administrator to:
1. Enable/disable the heartbeat, or postpone the decision to enable/disable the heartbeat.
2. Enter network configuration information.
3. Register for Openbravo Support Services, entering relevant registration information.
4. Manually test sending of information.
5. View the details that are being sent to Openbravo by the heartbeat.
Process
1st Window – Decision window. The first time the system administrator logs in a small pop-up window displays.The window explains the heartbeat and update process and ask if they wish to configure the process or to do it later.
- Explanation of the heartbeat and update process.
- Configure button – This button takes the user to the configuration window.
- Postpone button – Allows the user to decide later.
First window will be manual window.
2nd Window – Configuration Window The configuration window contains three tabs.
1st Tab – Configuration Tab
- Enable/Disable check box.
- Proxy Configuration section (only visible if enable is selected).
- Proxy configuration section contains fields for the server, the port, and a button allowing the user to test the configuration.
The test button executes the send part of the background process. When the button is pressed a progress window is displayed indicating success/failure.
2nd Tab – Registration Information
- Company name
- Company address
- Contact name
- Contact title
- Contact email
- Contact phone
- Company industry
- Company size in revenues (€)
- Company size in number of employees
- Subscribe to development News (Yes, No) -> automatic subscription to development mailing list
- Subscribe to commercial News (Yes, No) -> automatic subscription to Y distribution list
- Allow commercial contact (Yes, No) -> register them as a lead in Openbravo CRM system
- Register button.
3rd Tab – Heartbeat History/Log
- List of all previous heartbeats (see Data section)
Background Process Component
Purpose
The purpose of the background component is to collect, store and send configuration data about the user's Openbravo installation to a central Openbravo server. The background process also receives update information back from the central server and delegates this information to an alert process.
Process
- Scheduled to run by Openbravo scheduler.
- The process starts and immediately checks for a network connection.
- If there is no network connection, the process stops and waits for the next scheduled run.
- If there is a network connection, proceed to read system configuration information (from existing database tables, system properties etc.)
- Store information in the AD_SYSTEM_INFO table.
- Store information in the AD_SYSTEM_LOG table.
- Send information to the Openbravo server in the form of a HTTPS request.
- Receive update information from the Openbravo server.
- If updates are available generate an alert. (See alert module)
Data
AD_SYSTEM_INFO table "AD_SYSTEM_INFO_ID" NUMBER(10,0) NOT NULL ENABLE, "AD_CLIENT_ID" NUMBER(10,0) NOT NULL ENABLE, "AD_ORG_ID" NUMBER(10,0) NOT NULL ENABLE, "ISACTIVE" CHAR(1 BYTE) DEFAULT 'Y' NOT NULL ENABLE, "CREATED" DATE DEFAULT SYSDATE NOT NULL ENABLE, "CREATEDBY" NUMBER(10,0) NOT NULL ENABLE, "UPDATED" DATE DEFAULT SYSDATE NOT NULL ENABLE, "UPDATEDBY" NUMBER(10,0) NOT NULL ENABLE, "ISPROXYREQUIRED" CHAR(1 BYTE) DEFAULT 'N' NOT NULL ENABLE, "PROXY_SERVER" NVARCHAR2(20), "PROXY_PORT" NUMBER(4,0), "SYSTEM_IDENTIFIER" VARCHAR2(25 BYTE), "IP_ADDRESS" NVARCHAR2(20), "ACTIVITY_RATE" NUMBER DEFAULT 1, "COMPLEXITY_RATE" NUMBER DEFAULT 1, "OS" NVARCHAR2(20), "OS_VERSION" NVARCHAR2(20), "DB" NVARCHAR2(20), "DB_VERSION" NVARCHAR2(20), "SERVLET_CONTAINER" NVARCHAR2(20), "SERVLET_CONTAINER_VERSION" NVARCHAR2(20), "APACHE_VERSION" NVARCHAR2(20), "JAVA_VERSION" NVARCHAR2(20), "ANT_VERSION" NVARCHAR2(20), "OB_VERSION" NVARCHAR2(20), "OB_INSTALLMODE" NVARCHAR2(20), "POSTPONE_DATE" DATE DEFAULT SYSDATE NOT NULL ENABLE, "ISHEARTBEATACTIVE" CHAR(1 BYTE) DEFAULT 'Y' NOT NULL ENABLE, "REGISTRATION_ID" NUMBER(20,0), "ISREGISTERED" CHAR(1 BYTE) DEFAULT 'Y' NOT NULL ENABLE, "REGISTERNOW" CHAR(1 BYTE) DEFAULT 'Y' NOT NULL ENABLE, "COMPANYNAME" NVARCHAR2(60), "COMPANYADDRESS" NVARCHAR2(255), "CONTACTNAME" NVARCHAR2(60), "CONTACTTITLE" NVARCHAR2(10), "CONTACTEMAIL" NVARCHAR2(60), "CONTACTPHONE" NUMBER(20,0), "COMPANYINDUSTRY" NVARCHAR2(60), "COMPANYREVENUE" VARCHAR2(10 BYTE), "COMPANYNUM_EMPLOYEES" NUMBER(10,0), "ISSUBSCRIBECOMMERCIAL" CHAR(1 BYTE) DEFAULT 'Y' NOT NULL ENABLE, "ISSUBSCRIBEDEVELOPMENT" CHAR(1 BYTE) DEFAULT 'Y' NOT NULL ENABLE, "ISCOMMERCIALCONTACT" CHAR(1 BYTE) DEFAULT 'Y' NOT NULL ENABLE, "TESTPROXY" CHAR(1 BYTE) DEFAULT 'Y' NOT NULL ENABLE
Design Decisions/Considerations
The SYSTEM_IDENTIFIER field of the AD_SYSTEM_INFO table will be a unique identifier that is generated for each distinct installation of Openbravo ERP.
Network Availability – The success of the heartbeat background process in being able to send information depends on network connectivity. Consideration needs to be given to situations where there is no network connection available
Scheduled beat time needs to be configured through existing scheduler functionality.
The background process is designed to be exceptionally light.
Heartbeat Update Server
Purpose
The purpose of the heartbeat update server component is to receive requests, containing system configuration information, from Openbravo instances, and to process the requests and store the data in a database. The heartbeat server is also to return update information the requesting Openbravo instance.
Process
- Request received as a HTTPS request.
- Information is extracted from the request (and parsed/processed).
- Information is inserted into the AD_SYSTEM_INFO table
- The information is compared to the UPDATE_INFO table, and updates to any system components are selected.
- The update information is returned via HTTPS.
Data
HEARTBEAT_INFO table "HEARTBEAT_INFO_ID" NUMBER(10,0) NOT NULL ENABLE, "CREATED" DATE DEFAULT SYSDATE NOT NULL ENABLE, "CREATEDBY" NUMBER(10,0) NOT NULL ENABLE, "UPDATED" DATE DEFAULT SYSDATE NOT NULL ENABLE, "UPDATEDBY" NUMBER(10,0) NOT NULL ENABLE, "ISPROXYREQUIRED" CHAR(1 BYTE) DEFAULT 'N' NOT NULL ENABLE, "PROXY_SERVER" NVARCHAR2(20), "PROXY_PORT" NUMBER(4,0), "SYSTEM_IDENTIFIER" VARCHAR2(25 BYTE), "IP_ADDRESS" NVARCHAR2(20), "ACTIVITY_RATE" NUMBER DEFAULT 1, "COMPLEXITY_RATE" NUMBER DEFAULT 1, "OS" NVARCHAR2(20), "OS_VERSION" NVARCHAR2(20), "DB" NVARCHAR2(20), "DB_VERSION" NVARCHAR2(20), "SERVLET_CONTAINER" NVARCHAR2(20), "SERVLET_CONTAINER_VERSION" NVARCHAR2(20), "APACHE_VERSION" NVARCHAR2(20), "JAVA_VERSION" NVARCHAR2(20), "ANT_VERSION" NVARCHAR2(20), "OB_VERSION" NVARCHAR2(20), "OB_INSTALLMODE" NVARCHAR2(20), "POSTPONE_DATE" DATE DEFAULT SYSDATE NOT NULL ENABLE, "ISHEARTBEATACTIVE" CHAR(1 BYTE) DEFAULT 'Y' NOT NULL ENABLE, "REGISTRATION_ID" NUMBER(20,0), "ISREGISTERED" CHAR(1 BYTE) DEFAULT 'Y' NOT NULL ENABLE, "REGISTERNOW" CHAR(1 BYTE) DEFAULT 'Y' NOT NULL ENABLE, "COMPANYNAME" NVARCHAR2(60), "COMPANYADDRESS" NVARCHAR2(255), "CONTACTNAME" NVARCHAR2(60), "CONTACTTITLE" NVARCHAR2(10), "CONTACTEMAIL" NVARCHAR2(60), "CONTACTPHONE" NUMBER(20,0), "COMPANYINDUSTRY" NVARCHAR2(60), "COMPANYREVENUE" VARCHAR2(10 BYTE), "COMPANYNUM_EMPLOYEES" NUMBER(10,0), "ISSUBSCRIBECOMMERCIAL" CHAR(1 BYTE) DEFAULT 'Y' NOT NULL ENABLE, "ISSUBSCRIBEDEVELOPMENT" CHAR(1 BYTE) DEFAULT 'Y' NOT NULL ENABLE, "ISCOMMERCIALCONTACT" CHAR(1 BYTE) DEFAULT 'Y' NOT NULL ENABLE, "TESTPROXY" CHAR(1 BYTE) DEFAULT 'Y' NOT NULL ENABLE,
UPDATE_INFO table ... COMPONENT OPTION VERSION SEQUENCE_ID DESCRIPTION ...
Design Considerations
Consideration needs to be given to the reporting module that will be completed in the second phase of the heartbeat project. The reporting module needs to be as detailed as possible to gain the most benefit out of the heartbeat project, and the type of reports required needs to be considered, which will affect the information stored on the server.
Alerts
Purpose
The Alerts will notify the System Administrator of available updates detected by the Heartbeat module; this notifications include: updates for the Openbravo stack (tomcat, ant, java, etc) and the application itself.
Process
- The Heartbeat Update Server identifies an available update
- The update information is send back to the Background Process component
- The Background Process component creates new alert instances based on the update information