Patent ID: 8000335

Claim:
A media gateway which (a) generates a plurality of contexts independently from each other based on respective control messages transmitted from respective media gateway controllers corresponding to a first network and a second network, and (b) performs media conversion for bearer transfers using the plurality of contexts between the first network and the second network, comprising: a memory unit which stores setting information, function information and performance information for resources associated with each of the plurality of contexts, wherein the function information indicates a function of the resources and an available function, and the performance information includes information on processing power of a device; a context determination unit which determines whether or not an internal connection which connects a plurality of contexts for a same stream within the media gateway exists between the contexts corresponding to each of the first network and the second network based on the setting information stored in the memory unit; an optimization judgment unit which judges whether a new context, generated by combining the contexts originally corresponding to each of the first network and the second network and omitting functionally redundant resources, may maintain communication including media conversion between the first network and the second network, based on the function information or the performance information stored in the memory unit, when the context determination unit determines that the internal connection exists; an optimization processing unit which generates the new context when the optimization judgment unit judges that the new context can be generated, and associates the setting information of the new context with each of the setting information on the contexts originally corresponding to each of the first network and the second network; and a context control unit which controls the bearer transfer between the first network and the second network by using the new context, and transmits a response message including information that the context is set up to each of the media gateway controllers by using the setting information on the contexts originally corresponding to each of the first network and the second network, respectively.