A method and device for executing business

By receiving service requests and configuring the middleware of the target service, using the middleware code and configuration data of the storage center, the serious problem of middleware coupling with the business is solved, and the development and update efficiency is improved.

CN112596780BActive Publication Date: 2025-08-22BEIJING SANKUAI ONLINE TECH CO LTD
View PDF 1 Cites 0 Cited by

Patent Information

Application Number
CN202011488555.7
Authority / Receiving Office
CN · China
Patent Type
Patents(China)
Current Assignee / Owner
Filing Date
2020-12-16
Publication Date
2025-08-22
Estimated Expiration
2040-12-16

AI Technical Summary

Technical Problem

The existing middleware is severely coupled with the target business, resulting in cumbersome business code modification and reducing development and update efficiency.

Method used

By receiving service requests, determine the target service and configure the corresponding middleware to be configured, and dynamically configure the middleware using the middleware code and configuration data in the storage center to reduce the coupling between the middleware and the service.

Benefits of technology

It realizes dynamic configuration of middleware, simplifies the process of adding, deleting and modifying middleware, and improves the work efficiency of developers.

✦ Generated by Eureka AI based on patent content.

Smart Images

  • Figure CN112596780B_ABST
    Figure CN112596780B_ABST
Patent Text Reader

Abstract

This specification discloses a method and device for executing a business, which receives a business request sent by a user, determines the business corresponding to the business request as the target business, and determines at least one middleware to be configured corresponding to the target business. For each middleware to be configured, the middleware code corresponding to the middleware to be configured and the middleware configuration data corresponding to the middleware to be configured stored in a preset storage center are used to configure the middleware to be configured, thereby obtaining the configured middleware. According to each configured middleware, the target business is executed. When receiving a business request sent by a user, this method can configure the middleware to execute the target business corresponding to the business request, thereby reducing the coupling between the middleware and the business and realizing the dynamic configuration of the middleware. By separating the middleware code or the middleware configuration data, developers can save a lot of time and improve work efficiency when modifying the middleware.
Need to check novelty before this filing date? Find Prior Art

Description

Technical Field

[0001] This specification relates to the field of computer technology, and in particular to a method and device for executing a service. Background Art

[0002] Middleware is a type of software that sits between application systems and system software. It uses the basic services (functions) provided by system software to connect various parts of application systems or different applications on the network, thereby achieving the purpose of resource sharing and function sharing.

[0003] Currently, most projects develop middleware based on customized business requirements. This customized middleware is heavily coupled with the target business, resulting in a lack of flexibility in subsequent modifications, maintenance, and upgrades to the business code. For example, changes in business requirements necessitate modifications to the middleware. However, each addition, deletion, or modification requires re-downloading the entire business code, modifying the middleware, and then re-releasing it. This process of adding, deleting, and modifying middleware is cumbersome, and every change in business requirements can require modifications to the middleware, which consumes significant developer time and reduces productivity.

[0004] Therefore, how to avoid serious coupling between middleware and target business and improve the efficiency of business development and update is an urgent problem to be solved. Summary of the Invention

[0005] This specification provides a method, device, storage medium, and electronic device for executing a service to partially solve the above-mentioned problems existing in the prior art.

[0006] This manual adopts the following technical solutions:

[0007] This specification provides a method for executing a service, including:

[0008] Receive business requests sent by users;

[0009] According to the service request, determining a service corresponding to the service request as a target service;

[0010] Determining, according to the target business, at least one middleware to be configured corresponding to executing the target business;

[0011] For each middleware to be configured, configure the middleware to be configured using the middleware code corresponding to the middleware to be configured and the middleware configuration data corresponding to the middleware to be configured stored in a preset storage center to obtain the configured middleware;

[0012] According to each configured middleware, the target business is executed.

[0013] Optionally, determining, according to the target service, at least one middleware to be configured corresponding to executing the target service specifically includes:

[0014] Determining the middleware involved in executing the target business as the target middleware;

[0015] A middleware that has not been configured is determined from the target middleware as the middleware to be configured.

[0016] Optionally, according to each configured middleware, before executing the target service, the method further includes:

[0017] Determining deployed middleware other than the at least one middleware to be configured from the target middleware;

[0018] According to each configured middleware, the target business is executed, specifically including:

[0019] The configured middlewares are deployed, and the target business is executed according to the deployed middlewares and the configured middlewares.

[0020] Optionally, determining deployed middleware other than the at least one middleware to be configured specifically includes:

[0021] Determine the pre-cached middleware;

[0022] For each target middleware, if the pre-cached middleware includes the target middleware, the target middleware is determined to be a deployed middleware.

[0023] Optionally, before executing the target service according to the deployed middleware and each configured middleware, the method further includes:

[0024] Determining the middleware identifier of the deployed middleware;

[0025] querying, from the storage center according to the middleware identifier, whether there is data update for the middleware code and / or middleware configuration data corresponding to the deployed middleware;

[0026] If so, the deployed middleware is updated using the middleware code and middleware configuration data corresponding to the deployed middleware stored in the storage center.

[0027] Optionally, for each middleware to be configured, configuring the middleware to be configured by using the middleware code corresponding to the middleware to be configured and the middleware configuration data corresponding to the middleware to be configured stored in a preset storage center specifically includes:

[0028] For each middleware to be configured, determine the identifier corresponding to the middleware to be configured;

[0029] The identifier is sent to the storage center so that the storage center configures the middleware to be configured according to the identifier, the middleware code corresponding to the middleware to be configured, and the middleware configuration data corresponding to the middleware to be configured, wherein different middlewares correspond to different identifiers, and the identifier is used to distinguish the same custom variable names in different middlewares.

[0030] This specification provides a system for business execution, including: a storage center and a business platform;

[0031] The business platform is configured to receive a business request sent by a user, determine the business corresponding to the business request as a target business based on the business request, determine at least one to-be-configured middleware corresponding to the target business to be executed based on the target business, send a data acquisition request to a preset storage center for each to-be-configured middleware to obtain the middleware code and middleware configuration data corresponding to the to-be-configured middleware from the storage center, configure the to-be-configured middleware based on the middleware code and middleware configuration data corresponding to the to-be-configured middleware, obtain configured middleware, and execute the target business based on each configured middleware;

[0032] The storage center is used to receive the data acquisition request sent by the business platform, query the middleware code and middleware configuration data that the business platform needs to obtain according to the data acquisition request, and return the query middleware code and middleware configuration data to the business platform.

[0033] Optionally, the storage center includes: a first sub-storage center and a second sub-storage center, the first sub-storage center stores middleware codes corresponding to each middleware, and the second sub-storage center stores middleware configuration data corresponding to each middleware.

[0034] Optionally, the storage center is further configured to, for each middleware, update the middleware code corresponding to the middleware stored in the first sub-storage center based on the acquired changed middleware code corresponding to the middleware if a change is detected in the middleware code corresponding to the middleware;

[0035] The storage center is also used to update the middleware configuration data corresponding to each middleware stored in the second sub-storage center based on the acquired changed middleware configuration data corresponding to the middleware, if it monitors that the middleware configuration data corresponding to the middleware has changed.

[0036] This specification provides a device for executing a service, including:

[0037] Receiving module, used to receive service requests sent by users;

[0038] A service module, configured to determine, according to the service request, a service corresponding to the service request as a target service;

[0039] A determination module, configured to determine, based on the target business, at least one middleware to be configured that executes the target business;

[0040] A configuration module configured to configure each middleware to be configured by using the middleware code corresponding to the middleware to be configured and the middleware configuration data corresponding to the middleware to be configured stored in a preset storage center to obtain the configured middleware;

[0041] The execution module is used to execute the target business according to each configured middleware.

[0042] This specification provides a computer-readable storage medium, which stores a computer program. When the computer program is executed by a processor, the method for executing the above-mentioned service is implemented.

[0043] This specification provides an electronic device, including a memory, a processor, and a computer program stored in the memory and executable on the processor, wherein the processor implements the above-mentioned service execution method when executing the program.

[0044] At least one of the above technical solutions adopted in this specification can achieve the following beneficial effects:

[0045] In the service execution method provided in this specification, a service request sent by a user is received. Based on the service request, the service corresponding to the service request is determined as a target service. Based on the target service, at least one middleware to be configured corresponding to the target service is determined. Then, for each middleware to be configured, the middleware code and middleware configuration data corresponding to the middleware to be configured stored in a preset storage center are used to configure the middleware to be configured, thereby obtaining a configured middleware. Finally, the target service is executed based on each configured middleware.

[0046] It can be seen from the above method that when a business request sent by a user is received, the middleware that executes the target business corresponding to the business request can be configured, thereby reducing the coupling between the middleware and the business and realizing the dynamic configuration of the middleware. In addition, in the process of determining the configured middleware, it is necessary to combine the middleware code corresponding to the middleware to be configured and the middleware configuration data corresponding to the middleware to be configured to obtain the configured middleware. In other words, the middleware code or the middleware configuration data is separated, so that the middleware code or the middleware configuration data can be modified separately, avoiding the tedious process of adding, deleting and modifying middleware, saving developers a lot of time and improving work efficiency. BRIEF DESCRIPTION OF THE DRAWINGS

[0047] The drawings described herein are used to provide a further understanding of this specification and constitute a part of this specification. The exemplary embodiments and descriptions of this specification are used to explain this specification and do not constitute an improper limitation of this specification. In the drawings:

[0048] Figure 1 A flowchart of a method for executing a service provided in an embodiment of this specification;

[0049] Figure 2 A schematic diagram of a business platform and storage center processing process provided in an embodiment of this specification;

[0050] Figure 3 A schematic diagram of the structure of a device for executing a service provided in an embodiment of this specification;

[0051] Figure 4 This is a schematic diagram of the structure of an electronic device provided in an embodiment of this specification. DETAILED DESCRIPTION

[0052] To make the objectives, technical solutions, and advantages of this specification more clear, the following will clearly and completely describe the technical solutions of this specification in conjunction with the specific embodiments of this specification and the corresponding drawings. Obviously, the embodiments described are only part of the embodiments of this specification, not all of the embodiments. Based on the embodiments in this specification, all other embodiments obtained by ordinary technicians in this field without making any creative efforts are within the scope of protection of this specification.

[0053] The technical solutions provided by the embodiments of this specification are described in detail below with reference to the accompanying drawings.

[0054] In the embodiment of this specification, the service corresponding to the service request sent by the user is taken as the target service. To execute the target service, it is necessary to configure the middleware corresponding to the target service, and then execute the target service according to the configured middleware. Therefore, the following will first introduce the process of configuring the middleware to be configured corresponding to the target service, obtaining the configured middleware, and executing the target service. Figure 1 shown.

[0055] Figure 1 A flowchart of a method for executing a service provided in an embodiment of this specification specifically includes the following steps:

[0056] S100: Receive a service request sent by a user.

[0057] In the embodiments of this specification, a service platform can receive service requests sent by users. The terminal device used by the user to send the service request can be a mobile phone, tablet computer, or other terminal device, and the entity that executes the service request can be the service platform, server, or other entity. For ease of description, the following describes a service execution method provided in this specification using the service platform as the execution entity.

[0058] S102: According to the service request, determine the service corresponding to the service request as the target service.

[0059] S104: Determine, according to the target service, at least one middleware to be configured that executes the target service.

[0060] In the embodiments of this specification, each business request corresponds to a business. Therefore, after receiving the business request, the business platform can determine the business corresponding to the business request as the target business based on the business request. The target business mentioned here can be any business, such as online shopping business, online car-hailing business, takeout ordering business, etc.

[0061] Among them, the target business can have multiple target middlewares to execute the target business. The target middleware here refers to the middleware involved in executing the target business. Different target middlewares provide different business functions during the execution of the target business. Therefore, before the business platform executes the target business according to the business request, it needs to first determine the multiple target middlewares corresponding to the target business.

[0062] For the multiple target middleware corresponding to the target business, some target middleware may have been configured and deployed in the business platform, while some may not have been configured yet. Therefore, the middleware that has not been configured in the target middleware can be called middleware to be configured, and the middleware other than the middleware to be configured in the target middleware can be called deployed middleware. Some of the middleware pre-cached in the business platform can be configured by the business platform when executing business in the past. Therefore, if the pre-cached middleware contains the target middleware corresponding to the target business (that is, the deployed middleware), the deployed middleware can be directly obtained.

[0063] S106: For each middleware to be configured, configure the middleware to be configured using the middleware code corresponding to the middleware to be configured and the middleware configuration data corresponding to the middleware to be configured stored in a preset storage center to obtain the configured middleware.

[0064] In an embodiment of the present specification, the storage center pre-stores the middleware code and the middleware configuration data corresponding to the middleware code. The pre-stored middleware code and the middleware configuration data corresponding to the middleware code can be pre-stored by developers in the storage center. That is, developers can develop the middleware code and middleware configuration data corresponding to the middleware involved in the business execution process according to actual business needs, and upload the middleware code and middleware configuration data to the storage center for storage. Among them, the middleware code and middleware configuration data corresponding to a middleware contain the same middleware identification information. When configuring the middleware later, the middleware code and middleware configuration data corresponding to the middleware identification of the middleware to be configured can be determined from the storage center according to the middleware identification of the middleware to be configured, so as to configure the middleware to be configured.

[0065] For a piece of middleware, the middleware code corresponding to the middleware can be used to reflect the business logic of the middleware when performing data processing, while the middleware configuration data corresponding to the middleware can be used to reflect the specific data type that the middleware needs to process. As can be seen from the above, since the middleware code and middleware configuration data of the same middleware can be stored separately in the storage center, when developers make changes to a piece of middleware, they can only modify the middleware code or the middleware configuration data according to actual needs, which greatly improves the efficiency of developers' middleware updates.

[0066] In actual applications, the variable names in the middleware code are often customized by the developer. Therefore, the middleware codes corresponding to different middleware in the storage center may contain the same variable names. For example, the developer sets the variable name representing the user name in the middleware code corresponding to middleware 1 to "name", and sets the variable name representing the business name in the middleware code corresponding to middleware 2 to "name". The two variable names are the same, but it can be seen that the two variable names represent different meanings. Therefore, if the same variable names in different middleware are not distinguished, then if the above-mentioned target business involves different middleware containing the same variable names, the business platform may encounter execution errors in the process of executing the target business.

[0067] To avoid this situation, the business platform can determine the identifier corresponding to each middleware to be configured and use the identifier to distinguish the same custom variable names in different middleware. This can be done by adding the middleware's identifier to all variable names in the middleware code corresponding to the middleware, or by first determining the same variable names in different middleware and then adding the corresponding middleware identifier to the same variable names in different middleware to distinguish the variable names.

[0068] If middleware configuration is performed by the storage center, the business platform can determine the identifier of at least one middleware to be configured based on the target business and send it to the storage center. Upon receiving the identifier of the middleware to be configured, the storage center can first query the middleware code and configuration data for the middleware to be configured. Based on the identifier, the middleware code and configuration data corresponding to the middleware to be configured, the storage center can then configure the middleware to be configured. The configured middleware can then be returned to the business platform.

[0069] Of course, middleware configuration can also be completed by the business platform. Specifically, the storage center can send the middleware code and middleware configuration data corresponding to the middleware to be configured to the business platform. The business platform can configure the middleware to be configured based on the identifier of the middleware to be configured and the middleware code and middleware configuration data obtained.

[0070] In the embodiments of this specification, the identifier of a middleware can be pre-set, that is, a corresponding identifier can be set in advance for each middleware, and the identifiers of different middlewares are different. Of course, after receiving the service request sent by the user, the identifiers of different target middlewares involved in the target business can be created according to the different types of user data of the user. It should be noted that if it is necessary to determine the identifier of the middleware based on the service request sent by the user, then after the above-mentioned target business is completed by the configured middleware, these configured middlewares can be deleted. This is because the middleware configured in this way is often only applicable to the service request sent by the user this time.

[0071] S108: Execute the target business according to each configured middleware.

[0072] The business platform obtains the configured middleware corresponding to the target business and executes the target business based on the configured middleware. The business platform identifies the middleware involved in executing the target business as the target middleware. This target middleware includes both the middleware to be configured and the deployed middleware. The platform deploys the configured middleware and executes the target business based on the deployed middleware and the configured middleware.

[0073] It should be noted that before executing the target business based on the deployed middleware and each configured middleware, the middleware identifier of the deployed middleware is sent to the storage center. The storage center then queries the middleware identifier to see if there are any updates to the middleware code and / or middleware configuration data corresponding to the deployed middleware. If so, the storage center sends the stored middleware code and configuration data corresponding to the deployed middleware to the business platform, allowing the business platform to update the deployed middleware.

[0074] In the embodiments of this specification, the data update involved in the middleware can be achieved by the developer uploading the middleware code and / or middleware configuration data of the new version of the middleware corresponding to the deployed middleware in advance, or it can be achieved by the developer modifying the middleware code and / or middleware configuration data corresponding to the deployed middleware online.

[0075] As can be seen from the above process, upon receiving a service request from a user, the service platform configures the middleware required to execute the target service. This means that the middleware involved in service execution does not need to be configured in advance; instead, it can be configured in real time during service execution. This significantly reduces the coupling between the middleware and the service, enabling dynamic middleware configuration. Furthermore, because the storage center stores middleware code and configuration data separately, developers can modify either middleware code or configuration data separately, simplifying the process of adding, deleting, and modifying middleware, saving developers considerable time and improving work efficiency.

[0076] In the embodiment of this specification, when the service platform processes the request sent by the client, the processing process between the service platform and the storage center is as follows: Figure 2 shown.

[0077] Figure 2 This is a schematic diagram of a business platform and storage center processing process provided in an embodiment of this specification.

[0078] In the embodiments of this specification, the storage center and the service platform form a service execution system. In this system, the service platform includes a service execution module and a service maintenance module. The service execution module includes at least one middleware, and the service maintenance module may include a cache module, an update module, and an identification module.

[0079] In this system, after receiving a service request from a user via a client, the service platform can determine the service corresponding to the service request as the target service. Then, based on the target service, it can determine at least one middleware to be configured corresponding to the target service to be executed. These middleware to be configured are the middleware that needs to be configured in the service execution module. For each middleware to be configured, the service platform can send a data acquisition request to a preset storage center to obtain the middleware code and configuration data corresponding to the middleware to be configured from the storage center. The service platform can then configure the middleware to be configured based on the middleware code and configuration data, obtaining the configured middleware, and deploying the configured middleware in the service execution module to execute the target service.

[0080] For the storage center, after receiving the data acquisition request sent by the business platform, the storage center can query the middleware code and middleware configuration data that the business platform needs to obtain based on the data acquisition request, and return the queried middleware code and middleware configuration data to the business platform.

[0081] The storage center includes: a first sub-storage center and a second sub-storage center. The first sub-storage center stores the middleware code corresponding to each middleware, and the second sub-storage center stores the middleware configuration data corresponding to each middleware. In the process of managing and maintaining each middleware, the storage center also needs to promptly update the middleware code and middleware configuration data of the middleware. Specifically, for each middleware managed by the storage center, if the storage center detects that the middleware code corresponding to the middleware has changed, it can update the middleware code corresponding to the middleware stored in the first sub-storage center based on the obtained changed middleware code corresponding to the middleware. When it detects that the middleware configuration data corresponding to the middleware has changed, it can update the middleware configuration data corresponding to the middleware stored in the second sub-storage center based on the obtained changed middleware configuration data corresponding to the middleware.

[0082] In the embodiments of this specification, the business platform caches some middleware through a cache module. The cached middleware can be the middleware configured by the business platform when executing the business before, or it can be the preset middleware that is always cached. Accordingly, when configuring the middleware corresponding to the target business, the business platform can first query whether the target middleware corresponding to the target business is cached. For the cached target middleware, it can be directly called as the deployed middleware. For the target middleware that is not cached, it can be treated as the middleware to be configured, and the middleware to be configured can be configured according to the middleware code and middleware configuration data corresponding to the middleware to be configured queried from the storage center.

[0083] For the identification module included in the business maintenance module, the business platform can determine the identifier of the above-mentioned middleware to be configured through the identification module, and configure the middleware to be configured based on the identifier of the middleware to be configured, the middleware code of the middleware to be configured queried from the storage center, and the middleware configuration data.

[0084] For the update module included in the business maintenance module, before executing the target business, the business platform can use the update module to send the middleware identifier of the deployed middleware determined from the cache to the storage center. The storage center queries the middleware code and / or middleware configuration data corresponding to each deployed middleware based on each middleware identifier to see whether there is a data update. If so, the storage center sends the middleware code and middleware configuration data corresponding to the deployed middleware stored in the storage center to the business platform, so that the business platform updates the deployed middleware.

[0085] During the business execution process, each target middleware in the business execution module needs to process the business request in turn. In the process of processing the business request, the target middleware can obtain the corresponding business information based on the business request and modify the business information. After the business request is processed by each target middleware, the business processing results will be returned in sequence according to the processing order of each target middleware, and the final business processing results will be sent to the client. Among them, the data mode of the target middleware in the above-mentioned business execution module can be Koa under the web framework, Koa2 under the web framework, or Express under the web framework. This specification does not limit the specific data processing method adopted by the middleware.

[0086] Of course, the configuration of the middleware can also be completed by the storage center. That is, after the business platform determines the middleware identification information of the middleware to be configured, it can send the middleware identification information to the storage center to request the corresponding middleware from the storage center. Based on the middleware identification information, the storage center searches for the middleware code corresponding to the middleware identification information in the first sub-storage center, and searches for the middleware configuration data corresponding to the middleware identification information in the second sub-storage center. The storage center can configure the middleware to be configured based on the determined identifier corresponding to the middleware to be configured, the middleware code corresponding to the middleware to be configured, and the middleware configuration data corresponding to the middleware to be configured, and send the configured middleware to the business platform. After receiving the configured middleware, the business platform can sort the configured middleware and the deployed middleware according to the execution order of the target business, and execute the target business through these middleware.

[0087] From the above content, it can be seen that since the storage center can store the middleware code and intermediate configuration data of the middleware in the first sub-storage center and the second sub-storage center respectively, this simplifies the modification process of the middleware when developers modify the middleware, saves developers a lot of time, and improves the maintenance efficiency of the middleware.

[0088] The above is a method for executing a service provided in one or more embodiments of this specification. Based on the same idea, this specification also provides a corresponding device for executing a service, such as Figure 3 shown.

[0089] Figure 3 A schematic diagram of a structure of a device for executing a service provided in an embodiment of this specification, specifically including:

[0090] Receiving module 300, used to receive a service request sent by a user;

[0091] A service module 302 is configured to determine, based on the service request, a service corresponding to the service request as a target service;

[0092] A determination module 304 is configured to determine, based on the target service, at least one middleware to be configured that executes the target service;

[0093] Configuration module 306, configured to configure each middleware to be configured by using the middleware code corresponding to the middleware to be configured and the middleware configuration data corresponding to the middleware to be configured stored in a preset storage center, to obtain the configured middleware;

[0094] The execution module 308 is configured to execute the target business according to each configured middleware.

[0095] Optionally, the determining module 304 is specifically configured to determine middleware involved in executing the target business as target middleware, and determine middleware that has not been configured from the target middleware as middleware to be configured.

[0096] Optionally, the configuration module 306 is specifically used to determine the deployed middleware other than the at least one middleware to be configured from the target middleware, deploy the configured middleware, and execute the target business based on the deployed middleware and the configured middleware.

[0097] Optionally, the configuration module 306 is specifically configured to determine various pre-cached middlewares, and for each target middleware, if the pre-cached middlewares include the target middleware, determine the target middleware as a deployed middleware.

[0098] Optionally, the configuration module 306 is specifically used to determine the middleware identifier of the deployed middleware, and based on the middleware identifier, query from the storage center whether there is any data update for the middleware code and / or middleware configuration data corresponding to the deployed middleware; if so, update the deployed middleware through the middleware code and middleware configuration data corresponding to the deployed middleware stored in the storage center.

[0099] Optionally, the configuration module 306 is specifically used to determine, for each middleware to be configured, an identifier corresponding to the middleware to be configured, and send the identifier to the storage center so that the storage center configures the middleware to be configured according to the identifier, the middleware code corresponding to the middleware to be configured, and the middleware configuration data corresponding to the middleware to be configured, wherein different middlewares have different corresponding identifiers, and the identifier is used to distinguish the same custom variable names in different middlewares.

[0100] This specification also provides a computer-readable storage medium, which stores a computer program that can be used to execute the above Figure 1 Provides methods for executing business operations.

[0101] This manual also provides Figure 4 The structural diagram of the electronic device shown in FIG. Figure 4 As mentioned above, at the hardware level, the equipment for the service execution method includes a processor, an internal bus, a network interface, a memory and a non-volatile memory, and may also include other hardware required for the service. The processor reads the corresponding computer program from the non-volatile memory into the memory and then runs it to implement the above Figure 1 Of course, in addition to software implementation, this specification does not exclude other implementation methods, such as logic devices or a combination of software and hardware, etc., that is, the execution subject of the following processing flow is not limited to each logic unit, but can also be hardware or logic devices.

[0102] In the 1990s, technological improvements could be clearly distinguished as either hardware improvements (for example, improvements to circuit structures like diodes, transistors, and switches) or software improvements (improvements to process flows). However, with the advancement of technology, many process flow improvements today can now be considered direct improvements to hardware circuit structures. Designers almost always create the corresponding hardware circuit structure by programming the improved process flow into the hardware circuit. Therefore, it cannot be said that a process flow improvement cannot be implemented using hardware modules. For example, a programmable logic device (PLD), such as a field programmable gate array (FPGA), is an integrated circuit whose logical function is determined by user programming. Designers can "integrate" a digital system on a PLD through their own programming, without having to hire a chip manufacturer to design and manufacture a dedicated integrated circuit chip. Moreover, nowadays, instead of manually fabricating integrated circuit chips, this programming is mostly done using "logic compiler" software. This is similar to the software compiler used when developing programs. Before compilation, the original code must also be written in a specific programming language, called a hardware description language (HDL). There is not just one HDL, but many, such as ABEL (Advanced Boolean Expression Language), AHDL (Altera Hardware Description Language), Confluence, CUPL (Cornell University Programming Language), HDCal, JHDL (Java Hardware Description Language), Lava, Lola, MyHDL, PALASM, RHDL (Ruby Hardware Description Language), etc. The most commonly used ones are VHDL (Very-High-Speed ​​Integrated Circuit Hardware Description Language) and Verilog. Those skilled in the art will also understand that by simply programming the method flow in one of these hardware description languages ​​and then programming it into an integrated circuit, a hardware circuit that implements the logic method flow can be easily obtained.

[0103] The controller can be implemented in any suitable manner. For example, the controller can take the form of a microprocessor or processor and a computer-readable medium storing computer-readable program code (e.g., software or firmware) executable by the (micro)processor, logic gates, switches, application-specific integrated circuits (ASICs), programmable logic controllers, and embedded microcontrollers. Examples of controllers include, but are not limited to, the following microcontrollers: ARC 625D, Atmel AT91SAM, Microchip PIC18F26K20, and Silicone Labs C8051F320. The memory controller can also be implemented as part of the control logic of the memory. Those skilled in the art will also know that in addition to implementing the controller in a purely computer-readable program code format, the controller can be implemented in the form of logic gates, switches, application-specific integrated circuits, programmable logic controllers, and embedded microcontrollers by logically programming the method steps. Therefore, such a controller can be considered a hardware component, and the devices included therein for implementing various functions can also be considered as structures within the hardware component. Or even, the devices for implementing various functions can be considered as both software modules that implement the method and structures within the hardware component.

[0104] The systems, devices, modules, or units described in the above embodiments may be implemented by computer chips or entities, or by products having certain functions. A typical implementation device is a computer. Specifically, the computer may be, for example, a personal computer, a laptop computer, a cellular phone, a camera phone, a smartphone, a personal digital assistant, a media player, a navigation device, an email device, a game console, a tablet computer, a wearable device, or a combination of any of these devices.

[0105] For the convenience of description, the above devices are described as being divided into various units according to their functions. Of course, when implementing this specification, the functions of each unit can be implemented in the same or multiple software and / or hardware.

[0106] It will be understood by those skilled in the art that embodiments of the present invention may be provided as methods, systems, or computer program products. Thus, the present invention may take the form of an entirely hardware embodiment, an entirely software embodiment, or an embodiment combining software and hardware. Furthermore, the present invention may take the form of a computer program product implemented on one or more computer-usable storage media (including but not limited to magnetic disk storage, CD-ROM, optical storage, etc.) containing computer-usable program code.

[0107] The present invention is described with reference to flowcharts and / or block diagrams of methods, devices (systems), and computer program products according to embodiments of the present invention. It should be understood that each process and / or block in the flowcharts and / or block diagrams, as well as combinations of processes and / or blocks in the flowcharts and / or block diagrams, can be implemented by computer program instructions. These computer program instructions can be provided to a processor of a general-purpose computer, a special-purpose computer, an embedded processor, or other programmable data processing device to produce a machine, so that the instructions executed by the processor of the computer or other programmable data processing device generate instructions for implementing the processes in the flowcharts and / or block diagrams. Figure 1 a process or multiple processes and / or boxes Figure 1 A device that provides the functions specified in a block or multiple blocks.

[0108] These computer program instructions may also be stored in a computer readable memory that can direct a computer or other programmable data processing device to work in a specific manner, so that the instructions stored in the computer readable memory produce an article of manufacture comprising an instruction device, which implements the process Figure 1 a process or multiple processes and / or boxes Figure 1 The function specified in one or more boxes.

[0109] These computer program instructions can also be loaded onto a computer or other programmable data processing device so that a series of operational steps are executed on the computer or other programmable device to produce a computer-implemented process, thereby providing the instructions executed on the computer or other programmable device for implementing the process. Figure 1 a process or multiple processes and / or boxes Figure 1 A step that specifies a function in one or more boxes.

[0110] In a typical configuration, a computing device includes one or more processors (CPUs), input / output interfaces, network interfaces, and memory.

[0111] Memory may include non-permanent storage in a computer-readable medium, random access memory (RAM) and / or non-volatile memory in the form of read-only memory (ROM) or flash RAM. Memory is an example of a computer-readable medium.

[0112] Computer-readable media includes permanent and non-permanent, removable and non-removable media that can be implemented by any method or technology to store information. The information can be computer-readable instructions, data structures, program modules or other data. Examples of computer storage media include, but are not limited to, phase change memory (PRAM), static random access memory (SRAM), dynamic random access memory (DRAM), other types of random access memory (RAM), read-only memory (ROM), electrically erasable programmable read-only memory (EEPROM), flash memory or other memory technology, compact disc read-only memory (CD-ROM), digital versatile disc (DVD) or other optical storage, magnetic cassettes, magnetic tape, magnetic disk storage or other magnetic storage devices or any other non-transmission media that can be used to store information that can be accessed by a computing device. As defined herein, computer-readable media does not include transitory computer-readable media (transitory media), such as modulated data signals and carrier waves.

[0113] It should also be noted that the terms "comprises," "includes," or any other variations thereof are intended to encompass non-exclusive inclusion, such that a process, method, commodity, or apparatus that includes a series of elements includes not only those elements but also other elements not explicitly listed, or includes elements inherent to such process, method, commodity, or apparatus. In the absence of further limitations, an element defined by the phrase "comprises a ..." does not exclude the presence of other identical elements in the process, method, commodity, or apparatus that includes the element.

[0114] Those skilled in the art will appreciate that the embodiments of this specification may be provided as methods, systems, or computer program products. Thus, this specification may take the form of an entirely hardware embodiment, an entirely software embodiment, or an embodiment combining software and hardware. Furthermore, this specification may take the form of a computer program product implemented on one or more computer-usable storage media (including but not limited to magnetic disk storage, CD-ROM, optical storage, etc.) containing computer-usable program code.

[0115] This specification may be described in the general context of computer-executable instructions, such as program modules, executed by a computer. Generally, program modules include routines, programs, objects, components, data structures, and the like that perform specific tasks or implement specific abstract data types. This specification may also be practiced in distributed computing environments where tasks are performed by remote processing devices connected through a communications network. In a distributed computing environment, program modules may be located in both local and remote computer storage media, including storage devices.

[0116] The various embodiments in this specification are described in a progressive manner. Similar parts between the various embodiments can be referred to in conjunction with each other. Each embodiment focuses on the differences between the other embodiments. In particular, the system embodiments are generally similar to the method embodiments, so the description is relatively simple. For relevant parts, refer to the description of the method embodiments.

[0117] The foregoing is merely an example of the present invention and is not intended to limit the present invention. Various modifications and variations are possible for those skilled in the art. Any modifications, equivalent substitutions, or improvements made within the spirit and principles of the present invention are intended to be included within the scope of the claims of the present invention.

Claims

1. A method for executing a service, characterized in that: include: Receive business requests sent by users; According to the service request, determining a service corresponding to the service request as a target service; Determine the middleware involved in executing the target business as the target middleware, and determine at least one middleware to be configured and deployed middleware other than the at least one middleware to be configured from the target middleware; For each middleware to be configured, the middleware to be configured is configured using the middleware code corresponding to the middleware to be configured and the middleware configuration data corresponding to the middleware to be configured stored in a preset storage center to obtain the configured middleware; wherein the middleware code and middleware configuration data of the same middleware are stored separately in the storage center; querying the storage center whether there is any data update for the middleware code and / or middleware configuration data corresponding to the deployed middleware; if so, updating the deployed middleware using the middleware code and middleware configuration data corresponding to the deployed middleware stored in the storage center; The configured middlewares are deployed, and the target business is executed according to the deployed middlewares and the configured middlewares.

2. The method according to claim 1, wherein Determining deployed middleware other than the at least one middleware to be configured specifically includes: Determine the pre-cached middleware; For each target middleware, if the pre-cached middleware includes the target middleware, the target middleware is determined to be a deployed middleware.

3. The method according to claim 1, wherein Querying the storage center for whether there is data update for the middleware code and / or middleware configuration data corresponding to the deployed middleware specifically includes: Determining the middleware identifier of the deployed middleware; According to the middleware identifier, the storage center is queried to determine whether there is any data update for the middleware code and / or middleware configuration data corresponding to the deployed middleware.

4. The method according to claim 1, wherein For each middleware to be configured, configuring the middleware to be configured by using the middleware code corresponding to the middleware to be configured and the middleware configuration data corresponding to the middleware to be configured stored in a preset storage center, specifically includes: For each middleware to be configured, determine the identifier corresponding to the middleware to be configured; The identifier is sent to the storage center so that the storage center configures the middleware to be configured according to the identifier, the middleware code corresponding to the middleware to be configured, and the middleware configuration data corresponding to the middleware to be configured, wherein different middlewares correspond to different identifiers, and the identifier is used to distinguish the same custom variable names in different middlewares.

5. A system for executing business operations, characterized in that: Including: storage center and business platform; The service platform is used to receive service requests sent by users; According to the service request, determining a service corresponding to the service request as a target service; Determine the middleware involved in executing the target business as the target middleware, and determine at least one middleware to be configured and deployed middleware other than the at least one middleware to be configured from the target middleware; for each middleware to be configured, send a data acquisition request to a preset storage center to obtain the middleware code corresponding to the middleware to be configured and the middleware configuration data corresponding to the middleware to be configured from the storage center, and configure the middleware to be configured according to the middleware code corresponding to the middleware to be configured and the middleware configuration data corresponding to the middleware to be configured to obtain the configured middleware; query the storage center to see whether the middleware code and / or middleware configuration data corresponding to the deployed middleware have any data updates; if so, update the deployed middleware using the middleware code and middleware configuration data corresponding to the deployed middleware stored in the storage center; Deploy the configured middlewares, and execute the target business according to the deployed middlewares and the configured middlewares; The storage center is configured to receive the data acquisition request sent by the business platform, query the middleware code and middleware configuration data required by the business platform according to the data acquisition request, and return the query middleware code and middleware configuration data to the business platform; The storage center includes: a first sub-storage center and a second sub-storage center, the first sub-storage center stores the middleware code corresponding to each middleware, and the second sub-storage center stores the middleware configuration data corresponding to each middleware; The storage center is further configured to update the middleware code corresponding to each middleware stored in the first sub-storage center based on the acquired changed middleware code corresponding to the middleware, if a change is detected in the middleware code corresponding to the middleware; The storage center is also used to update the middleware configuration data corresponding to each middleware stored in the second sub-storage center based on the acquired changed middleware configuration data corresponding to the middleware, if it monitors that the middleware configuration data corresponding to the middleware has changed.

6. A device for executing a service, characterized in that: include: Receiving module, used to receive service requests sent by users; A service module, configured to determine, according to the service request, a service corresponding to the service request as a target service; a determination module, configured to determine middleware involved in executing the target business as target middleware, and to determine at least one middleware to be configured from the target middleware; a configuration module configured to configure each middleware to be configured by using the middleware code and middleware configuration data corresponding to the middleware to be configured stored in a preset storage center, thereby obtaining the configured middleware; wherein the middleware code and middleware configuration data of the same middleware are stored separately in the storage center; The configuration module is further configured to determine deployed middleware other than the at least one middleware to be configured from the target middleware, query the storage center to see whether there is any data update for the middleware code and / or middleware configuration data corresponding to the deployed middleware; and if so, update the deployed middleware using the middleware code and middleware configuration data corresponding to the deployed middleware stored in the storage center; An execution module is used to deploy the configured middlewares and execute the target business according to the deployed middlewares and the configured middlewares.

7. A computer-readable storage medium, characterized in that The storage medium stores a computer program, and when the computer program is executed by a processor, the method according to any one of claims 1 to 4 is implemented.

8. An electronic device comprising a memory, a processor, and a computer program stored in the memory and executable on the processor, wherein: When the processor executes the program, the method according to any one of claims 1 to 4 is implemented.

Citation Information

Patent Citations

  • Method and device for generating service code framework

    CN111258572A