Patent ID: 7920582

Claim:
A method for reporting events by a media gateway to a media gateway controller in a network, comprising: executing a state machine which is established in the media gateway and includes service states driven by events, wherein the state machine comprises a state of Suspension, and the state machine is established with the following process: A1. classifying the events in accordance with a relation between service logic processing and the events; A2. obtaining a state machine for processing the events corresponding to the service logic from a mechanism of events driving service state transition, based on the classification; A3. revising the state machine by using an event processing rule specified in a protocol, and obtaining the state machine including service states driven by events; wherein the executing process comprises: entering into the state of Suspension when an event is reported to the media gateway controller, if the state machine is in a state other than the state of Suspension; and storing an event which can not be reported temporarily to the media gateway controller in an EventBuffer queue which is established in the media gateway, and returning to a state prior to the state of Suspension when the event reported is responded, if the state machine is in the state of Suspension; and wherein the method further comprises: detecting the event reported in accordance with an Events Descriptor; and updating the Events Descriptor in accordance with a command sent by the media gateway controller.