CN113055470A - Service request distribution method and system - Google Patents

Service request distribution method and system Download PDF

Info

Publication number
CN113055470A
CN113055470A CN202110266612.5A CN202110266612A CN113055470A CN 113055470 A CN113055470 A CN 113055470A CN 202110266612 A CN202110266612 A CN 202110266612A CN 113055470 A CN113055470 A CN 113055470A
Authority
CN
China
Prior art keywords
service
request
determining
architecture
service request
Prior art date
Legal status (The legal status is an assumption and is not a legal conclusion. Google has not performed a legal analysis and makes no representation as to the accuracy of the status listed.)
Granted
Application number
CN202110266612.5A
Other languages
Chinese (zh)
Other versions
CN113055470B (en
Inventor
张强
孔婕
Current Assignee (The listed assignees may be inaccurate. Google has not performed a legal analysis and makes no representation or warranty as to the accuracy of the list.)
China Construction Bank Corp
Original Assignee
China Construction Bank Corp
Priority date (The priority date is an assumption and is not a legal conclusion. Google has not performed a legal analysis and makes no representation as to the accuracy of the date listed.)
Filing date
Publication date
Application filed by China Construction Bank Corp filed Critical China Construction Bank Corp
Priority to CN202110266612.5A priority Critical patent/CN113055470B/en
Publication of CN113055470A publication Critical patent/CN113055470A/en
Application granted granted Critical
Publication of CN113055470B publication Critical patent/CN113055470B/en
Active legal-status Critical Current
Anticipated expiration legal-status Critical

Links

Images

Classifications

    • HELECTRICITY
    • H04ELECTRIC COMMUNICATION TECHNIQUE
    • H04LTRANSMISSION OF DIGITAL INFORMATION, e.g. TELEGRAPHIC COMMUNICATION
    • H04L67/00Network arrangements or protocols for supporting network services or applications
    • H04L67/50Network services
    • H04L67/60Scheduling or organising the servicing of application requests, e.g. requests for application data transmissions using the analysis and optimisation of the required network resources
    • HELECTRICITY
    • H04ELECTRIC COMMUNICATION TECHNIQUE
    • H04LTRANSMISSION OF DIGITAL INFORMATION, e.g. TELEGRAPHIC COMMUNICATION
    • H04L67/00Network arrangements or protocols for supporting network services or applications
    • H04L67/01Protocols
    • H04L67/10Protocols in which an application is distributed across nodes in the network
    • HELECTRICITY
    • H04ELECTRIC COMMUNICATION TECHNIQUE
    • H04LTRANSMISSION OF DIGITAL INFORMATION, e.g. TELEGRAPHIC COMMUNICATION
    • H04L67/00Network arrangements or protocols for supporting network services or applications
    • H04L67/50Network services
    • H04L67/51Discovery or management thereof, e.g. service location protocol [SLP] or web services

Landscapes

  • Engineering & Computer Science (AREA)
  • Computer Networks & Wireless Communication (AREA)
  • Signal Processing (AREA)
  • Data Exchanges In Wide-Area Networks (AREA)
  • Computer And Data Communications (AREA)

Abstract

The invention discloses a service request distribution method and a service request distribution system, and relates to the technical field of computers. One embodiment of the method comprises: receiving a service request sent by a channel party; determining a target business service according to the service request, wherein the target business service comprises: services based on a centralized architecture and services based on a micro-service architecture; and distributing the service request according to the target service. The implementation mode can better support a centralized service architecture and a distributed micro-service architecture at the same time.

Description

Service request distribution method and system
Technical Field
The present invention relates to the field of computer technologies, and in particular, to a service request distribution method and system.
Background
With the development of technology and business, the application system construction of each enterprise successively goes through several design modes such as host centralization, open distribution and the like. The granularity of the corresponding service implementation also evolves from jumbo services, mini services to micro services. Currently, in the process of evolving from a centralized service architecture to a distributed micro-service architecture, a design method capable of better supporting both the centralized service architecture and the distributed micro-service architecture is still lacking.
Disclosure of Invention
In view of this, embodiments of the present invention provide a method and a system for distributing a service request, which can better support a centralized service architecture and a distributed micro-service architecture at the same time.
In a first aspect, an embodiment of the present invention provides a service request distribution method, including:
receiving a service request sent by a channel party;
determining a target business service according to the service request, wherein the target business service comprises: services based on a centralized architecture and services based on a micro-service architecture;
and distributing the service request according to the target service.
Optionally, the determining a target service according to the service request includes:
determining request parameters for the service request, the request parameters including at least one of: path parameters, identity information, a current domain name and service parameters;
and determining the target business service according to the request parameters.
Optionally, the method further comprises:
determining and storing the corresponding relation between the business service and the request parameter;
the determining the target business service according to the request parameter includes:
acquiring the corresponding relation;
and determining the target business service according to the request parameters and the corresponding relation.
Optionally, the method further comprises:
determining at least one service component corresponding to a business service, wherein the business service is a service based on a centralized architecture or a service based on a micro-service architecture;
arranging the at least one service component to generate a sub-model of the business service, the sub-model being used to respond to service requests.
Optionally, the method further comprises:
acquiring and storing registration information of a service component, wherein the registration information comprises at least one of the following: ip address, port number, service agent and service identification;
the determining at least one service component corresponding to the business service includes:
and determining the at least one service component corresponding to the business service according to the registration information.
Optionally, the method further comprises:
judging whether the message of the service request needs to be decrypted or not;
and if so, decrypting the message of the service request.
Optionally, the decrypting the message of the service request includes:
acquiring safety processing parameter information from a configuration file of a configuration center;
and decrypting the message of the service request according to the safety processing parameter information.
Optionally, the method further comprises:
judging whether the message of the service request needs to be encrypted;
and if so, encrypting the message of the service request.
Optionally, the method further comprises:
determining the identity information of the channel party according to the service request;
judging whether the identity information meets a preset authentication requirement or not;
if yes, executing the step of distributing the service request;
if not, a prompt for prohibiting access is sent out.
Optionally, the method further comprises:
judging whether each service is in a healthy state;
if not, sending out a prompt of abnormal service.
Optionally, the method further comprises:
judging whether the monitoring service is in an unavailable state;
and if so, carrying out fusing processing on the monitoring service.
Optionally, the method further comprises:
determining the maximum concurrency and the current access number of the target business service;
judging whether the current access number is larger than the maximum concurrency amount or not;
and if so, discarding the service request.
In a second aspect, an embodiment of the present invention provides a service request distribution system, including: a channel party, a service party, an application route, a configuration center and a service integration agent;
the application route is used for receiving a service request sent by a channel party; determining a target business service according to the service request, wherein the target business service comprises: services based on a centralized architecture or services based on a micro-service architecture; according to the target business service, the service request is distributed to the service party;
the service integration agent is used for determining at least one service component corresponding to a service, and the service is a micro-service architecture service; arranging the at least one service component to generate a sub-model of the business service;
and the configuration center is used for determining and storing the corresponding relation between the business service or the sub-model and the request parameter.
In a third aspect, an embodiment of the present invention provides an electronic device, including:
one or more processors;
a storage device for storing one or more programs,
when executed by the one or more processors, cause the one or more processors to implement the method of any of the embodiments described above.
In a fourth aspect, an embodiment of the present invention provides a computer-readable medium, on which a computer program is stored, where the computer program, when executed by a processor, implements the method of any one of the above embodiments.
One embodiment of the above invention has the following advantages or benefits: and determining a target business service according to the service request sent by the channel side, wherein the target business service can be a service based on a centralized architecture or a service based on a micro-service architecture, and distributing the service request according to the target business service. Therefore, the method of the embodiment of the invention can better support a centralized service architecture and a distributed micro-service architecture at the same time.
Further effects of the above-mentioned non-conventional alternatives will be described below in connection with the embodiments.
Drawings
The drawings are included to provide a better understanding of the invention and are not to be construed as unduly limiting the invention. Wherein:
FIG. 1 is a schematic diagram of the architecture of a service request distribution system in the prior art;
FIG. 2 is a schematic diagram of the architecture of another service request distribution system in the prior art;
fig. 3 is a schematic diagram of an application scenario of a service request distribution method according to an embodiment of the present invention;
fig. 4 is a schematic diagram illustrating a flow of a service request distribution method according to an embodiment of the present invention;
fig. 5 is a schematic diagram illustrating a flow of another service request distribution method according to an embodiment of the present invention;
fig. 6 is a schematic structural diagram of a service request distribution system according to an embodiment of the present invention;
fig. 7 is a schematic block diagram of a computer system suitable for use in implementing a terminal device or server of an embodiment of the invention.
Detailed Description
Exemplary embodiments of the present invention are described below with reference to the accompanying drawings, in which various details of embodiments of the invention are included to assist understanding, and which are to be considered as merely exemplary. Accordingly, those of ordinary skill in the art will recognize that various changes and modifications of the embodiments described herein can be made without departing from the scope and spirit of the invention. Also, descriptions of well-known functions and constructions are omitted in the following description for clarity and conciseness.
In the process of evolving from a centralized service architecture to a distributed micro-service architecture, the centralized service architecture and the distributed micro-service architecture can be simultaneously supported in the following two ways.
In the first mode, the channel side service is modified in a distributed mode based on the current situation. Fig. 1 is a schematic diagram of an architecture of a service request distribution system in the prior art. As shown in fig. 1, in the IT practice of each enterprise, when a distributed micro-service architecture is modified, application modification of a channel caller is generally involved to meet the distributed micro-service architecture requirement of a server. Under the original centralized architecture, a plurality of services of different business systems on a trading line are sequentially called on the basis of the design of the whole trading line by service calling of a chain mechanism from a trading initiator according to the processing flow requirements of businesses, and after one service at the tail end is successfully called and responses are returned in a reverse order according to the trading line, the whole business flow is completed.
In the whole process of business process distributed transformation, the distributed service transformation and deployment change of the server application can affect the channel calling mode. At this time, the design purpose can be achieved by a way that a channel side synchronously carries out distributed transformation based on the current situation.
In the mode, the channel side and the service side need to meet the requirement of the distributed micro-service architecture on the basis of meeting the requirement of the current centralized architecture, and the complexity of cooperation of the channel side and the service side is increased, so that the complexity of distributed transformation is increased; in the presence of objective constraints such as manpower, time, cost, etc., the usability and stability of external services of an enterprise may be adversely affected.
And secondly, independently adding a distributed unit to the channel side service. Fig. 2 is a schematic diagram of the architecture of another service request distribution system in the prior art. As shown in fig. 2, in the second mode, on the basis of the distributed modification of the service party in the first mode, according to the distributed modification progress of the service party, in the period of coexistence of the enterprise centralized architecture and the distributed microservice architecture, the channel party adds the distributed unit to independently adapt to the distributed service.
In this mode, although the channel-side service provider independently adds the deployment unit, the requirement of coexistence of the centralized architecture and the distributed micro-service architecture can be satisfied, and compared with the first mode, the method can isolate the service range of the distributed micro-service architecture from the original centralized architecture, but still has the situation that the channel-side call needs to be synchronously modified with the distributed service provider, and meanwhile, has the problems of complexity of service selection for the user of the existing service process and the like.
In view of the problems associated with both of the above approaches. The embodiment of the invention combines some new requirements existing after the enterprise SOA (Service-Oriented Architecture) Architecture is implemented, and needs to consider that the distributed micro-Service and other new technologies are adopted to transform part of application components, so as to inherit and optimize the existing SOA Architecture. On the basis of conforming to the requirements of the distributed micro-service architecture, the related requirements put forward by the distributed micro-service architecture are analyzed, the distributed platform scheme is selected and designed according to the actual situation of the existing application components of the enterprise, and conditions and references are provided for the implementation of the subsequent service party under the condition that the constraint of noninductivity to the channel party is met.
Fig. 3 is a schematic diagram of an application scenario of a service request distribution method according to an embodiment of the present invention. As shown in fig. 3, the service request distribution method according to the embodiment of the present invention may be applied to the gateway apparatus 304. The gateway device 304 may be a gateway, router, switch, firewall, or the like.
The channel parties 301, 302, 303 send service request messages to the gateway device 304, and the gateway device 304 determines a target service according to the service request, wherein the target service includes: services based on a centralized architecture and services based on a micro-service architecture; distributing the service request to the service parties 305, 306, 307 in accordance with the target business service.
The channeling parties 301, 302, 303 may be cell phones, notebooks, tablets, laptop portable computers, servers, and the like. The service parties 305, 306, 307 may be servers deployed based on a centralized architecture or may be servers deployed based on a distributed microservice architecture.
It should be noted that the service request distribution method provided by the embodiment of the present invention is generally executed by the gateway device 304, and accordingly, the service request distribution system is generally disposed in the gateway device 304.
Fig. 4 is a schematic diagram of a flow of a service request distribution method according to an embodiment of the present invention, where as shown in fig. 4, the method includes:
step 401: and receiving a service request sent by a channel party.
Step 402: determining a target business service according to the service request, wherein the target business service comprises: services based on a centralized architecture and services based on a micro-service architecture.
A centralized architecture based service is deployed in a centralized architecture mode for a server or cluster of servers that provide the service. The services based on the micro-service architecture are deployed in a mode of a distributed micro-service architecture for the servers or server clusters providing the services.
In one embodiment of the present invention, step 402 may comprise:
determining request parameters for the service request, the request parameters including at least one of: path parameters, identity information, a current domain name and service parameters;
and determining the target business service according to the request parameters.
The path parameters may include: protocol type, access address, etc. The identity information may include one or any combination of a user name, a password, fingerprint authentication information, voiceprint authentication information, iris authentication information, and the like of a user corresponding to the client. And the current domain name is a network domain mapped by the IP address of the current client. The traffic parameters may be used to characterize the current environmental parameters on which the service request depends.
The target business service may be determined by: determining and storing the corresponding relation between the service and the request parameter by using a configuration center; and determining the target business service according to the request parameters and the corresponding relation.
The correspondence of the business service and the request parameter may be set in the configuration center in advance. Specifically, the corresponding relationship between the service request address and the service link address may be stored in the configuration center, and when the service request is received, the service corresponding to the request parameter is searched in the corresponding relationship, and the service is determined as the target service.
Step 403: and distributing the service request according to the target service.
And distributing the service request to a service party corresponding to the target business service. The server can be a server providing services based on a centralized architecture or a server providing services based on a micro-service architecture. The distribution service request may be implemented using a component such as nginx or spring closed gateway.
In the embodiment of the invention, the target business service is determined according to the service request sent by the channel side, the target business service can be a service based on a centralized architecture or a micro-service architecture, and the service request is distributed according to the target business service. Therefore, the problem that the centralized service architecture and the distributed micro-service architecture cannot be simultaneously and well supported in the prior art can be solved.
In one embodiment of the present invention, further comprising:
judging whether the message of the service request needs to be decrypted or not;
if yes, the message of the service request is decrypted.
An encryption flag bit can be set in the message header of the request message, and whether the received request message needs to be decrypted is determined according to the encryption flag bit. If the request message needs to be decrypted, the security parameter information can be obtained from the configuration file of the configuration center, and the message of the service request is decrypted by using a decryption algorithm, a key and the like corresponding to the security parameter information. The gateway is used for realizing the encryption and decryption of the message, so that the safety of the message information in the network transmission process can be improved.
In one embodiment of the present invention, further comprising:
judging whether the message of the service request needs to be encrypted;
if yes, the message of the service request is encrypted.
Whether the message of the service request needs to be encrypted or not can be judged by various methods, for example, whether the message needs to be encrypted or not can be determined by an encryption flag bit in a message header; or judging whether the sensitive field exists in the message, and if so, encrypting the message. The sensitive fields may include: user name, password, amount, etc.
If the request message needs to be encrypted, the security parameter information can be obtained from the configuration information of the configuration center, and the message of the service request is encrypted by using an encryption algorithm, a key and the like corresponding to the security parameter information. The gateway is used for realizing the encryption and decryption of the message, so that the safety of the message information in the network transmission process can be improved.
In one embodiment of the present invention, further comprising:
determining the identity information of a channel party according to the service request;
judging whether the identity information meets the preset authentication requirement or not;
if yes, executing a service distribution request step;
if not, a prompt for prohibiting access is sent out.
The identity information may include one or any combination of a user name, a password, fingerprint authentication information, voiceprint authentication information, iris authentication information, and the like of a user corresponding to the client. According to the security-related authentication credential information, such as the user name and the password, it can be determined whether the current user name in the service request is in a legal user list, if so, it is continuously determined whether the current user name and the password are matched, and if so, it is determined that the current identity information meets the preset authentication requirement. And if the current identity information is judged not to meet the preset authentication requirement, prompting information for forbidding access can be sent to the channel side.
In one embodiment of the present invention, further comprising:
judging whether each service is in a healthy state;
if not, sending out a prompt of abnormal service.
The state information of the server where each service is located, such as the CPU utilization, the number of processes, and the physical memory occupancy, can be obtained first. And judging whether each service is in a healthy state according to the state information. And if the business service in the unhealthy state exists, sending out a prompt of abnormal service to prompt related technical personnel to check so as to ensure the overall stable operation of the system.
In one embodiment of the present invention, further comprising:
judging whether the monitoring service is in an unavailable state;
and if so, carrying out fusing processing on the monitoring service.
When a request is sent to a server, proxy is carried out through a fuse, timeout time and retry times of the fuse can be set, failure logic is triggered or retry is carried out when the request of the fuse proxy is not responded after a period of time, the number of times of request failure of a service instance is counted in a sliding window, fusing is triggered when the call failure ratio in the window is higher than a threshold value, and the corresponding service instance is marked to be unavailable.
In one embodiment of the present invention, further comprising:
determining the maximum concurrency and the current access number of the target business service;
judging whether the current access number is larger than the maximum concurrency amount or not;
if so, the service request is discarded.
If the current access number of the business service is larger than the maximum concurrency of the business service, the service party of the business service may be unable to access or even down due to excessive access needing to be processed. Therefore, in order to ensure the normal operation of the business service, under the condition that the current access number is large, the partial service request can be discarded.
Fig. 5 is a schematic diagram of a flow of a service request distribution method according to an embodiment of the present invention, where, as shown in fig. 5, the method includes:
step 501: and receiving a service request sent by a channel party.
Step 502: determining a target business service according to the service request, wherein the target business service comprises: services based on a centralized architecture and services based on a micro-service architecture.
Step 503: and distributing the service request according to the target service.
Step 504: and determining at least one service component corresponding to the business service, wherein the business service is a service based on the micro-service architecture.
Step 505: at least one service component is orchestrated to generate sub-models of business services.
In one embodiment of the present invention, step 505 comprises:
acquiring and storing registration information of the service component, wherein the registration information comprises at least one of the following information: ip address, port number, service agent and service identification;
and determining at least one service component corresponding to the business service according to the registration information.
With component orchestration, a single application can be split into many loosely coupled and independently deployable smaller components or services. The component arrangement can enhance the reusability of codes, reduce the software development cost and the test cost, improve the maintainability of software and reduce the maintenance cost.
Step 506: and responding to the service request according to the submodel.
In the embodiment of the invention, the target business service is determined according to the service request sent by the channel side, and the target business service can be a service based on a centralized architecture or a service based on a micro-service architecture. The method comprises the steps of setting up a sub-model for a micro-service architecture-based service in a stream arrangement mode, and responding to a service request according to the sub-model. Therefore, the method of the embodiment of the invention can better and flexibly support the problems of a centralized service architecture and a distributed micro-service architecture.
In addition, the embodiment of the invention also provides a distributed platform integration scheme. The integration scheme is combined with the prior component application SOA architecture to integrate the distributed platform scheme, and new technical architectures such as enterprise level gateways, micro service gateways, micro services and the like are introduced; the method supports the interaction capability in the north-south direction and the east-west direction, and adds the adaptation support to new messages and protocols on the adaptation capability; a new service integration agent function supports the integration capability of cross-distributed component application service and the existing application component service according to service elements; an application routing function is newly added, the south-north direction and east-west direction interaction capacity is supported, and the request can be forwarded according to business elements in different scenes, so that the distributed application service is transparent to the position of a channel; the configuration center addressing function is enhanced, and meanwhile, the service addressing of the existing centralized architecture service addressing and the service addressing of the distributed micro-service architecture are supported, so that the distributed micro-service architecture based on the existing SOA architecture is supported to be smoothly and effectively implemented. The integration scheme comprises the following steps: application routing, service integration proxy and configuration center.
Fig. 6 is a schematic structural diagram of a service request distribution system according to an embodiment of the present invention. As shown in fig. 6, the system includes: channel side, service side, application route, configuration center and service integration agent.
The application route is used for receiving a service request sent by a channel party; determining a target business service according to the service request, wherein the target business service comprises: services based on a centralized architecture or services based on a micro-service architecture; distributing the service request to a service party according to the target service;
the service integration agent is used for determining at least one service component corresponding to the service, and the service is centralized architecture service or micro service architecture service; arranging at least one service component to generate a sub-model of a business service;
and the configuration center is used for determining and storing the corresponding relation between the business service or the sub-model and the request parameters.
Optionally, the application routing is specifically configured to:
determining request parameters for the service request, the request parameters including at least one of: path parameters, identity information, a current domain name and service parameters;
and determining the target business service according to the request parameters.
Optionally, the application routing is specifically configured to:
acquiring a corresponding relation;
and determining the target business service according to the request parameters and the corresponding relation.
Optionally, the service integration agent is specifically configured to:
determining at least one service component corresponding to a business service, wherein the business service is a service based on a centralized architecture or a service based on a micro-service architecture;
at least one service component is orchestrated to generate a sub-model of the business service, the sub-model for responding to service requests.
Optionally, the service integration agent is specifically configured to:
acquiring and storing registration information of the service component, wherein the registration information comprises at least one of the following information: ip address, port number, service agent and service identification;
and determining at least one service component corresponding to the business service according to the registration information.
Optionally, the application route is further for:
judging whether the message of the service request needs to be decrypted or not;
if yes, the message of the service request is decrypted.
Optionally, the application route is further for:
acquiring preset safety parameter information from a configuration file of a configuration center;
and decrypting the message of the service request according to the security parameter information.
Optionally, the application route is further for:
judging whether the message of the service request needs to be encrypted;
if yes, the message of the service request is encrypted.
Optionally, the application route is further for:
determining the identity information of a channel party according to the service request;
judging whether the identity information meets the preset authentication requirement or not;
if yes, executing a service distribution request step;
if not, a prompt for prohibiting access is sent out.
Optionally, the application route is further for:
judging whether each service is in a healthy state;
if not, sending out a prompt of abnormal service.
Optionally, the application route is further for: :
judging whether the monitoring service is in an unavailable state;
and if so, performing fusing processing on the monitoring service.
Optionally, the application route is further for:
determining the maximum concurrency and the current access number which are also used for the target business service;
judging whether the current access number is larger than the maximum concurrency amount or not;
if so, discard and still use for the service request.
Under the distributed micro-service architecture, an application route is used as a uniform entrance for a channel party to access a service party application, is addressed and forwarded to different physical positions of a service party application instance according to a message of the channel party, has self-protection capability and capability of protecting downstream services, is logically decoupled from specific services, adopts a 'stateless' design, and simultaneously realizes transaction-level current limiting, degradation, fusing, link tracking and the like. The specific role of application routing is as follows:
(1) the uniform access specification is provided, the channel side is supported to access the back-end component by adopting different protocols, and the iterative update of subsequent channel side application is facilitated.
(2) The distributed server application has corresponding hosting service capability, a uniform forwarding mode is provided according to request message characteristics and physical deployment of a rear-end distributed application instance, and the distributed application selects a specific mode according to configuration.
(3) Increasing flow control capacity, and controlling the inlet flow within a bearable range by defining various factors such as distributed service overtime threshold values and the like; current limiting and fusing are carried out on the downstream distributed application; and flow control is carried out on the downstream distributed application by expanding various factors such as the maximum transaction concurrency number, the service baseline current limiting rule/fusing rule and the like.
(4) The online/offline management capability of the service integration agent instance and each instance of the distributed application is provided, and the service processing and calling (giant service, small service and micro service) with different granularities are supported.
(5) The system has measurable and trackable capacity, is turned on or off in a switching mode, monitors the performance of the system, the transaction time consumption, the transaction amount and the transaction success rate in real time by collecting logs, and generates a dynamic topology of managed services in real time by defining various tracking conditions (such as time, transaction ID, employee number and the like) and preset embedded points.
(6) The method has corresponding security identity, provides encryption and decryption service, authentication and tamper-proof service for the message, provides point-to-point conversion encryption and decryption service for sensitive data, and can assign a specific encryption and decryption algorithm through the message by a channel side application; inheriting the security and other element processing modes of the original centralized rear-end service party.
(7) The method adopts a service logic minimization design, realizes 'stateless' in design, focuses on unified access, transaction forwarding and message encryption and decryption, does not process service related logic, and deals with peak access flow through horizontal extension.
(8) The system has the capacity of multiple places, multiple centers and multiple activities, is deployed according to central units, has service isolation among all internal modules, and avoids the existence of concentration points during physical deployment.
The role of the service integration agent design is as follows: according to the distributed transformation and deployment conditions of the service side, a service integration agent cluster is newly added, an enterprise-level service integration agent mode is realized, a service arrangement and combination function is provided, and the service consistency and other processing are completed; the method fully considers the function and development of the current business, establishes the sub-models of various service arrangement, completes the realization of the business function by the assembly of the sub-models, and simplifies the complexity of development design and the like; the consistency of abnormal scenes is not required to be considered during the distributed service logic processing, and only the normal service logic is required to be considered.
The configuration center is designed to be combined with the existing SOA architecture to perform distributed platform scheme integration and provide the unified service information registration and management functions for the enterprise system. The specific role of the configuration center is as follows:
(1) according to the distributed transformation and deployment conditions of a server, distributed cluster expansion is carried out in multiple centers, data of the distributed cluster expansion is globally shared in an enterprise, and high availability and disaster recovery requirements are met; the fault of any single machine room configuration center does not affect the external service capability of machine rooms in different cities and machine rooms in different places.
(2) The method provides the public basic capabilities of enterprise-level service configuration management, service discovery and treatment, service load balancing, service fault isolation and recovery and the like so as to support the landing implementation of the distributed micro-service on the basis of the existing SOA architecture.
(3) And according to the design requirement of the distributed micro-service architecture, the unitized positioning capability is perfected.
(4) And diversified capacity design is carried out, and the self-defined and free service management capacity is realized based on the existing standard service management capacity.
The technical scheme of the embodiment of the invention carries out complete inheritance on the design of the existing SOA architecture of an enterprise. The design and landing practice of the distributed micro-service architecture is supported on the basis of keeping the existing enterprise service capability. Under the condition of coexistence of a centralized architecture and a distributed micro-service architecture, smooth transition is realized through incremental gradual switching; in the design process of the distributed micro-service architecture, a transition process from a transition state to a target state is provided, in the transition state, the centralized switching to the distributed switching can support the self-defined dimension switching according to mechanisms or applications and the like, and the normal development of the service of a switching object is not influenced. The distributed micro-service transformation is insensitive to the application of the channel side service and supports the flexibility of the channel side service; reducing the risk of dependence on external systems.
The method of the embodiment of the invention can meet the design requirements of various customized services of enterprises, provides a distributed fusion design with rich functions and strong performance, and the design supports that one large functional module is decomposed into different micro-services for realization through a function decomposition mode according to the service functions, thereby realizing function focusing and fault isolation and being suitable for various complex service scenes; and an incremental and progressive switching mode is supported, and the manageable operability is ensured.
An embodiment of the present invention provides an electronic device, including:
one or more processors;
a storage device for storing one or more programs,
when the one or more programs are executed by the one or more processors, the one or more processors are caused to implement the method of any of the embodiments described above.
Referring now to FIG. 7, shown is a block diagram of a computer system 700 suitable for use with a terminal device implementing an embodiment of the present invention. The terminal device shown in fig. 7 is only an example, and should not bring any limitation to the functions and the scope of use of the embodiments of the present invention.
As shown in fig. 7, the computer system 700 includes a Central Processing Unit (CPU)701, which can perform various appropriate actions and processes in accordance with a program stored in a Read Only Memory (ROM)702 or a program loaded from a storage section 708 into a Random Access Memory (RAM) 703. In the RAM 703, various programs and data necessary for the operation of the system 700 are also stored. The CPU 701, the ROM 702, and the RAM 703 are connected to each other via a bus 704. An input/output (I/O) interface 705 is also connected to bus 704.
The following components are connected to the I/O interface 705: an input portion 706 including a keyboard, a mouse, and the like; an output section 707 including a display such as a Cathode Ray Tube (CRT), a Liquid Crystal Display (LCD), and the like, and a speaker; a storage section 708 including a hard disk and the like; and a communication section 709 including a network interface card such as a LAN card, a modem, or the like. The communication section 709 performs communication processing via a network such as the internet. A drive 710 is also connected to the I/O interface 705 as needed. A removable medium 711 such as a magnetic disk, an optical disk, a magneto-optical disk, a semiconductor memory, or the like is mounted on the drive 710 as necessary, so that a computer program read out therefrom is mounted into the storage section 708 as necessary.
In particular, according to the embodiments of the present disclosure, the processes described above with reference to the flowcharts may be implemented as computer software programs. For example, embodiments of the present disclosure include a computer program product comprising a computer program embodied on a computer readable medium, the computer program comprising program code for performing the method illustrated in the flow chart. In such an embodiment, the computer program can be downloaded and installed from a network through the communication section 709, and/or installed from the removable medium 711. The computer program performs the above-described functions defined in the system of the present invention when executed by the Central Processing Unit (CPU) 701.
It should be noted that the computer readable medium shown in the present invention can be a computer readable signal medium or a computer readable storage medium or any combination of the two. A computer readable storage medium may be, for example, but not limited to, an electronic, magnetic, optical, electromagnetic, infrared, or semiconductor system, apparatus, or device, or any combination of the foregoing. More specific examples of the computer readable storage medium may include, but are not limited to: an electrical connection having one or more wires, a portable computer diskette, a hard disk, a Random Access Memory (RAM), a read-only memory (ROM), an erasable programmable read-only memory (EPROM or flash memory), an optical fiber, a portable compact disc read-only memory (CD-ROM), an optical storage device, a magnetic storage device, or any suitable combination of the foregoing. In the present invention, a computer readable storage medium may be any tangible medium that can contain, or store a program for use by or in connection with an instruction execution system, apparatus, or device. In the present invention, however, a computer readable signal medium may include a propagated data signal with computer readable program code embodied therein, for example, in baseband or as part of a carrier wave. Such a propagated data signal may take many forms, including, but not limited to, electro-magnetic, optical, or any suitable combination thereof. A computer readable signal medium may also be any computer readable medium that is not a computer readable storage medium and that can communicate, propagate, or transport a program for use by or in connection with an instruction execution system, apparatus, or device. Program code embodied on a computer readable medium may be transmitted using any appropriate medium, including but not limited to: wireless, wire, fiber optic cable, RF, etc., or any suitable combination of the foregoing.
The flowchart and block diagrams in the figures illustrate the architecture, functionality, and operation of possible implementations of systems, methods and computer program products according to various embodiments of the present invention. In this regard, each block in the flowchart or block diagrams may represent a module, segment, or portion of code, which comprises one or more executable instructions for implementing the specified logical function(s). It should also be noted that, in some alternative implementations, the functions noted in the block may occur out of the order noted in the figures. For example, two blocks shown in succession may, in fact, be executed substantially concurrently, or the blocks may sometimes be executed in the reverse order, depending upon the functionality involved. It will also be noted that each block of the block diagrams or flowchart illustration, and combinations of blocks in the block diagrams or flowchart illustration, can be implemented by special purpose hardware-based systems which perform the specified functions or acts, or combinations of special purpose hardware and computer instructions.
The modules described in the embodiments of the present invention may be implemented by software or hardware. The described modules may also be provided in a processor, which may be described as: application routing, configuration center and service integration agent. The names of the modules do not form a limitation on the modules per se under certain conditions, for example, application routing can also be described as receiving a service request sent by a channel side; determining a target business service according to the service request, wherein the target business service comprises: services based on a centralized architecture or services based on a micro-service architecture; and a module for distributing the service request to the service party according to the target service.
As another aspect, the present invention also provides a computer-readable medium that may be contained in the apparatus described in the above embodiments; or may be separate and not incorporated into the device. The computer readable medium carries one or more programs which, when executed by a device, cause the device to comprise:
receiving a service request sent by a channel party;
determining a target business service according to the service request, wherein the target business service comprises: services based on a centralized architecture and services based on a micro-service architecture;
and distributing the service request according to the target service.
According to the technical scheme of the embodiment of the invention, the target business service is determined based on the service request sent by the channel side, the target business service can be a service based on a centralized architecture or a micro-service architecture, and the service request is distributed according to the target business service. Therefore, the method of the embodiment of the invention can better support a centralized service architecture and a distributed micro-service architecture at the same time.
The above-described embodiments should not be construed as limiting the scope of the invention. Those skilled in the art will appreciate that various modifications, combinations, sub-combinations, and substitutions can occur, depending on design requirements and other factors. Any modification, equivalent replacement, and improvement made within the spirit and principle of the present invention should be included in the protection scope of the present invention.

Claims (15)

1. A service request distribution method, comprising:
receiving a service request sent by a channel party;
determining a target business service according to the service request, wherein the target business service comprises: services based on a centralized architecture and services based on a micro-service architecture;
and distributing the service request according to the target service.
2. The method of claim 1, wherein the determining a target business service according to the service request comprises:
determining request parameters for the service request, the request parameters including at least one of: path parameters, identity information, a current domain name and service parameters;
and determining the target business service according to the request parameters.
3. The method of claim 2, further comprising:
determining and storing the corresponding relation between the business service and the request parameter;
the determining the target business service according to the request parameter includes:
acquiring the corresponding relation;
and determining the target business service according to the request parameters and the corresponding relation.
4. The method of claim 1, further comprising:
determining at least one service component corresponding to a business service, wherein the business service is a service based on a centralized architecture or a service based on a micro-service architecture;
arranging the at least one service component to generate a sub-model of the business service, the sub-model being used to respond to service requests.
5. The method of claim 4, wherein before determining at least one service component corresponding to the business service, further comprising:
acquiring and storing registration information of a service component, wherein the registration information comprises at least one of the following: ip address, port number, service agent and service identification;
and determining the at least one service component corresponding to the business service according to the registration information.
6. The method of claim 1, further comprising:
judging whether the message of the service request needs to be decrypted or not;
and if so, decrypting the message of the service request.
7. The method according to claim 6, wherein the decrypting the message of the service request includes:
acquiring safety processing parameter information from configuration information of a configuration center;
and decrypting the message of the service request according to the safety processing parameter information.
8. The method of claim 1, further comprising:
judging whether the message of the service request needs to be encrypted;
and if so, encrypting the message of the service request.
9. The method of claim 1, further comprising:
determining the identity information of the channel party according to the service request;
judging whether the identity information meets a preset authentication requirement or not;
if yes, executing the step of distributing the service request;
if not, a prompt for prohibiting access is sent out.
10. The method of claim 1, further comprising:
judging whether each service is in a healthy state;
if not, sending out a prompt of abnormal service.
11. The method of claim 1, further comprising:
judging whether the monitoring service is in an unavailable state;
and if so, carrying out fusing processing on the monitoring service.
12. The method of claim 1, further comprising:
determining the maximum concurrency and the current access number of the target business service;
judging whether the current access number is larger than the maximum concurrency amount or not;
and if so, discarding the service request.
13. A service request distribution system, comprising: a channel party, a service party, an application route, a configuration center and a service integration agent;
the application route is used for receiving a service request sent by a channel party; determining a target business service according to the service request, wherein the target business service comprises: services based on a centralized architecture or services based on a micro-service architecture; according to the target business service, the service request is distributed to the service party;
the service integration agent is used for determining at least one service component corresponding to a business service, wherein the business service is a service based on a centralized architecture or a service based on a micro-service architecture; arranging the at least one service component to generate a sub-model of the business service;
the configuration center is used for determining and storing the corresponding relation between the business service and the request parameter.
14. An electronic device, comprising:
one or more processors;
a storage device for storing one or more programs,
when executed by the one or more processors, cause the one or more processors to implement the method of any one of claims 1-12.
15. A computer-readable medium, on which a computer program is stored, which, when being executed by a processor, carries out the method according to any one of claims 1-12.
CN202110266612.5A 2021-03-10 2021-03-10 Service request distribution method and system Active CN113055470B (en)

Priority Applications (1)

Application Number Priority Date Filing Date Title
CN202110266612.5A CN113055470B (en) 2021-03-10 2021-03-10 Service request distribution method and system

Applications Claiming Priority (1)

Application Number Priority Date Filing Date Title
CN202110266612.5A CN113055470B (en) 2021-03-10 2021-03-10 Service request distribution method and system

Publications (2)

Publication Number Publication Date
CN113055470A true CN113055470A (en) 2021-06-29
CN113055470B CN113055470B (en) 2023-04-28

Family

ID=76511699

Family Applications (1)

Application Number Title Priority Date Filing Date
CN202110266612.5A Active CN113055470B (en) 2021-03-10 2021-03-10 Service request distribution method and system

Country Status (1)

Country Link
CN (1) CN113055470B (en)

Cited By (3)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN114363378A (en) * 2022-01-14 2022-04-15 上海交通大学 Micro-service system architecture and management method for industrial heterogeneous network management
CN114827228A (en) * 2022-04-21 2022-07-29 马上消费金融股份有限公司 Link processing method and device
CN115001956A (en) * 2022-05-24 2022-09-02 中国平安财产保险股份有限公司 Server cluster operation method, device, equipment and storage medium

Citations (6)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN107438101A (en) * 2017-07-26 2017-12-05 北京中电普华信息技术有限公司 A kind of service extension method and device of monomer-type application
CN110310034A (en) * 2019-06-28 2019-10-08 京东数字科技控股有限公司 A kind of service orchestration applied to SaaS, business flow processing method and apparatus
CN110519379A (en) * 2019-08-29 2019-11-29 泰康保险集团股份有限公司 Request processing method and equipment based on micro services
CN110928709A (en) * 2019-11-21 2020-03-27 中国民航信息网络股份有限公司 Service calling method and device under micro-service framework and server
CN111163166A (en) * 2019-12-30 2020-05-15 广州银行股份有限公司 Enterprise service bus system
CN112165507A (en) * 2020-08-27 2021-01-01 福建摩尔软件有限公司 Method, device, equipment and medium for supporting multi-service architecture by single Web project

Patent Citations (6)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN107438101A (en) * 2017-07-26 2017-12-05 北京中电普华信息技术有限公司 A kind of service extension method and device of monomer-type application
CN110310034A (en) * 2019-06-28 2019-10-08 京东数字科技控股有限公司 A kind of service orchestration applied to SaaS, business flow processing method and apparatus
CN110519379A (en) * 2019-08-29 2019-11-29 泰康保险集团股份有限公司 Request processing method and equipment based on micro services
CN110928709A (en) * 2019-11-21 2020-03-27 中国民航信息网络股份有限公司 Service calling method and device under micro-service framework and server
CN111163166A (en) * 2019-12-30 2020-05-15 广州银行股份有限公司 Enterprise service bus system
CN112165507A (en) * 2020-08-27 2021-01-01 福建摩尔软件有限公司 Method, device, equipment and medium for supporting multi-service architecture by single Web project

Cited By (6)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN114363378A (en) * 2022-01-14 2022-04-15 上海交通大学 Micro-service system architecture and management method for industrial heterogeneous network management
CN114363378B (en) * 2022-01-14 2022-10-11 上海交通大学 Micro-service system architecture and management method for industrial heterogeneous network management
CN114827228A (en) * 2022-04-21 2022-07-29 马上消费金融股份有限公司 Link processing method and device
CN114827228B (en) * 2022-04-21 2024-04-09 马上消费金融股份有限公司 Link processing method and device
CN115001956A (en) * 2022-05-24 2022-09-02 中国平安财产保险股份有限公司 Server cluster operation method, device, equipment and storage medium
CN115001956B (en) * 2022-05-24 2023-06-16 中国平安财产保险股份有限公司 Method, device, equipment and storage medium for running server cluster

Also Published As

Publication number Publication date
CN113055470B (en) 2023-04-28

Similar Documents

Publication Publication Date Title
Bierzynski et al. Cloud, fog and edge: Cooperation for the future?
CN113055470B (en) Service request distribution method and system
US10116507B2 (en) Method of and system for managing computing resources
US9667653B2 (en) Context-aware network service policy management
US20180337893A1 (en) Scalable proxy clusters
US11645144B2 (en) Methods and systems securing an application based on auto-learning and auto-mapping of application services and APIs
CN112187491A (en) Server management method, device and equipment
US20070115818A1 (en) Triggered notification
Bracciale et al. Lightweight named object: An ICN-based abstraction for IoT device programming and management
CN109597643A (en) Using gray scale dissemination method, device, electronic equipment and storage medium
CN114175591B (en) Peer node discovery procedure for disconnected nodes in a software defined network
CN112202744B (en) Multi-system data communication method and device
EP1665725B1 (en) Remote ipsec security association management
CN110932860A (en) Channel switching method, device, equipment and storage medium based on multiple CA
US11595471B1 (en) Method and system for electing a master in a cloud based distributed system using a serverless framework
Costa et al. Enhancing orchestration and infrastructure programmability in SDN with notoriety
US11777870B1 (en) Machine-learning (ML)-based systems and methods for maximizing resource utilization
Duong et al. Tracking events in mobile device management system
CN110932861A (en) Digital certificate management method, device, equipment and storage medium based on multiple CA
CN111866100A (en) Method, device and system for controlling data transmission rate
Zhu A survey on mobile edge platform with blockchain
US10447777B1 (en) Method and system for providing a dynamically updated expertise and context based peer-to-peer customer support system within a software application
CN115550322B (en) User registration method and device based on network security protocol, electronic equipment and medium
KR20150002228A (en) Method and apparatus of controlling selective multi-connection in M2M System
US11258720B2 (en) Flow-based isolation in a service network implemented over a software-defined network

Legal Events

Date Code Title Description
PB01 Publication
PB01 Publication
SE01 Entry into force of request for substantive examination
SE01 Entry into force of request for substantive examination
GR01 Patent grant
GR01 Patent grant