The present application relates to the technical field of micro-
service gateway, and particularly relates to a method and
system for dynamically loading plug-ins and starting and stopping ports based on a micro-
service gateway, which comprises the following steps: loading a public dependent plug-in
package and a private dependent plug-in
package through a
dynamic loading class manager; calling a transmission port opening and monitoring method, and traversing address information bound to the gateway to load information and open monitoring; responding to a query in-
service gateway instruction, querying an in-service gateway, and displaying a gateway running instance; responding to an address information query of the gateway running instance instruction, querying address information of all in-service gateways in a
database, comparing the address information with address loaded in a
memory mapping table, and returning address information containing address states; performing an enable, disable, restart or parameter refresh operation on a single address; and dynamically loading a public protocol
package and a secondary developed private protocol package.The present application realizes
dynamic management of multiple protocol ports without interrupting gateway services, and improves flexibility and availability of the
system.