CN110502761B - Translation platform and load adjustment method thereof - Google Patents

Translation platform and load adjustment method thereof Download PDF

Info

Publication number
CN110502761B
CN110502761B CN201910797805.6A CN201910797805A CN110502761B CN 110502761 B CN110502761 B CN 110502761B CN 201910797805 A CN201910797805 A CN 201910797805A CN 110502761 B CN110502761 B CN 110502761B
Authority
CN
China
Prior art keywords
translation
engine
registry
instruction
translation engine
Prior art date
Legal status (The legal status is an assumption and is not a legal conclusion. Google has not performed a legal analysis and makes no representation as to the accuracy of the status listed.)
Active
Application number
CN201910797805.6A
Other languages
Chinese (zh)
Other versions
CN110502761A (en
Inventor
马力
唐剑波
李长亮
郭馨泽
Current Assignee (The listed assignees may be inaccurate. Google has not performed a legal analysis and makes no representation or warranty as to the accuracy of the list.)
Beijing Kingsoft Digital Entertainment Co Ltd
Chengdu Kingsoft Digital Entertainment Co Ltd
Original Assignee
Beijing Kingsoft Digital Entertainment Co Ltd
Chengdu Kingsoft Digital Entertainment Co Ltd
Priority date (The priority date is an assumption and is not a legal conclusion. Google has not performed a legal analysis and makes no representation as to the accuracy of the date listed.)
Filing date
Publication date
Application filed by Beijing Kingsoft Digital Entertainment Co Ltd, Chengdu Kingsoft Digital Entertainment Co Ltd filed Critical Beijing Kingsoft Digital Entertainment Co Ltd
Priority to CN201910797805.6A priority Critical patent/CN110502761B/en
Publication of CN110502761A publication Critical patent/CN110502761A/en
Application granted granted Critical
Publication of CN110502761B publication Critical patent/CN110502761B/en
Active legal-status Critical Current
Anticipated expiration legal-status Critical

Links

Classifications

    • GPHYSICS
    • G06COMPUTING; CALCULATING OR COUNTING
    • G06FELECTRIC DIGITAL DATA PROCESSING
    • G06F9/00Arrangements for program control, e.g. control units
    • G06F9/06Arrangements for program control, e.g. control units using stored programs, i.e. using an internal store of processing equipment to receive or retain programs
    • G06F9/46Multiprogramming arrangements
    • G06F9/50Allocation of resources, e.g. of the central processing unit [CPU]
    • G06F9/5005Allocation of resources, e.g. of the central processing unit [CPU] to service a request
    • G06F9/5027Allocation of resources, e.g. of the central processing unit [CPU] to service a request the resource being a machine, e.g. CPUs, Servers, Terminals
    • G06F9/505Allocation of resources, e.g. of the central processing unit [CPU] to service a request the resource being a machine, e.g. CPUs, Servers, Terminals considering the load

Landscapes

  • Engineering & Computer Science (AREA)
  • Software Systems (AREA)
  • Theoretical Computer Science (AREA)
  • Physics & Mathematics (AREA)
  • General Engineering & Computer Science (AREA)
  • General Physics & Mathematics (AREA)
  • Machine Translation (AREA)
  • Information Transfer Between Computers (AREA)

Abstract

The application provides a translation platform and a load adjustment method thereof, wherein the translation platform comprises a management background and a registration center; the method comprises the following steps: the management background sends heartbeat check instructions to a plurality of services through the registry to monitor the load of each service, wherein each service corresponds to at least one translation engine; if the load of the service is smaller than a first threshold value, the management background generates a stop instruction of at least one translation engine and sends the stop instruction to the corresponding translation engine through the registry; if the load of the service is greater than or equal to a second threshold, the management background generates a starting instruction of at least one translation engine and sends the starting instruction to the corresponding translation engine through the registration center, so that the dynamic increase and decrease of each service capacity are realized, the dynamic adjustment of the service capacity is realized, and the resource waste is reduced.

Description

Translation platform and load adjustment method thereof
Technical Field
The present application relates to the field of internet technologies, and in particular, to a translation platform, a load adjustment method thereof, a computing device, and a computer readable storage medium.
Background
The function of machine translation is served as a callable service, and is understood as a translation service that can be called by url (Uniform Resource Locator ) address.
Translation engines are currently deployed: the whole cluster is provided with a plurality of machines, one machine is provided with a plurality of cards, and each card is provided with a plurality of engines; in an automatic publishing tool, external service publishing is usually performed by writing parameter scripts related to a frame model.
For different services, the highest/lowest number of concurrent services often varies greatly at different times, and there are also peak-shifting situations for different applications. In an actual production environment, if all services determine the number of engines according to the maximum concurrency requirement, a great amount of resource waste is caused in idle time.
Disclosure of Invention
In view of the above, embodiments of the present application provide a translation platform, a load adjustment method thereof, a computing device and a computer readable storage medium, so as to solve the technical defects in the prior art.
The embodiment of the application provides a load adjustment method of a translation platform, wherein the translation platform comprises a management background and a registry; the method comprises the following steps:
the management background sends heartbeat check instructions to a plurality of services through the registry to monitor the load of each service, wherein each service corresponds to at least one translation engine;
if the load of the service is smaller than a first threshold value, the management background generates a stop instruction of at least one translation engine and sends the stop instruction to the corresponding translation engine through the registry;
and if the load of the service is greater than or equal to a second threshold value, the management background generates a starting instruction of at least one translation engine and sends the starting instruction to the corresponding translation engine through the registry.
Optionally, the translation platform further comprises an engine agent;
the management background sending heartbeat check instructions to a plurality of services via the registry to monitor the load of each of the services, comprising:
the management background sends a heartbeat check instruction to the engine agent through the registry;
and the engine agent sends the heartbeat check instruction to a plurality of services respectively, and returns the received load response information returned by the services to the management background through the registration center.
Optionally, the management background generates a stop instruction of at least one translation engine and sends the stop instruction to a corresponding translation engine via the registry, including:
the management background sends the generated stop instruction of at least one translation engine to the registry;
the registry sends a stop instruction of at least one of the translation engines to a corresponding at least one translation engine via the engine agent.
Optionally, the management background generates a start instruction of at least one translation engine and sends the start instruction to a corresponding translation engine via the registry, including:
the management background sends the generated starting instruction of at least one translation engine to the registry;
the registry sends a start instruction of at least one of the translation engines to a corresponding at least one translation engine via the engine agent.
Optionally, the registry further stores a translation engine service list, wherein the translation engine service list includes at least one started translation engine;
the method further comprises the steps of:
under the condition that a stop instruction of at least one translation engine is received, deleting the at least one translation engine corresponding to the stop instruction from the translation engine service list by the registry;
and under the condition that a starting instruction of at least one translation engine is received, adding the at least one translation engine corresponding to the starting instruction into the translation engine service list by the registry.
Optionally, the load adjustment method further includes:
the management background generates an operation instruction according to the received input instruction, wherein the operation instruction comprises an addition instruction, a deletion instruction and a modification instruction of the translation engine;
the registry receives the operation instruction and updates the state of the translation engine in the translation engine service list according to the operation instruction;
the registry sends the operation instruction to a corresponding translation engine through the engine agent, and sends an operation result returned by the engine agent to the management background.
Optionally, the load includes:
at least one of concurrency of the service interface and failure frequency statistics; and
at least one of processor utilization rate, memory computing power utilization rate and memory utilization rate of the machine corresponding to the service.
The embodiment of the application provides a translation platform, which comprises a management background and a registry;
the management background sends heartbeat check instructions to a plurality of services through the registry to monitor the load of each service, wherein each service corresponds to at least one translation engine;
if the load of the service is smaller than a threshold value, the management background generates a stop instruction of at least one translation engine and sends the stop instruction to the corresponding translation engine through the registry;
and if the load of the service is greater than or equal to a threshold value, the management background generates a starting instruction of at least one translation engine and sends the starting instruction to the corresponding translation engine through the registry.
Optionally, the translation platform further comprises an engine agent;
the management background sending heartbeat check instructions to a plurality of services via the registry to monitor the load of each of the services, comprising:
the management background sends a heartbeat check instruction to the engine agent through the registry;
and the engine agent sends the heartbeat check instruction to a plurality of services respectively, and returns the received load response information returned by the services to the management background through the registration center.
Embodiments of the present application provide a computing device comprising a memory, a processor, and computer instructions stored on the memory and executable on the processor, which when executed by the processor implement the steps of the load adjustment method as described above.
Embodiments of the present application provide a computer readable storage medium storing computer instructions which, when executed by a processor, implement the steps of a load adjustment method as described above.
According to the load adjustment method of the translation platform, the management background sends the heartbeat check instruction to the plurality of services through the registry to monitor the load of each service, and sends the generated stop instruction of the translation engine to the corresponding translation engine through the registry to stop the corresponding translation engine under the condition that the load of the service is smaller than the first threshold; and under the condition that the load of the service is greater than or equal to a second threshold value, the management background sends the generated starting instruction of the translation engine to the corresponding translation engine through the registry to start the corresponding translation engine, so that the dynamic increase and decrease of each service capacity are realized, the dynamic adjustment of the service capacity is realized, and the resource waste is reduced.
In addition, in the running process, the management background sends the generated stop instruction or start instruction of the translation engine to the registry to stop or start the corresponding translation engine, so that the dynamic increase and decrease of the service capacity are further realized.
Drawings
FIG. 1 is a schematic diagram of a translation platform according to an embodiment of the present application;
FIG. 2 is a schematic diagram of a translation engine template according to one embodiment of the present application;
FIG. 3 is a flowchart illustrating a load adjustment method of a translation platform according to an embodiment of the present application;
FIG. 4 is a flowchart illustrating a load adjustment method of a translation platform according to another embodiment of the present application;
FIG. 5 is a flowchart illustrating a load adjustment method of a translation platform according to another embodiment of the present application;
FIG. 6 is a schematic diagram of a computing device in accordance with another embodiment of the application.
Detailed Description
In the following description, numerous specific details are set forth in order to provide a thorough understanding of the present application. The present application may be embodied in many other forms than those herein described, and those skilled in the art will readily appreciate that the present application may be similarly embodied without departing from the spirit or essential characteristics thereof, and therefore the present application is not limited to the specific embodiments disclosed below.
The terminology used in the one or more embodiments of the specification is for the purpose of describing particular embodiments only and is not intended to be limiting of the one or more embodiments of the specification. As used in this specification, one or more embodiments and the appended claims, the singular forms "a," "an," and "the" are intended to include the plural forms as well, unless the context clearly indicates otherwise. It should also be understood that the term "and/or" as used in one or more embodiments of the present specification refers to and encompasses any or all possible combinations of one or more of the associated listed items.
It should be understood that, although the terms first, second, etc. may be used in one or more embodiments of this specification to describe various information, these information should not be limited by these terms. These terms are only used to distinguish one type of information from another. For example, a first may also be referred to as a second, and similarly, a second may also be referred to as a first, without departing from the scope of one or more embodiments of the present description. The word "if" as used herein may be interpreted as "at … …" or "at … …" or "responsive to a determination", depending on the context.
First, terms related to one or more embodiments of the present application will be explained.
Machine translation: by entering a sentence in the source language into the machine, the machine returns sentences in one or more target languages, a process called machine translation.
Translation engine: the machine translation function is served to be a callable service. It is understood that translation may be invoked by url (Uniform Resource Locator ) addresses.
Translation platform: a translation engine and a management platform for external services.
Isomorphism engine: it is meant that the same translation framework is used, but because of the inconsistent model parameters, each engine instance needs to run with different parameters.
Heterogeneous engine: refers to translation engines written using different frameworks, such as Tensorlow or pytorch.
Dock engine: is an open-source application container engine, which allows developers to package their applications and rely on packages into a portable container, then release them to any popular Linux machine, and also can implement virtualization. The containers are completely sandboxed without any interface to each other.
In the present application, a method and apparatus for adjusting load of a translation platform, a computing device, and a computer readable storage medium are provided, and the following embodiments are described in detail.
First, a translation platform according to an embodiment of the present application will be described. Referring to fig. 1, the translation platform includes:
management background-management work of all translation engines, including the functions of translation engine creation, model parameter addition and deletion, translation engine starting and stopping, translation engine release, etc. Operated by an interface presented to the display device.
Registry-the actual logical layer that performs the translation engine management commands issued by the user and sent by the management background. The method realizes the addition, modification and deletion of the translation engine, the starting and stopping of the engine, the release or release cancellation of the service and the like.
An engine agent, such as a docker engine agent, runs on the machine and is responsible for receiving commands initiated by a user in the management background to actually operate the machine translation engine, such as starting and stopping the engine forwarded by the registry.
External interface-obtaining available engine or service through registry, and then calling.
And the translation engine is operated in the GPU of the cluster machine, and translates the received sentence to be translated to obtain a corresponding translation sentence.
The management platform of the embodiment generates a translation engine template through abstract engine translation flow and engine parameters, solves the problem of isomorphic and heterogeneous engine compatibility, and achieves simplification of engine management and service management.
The whole engine translation flow is divided into three parts: pretreatment, translation and post-treatment; the method comprises the steps of preprocessing original data, word segmentation, inputting the segmented data into a model for translation, and performing post-processing, such as sub-word merging/symbol processing and the like, according to a result output by the model. This is also an abstract principle of the engine translation flow.
The abstract engine translation flow may not necessarily cover all models, but may be extended to support newly added models.
For preprocessing and post-processing, many preprocessing modes are already implemented in the translation platform, such as jieba segmentation, pku segmentation, sentencephem segmentation, and the like. For a newly added model, if a new word segmentation algorithm is newly proposed, it can also be loaded by the platform as long as the new word segmentation is added to the platform.
See FIG. 2 for a schematic diagram of a translation engine template. A basic translation flow template is provided to abstract the basic flow of translation engine work. The translation engines of different implementations are realized when being accessed to the platform, thereby being capable of meeting the requirement of unified management by the platform. Wherein, referring to fig. 2, the "preprocessing parameters" are used to add the preprocessing parameters to the platform, such as word segmentation.
The "post-processing parameters" are used to add post-processing parameters to the platform, such as subword merging or processing symbols.
The "model command line parameters" are used to add parameters of the model itself to the platform. For this portion, the translation engine templates do not need to be parsed, but are left for each model to parse itself when implementing the translation engine templates.
"docker target path" refers to a directory binding in a container to a host directory location;
the "docker image name" refers to an environment image on which the program depends.
The dock mirror image is an environment for running an engine, is equivalent to an un-started virtual machine, and can mount a dock target path to a host machine, namely an entity machine for running the virtual machine, which corresponds to a host source path after the virtual machine is started, so as to share programs or model data.
Specifically, the engine translation flow in this embodiment includes:
1) Sentence pretreatment: standard preprocessing such as correction of some punctuations.
2) Model-dependent preprocessing: [ model-specific methods ] such as word segmentation and the like.
3) Model translation: the pre-processed sentences are translated [ model specific methods ].
4) Model-dependent post-processing [ model-specific methods ].
5) Sentence post-processing: standard post-processing such as punctuation correction, space deletion, etc.
The general method refers to a method for realizing general parameters of the translation flow template, and the model-specific method refers to a method for realizing parameters of each different translation engine.
Thus, a basic service template can be defined [ pseudo code ]:
String translate(org_sentence):
preprocessed = pre-process (org-sense) # universal pre-processing
preprocessed = model preprocess (preprocessed) # model dependent preprocessing, e.g. word segmentation, etc
Translated = model_ translation (preprocessed) # model translation
postprocessed = model postprocess (translated) # model dependent post-processing
final=post_ process (postprocessed) # general post-processing
return final # returns final translation
Wherein the general preprocessing and the general post-processing have been implemented by the base class of the translation service engine. The model specific preprocessing, translation and post-processing are realized by the specific class of the translation engine for realizing the template, so that the specific model related realization is also carried out for each translation engine while the standardization and the templatization of the service of the translation engine are realized.
In this way, only one of the different translation engines exists in the project to realize the subclass of the translation engine template, so that a single project supports all the translation engines, and the compatibility of heterogeneous engines is realized.
Referring to FIG. 2, for the generic parameters of the translation engine template, the translation engine template will parse; for different parameters of the translation engine, the translation engine template does not analyze the parameters of the models, but leaves the parameters to be analyzed by each model when the translation engine template is realized, so that the parameter compatibility of the isomorphic engine and the heterogeneous engine is realized.
Through further abstracting engine parameters, information such as IP, port, running GPU, engine frame, model name, language, preprocessing parameters, post-processing parameters, frame model related parameters, engine state and the like of the service is defined as engine service parameters, so that operations such as adding, deleting, modifying, starting and stopping the translation engine, publishing or canceling the service and the like of the translation engine are realized by a management background, and management of the translation engine and management of the service are simplified.
The embodiment of the application discloses a load adjustment method of a translation platform, which is shown in fig. 3 and comprises the following steps:
301. the management background sends heartbeat check instructions to a plurality of services via the registry to monitor the load of each of the services, wherein each of the services corresponds to at least one translation engine.
In this embodiment, a plurality of translation engines are grouped, each group corresponding to a service. The grouping principle can be grouping according to the attributes of engine industry/engine type and the like. Each service's corresponding translation engine runs in the GPU of one machine.
Wherein the load may include a variety of:
at least one of concurrency of the service interface and failure frequency statistics; and
at least one of processor utilization rate, memory computing power utilization rate and memory utilization rate of the machine corresponding to the service.
Specifically, step 301 includes:
s3011, the management background sends a heartbeat check instruction to the engine agent through the registry.
S3012, the engine agent sends the heartbeat checking instruction to a plurality of services respectively, and returns the received load response information returned by the services to the management background through the registry.
302. And if the load of the service is smaller than a first threshold value, the management background generates a stop instruction of at least one translation engine and sends the stop instruction to the corresponding translation engine through the registry.
The first threshold may be set according to practical requirements, for example, set to 30%. For this situation, the service is less loaded/accessed and should be stopped.
Specifically, the registry also stores a translation engine service list, wherein the translation engine service list comprises at least one started translation engine;
and under the condition that a stop instruction of at least one translation engine is received, deleting the at least one translation engine corresponding to the stop instruction in the translation engine service list by the registry, and re-requesting a new translation engine list from the registry by an external interface so as to re-provide service loads for external services.
Specifically, the management background generates a stop instruction of at least one translation engine and sends the stop instruction to a corresponding translation engine through the registry, and the method comprises the following steps:
s3021, the management background sends the generated stop instruction of at least one translation engine to the registry.
S3022, the registry sends a stop instruction of at least one translation engine to the corresponding at least one translation engine via the engine agent.
303. And if the load of the service is greater than or equal to a second threshold value, the management background generates a starting instruction of at least one translation engine and sends the starting instruction to the corresponding translation engine through the registry.
The second threshold may be set according to practical requirements, for example, set to 80%. For this situation, the service is loaded higher/accessed more, and a translation engine should be added for the service.
Specifically, the registry also stores a translation engine service list, wherein the translation engine service list includes at least one started translation engine.
And under the condition that a starting instruction of at least one translation engine is received, adding the at least one translation engine corresponding to the starting instruction into the translation engine service list by the registry.
Specifically, step 303 includes:
s3031, the management background sends the generated starting instruction of at least one translation engine to the registry.
S3032, the registry sends a start instruction of at least one translation engine to the corresponding at least one translation engine through the engine agent.
According to the load adjustment method of the translation platform, the management background sends the heartbeat check instruction to the plurality of services through the registry to monitor the load of each service, and sends the generated stop instruction of the translation engine to the corresponding translation engine through the registry to stop the corresponding translation engine under the condition that the load of the service is smaller than the first threshold; and under the condition that the load of the service is greater than or equal to a second threshold value, the management background sends the generated starting instruction of the translation engine to the corresponding translation engine through the registry to start the corresponding translation engine, so that the dynamic increase and decrease of each service capacity are realized, the dynamic adjustment of the service capacity is realized, and the resource waste is reduced.
The embodiment of the application also discloses a load adjustment method of the translation platform, referring to fig. 4, the method comprises the following steps 401-406:
401. the management background sends heartbeat check instructions to a plurality of services via the registry to monitor the load of each of the services, wherein each of the services corresponds to at least one translation engine.
402. And if the load of the service is smaller than a first threshold value, the management background generates a stop instruction of at least one translation engine and sends the stop instruction to the corresponding translation engine through the registry.
403. And if the load of the service is greater than or equal to a second threshold value, the management background generates a starting instruction of at least one translation engine and sends the starting instruction to the corresponding translation engine through the registry.
Steps 401 to 403 are the same as steps 301 to 303 in the previous embodiment, and the method in this embodiment is not described again.
404. And generating an operation instruction according to the received input instruction by the management background, wherein the operation instruction comprises an addition instruction, a deletion instruction and a modification instruction of the translation engine.
The operation instruction can be generated according to clicking of the interface of the display device by a user.
Specifically, in the interface of the management background, a translation engine and corresponding operation buttons are displayed.
Table 1 below shows a list of interfaces that manage the background.
TABLE 1
The operation buttons are displayed on the interface for the user to click.
405. And the registry receives the operation instruction and updates the state of the translation engine in the translation engine service list according to the operation instruction.
406. And the registry transmits the operation instruction to a corresponding translation engine through the engine agent, and transmits an operation result returned by the engine agent to the management background.
With respect to additions, deletions and modifications of translation engines, it is essential to modify database entries, not involving engine agents. It should be noted that, unlike start/stop, additions, deletions, and modifications to the translation engine need to be made with the translation engine stopped. The translation engine cannot be operated without stopping its operation.
According to the load adjustment method of the translation platform, provided by the application, besides the management background is used for sending the heartbeat check instruction to the machine running the plurality of translation engines through the engine agent through the registration center so as to monitor the load of each service, the adjustment of the translation engine can be actively realized through the generation of the addition instruction, the deletion instruction and the modification instruction of the translation engine through the management background, and the increase and decrease of the capacity of each service are further realized, so that the dynamic adjustment of the service capacity is realized, and the resource waste is reduced.
In addition, in the running process, the management background sends the generated stop instruction or start instruction of the translation engine to the registry to stop or start the corresponding translation engine, so that the dynamic increase and decrease of the service capacity are further realized.
Referring to fig. 5, another embodiment of the present application discloses a load adjustment method of a translation platform, for adjusting a translation engine under the condition that the translation engine generates a stop instruction or a start instruction, including:
501. the management background generates a stop instruction or a start instruction of the translation engine according to the received first input instruction, and then performs step 506.
502. The plurality of translation engines are grouped, one service for each group.
503. The management background sends a heartbeat check instruction to a machine running a plurality of the translation engines via the registry through the engine proxy to monitor the load of each of the services.
504. If the load of the service is less than the first threshold, the management background generates a stop instruction of at least one translation engine and sends the stop instruction to the corresponding translation engine through the registry, and step 506 is executed.
505. If the load of the service is greater than or equal to the second threshold, the management background generates a start instruction of at least one translation engine and sends the start instruction to the corresponding translation engine through the registry, and step 506 is executed.
Wherein the load comprises:
at least one of concurrency of the service interface and failure frequency statistics; and
at least one of processor utilization rate, memory computing power utilization rate and memory utilization rate of the machine corresponding to the service.
Specifically, for services with lower load/less access, the management background deletes corresponding data from the translation engine list of the registry, and requests a new translation engine list from the registry again to the external interface.
For the service with higher load/more access, the management background starts a new translation engine, updates the registry, and requests the new translation engine list to the registry again for the external interface.
506. The registry searches the loaded translation engine according to the stop instruction or the start instruction of the translation engine, operates the translation engine, and sends the obtained operation result to the management background.
507. And the management background acquires the data of the translation engine again according to the operation result and updates the user interface.
According to the load adjustment method of the translation platform, the management background sends the heartbeat check instruction to the plurality of services through the registry to monitor the load of each service, and sends the generated stop instruction of the translation engine to the corresponding translation engine through the registry to stop the corresponding translation engine under the condition that the load of the service is smaller than the first threshold; and under the condition that the load of the service is greater than or equal to a second threshold value, the management background sends the generated starting instruction of the translation engine to the corresponding translation engine through the registry to start the corresponding translation engine, so that the dynamic increase and decrease of each service capacity are realized, the dynamic adjustment of the service capacity is realized, and the resource waste is reduced.
In addition, in the running process, the management background sends the generated stop instruction or start instruction of the translation engine to the registry to stop or start the corresponding translation engine, so that the dynamic increase and decrease of the service capacity are further realized.
An embodiment of the present application also provides a computing device storing computer instructions that, when executed by a processor, implement the steps of a load adjustment method for a translation platform as described above.
Fig. 6 is a block diagram illustrating a configuration of a computing device 600 according to an embodiment of the present description. The components of computing device 600 include, but are not limited to, memory 610 and processor 620. The processor 620 is coupled to the memory 610 via a bus 630 and a database 650 is used to hold data.
Computing device 600 also includes access device 640, access device 640 enabling computing device 600 to communicate via one or more networks 660. Examples of such networks include the Public Switched Telephone Network (PSTN), a Local Area Network (LAN), a Wide Area Network (WAN), a Personal Area Network (PAN), or a combination of communication networks such as the internet. The access device 640 may include one or more of any type of network interface (e.g., a Network Interface Card (NIC)) whether wired or wireless, such as an IEEE802.11 Wireless Local Area Network (WLAN) wireless interface, a worldwide interoperability for microwave access (Wi-MAX) interface, an ethernet interface, a Universal Serial Bus (USB) interface, a cellular network interface, a bluetooth interface, a Near Field Communication (NFC) interface, and so forth.
In one embodiment of the present description, the above-described components of computing device 600, as well as other components not shown in FIG. 6, may also be connected to each other, such as by a bus. It should be understood that the block diagram of the computing device shown in FIG. 6 is for exemplary purposes only and is not intended to limit the scope of the present description. Those skilled in the art may add or replace other components as desired.
Computing device 600 may be any type of stationary or mobile computing device, including a mobile computer or mobile computing device (e.g., tablet, personal digital assistant, laptop, notebook, netbook, etc.), mobile phone (e.g., smart phone), wearable computing device (e.g., smart watch, smart glasses, etc.), or other type of mobile device, or a stationary computing device such as a desktop computer or PC. Computing device 600 may also be a mobile or stationary server.
The foregoing is a schematic illustration of a computing device of this embodiment. It should be noted that, the technical solution of the computing device and the technical solution of the load adjustment method of the translation platform belong to the same concept, and details of the technical solution of the computing device, which are not described in detail, can be referred to the description of the technical solution of the load adjustment method of the translation platform.
An embodiment of the present application also provides a computer-readable storage medium storing computer instructions that, when executed by a processor, implement the steps of a load adjustment method for a translation platform as described above.
The above is an exemplary version of a computer-readable storage medium of the present embodiment. It should be noted that, the technical solution of the storage medium and the technical solution of the load adjustment method of the translation platform belong to the same concept, and details of the technical solution of the storage medium which are not described in detail can be referred to the description of the technical solution of the load adjustment method of the translation platform.
The computer instructions include computer program code that may be in source code form, object code form, executable file or some intermediate form, etc. The computer readable medium may include: any entity or device capable of carrying the computer program code, a recording medium, a U disk, a removable hard disk, a magnetic disk, an optical disk, a computer Memory, a Read-Only Memory (ROM), a random access Memory (RAM, random Access Memory), an electrical carrier signal, a telecommunications signal, a software distribution medium, and so forth. It should be noted that the computer readable medium contains content that can be appropriately scaled according to the requirements of jurisdictions in which such content is subject to legislation and patent practice, such as in certain jurisdictions in which such content is subject to legislation and patent practice, the computer readable medium does not include electrical carrier signals and telecommunication signals.
It should be noted that, for the sake of simplicity of description, the foregoing method embodiments are all expressed as a series of combinations of actions, but it should be understood by those skilled in the art that the present application is not limited by the order of actions described, as some steps may be performed in other order or simultaneously in accordance with the present application. Further, those skilled in the art will appreciate that the embodiments described in the specification are all preferred embodiments, and that the acts and modules referred to are not necessarily all required for the present application.
In the foregoing embodiments, the descriptions of the embodiments are emphasized, and for parts of one embodiment that are not described in detail, reference may be made to the related descriptions of other embodiments.
The preferred embodiments of the application disclosed above are intended only to assist in the explanation of the application. Alternative embodiments are not intended to be exhaustive or to limit the application to the precise form disclosed. Obviously, many modifications and variations are possible in light of the above teaching. The embodiments were chosen and described in order to best explain the principles of the application and the practical application, to thereby enable others skilled in the art to best understand and utilize the application. The application is limited only by the claims and the full scope and equivalents thereof.

Claims (11)

1. The load adjustment method of the translation platform is characterized in that the translation platform comprises a management background and a registry;
the method comprises the following steps:
the management background sends heartbeat check instructions to a plurality of services through the registry to monitor the load of each service, wherein each service corresponds to at least one translation engine, the translation engine corresponding to each service operates in one machine, and the registry is an actual logic layer for executing the translation engine management command sent by a user and sent by the management background;
if the load of the service is smaller than a first threshold value, the management background generates a stop instruction of at least one translation engine and sends the stop instruction to the corresponding translation engine through the registry;
and if the load of the service is greater than or equal to a second threshold value, the management background generates a starting instruction of at least one translation engine and sends the starting instruction to the corresponding translation engine through the registry.
2. The method of load adjustment of a translation platform of claim 1, wherein the translation platform further comprises an engine agent;
the management background sending heartbeat check instructions to a plurality of services via the registry to monitor the load of each of the services, comprising:
the management background sends a heartbeat check instruction to the engine agent through the registry;
and the engine agent sends the heartbeat check instruction to a plurality of services respectively, and returns the received load response information returned by the services to the management background through the registration center.
3. The method for load adjustment of a translation platform according to claim 2, wherein the management background generates a stop instruction of at least one of the translation engines and transmits the stop instruction to the corresponding translation engine via the registry, comprising:
the management background sends the generated stop instruction of at least one translation engine to the registry;
the registry sends a stop instruction of at least one of the translation engines to a corresponding at least one translation engine via the engine agent.
4. The method for adjusting load of translation platform according to claim 2, wherein the management background generates a start instruction of at least one of the translation engines and sends the start instruction to the corresponding translation engine via the registry, comprising:
the management background sends the generated starting instruction of at least one translation engine to the registry;
the registry sends a start instruction of at least one of the translation engines to a corresponding at least one translation engine via the engine agent.
5. The method of load adjustment of a translation platform of claim 2, wherein the registry further stores a translation engine service list, wherein the translation engine service list includes at least one started translation engine;
the method further comprises the steps of:
under the condition that a stop instruction of at least one translation engine is received, deleting the at least one translation engine corresponding to the stop instruction from the translation engine service list by the registry;
and under the condition that a starting instruction of at least one translation engine is received, adding the at least one translation engine corresponding to the starting instruction into the translation engine service list by the registry.
6. The method of load adjustment of a translation platform of claim 2, further comprising:
the management background generates an operation instruction according to the received input instruction, wherein the operation instruction comprises an addition instruction, a deletion instruction and a modification instruction of the translation engine;
the registry receives the operation instruction and updates the state of the translation engine in the translation engine service list according to the operation instruction;
the registry sends the operation instruction to a corresponding translation engine through the engine agent, and sends an operation result returned by the engine agent to the management background.
7. The method of load adjustment of a translation platform of claim 1, wherein the load comprises:
at least one of concurrency of the service interface and failure frequency statistics; and
at least one of processor utilization rate, memory computing power utilization rate and memory utilization rate of the machine corresponding to the service.
8. A translation platform, wherein the translation platform comprises a management background and a registry;
the management background sends heartbeat check instructions to a plurality of services through the registry to monitor the load of each service, wherein each service corresponds to at least one translation engine, the translation engine corresponding to each service operates in one machine, and the registry is an actual logic layer for executing the translation engine management command sent by a user and sent by the management background;
if the load of the service is smaller than a threshold value, the management background generates a stop instruction of at least one translation engine and sends the stop instruction to the corresponding translation engine through the registry;
and if the load of the service is greater than or equal to a threshold value, the management background generates a starting instruction of at least one translation engine and sends the starting instruction to the corresponding translation engine through the registry.
9. The translation platform of claim 8, wherein the translation platform further comprises an engine agent;
the management background sending heartbeat check instructions to a plurality of services via the registry to monitor the load of each of the services, comprising:
the management background sends a heartbeat check instruction to the engine agent through the registry;
and the engine agent sends the heartbeat check instruction to a plurality of services respectively, and returns the received load response information returned by the services to the management background through the registration center.
10. A computing device comprising a memory, a processor, and computer instructions stored on the memory and executable on the processor, wherein the processor, when executing the instructions, implements the steps of the method of any of claims 1-7.
11. A computer readable storage medium storing computer instructions which, when executed by a processor, implement the steps of the method of any one of claims 1 to 7.
CN201910797805.6A 2019-08-27 2019-08-27 Translation platform and load adjustment method thereof Active CN110502761B (en)

Priority Applications (1)

Application Number Priority Date Filing Date Title
CN201910797805.6A CN110502761B (en) 2019-08-27 2019-08-27 Translation platform and load adjustment method thereof

Applications Claiming Priority (1)

Application Number Priority Date Filing Date Title
CN201910797805.6A CN110502761B (en) 2019-08-27 2019-08-27 Translation platform and load adjustment method thereof

Publications (2)

Publication Number Publication Date
CN110502761A CN110502761A (en) 2019-11-26
CN110502761B true CN110502761B (en) 2023-09-19

Family

ID=68590028

Family Applications (1)

Application Number Title Priority Date Filing Date
CN201910797805.6A Active CN110502761B (en) 2019-08-27 2019-08-27 Translation platform and load adjustment method thereof

Country Status (1)

Country Link
CN (1) CN110502761B (en)

Families Citing this family (1)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN112818710A (en) * 2021-02-05 2021-05-18 中译语通科技股份有限公司 Method and device for processing asynchronous network machine translation request

Citations (12)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN102394807A (en) * 2011-08-23 2012-03-28 北京京北方信息技术有限公司 System and method for decentralized scheduling of autonomous flow engine load balancing clusters
CN102722795A (en) * 2012-06-06 2012-10-10 复旦大学 Service management method of business operation support system based on service-oriented architecture (SOA)
CN103051564A (en) * 2013-01-07 2013-04-17 杭州华三通信技术有限公司 Dynamic resource allocation method and device
CN103559093A (en) * 2013-11-15 2014-02-05 北京中指实证数据信息技术有限公司 Resource allocation method and device for servers
CN103944940A (en) * 2013-01-21 2014-07-23 华耀(中国)科技有限公司 Equipment and method for dynamically configuring proxy server
CN106331065A (en) * 2016-08-15 2017-01-11 众安在线财产保险股份有限公司 Proxy application for host system with service container and system
CN106408272A (en) * 2016-10-26 2017-02-15 金航数码科技有限责任公司 Distributed deployment based cross-system process engine collaboration system and method
CN106453125A (en) * 2016-11-04 2017-02-22 中国电子科技集团公司第二十八研究所 Load balancing system for remote service calling based on real-time load rate
CN106603594A (en) * 2015-10-15 2017-04-26 中国电信股份有限公司 Distributed service management method and system
WO2018095138A1 (en) * 2016-11-25 2018-05-31 华为技术有限公司 Container deployment method, communication method between services and related devices
CN108712464A (en) * 2018-04-13 2018-10-26 中国科学院信息工程研究所 A kind of implementation method towards cluster micro services High Availabitity
CN109246246A (en) * 2018-10-31 2019-01-18 成都知道创宇信息技术有限公司 A kind of full-automatic service discovery SiteServer LBS of centralization

Patent Citations (12)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN102394807A (en) * 2011-08-23 2012-03-28 北京京北方信息技术有限公司 System and method for decentralized scheduling of autonomous flow engine load balancing clusters
CN102722795A (en) * 2012-06-06 2012-10-10 复旦大学 Service management method of business operation support system based on service-oriented architecture (SOA)
CN103051564A (en) * 2013-01-07 2013-04-17 杭州华三通信技术有限公司 Dynamic resource allocation method and device
CN103944940A (en) * 2013-01-21 2014-07-23 华耀(中国)科技有限公司 Equipment and method for dynamically configuring proxy server
CN103559093A (en) * 2013-11-15 2014-02-05 北京中指实证数据信息技术有限公司 Resource allocation method and device for servers
CN106603594A (en) * 2015-10-15 2017-04-26 中国电信股份有限公司 Distributed service management method and system
CN106331065A (en) * 2016-08-15 2017-01-11 众安在线财产保险股份有限公司 Proxy application for host system with service container and system
CN106408272A (en) * 2016-10-26 2017-02-15 金航数码科技有限责任公司 Distributed deployment based cross-system process engine collaboration system and method
CN106453125A (en) * 2016-11-04 2017-02-22 中国电子科技集团公司第二十八研究所 Load balancing system for remote service calling based on real-time load rate
WO2018095138A1 (en) * 2016-11-25 2018-05-31 华为技术有限公司 Container deployment method, communication method between services and related devices
CN108712464A (en) * 2018-04-13 2018-10-26 中国科学院信息工程研究所 A kind of implementation method towards cluster micro services High Availabitity
CN109246246A (en) * 2018-10-31 2019-01-18 成都知道创宇信息技术有限公司 A kind of full-automatic service discovery SiteServer LBS of centralization

Also Published As

Publication number Publication date
CN110502761A (en) 2019-11-26

Similar Documents

Publication Publication Date Title
US10904361B2 (en) Method, apparatus, and system for implementing JAVA application installation by means of cloud compilation
US20210216700A1 (en) Information Processing Method and System
CN113312037A (en) Data processing method, device and equipment applied to microservice and storage medium
US20210342547A1 (en) System for focused conversation context management in a reasoning agent/behavior engine of an agent automation system
US20110035396A1 (en) Runtime-defined dynamic queries
CN111324343B (en) Code generation method and device
CN104516885A (en) Implementation method and device of browse program double-kernel assembly
US20230141398A1 (en) Data augmentation for intent classification
CN112115511A (en) Authority verification method, device and system, and service authority configuration method and device
CN114356971A (en) Data processing method, device and system
CN116301951B (en) Micro-service application installation upgrading method and device based on kubernetes
CN110502761B (en) Translation platform and load adjustment method thereof
CN112243016B (en) Middleware platform, terminal equipment, 5G artificial intelligence cloud processing system and processing method
US20140208309A1 (en) Method, apparatus, and communication system for implementing internet application
CN110888672A (en) Metadata architecture-based expression engine implementation method and system
CN112084795A (en) Translation system and translation service calling method and device
CN105989010B (en) Web page data generation method, Web server and Web application system
CN110502762B (en) Translation platform and management method thereof
CN116578423A (en) Task processing method, automatic question answering method and image generation method
CN110599112B (en) Network page development and maintenance method and device
CN111414154A (en) Method and device for front-end development, electronic equipment and storage medium
CN115291933A (en) Method, device and equipment for constructing small program data packet and storage medium
US20230247111A1 (en) Runtime module conversion
CN108694046A (en) Container assembly method and device
CN114095758B (en) Cloud image intercepting method and related device

Legal Events

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