Patent ID: 9256628
Filing Date: 2016-02-09
CPC Classification: G06F,H04L

Claim Text:
1. A system for efficient logging of event records in an uninterruptible power supply (UPS) array, the system comprising: a server computer; a UPS array, that includes a plurality of UPSs, for providing power to the server computer; and an embedded controller coupled to the server computer, wherein the embedded controller includes: a microcontroller control program (MCP), a first storage module, a second storage module that includes a register and a history record store, a serial port controller, a serial bus coupled to the serial port controller and to each of the UPSs, and a message queue data structure coupled to the server computer, the MCP, and to the serial port controller for queuing messages from the server and the MCP to UPSs of the UPS array; wherein: the MCP allocates an event log in the first storage module; the MCP periodically sends status and control messages to the UPSs of the UPS array via the message queue data structure; and the MCP, in response to determining that a message has been received in the message queue from the server computer: creates a history record in the history record store corresponding to the received message; determines the duration to complete transmission onto the serial bus of a message that is in process of being transmitted onto the serial bus from the message queue via the serial port controller when the message from the server computer arrives in the message queue; stores, in the created history record, an entry for the determined duration to complete transmission onto the serial bus of the message that was in process of being transmitted onto the serial bus; for each message in the message queue that is queued before the message determined to have been received from the server computer, not including the message that was in the process of being transmitted onto the serial bus from the message queue via the serial port controller when the message from the server computer arrived in the message queue, but including the message determined to have been received from the server computer, determines, for each such message, the duration to complete transmission onto the serial bus; stores, in the created history record, an entry for the determined duration to complete transmission onto the serial bus of each message in the message queue that is queued before the message determined to have been received from the server computer, not including the message that was in the process of being transmitted onto the serial bus from the message queue via the serial port controller when the message from the server computer arrived in the message queue, but including the message determined to have been received from the server computer; determines a total queue processing time by summing all of the stored durations for the history record entries corresponding to messages in the message queue that were queued before the message determined to have been received from the server computer, not including the message that was in the process of being transmitted onto the serial bus from the message queue via the serial port controller when the message from the server computer arrived in the message queue, but including the message determined to have been received from the server computer, and subtracting from the sum the duration to complete transmission onto the serial bus of the message that was in process of being transmitted onto the serial bus from the message queue via the serial port controller when the message from the server computer arrived in the message queue; compares the determined total queue processing time to a value in the register corresponding to a previously determined total queue processing time; and in response to determining that the determined total queue processing time is greater than the value in the register corresponding to a previously determined total queue processing time, stores the determined total queue processing time in the register, and logs the created history record into the event log; whereby only history records indicating a worst case queue processing time are logged into the event log, and whereby the MCP allocates an event log of a size smaller than would be required if all history records were stored in the event log.