Providing optimization in microservices architecture
Patent Information
- Application Number
- JP2022518413
- Authority / Receiving Office
- JP · JP
- Patent Type
- Patents
- Current Assignee / Owner
- Priority Date
- 2019-09-20
- Filing Date
- 2020-09-21
- Publication Date
- 2025-03-14
- Estimated Expiration
- 2040-09-21
Smart Images

Figure 0007645877000001 
Figure 0007645877000002 
Figure 0007645877000003
Abstract
Description
[Technical field]
[0001] The present disclosure relates generally to the field of microservices and, more specifically, to providing optimizations in microservices architectures. [Background technology]
[0002] In contrast to monolithic applications, microservices are composed of loosely coupled services that offer advantages in development agility, scalability, and adaptability, as well as the ability to decouple the work of different teams from each other and reuse services across different projects.
[0003] The advantage of microservices is that they provide decoupled services that are much easier to develop, update, and maintain by small teams.
[0004] However, using microservices for various tasks also brings some drawbacks, such as data accessibility, infrastructure overhead, and more complex systems.
[0005] Therefore, an alternative approach to consuming microservices is needed. Summary of the Invention
[0006] It should be emphasized that the terms "comprise" and / or "comprising," as used herein, are used to specify the presence of stated features, integers, steps, or components, but do not exclude the presence or addition of one or more other features, integers, steps, components, or groups thereof. As used herein, the singular forms "a," "an," and "the" are intended to include the plural forms unless the context clearly dictates otherwise.
[0007] Generally, when a configuration is referred to herein, it should be understood as a physical product, e.g., a device. The physical product may comprise one or more components, such as control circuitry in the form of one or more controllers, or one or more processors, etc.
[0008] It is an object of certain embodiments to address or mitigate, alleviate or eliminate at least some of the above or other disadvantages.
[0009] According to a first aspect, this object is achieved by a computer-implemented method for providing optimization in a microservices architecture comprising at least one optimization service comprising: a management component configured to provide clients with access to the at least one optimization service; a messaging component configured to queue optimization requests; at least one work component configured to solve optimization tasks; and at least one storage component, wherein the components of the at least one optimization service are operatively connected to each other.
[0010] The method includes receiving, by a management component, an optimization request sent from a client, the optimization request including an optimization task and corresponding data for the optimization; storing, by the management component, the corresponding data for the optimization and a created association identifier of the optimization task in at least one storage component; sending, by the management component, the optimization task and the association identifier of the optimization task to a messaging component; and monitoring, by at least one work component, the messaging component for the received optimization task.
[0011] The method further includes, upon detection of the received optimization task by the at least one work component, retrieving, by the at least one work component, stored data for the corresponding optimization from the at least one storage component through an associated identifier of the optimization task, creating, by the at least one work component, an optimization model for solving the optimization task, solving, by the at least one work component, the optimization task based on the created optimization model, and storing, by the at least one work component, a solution to the optimization task and an associated identifier of the optimization task in the at least one storage component.
[0012] In this context, the term "client" should be understood as a piece of computer hardware or software that accesses the optimization service. The optimization service may be made available by a server as part of a client-server model of a computer network. The server may be on another computer system. A client typically sends optimization requests to the optimization service. The term "client" may also be understood as a computer or device that runs the client software, or a user that uses the client software. A client may be different from an end user. A client may be defined by client attributes such as an IP address.
[0013] An advantage of some embodiments is that an alternative approach for consuming microservices is provided.
[0014] Another advantage of some embodiments is that the microservices architecture, the optimization service(s), and their components are guaranteed to be scalable and robust.
[0015] Additionally, an advantage of some embodiments is that scalability reduces the risk of overloading a component, e.g., a work component, as components can be added to the optimization service(s) to match the optimization load so that changing resource demands are met.
[0016] Furthermore, scalability reduces the risk of a component, e.g., a working component, going idle, as components can be removed from the optimization service(s) to match the optimization load so that changing resource demands are met.
[0017] Yet another advantage of some embodiments is that robustness reduces the risk of failure of a component, e.g., a working component, because one or several other components can replace a component that is at risk of causing a failure, e.g., by temporarily assuming the workload of that component.
[0018] A further advantage of some embodiments is that the microservices architecture, its optimization service(s), and their components become easier to develop, update, and maintain accordingly.
[0019] In some embodiments, the method further includes determining, by the management component, metadata based at least on the transmitted optimization request, where the metadata includes transmission data of the optimization request, and storing, by the management component, the determined metadata in at least one storage component, where the at least one storage component is accessible to both the management component and the at least one working component.
[0020] An advantage of some embodiments is that since metadata of an optimization request is determined and separated from the data for optimization and stored accordingly, the metadata has a predictable data size as opposed to the payload which may have a varying data size, providing a storage advantage to the optimization service, for example, in providing or selecting an appropriate or ideal storage solution for the metadata.
[0021] Another advantage is that the metadata provides an association between the client and the optimization request that the client sent, since it annotates the optimization request with, for example, the client's username and IP address. Since the optimization is performed in a distributed system of components, the metadata provides the annotations necessary for the management component to manage the optimization requests for the client, for example, in the status to update, stop, provide a solution for the optimization task to the client that sent the optimization request.
[0022] In some embodiments, the method further includes determining, by the management component, a payload based on the transmitted optimization request, where the payload includes data for the corresponding optimization, and storing, by the management component, the determined payload in at least one storage component, where the at least one storage component is accessible to both the management component and the at least one working component.
[0023] An advantage of some embodiments is that since the payload of an optimization request is determined, separated from the metadata, and stored accordingly, the stored payload itself can be treated as data for optimization since the metadata is already separated. Since the optimization is performed in a distributed system of stateless components, the separated payload provides input to the work components without further pre-processing required for the work components.
[0024] In some embodiments, the at least one storage component comprises a database.
[0025] An advantage of some embodiments is that a single storage, i.e., database, within the optimization service provides the storage required for both metadata and payload. Thus, the optimization service is further simplified and a less complex optimization service may be achieved with only a single storage implementation.
[0026] In some embodiments, the at least one storage component comprises two storage components each including a database and an object storage.
[0027] An advantage of some embodiments is that two separate storages, i.e. database and object storage, provide data type specific storage, i.e. database that can store metadata, and object storage that can store payload, where object storage is data type specific for storing payload, large raw data, i.e. data for optimization, write / read data, calculation data, and is especially efficient for storing large amounts of data, e.g. large binary datasets and Binary Large Objects (BLOBs), data that does not need to be (partially) updated, does not need to be modified. BLOBs are collections of binary data such as images or other multimedia objects stored as a single entity in a database management system.
[0028] In some embodiments, the database is configured to store metadata or metadata and the payload of the optimization request.
[0029] An advantage of some embodiments is that the database provides storage for metadata only, whereby the data size of the metadata is predictable and typically smaller than the payload, and thus the database is less complex and can be reduced in size since it is dedicated only to metadata. SQL and NoSQL databases can be used to store the metadata. Further advantages of a database that stores only metadata are that it offers simplicity of design, easier expansion, and finer control over availability.
[0030] An advantage of some embodiments is that the database provides the necessary storage for both metadata and payload, thereby further simplifying the optimization service and achieving a less complex optimization service on a per-component basis by merely implementing a single storage dedicated to both metadata and payload.
[0031] In some embodiments, the metadata includes data for annotating the optimization request.
[0032] An advantage of some embodiments is that the metadata annotates the optimization request, e.g., the client's username and IP address, such that the annotation provides an association between the client and the optimization request that the client sent.
[0033] In some embodiments, the object storage is configured to store the payload of the optimization request.
[0034] An advantage of some embodiments is that object storage is particularly efficient for storing large raw data payloads, i.e., data types specific to the storage of data for optimization, and large amounts of data, e.g., large binary data sets that do not need to be (partially) updated. A further advantage of object storage is that it provides data scalability and security, i.e., customers of any size and industry can use object storage to store any amount of data, knowing that the data is protected. Another further advantage is that object storage provides data availability and performance, i.e., data is easy to use and organize, and access controls are finely tuned to meet specific requirements. Furthermore, unstructured data can be stored within. Object storage can be storage such as Microsoft Azure and Amazon S3.
[0035] In some embodiments, the payload includes data for optimization corresponding to the optimization request.
[0036] An advantage of some embodiments is that the decisions and separated payloads provide input to the work component without further pre-processing required by the work component.
[0037] In some embodiments, the method further includes updating, by the work component, a status of the optimization request in the at least one storage component.
[0038] An advantage of some embodiments is that the management component, and thus the client, is provided with correct data regarding the current status of an optimization request.
[0039] In some embodiments, the method further includes querying, by the client, a status of the optimization request from the management component; and receiving, by the client, a notification from the management component indicating a status of the optimization request retrieved from the at least one storage component.
[0040] An optimization request may have a versatile life cycle, moving from one state to another. An optimization request may move through final and non-final states. Examples of final states include Invalid, Stopped, Critical, and Optimized, which are states that are final and cannot be moved to another state. Examples of non-final states include Queued, Error, and Loaded, which are states that are non-final and can still be moved to another non-final or final state. The state may be communicated to the client by a management component. Communicating the state to the client ensures that feedback is provided and also ensures a more robust system, especially when unexpected errors occur.
[0041] An advantage of some embodiments is that, upon request from a client, the management component, and thus the client, is provided with the current status of an optimization request.
[0042] In some embodiments, the method further includes providing, by the management component upon request from the client, to the client, the stored solutions for the optimization tasks having a completed status.
[0043] An advantage of some embodiments is that a solution is provided to a client when the solution is completed and the status is set to completed in at least one storage component.
[0044] In some embodiments, the method further includes de-servicing, by the management component upon request from the client, optimization tasks that have an uncompleted status.
[0045] An advantage of some embodiments is that a client has the ability to stop an optimization task that is being serviced, i.e. before it is completed, thereby freeing up resources within the optimization service.
[0046] In some embodiments, the at least one optimization service is configured to solve an optimization problem.
[0047] An advantage of some embodiments is that the optimization service provides a framework oriented around a single optimization problem that enables efficient microservices architectures.
[0048] In some embodiments, at least one optimization service includes at least two work components, the at least two work components being identical instances and configured to create a same optimization model corresponding to one optimization problem.
[0049] An advantage of some embodiments is that the working components share a common framework aimed at the same optimization problem, enabling scalability and efficiency of optimization services in a microservices architecture.
[0050] In some embodiments, the work component includes a generic portion and an optimization-specific portion.
[0051] An advantage of some embodiments is that the work components may share some common generic parts that allow for extensibility, while still being configurable to create optimization models that correspond to specific optimization problems.
[0052] In some embodiments, at least one optimization service component is a stateless component. The working component may be a stateless component. When a component is stateless, the optimization service server may not store any state regarding the client session. Instead, session data may be stored on the client and passed to the optimization service server as needed. That is, session data is stored locally on the client when an Internet connection is not available, and uploaded and replicated to the cloud when a connection becomes available or when a request for session data is received. The client may be an end user's device.
[0053] An advantage of some embodiments is that a lightweight implementation is provided in which components can be quickly started and stopped.
[0054] In some embodiments, optimization tasks are submitted by clients to at least one optimization service in an ad-hoc manner.
[0055] An advantage of some embodiments is that different transmission rates of optimization requests can be satisfied.
[0056] In some embodiments, the optimization task includes at least one optimization criterion.
[0057] An advantage of some embodiments is that they may complete an optimization task and provide a solution accordingly.
[0058] In some embodiments, the architecture comprises a decision support system and / or an optimization system, each of which utilizes a cloud infrastructure.
[0059] An advantage of some embodiments is that the cloud infrastructure provides serverless computing, allowing for scalability and deployment of optimized workloads.
[0060] A second aspect is a computer program product comprising a non-transitory computer readable medium having therein a computer program including program instructions, the computer program being loadable into a data processing unit and configured to cause the execution of the method according to the first aspect when the computer program is executed by the data processing unit.
[0061] A third aspect is a microservices architecture for providing optimization, the microservices architecture comprising at least one optimization service comprising: a management component configured to provide clients with access to the at least one optimization service; a messaging component configured to queue optimization requests; at least one work component configured to resolve optimization tasks; and at least one storage component, wherein the components of the at least one optimization service are operatively connected to each other.
[0062] The architecture includes a memory including executable instructions and one or more processors configured to communicate with the memory, the one or more processors configured to cause: a management component to receive an optimization request sent from a client, the optimization request including an optimization task and corresponding data for the optimization; the management component to store, by the management component, the corresponding data for the optimization and a created association identifier of the optimization task in at least one storage component; the management component to send, by the management component, the optimization task and the association identifier of the optimization task to a messaging component; and the at least one work component to monitor the messaging component for the received optimization task.
[0063] The one or more processors are further configured to cause, upon detection of the received optimization task by the at least one work component, to retrieve, by the at least one work component, stored data for the corresponding optimization from the at least one storage component through an associated identifier of the optimization task, to create, by the at least one work component, an optimization model for solving the optimization task, to solve the optimization task based on the created optimization model, and to store, by the at least one work component, a solution to the optimization task and an associated identifier of the optimization task in the at least one storage component.
[0064] An advantage of some embodiments is that an alternative approach for consuming microservices is provided.
[0065] Another advantage of some embodiments is that the microservices architecture, the optimization service(s), and their components are guaranteed to be scalable and robust.
[0066] Additionally, an advantage of some embodiments is that scalability reduces the risk of overloading a component, e.g., a work component, as components can be added to the optimization service(s) to match the optimization load so that changing resource demands are met. Furthermore, scalability reduces the risk of a component, e.g., a working component, going idle, as components can be removed from the optimization service(s) to match the optimization load so that changing resource demands are met.
[0067] Yet another advantage of some embodiments is that robustness reduces the risk of failure of a component, e.g., a working component, because one or several other components can replace a component that is at risk of causing a failure, e.g., by temporarily assuming the workload of that component.
[0068] A further advantage of some embodiments is that the microservices architecture, its optimization service(s), and their components become easier to develop, update, and maintain accordingly.
[0069] In some embodiments, the one or more processors are further configured to cause: determining, by the management component, metadata based on at least the transmitted optimization request, where the metadata includes transmission data of the optimization request; and storing, by the management component, the determined metadata in at least one storage component, where the at least one storage component is accessible to both the management component and the at least one working component.
[0070] An advantage of some embodiments is that since metadata of an optimization request is determined and separated from the data for optimization and stored accordingly, the metadata has a predictable data size as opposed to the payload which may have a varying data size, providing a storage advantage to the optimization service, for example, in providing or selecting an appropriate or ideal storage solution for the metadata.
[0071] Another advantage is that the metadata provides an association between the client and the optimization request that the client sent, since it annotates the optimization request with, for example, the client's username and IP address. Since the optimization is performed in a distributed system of components, the metadata provides the annotations necessary for the management component to manage the optimization requests for the client, for example, in the status to update, stop, provide a solution for the optimization task to the client that sent the optimization request.
[0072] In some embodiments, the one or more processors are further configured to cause: determining, based on the optimization request sent by the management component, a payload, where the payload includes data for the corresponding optimization; and storing, by the management component, the determined payload in at least one storage component, where the at least one storage component is accessible to both the management component and the at least one working component.
[0073] An advantage of some embodiments is that since the payload of an optimization request is determined, separated from the metadata, and stored accordingly, the stored payload itself can be treated as data for optimization since the metadata is already separated. Since the optimization is performed in a distributed system of stateless components, the separated payload provides input to the work components without further pre-processing required for the work components.
[0074] In some embodiments, the at least one storage component comprises a database.
[0075] An advantage of some embodiments is that a single storage, i.e., database, within the optimization service provides the storage required for both metadata and payload. Thus, the optimization service is further simplified and a less complex optimization service may be achieved with only a single storage implementation. In some embodiments, the at least one storage component comprises two storage components each including a database and an object storage.
[0076] An advantage of some embodiments is that two separate storages, i.e. database and object storage, provide data type specific storage, i.e. database that can store metadata, and object storage that can store payload, and object storage is efficient for storing payload, large raw data, i.e. data for optimization, and especially large amounts of data, e.g. large binary datasets, data that does not need to be (partially) updated.
[0077] In some embodiments, the database is configured to store metadata or metadata and the payload of the optimization request.
[0078] An advantage of some embodiments is that the database provides storage for metadata only, whereby the data size of the metadata is predictable and typically smaller than the data size of the payload, and therefore the database is less complex and can be reduced in size since it is dedicated only to metadata.
[0079] An advantage of some embodiments is that the database provides the necessary storage for both metadata and payload, thereby further simplifying the optimization service and achieving a less complex optimization service on a per-component basis by merely implementing a single storage dedicated to both metadata and payload.
[0080] In some embodiments, the metadata includes data for annotating the optimization request.
[0081] An advantage of some embodiments is that the metadata annotates the optimization request, e.g., the client's username and IP address, such that the annotation provides an association between the client and the optimization request that the client sent.
[0082] In some embodiments, the object storage is configured to store the payload of the optimization request.
[0083] An advantage of some embodiments is that object storage is particularly efficient for storing large raw data payloads, i.e. data types specific to the storage of data for optimization, and large amounts of data, e.g. large binary data sets that do not need to be (partially) updated.
[0084] In some embodiments, the payload includes data for optimization corresponding to the optimization request.
[0085] An advantage of some embodiments is that the decisions and separated payloads provide input to the work component without further pre-processing required by the work component. In some embodiments, the one or more processors are further configured to cause, by the work component, an update of a status of the optimization request in the at least one storage component.
[0086] An advantage of some embodiments is that the management component, and therefore the client, is provided with correct data regarding the current status of an optimization request.
[0087] In some embodiments, the one or more processors are further configured to cause the client to query, from the management component, a status of the optimization request; and the client to receive, from the management component, a notification indicating a status of the optimization request retrieved from the at least one storage component.
[0088] An advantage of some embodiments is that, upon request from a client, the management component, and thus the client, is provided with the current status of an optimization request.
[0089] In some embodiments, the one or more processors are further configured to cause, upon request from the client, the management component to provide to the client the stored solutions for the optimization tasks having a completed status.
[0090] An advantage of some embodiments is that a solution is provided to a client when the solution is completed and the status is set to completed in at least one storage component.
[0091] In some embodiments, the one or more processors are further configured to cause, upon request from a client, the management component to stop servicing optimization tasks that have a status of uncompleted.
[0092] An advantage of some embodiments is that a client has the ability to stop an optimization task that is being serviced, i.e. before it is completed, thereby freeing up resources within the optimization service.
[0093] In some embodiments, at least one optimization service (310) is configured to solve an optimization problem.
[0094] An advantage of some embodiments is that the optimization service provides a framework oriented around a single optimization problem that enables efficient microservices architectures.
[0095] In some embodiments, at least one optimization service includes at least two work components, the at least two work components being identical instances and configured to create a same optimization model corresponding to one optimization problem.
[0096] An advantage of some embodiments is that the working components share a common framework aimed at the same optimization problem, enabling scalability and efficiency of optimization services in a microservices architecture.
[0097] In some embodiments, the work component includes a generic portion and an optimization-specific portion.
[0098] An advantage of some embodiments is that the working components may share some common generic parts that allow for extensibility while still being configurable to create optimization models that correspond to specific optimization problems. Optimization models may include mathematical models and / or data structures used to perform the optimization. Optimization models may address many mathematical optimization classes, such as linear programming, mixed integer programming, non-linear optimization, constrained optimization, etc., and may be used in a variety of fields, such as critical path analysis or project planning, floor planning, i.e., designing the layout of equipment in a factory or components on a computer chip to reduce manufacturing time, network optimization, resource allocation problems, facility placement, allocation problems, etc.
[0099] In some embodiments, at least one component of the optimization service is a stateless component.
[0100] An advantage of some embodiments is that a lightweight implementation is provided in which components can be quickly started and stopped.
[0101] In some embodiments, optimization tasks are submitted by clients to at least one optimization service in an ad-hoc manner.
[0102] An advantage of some embodiments is that different transmission rates of optimization requests can be satisfied.
[0103] In some embodiments, the optimization task includes at least one optimization criterion.
[0104] An advantage of some embodiments is that they may complete an optimization task and provide a solution accordingly.
[0105] In some embodiments, the architecture comprises a decision support system and / or an optimization system, each of which utilizes a cloud infrastructure.
[0106] An advantage of some embodiments is that the cloud infrastructure provides serverless computing, allowing for scalability and deployment of optimized workloads.
[0107] Further objects, features, and advantages will become apparent from the following detailed description of the embodiments, taken in conjunction with the accompanying drawings, in which: The drawings are not necessarily to scale, emphasis instead being placed upon illustrating exemplary embodiments. [Brief description of the drawings]
[0108] [Figure 1] 1 is a flowchart illustrating example method steps according to some embodiments. [Figure 2a] FIG. 2 is a sequence diagram illustrating exemplary sequence steps according to some embodiments. [Figure 2b]FIG. 2 is a sequence diagram illustrating exemplary sequence steps according to some embodiments. [Figure 2c] FIG. 2 is a sequence diagram illustrating exemplary sequence steps according to some embodiments. [Figure 2d] FIG. 2 is a sequence diagram illustrating exemplary sequence steps according to some embodiments. [Figure 2e] FIG. 2 is a sequence diagram illustrating exemplary sequence steps according to some embodiments. [Figure 2f] FIG. 4 is a state diagram illustrating example states according to some embodiments. [Diagram 3] FIG. 1 is a schematic block diagram illustrating an example architecture according to some embodiments. [Figure 4] FIG. 1 is a schematic block diagram illustrating an exemplary configuration according to some embodiments. [Diagram 5] 1 is a schematic diagram illustrating an exemplary computer-readable medium according to some embodiments. DETAILED DESCRIPTION OF THE PREFERRED EMBODIMENTS
[0109] As already mentioned above, it should be emphasized that the terms "comprise" and / or "comprising", when used herein, are taken to specify the presence of stated features, integers, steps, or components, but do not exclude the presence or addition of one or more other features, integers, steps, components, or groups thereof. As used herein, the singular forms "a", "an", and "the" are intended to include the plural forms unless the context clearly indicates otherwise.
[0110]
[0023] Embodiments of the present disclosure are more fully described and illustrated below with reference to the accompanying drawings, in which:
[0024] However, the solutions disclosed herein may be embodied in many different forms and should not be construed as being limited to the embodiments set forth herein.
[0111] As mentioned above, microservices bring several drawbacks, such as data accessibility, infrastructure overhead, and more complex systems.
[0112] It is an object of certain embodiments to address or mitigate, alleviate or eliminate at least some of the above or other disadvantages.
[0113] In the following, embodiments are presented that describe alternative approaches for utilizing microservices.
[0114] More specifically, the presented embodiments describe techniques related to optimization in microservices architectures.
[0115] 1 is a flow chart illustrating method steps of an exemplary optimization method 100 according to some embodiments. The optimization method 100 is for providing optimization in a microservices architecture comprising at least one optimization service, the at least one optimization service comprising a management component configured to provide clients with access to the at least one optimization service, a messaging component configured to queue optimization requests, at least one work component configured to solve optimization tasks, and at least one storage component, the components of the at least one optimization service being operatively connected to each other. Thus, the optimization method 100 may be performed, for example, by the architecture 300 of FIG. 3 and / or the configuration 400 of FIG. 4 and / or the computer program product 500 of FIG. 5.
[0116] The optimization method 100 includes the following steps.
[0117] In step 101, an optimization request sent from a client, including an optimization task and corresponding data for optimization, is received by the management component.
[0118] Alternatively or additionally, receiving the optimization request may include receiving and / or accepting the optimization request.
[0119] Alternatively or additionally, the optimization request may be sent by the client to at least one optimization service in an ad-hoc manner, which includes on-demand optimization as opposed to a scheduled job that is executed automatically.
[0120] In some embodiments, metadata based at least on the submitted optimization request is determined by the management component at step 102. The metadata includes submission data of the optimization request.
[0121] For example, the determined metadata may include a username, a date, a time, and the like.
[0122] Alternatively or additionally, the metadata includes data for annotating the optimization request, the annotation including defining the optimization request and identifying the client sending the optimization request, e.g., by the client's username and IP address.
[0123] In some embodiments, a payload based on the transmitted optimization request is determined by the management component in step 103. The payload includes data for the corresponding optimization.
[0124] In step 104, the data for the corresponding optimization and the generated association identifier of the optimization task are stored in at least one storage component by the management component.
[0125] In step 104a, in some embodiments, the determined metadata is stored by the management component in at least one storage component, the at least one storage component being accessible to both the management component and, optionally, the at least one working component.
[0126] In step 104b, in some embodiments, the determined payload is stored by the management component in at least one storage component, the at least one storage component being accessible to both the management component and the at least one working component.
[0127] In step 105, the optimization task and an associated identifier of the optimization task are sent by the management component to the messaging component.
[0128] Alternatively or additionally, sending the optimization task and associated identifier may include queuing the optimization task and associated identifier in a messaging component.
[0129] In step 106, the messaging component is monitored by at least one work component for received optimization tasks.
[0130] In step 107, the received optimization task is detected by at least one work component, whereby the method either continues to step 108 (YES path from step 107) or, instead, the method returns to step 106 (NO path from step 107).
[0131] In step 108, the stored data for the corresponding optimization is retrieved from the at least one storage component by the at least one work component through an associated identifier of the optimization task.
[0132] Alternatively or additionally, additional data for optimization, for example based on the information in the payload, may be fetched by the at least one work component to formulate an optimization problem.
[0133] For example, the data for the corresponding optimization may provide one or more references for additional data to be fetched accordingly.
[0134] For example, at least one work component may fetch additional data for the optimization task from an application programming interface (API), a database, or other storage system.
[0135] In step 109, an optimization model for solving the optimization task is created by at least one task component.
[0136] Alternatively or additionally, the optimization model may include a mathematical model and / or data structures used to perform the optimization.
[0137] For example, an optimization model may include an algorithm that finds the best or better outcome for a decision-making problem.
[0138] For example, creating an optimization model may include, for example, specifying a mathematical model for solution, in step 110, where the solution may be performed through a commercial or open source solver or heuristic.
[0139] In step 110, an optimization task is solved based on an optimization model created by at least one work component.
[0140] For example, an optimization task is solved by applying an algorithm to an optimization model created by at least one work component.
[0141] In step 111, a solution to the optimization task and an associated identifier of the optimization task are stored by at least one work component in at least one storage component.
[0142] 2a is a sequence diagram illustrating some sequence steps of an exemplary optimization sequence 200a according to some embodiments. The optimization sequence 200a is for providing optimization in a microservices architecture with at least one optimization service, the at least one optimization service comprising a management component configured to provide clients with access to the at least one optimization service, a messaging component configured to queue optimization requests, at least one work component configured to solve optimization tasks, and at least one storage component, the components of the at least one optimization service being operatively connected to each other. Thus, the optimization sequence 200a may be performed, for example, by the architecture 300 of FIG. 3 and / or the configuration 400 of FIG. 4 and / or the computer program product 500 of FIG. 5.
[0143] The optimization sequence 200a includes the following steps.
[0144] In step 201, which corresponds to step 101 in FIG. 1, an optimization request sent from a client, including an optimization task and corresponding data for the optimization, is received by the managed component manager.
[0145] For example, the data for the corresponding optimization, i.e., the payload, can have different formats and sizes depending on the use case, e.g., the payload can be a reference to existing data (such as a scenario identifier), a user configuration of the optimization, the entire instance for the optimization, or a combination of the three. Each option has different advantages and disadvantages and tradeoffs, such as size of the payload, availability to the client, accessibility to internal identifiers, etc.
[0146] In step 202-1, an association identifier for the optimization task is created by the managing component manager (Manager). The association identifier includes identification data for the optimization request.
[0147] For example, the created identifier may include a globally unique identifier.
[0148] In step 202-2, which corresponds to step 102 in Figure 1, metadata based on at least the submitted optimization request is determined by the managed component manager, The metadata includes submitted data of the optimization request.
[0149] Alternatively or additionally (not shown), a payload based on the transmitted optimization request is determined by the managed component manager, corresponding to step 103 of Fig. 3. The payload includes data for the corresponding optimization.
[0150] In step 203, which corresponds to step 104a in FIG. 1, the determined metadata is stored by the managing component manager in at least one storage component database (Database), the database being accessible to both the managing component manager and optionally to at least one work component worker (Worker).
[0151] In step 204, which corresponds to step 104b in FIG. 1, the determined payload is stored by the management component manager in at least one storage component storage (Object Storage), which is accessible to both the management components, the manager and the at least one work component worker.
[0152] In step 205, which corresponds to step 105 in FIG. 1, the optimization task and its associated identifier are sent by the managed component manager to a messaging component queue.
[0153] Alternatively or additionally, when an optimization task is queued, the optimization task is confirmed to the client and an associated identifier is returned to the client so that the client can later reference the optimization task using the associated identifier.
[0154] 2b is a sequence diagram illustrating some sequence steps of an exemplary optimization sequence 200b according to some embodiments. The optimization sequence 200b is for providing optimization in a microservices architecture with at least one optimization service, the at least one optimization service comprising a management component configured to provide clients with access to the at least one optimization service, a messaging component configured to queue optimization requests, at least one work component configured to solve optimization tasks, and at least one storage component, the components of the at least one optimization service being operatively connected to each other. Thus, the optimization sequence 200b may be performed, for example, by the architecture 300 of FIG. 3 and / or the configuration 400 of FIG. 4 and / or the computer program product 500 of FIG. 5.
[0155] The optimization sequence 200b includes the following steps:
[0156] In step 207, corresponding to steps 106 and 107 of FIG. 1, the messaging component queue is monitored by at least one work component worker for a received optimization task, and upon detection of a received optimization task, the work component worker receives an associated identifier of the received optimization task.
[0157] Alternatively or additionally, a work component worker is responsible for performing optimizations and subscribes to a queue in a messaging component queue where the administrative component manager inputs new optimization requests, also called messages. If multiple work component workers, i.e., instances of a worker component, are running, the messaging component queue selects a work component based on, for example, a round-robin load balancing mechanism.
[0158] In step 208, which corresponds to step 108 in FIG. 1, the stored data for the corresponding optimization is obtained, i.e. retrieved and loaded by at least one work component worker from at least one storage component storage (object storage) via an associated identifier of the optimization task.
[0159] Alternatively or additionally, the work component worker may load additional data for the optimization task from an API, database, or other storage system.
[0160] In step 209, which corresponds to step 109 in FIG. 1, an optimization model for solving the optimization task is created by at least one work component worker.
[0161] Alternatively or additionally, when the stored corresponding data for optimization is obtained and an optimization model for solving the optimization task is created, the obtaining of the data and the creation of the optimization model are announced or made public to the client.
[0162] In step 210, which corresponds to step 110, an optimization task is solved based on an optimization model created by at least one work component worker.
[0163] For example, data for optimization is transformed, which may involve building mathematical models in programming frameworks, solver-specific libraries, or data structures used for (meta)heuristics.
[0164] In step 211, which corresponds to step 111, a solution to the optimization task and an associated identifier of the optimization task are stored by at least one work component worker in at least one storage component storage (object storage).
[0165] Alternatively or additionally, when the solution of the optimization task and the associated identifier of the optimization task are stored, the stored solution and the new state are announced or published to the managed component manager.
[0166] 2c is a sequence diagram illustrating some sequence steps of an exemplary optimization sequence 200c according to some embodiments. The optimization sequence 200c is for providing optimization in a microservices architecture with at least one optimization service, the at least one optimization service comprising a management component configured to provide clients with access to the at least one optimization service, a messaging component configured to queue optimization requests, at least one work component configured to solve optimization tasks, and at least one storage component, the components of the at least one optimization service being operatively connected to each other. Thus, the optimization sequence 200c may be performed, for example, by the architecture 300 of FIG. 3 and / or the configuration 400 of FIG. 4 and / or the computer program product 500 of FIG. 5.
[0167] The optimization sequence 200c includes the following steps: In step 212, the managed component manager ascertains the status of the optimization task upon initiation of the client, for example, by the client polling the managed component manager, providing an associated identifier of the optimization task, and querying at least one stored component database for the status of the optimization task.
[0168] Alternatively or additionally, when a solution to an optimization task and an associated identifier of the optimization task are stored in at least one storage component storage (object storage), this may be made known to the client, thereby enabling the client to retrieve (e.g., download) the stored solution from the at least one storage component.
[0169] For example, a client may use different approaches to check the status of a request: long polling or asynchronously; long polling typically blocks the client (e.g., a website) and displays some indication that optimization is in progress, whereas asynchronously means the user checks for updates. Alternatively or additionally, an optional message may be added to the status including the date and time the state was set.
[0170] In step 213, when the status of the optimization task is "Optimized", the solution is retrieved, eg, fetched, by the managing component manager from at least one stored component storage (object storage).
[0171] In step 214, the retrieved solution is provided to the client by the managed component manager.
[0172] Alternatively or additionally, instead of providing a URL to the solution including the retrieved solution to the client and the raw data in at least one stored component storage (object storage), for example, a request-specific access token is created and provided along with the URL, so that only the client has the information to access and download the stored solution.
[0173] 2d is a sequence diagram illustrating some sequence steps of an exemplary optimization sequence 200d according to some embodiments. The optimization sequence 200d is for providing optimization in a microservices architecture with at least one optimization service, the at least one optimization service comprising a management component configured to provide clients with access to the at least one optimization service, a messaging component configured to queue optimization requests, at least one work component configured to solve optimization tasks, and at least one storage component, the components of the at least one optimization service being operatively connected to each other. Thus, the optimization sequence 200d may be performed, for example, by the architecture 300 of FIG. 3 and / or the configuration 400 of FIG. 4 and / or the computer program product 500 of FIG. 5.
[0174] The optimization sequence 200d includes the following steps.
[0175] In step 215, the managing component manager checks the status of the optimization task through querying at least one stored component database for the status of the optimization task upon initiation of a client that provides an associated identifier of the optimization task.
[0176] In step 216, the status of the optimization task is determined and an acknowledgement is sent to the client containing the new status.
[0177] Alternatively or additionally, a client can inquire about the status of an optimization task by having the managed component manager check the current status of the optimization status.
[0178] 2e is a sequence diagram illustrating some sequence steps of an exemplary optimization sequence 200e according to some embodiments. The optimization sequence 200e is for providing optimization in a microservices architecture with at least one optimization service, the at least one optimization service comprising a management component configured to provide clients with access to the at least one optimization service, a messaging component configured to queue optimization requests, at least one work component configured to solve optimization tasks, and at least one storage component, the components of the at least one optimization service being operatively connected to each other. Thus, the optimization sequence 200e may be performed, for example, by the architecture 300 of FIG. 3 and / or the configuration 400 of FIG. 4 and / or the computer program product 500 of FIG. 5.
[0179] The optimization sequence 200e includes the following steps.
[0180] In step 217, the managing component manager checks the status of the optimization task through querying at least one stored component database for the status of the optimization task upon initiation of a client that provides an associated identifier of the optimization task.
[0181] In step 218, if the status of the optimization task is not in a final state such as "Invalid", "Stopped", "Critical" and "Optimized", the processing of the optimization task is stopped by the managed component manager.
[0182] Alternatively or additionally, the client may stop processing of the optimization task by the managed component manager checking the current status of the optimization status.
[0183] 2f is a state diagram illustrating some states of an example optimization sequence 200a, 200b, 200c, 200d, and 200e according to some embodiments. State diagram 200f illustrates the states of an optimization request and their transitions. State diagram 200f illustrates the lifecycle of an optimization request visualized as a state machine. The presented states are a minimal version, and more detailed states can be introduced if needed for a particular use case.
[0184] Examples of final states are Invalid, Stopped, Critical, and Optimized, which are states that are final and do not allow transition to another state.
[0185] Examples of non-final states are Queued, Error, and Loaded; a state is non-final and can still transition to another non-final or final state.
[0186] Once an optimization request is successfully sent, its state is set to Queued by the management component, indicating that it will be picked up by the work component. Once an optimization request is picked up by the work component, the data is loaded from its source (e.g., directly from input data, other APIs, databases, or data stores) and prepared for optimization. This may include, for example, setting up mathematical models or initializing heuristics in the framework. Its state is set to Loaded by the work component. Thus, if any issues occur during the loading of data, the state can transition to Error and Queued again. Once the optimization is finished and the solution is stored, its status is set to Optimized and the management component can return the stored solution to the client upon request. If the client stops the request, the non-final status becomes Stopped and no further state changes are performed.
[0187] When the work component recognizes invalid input data (e.g. wrong format), the state is set to Invalid to indicate a user-specific error. During request optimization, expected or unexpected errors can occur. These errors lead to state Error. Depending on the use case and / or exception, the system may wait for some time until the error is fixed and then try to requeue the request. However, eventually, if no solution is found after several attempts, the system will go to state Critical, which indicates that no further action will be taken by the optimization service.
[0188] Overall, an optimization request will end up in one of the final states Optimized, Stopped, Invalid, or Critical if at least one worker is available and the solution method is finite. For clients to function correctly, it is important that they rely on the optimization service to end up in one of these states. Communicating the state to the client ensures that feedback is provided, plus ensures a more robust system in the event of unexpected errors.
[0189] 3 is a schematic block diagram illustrating components of an exemplary microservices architecture 300 according to some embodiments. The microservices architecture 300 is for providing optimization and includes at least one optimization service 310, the at least one optimization service 310 including a management component 311 configured to provide a client 1 with access to the at least one optimization service 310, a messaging component 312 configured to queue optimization requests, at least one work component 313 configured to solve optimization tasks, and at least one storage component 314, where the components 311, 312, 313, 314 in the at least one optimization service 310 are operatively connected to each other. Thus, the microservices architecture 300 may, for example, perform the method steps of FIG. 1, any sequence steps of FIG. 2a-2e, and set the state of FIG. 2f for any optimization task sent to the microservices architecture 300.
[0190] The microservices architecture 300 is for providing optimization, which may include mathematical optimization, as a web service that solves a particular optimization problem.
[0191] Microservices architecture 300 may be referred to as optimization as a service (OaaS), reflecting a microservices approach to a single optimization use case that can be utilized by multiple applications.
[0192] The optimizations described herein may comprise a software service or web interface that can quickly provide the optimizations to consumers.
[0193] The components described herein are comprised of independent software processes that may be independently developed and tested, and which are loosely coupled and interact via network communication and / or shared storage.
[0194] For example, components may be independently developed and tested in different programming languages and platforms.
[0195] A stateless component as described herein is simply a component that does not maintain its own state, but is configured to perform a function and return a result, allowing for memory savings and clean, simple implementations and identical working components.
[0196] The microservices architecture 300 is based on the following: At least one optimization service that includes a stateless component; At least one optimization service 310 that addresses one particular optimization use case; and · Perform optimization in an ad-hoc manner. The optimization service 310 requires the following components: a management component 311, a manager, configured to provide external client access to the optimization service; a work component 313, a worker, configured to solve one mathematical optimization at a time; A messaging component 312, a messaging system configured to queue optimization requests for the work components to enable asynchronous request processing, e.g., the management component may add an optimization request to the queue when an optimization is triggered, again responding immediately, and the work component receives incoming requests for optimization and subscribes to the queue to work on potentially long-running tasks; A storage component 314, a database configured to store metadata for optimization requests, status changes, identifiers, or transmission information, where only the management component reads and writes to this storage component; In some embodiments, a storage component 315 (not shown), an object storage read and written by both the management component and the working component, configured to store the raw data required for the optimization, including data provided when submitting an optimization request, debug or intermediate data of the working component, and the final optimization solution.
[0197] FIG. 3 illustrates the interaction of clients 1-n with optimization services 310 and 320 to solve various optimization problems. These optimization services 310 and 320 may potentially be developed by different teams in different locations using different programming languages. Clients 1-n, for example, may have a web interface or other service that allows a user to select data for optimization, tune parameters, or define optimization scenarios. While each optimization service 310 and 320 may be built specifically for one optimization problem, the microservices architecture 300 may be flexible to accommodate clients 1-n accessing one or more optimization services based on their scope.
[0198] As shown in Fig. 3, the client 301 interfaces with the management component 311 of the optimization service 310, which is responsible for triggering the optimization, providing its status and solution, as well as stopping the optimization. The management component 311 does not resolve the actual optimization to avoid blocking other optimizations. Instead, it queues the optimization request in a queue, i.e., the messaging component 312, which allows the work component 313 to focus on resolving the optimization asynchronously. The work component 313 includes a general part for sharing functionality between different use cases and an optimization-specific part for implementing specific models and solution methods. Moreover, the work component 313 is responsible for updating the status of the request and storing its solution.
[0199] Thus, the microservices architecture 300 comprises at least one optimization service 310 comprising a management component 311 configured to provide access to the at least one optimization service to clients 301, a messaging component 312 configured to queue optimization requests, at least one work component 313 configured to resolve optimization tasks, and at least one storage component 314, wherein the components 311, 312, 313, 314 in the at least one optimization service 310 are operatively connected to one another.
[0200] The microservices architecture 300 further comprises a memory including executable instructions and one or more processors configured to communicate with the memory, the one or more processors configured to cause: a management component 311 to receive an optimization request sent from a client, the optimization request including an optimization task and corresponding data for the optimization; a management component 311 to store, in at least one storage component 314, the corresponding data for the optimization and a created association identifier of the optimization task; a management component 311 to send, in at least one storage component 314, the optimization task and the association identifier of the optimization task to a messaging component 312; and a monitoring, in at least one work component 313, of the messaging component 312 for the received optimization task.
[0201] The one or more processors are further configured to cause, upon detection of the received optimization task by the at least one work component 313, to retrieve, by the at least one work component 313, stored corresponding optimization data from the at least one storage component 314 through an associated identifier of the optimization task, to create, by the at least one work component (313), an optimization model for solving the optimization task, to solve the optimization task based on the created optimization model by the at least one work component 313, and to store, by the at least one work component 313, a solution to the optimization task and an associated identifier of the optimization task in the at least one storage component 314.
[0202] Thus, a microservices architecture may provide scalable, robust, and manageable small services because it focuses on small distributed components that are easy to test, maintain, independently and automatically scalable, and can be managed by small teams of optimized developers.
[0203] 4 is a schematic block diagram illustrating an example microservices configuration 400 according to some embodiments. The microservices configuration 400 is for providing optimization in a microservices architecture with at least one optimization service, the at least one optimization service comprising a management component configured to provide clients with access to the at least one optimization service, a messaging component configured to queue optimization requests, at least one work component configured to solve optimization tasks, and at least one storage component, the components of the at least one optimization service being operatively connected to each other. Thus, the microservices configuration 400 may, for example, perform the method steps of FIG. 1, any sequence steps of FIG. 2a-2e, and set the state of FIG. 2f for any optimization task sent to the microservices configuration 400.
[0204] The configuration 400 includes a device control circuit (CNTR, e.g., a controller or control module) 420, which in turn includes a receiver 401, e.g., a receiving circuit, configured to receive an optimization request sent from a client, including an optimization task and corresponding data for the optimization, a storer 404, e.g., a storage circuit, configured to store the corresponding data for optimization and a created associated identifier of the optimization task in storage 430, a sender 405, e.g., a sending circuit, configured to send the optimization task and the associated identifier of the optimization task to a messaging component, and a monitor 406, e.g., a monitoring circuit, configured to monitor the messaging component for received optimization tasks.
[0205] The CNTR 420 may further include (or may be otherwise associated, e.g., connected or connectable to) a detector 407, e.g., a detection circuit, configured to detect a received optimization task; an obtainer 408, e.g., an acquisition circuit, configured to obtain stored data for a corresponding optimization from the storage 430, e.g., through an associated identifier of the optimization task; a creator 409, e.g., a creation circuit configured to create an optimization model to solve the optimization task; a solver 410, e.g., a solving circuit configured to solve the optimization task based on the created optimization model; and a storer 411, e.g., a storage circuit, configured to store a solution to the optimization task and an associated identifier of the optimization task in the storage 430.
[0206] In some embodiments, the CNTR 420 may further comprise (or be otherwise associated with, e.g., connected or connectable to) a determiner 402, e.g., a determination circuit, configured to determine metadata based at least on a submitted optimization request, the metadata including transmission data of the optimization request.
[0207] In some embodiments, the CNTR 420 may further comprise a determiner 403, e.g., a decision circuit, (or otherwise associated with, e.g., connected or connectable to, the determiner 403) configured to determine a payload based on the transmitted optimization request, the payload including data for the corresponding optimization.
[0208] The configuration 400 may further comprise a storage 430, e.g., a storage circuit, (or otherwise associated with, e.g., connected or connectable to, the storage 430), configured to store the determined metadata and the determined payload. Generally, when a configuration is referred to herein, it should be understood as a physical product, e.g., a device. The physical product may comprise one or more components, such as control circuitry in the form of one or more controllers, or one or more processors, etc.
[0209] The described embodiments and their equivalents may be implemented in software or hardware, or a combination thereof. The embodiments may be performed by general purpose circuitry. Examples of general purpose circuitry include digital signal processors (DSPs), central processing units (CPUs), co-processing units, field programmable gate arrays (FPGAs), and other programmable hardware. Alternatively or additionally, the embodiments may be performed by specialized circuitry, such as application specific integrated circuits (ASICs). The general purpose and / or specialized circuitry may be associated with or included in an apparatus, such as, for example, a wireless communication device.
[0210] The embodiments may appear in an electronic device that includes structure, circuitry, and / or logic according to any of the embodiments described herein. Additionally or alternatively, the electronic device may be configured to perform a method according to any of the embodiments described herein.
[0211] According to some embodiments, the computer program product includes a computer readable medium, such as, for example, a physical memory. FIG. 5 illustrates an exemplary computer readable medium in the form of a physical memory 500, it is envisioned that the computer readable medium may be any computer readable medium. The computer program product may also include access to a server or cloud service, the server or cloud service including the computer readable medium. The computer readable medium has stored therein a computer program including program instructions. The computer program may be loadable into a data processor (PROC) 520, which may be included in, for example, an electronic device 510. When loaded into the data processing unit, the computer program may be stored in a memory (MEM) 530 associated with or included in the data processing unit. According to some embodiments, the computer program, when loaded and executed in the data processing unit, may cause the execution of, for example, method and / or sequence steps according to any of the methods and / or sequences illustrated in FIG. 1 and FIG. 2a-2e, or other methods described herein.
[0212] In general, all terms used in this specification are to be interpreted in accordance with their ordinary meaning in the relevant art unless a different meaning is clearly given and / or is implied from the context in which the term is used.
[0213] Reference is made herein to various embodiments, however, those of ordinary skill in the art will recognize numerous variations to the described embodiments that would still fall within the scope of the claims.
[0214] For example, the method embodiments described herein disclose exemplary methods through steps performed in a particular order. However, it is recognized that these sequences of events may occur in other orders without departing from the scope of the claims. Additionally, some method steps may be performed in parallel even though they are described as being performed sequentially. Thus, the steps of any method disclosed herein do not have to be performed in the exact order disclosed, unless a step is explicitly described as following or preceding another step and / or is implicitly described as requiring a step to follow or precede another step.
[0215] Similarly, it should be noted that in the description of the embodiments, the division of functional blocks into specific units is in no way intended to be limiting. On the contrary, these divisions are merely examples. Functional blocks described herein as one unit may be divided into two or more units. Furthermore, functional blocks described herein as being implemented as two or more units may be integrated into fewer (e.g., a single) units.
[0216] Any feature of any of the embodiments disclosed herein may be applied to any other embodiment wherever appropriate, and likewise any advantage of any embodiment may be applied to any other embodiment, and vice versa.
[0217] It is therefore to be understood that the details of the described embodiments are merely examples presented for purposes of illustration, and that all modifications that fall within the scope of the claims are intended to be embraced therein. [Aspect 1] 1. A computer-implemented method for providing optimization in a microservices architecture including at least one optimization service, the at least one optimization service comprising: a management component configured to provide clients with access to the at least one optimization service; a messaging component configured to queue optimization requests; at least one work component configured to resolve optimization tasks; and at least one storage component, the components within the at least one optimization service being operatively connected to one another, the method comprising: receiving (101) an optimization request sent by said client, said optimization request including an optimization task and corresponding data for the optimization, by said management component; storing (104) the corresponding optimization data and the generated association identifier of the optimization task in the at least one storage component by the management component; sending (105) the optimization task and the associated identifier of the optimization task to the messaging component by the management component; monitoring (106) the messaging component for received optimization tasks by the at least one work component; Upon detection (107) of a received optimization task, the at least one work component: retrieving (108) the stored data for the corresponding optimization from the at least one storage component through the association identifier of the optimization task by the at least one work component; creating (109) an optimization model for solving the optimization task by said at least one work component; - solving (110) the optimization task based on the created optimization model by the at least one work component; and storing (111) by the at least one work component, the solution to the optimization task and the associated identifier of the optimization task in the at least one storage component. [Aspect 2] determining (102) metadata based at least on the transmitted optimization request by the management component, the metadata including transmission data of the optimization request; The method of aspect 1, further comprising: storing (104a), by the management component, the determined metadata in the at least one storage component, the at least one storage component being accessible to both the management component and the at least one working component. [Aspect 3] determining (103) by the management component a payload based on the transmitted optimization request, the payload containing data for the corresponding optimization; 3. The method of claim 1 or 2, further comprising: storing (104b) the determined payload in the at least one storage component, by the management component, the at least one storage component being accessible to both the management component and the at least one working component. [Aspect 4] 4. The method of any one of aspects 1 to 3, wherein the at least one storage component comprises a database, the database configured to store metadata or metadata and payload of the optimization request. [Aspect 5] The method of any one of aspects 1 to 4, wherein the at least one storage component comprises two storage components including the database and an object storage, and the object storage is configured to store the payload of the optimization request. [Aspect 6] 6. The method of any one of aspects 2-5, wherein the metadata includes data for annotating the optimization request. [Aspect 7] 7. The method of any one of aspects 3 to 6, wherein the payload includes data for optimization corresponding to the optimization request. [Aspect 8] 8. The method of any one of aspects 1-7, wherein the architecture comprises a decision support system and / or an optimization system, each system utilizing a cloud infrastructure. [Aspect 9] 9. The method of any one of aspects 1-8, wherein the at least one working component is a stateless component. [Aspect 10] A method according to any one of aspects 1 to 9, wherein the client is a piece of computer hardware or software configured to access the optimization service. [Aspect 11] 9. A computer program product comprising a non-transitory computer readable medium having a computer program therein, the computer program comprising program instructions, the computer program being loadable into a data processing unit and configured to cause the execution of the method of any one of aspects 1 to 8 when the computer program is executed by the data processing unit. [Aspect 12] A microservices architecture (300) for providing optimization, the microservices architecture comprising at least one optimization service (310), the at least one optimization service comprising: a management component (311) configured to provide access to the at least one optimization service to a client (301); a messaging component (312) configured to queue optimization requests; at least one work component (313) configured to solve optimization tasks; and at least one storage component (314), the components (311, 312, 313, 314) in the at least one optimization service (310) being operatively connected to each other, the architecture comprising: and one or more processors configured to communicate with the memory, the one or more processors further comprising: receiving, by said management component (311), an optimization request sent from said client, comprising an optimization task and corresponding data for optimization; storing, by said management component (311), said corresponding optimization data and the generated association identifier of said optimization task in said at least one storage component; sending, by the management component (311), the optimization task and the associated identifier of the optimization task to the messaging component (312); monitoring the messaging component (312) for optimization tasks received by the at least one work component (313); Upon detection of the received optimization task by the at least one work component (313), retrieving, by the at least one work component (313), the stored data for the corresponding optimization from the at least one storage component (314) through the association identifier of the optimization task; creating, by said at least one work component (313), an optimization model for solving said optimization task; solving the optimization task based on the created optimization model by the at least one work component (313); and causing the at least one work component (313) to store the solution to the optimization task and the associated identifier of the optimization task in the at least one storage component (314).
Claims
1. 1. A computer-implemented method for providing optimization in a microservices architecture including at least one optimization service, the at least one optimization service comprising: a management component configured to provide clients with access to the at least one optimization service; a messaging component configured to queue optimization requests; at least one work component configured to resolve optimization tasks; and at least one storage component, the management component, the messaging component, the work component, and the storage component in the at least one optimization service being operatively connected to one another, the method comprising: - receiving (101) by said management component an optimization request sent by said client, said optimization request including an optimization task and corresponding data for optimization; storing (104) the corresponding optimization data and the generated association identifier of the optimization task in the at least one storage component by the management component; sending (105) by the management component the optimization task and the associated identifier of the optimization task to the messaging component; monitoring (106) the messaging component for received optimization tasks by the at least one work component; Upon detection (107) of a received optimization task, the at least one work component: Retrieving (108) the stored data for the corresponding optimization from the at least one storage component through the association identifier of the optimization task by the at least one work component; creating (109) an optimization model for solving the optimization task by said at least one work component; - solving (110) said optimization task based on said created optimization model by said at least one work component; storing (111) by said at least one work component a solution to said optimization task and said associated identifier of said optimization task in said at least one storage component; determining (102) by the management component metadata based at least on the transmitted optimization request, the metadata including transmission data of the optimization request; storing (104a) the determined metadata in the at least one storage component by the management component, the at least one storage component being accessible to both the management component and the at least one working component; 4. A computer-implemented method comprising:
2. - determining (103) by said management component a payload based on said transmitted optimization request, said payload containing data for said corresponding optimization; 2. The method of claim 1, further comprising: storing (104b) by the management component the determined payload in the at least one storage component, the at least one storage component being accessible to both the management component and the at least one working component.
3. The method of claim 1 or 2, wherein the at least one storage component comprises a database, the database configured to store metadata or metadata and payload of the optimization request.
4. The method of claim 3 , wherein the at least one storage component comprises the database and an object storage, the object storage configured to store the payload of the optimization request.
5. The method of claim 1 or 3, wherein the metadata includes data for annotating the optimization request.
6. The method according to any one of claims 2 to 4, wherein the payload comprises data for optimization corresponding to the optimization request.
7. The method of any one of claims 1 to 6, wherein the microservices architecture comprises a decision support system and / or an optimization system, each system utilizing a cloud infrastructure.
8. The method of any one of claims 1 to 7, wherein the at least one working component is a stateless component.
9. The method of any one of claims 1 to 8, wherein the client is a piece of computer hardware or software configured to access the optimization service.
10. A computer program product comprising a non-transitory computer readable medium having a computer program therein comprising program instructions, said computer program being loadable into a data processing unit and configured to cause the performance of the method of any one of claims 1 to 7 when said computer program is executed by said data processing unit.
11. A microservices architecture (300) for providing optimization, the microservices architecture comprising at least one optimization service (310), the at least one optimization service comprising: a management component (311) configured to provide access to the at least one optimization service to a client (301); a messaging component (312) configured to queue optimization requests; at least one work component (313) configured to resolve optimization tasks; and at least one storage component (314), the management component (311), the messaging component (312), the work component (313), and the storage component (314) of the at least one optimization service (310) being operatively connected to each other, the microservices architecture comprising: The method further comprises: a memory including executable instructions; and one or more processors configured to communicate with the memory, the one or more processors: receiving, by said management component (311), an optimization request sent from said client, comprising an optimization task and corresponding data for optimization; storing, by said management component (311), said corresponding optimization data and the generated association identifier of said optimization task in said at least one storage component; sending, by the management component (311), the optimization task and the associated identifier of the optimization task to the messaging component (312); monitoring the messaging component (312) for received optimization tasks by the at least one work component (313); Upon detection of a received optimization task by the at least one work component (313), retrieving, by the at least one work component (313), the stored corresponding optimization data from the at least one storage component (314) through the association identifier of the optimization task; creating, by said at least one work component (313), an optimization model for solving said optimization task; solving the optimization task based on the created optimization model by the at least one work component (313); storing, by said at least one work component (313), a solution to said optimization task and said associated identifier of said optimization task in said at least one storage component (314); determining, by the management component, metadata based at least on the transmitted optimization request, the metadata including transmission data of the optimization request; storing, by the management component, the determined metadata in the at least one storage component, the at least one storage component being accessible to both the management component and the at least one working component; The system is configured to cause
Citation Information
Patent Citations
Log record processing method, server and storage medium
CN110175154A
targeted mobile advertising
JP2009527864A
Methods and systems for quantum-immediate or quantum-enabled computers
JP2019521431A