CN110895474A - Terminal micro-service device and method and electronic equipment - Google Patents

Terminal micro-service device and method and electronic equipment Download PDF

Info

Publication number
CN110895474A
CN110895474A CN201810974622.2A CN201810974622A CN110895474A CN 110895474 A CN110895474 A CN 110895474A CN 201810974622 A CN201810974622 A CN 201810974622A CN 110895474 A CN110895474 A CN 110895474A
Authority
CN
China
Prior art keywords
sending
data
configuration information
module
functional component
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.)
Pending
Application number
CN201810974622.2A
Other languages
Chinese (zh)
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.)
Shenzhen Honghe Innovation Information Technology Co Ltd
Original Assignee
Shenzhen Honghe Innovation Information Technology 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 Shenzhen Honghe Innovation Information Technology Co Ltd filed Critical Shenzhen Honghe Innovation Information Technology Co Ltd
Priority to CN201810974622.2A priority Critical patent/CN110895474A/en
Publication of CN110895474A publication Critical patent/CN110895474A/en
Pending legal-status Critical Current

Links

Images

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/44Arrangements for executing specific programs
    • G06F9/445Program loading or initiating
    • G06F9/44521Dynamic linking or loading; Link editing at or after load time, e.g. Java class loading

Landscapes

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

Abstract

The invention discloses a terminal micro-service device and method and electronic equipment, wherein the terminal micro-service device comprises: the configuration module is used for respectively configuring configuration information of data sending requests of all the functional components, and the configuration information comprises sending frequency and sending time; the message sending module is used for sending a data request according to the configuration information of each functional component; the message receiving module is used for receiving response data; the cache module is used for caching the response data; and the component management module is used for maintaining each functional component, and each functional component loads the response data from the cache module. The invention sends the data request to the server at regular time through the terminal microservice and caches the returned response data, thereby ensuring the function of loading data of each functional component and effectively relieving the data interaction pressure of the server.

Description

Terminal micro-service device and method and electronic equipment
Technical Field
The present invention relates to the field of micro-service architecture technologies, and in particular, to a terminal micro-service apparatus and method, and an electronic device.
Background
As shown in fig. 1, an existing digital electronic whiteboard has a plurality of functional components, such as a courseware component, a class information component, an examination hall component, an attendance component, and the like, and each component needs to send a request to a server to obtain corresponding data during a loading process. Therefore, when a plurality of components of a plurality of digital electronic whiteboards load data at the same time, data requests need to be sent to the server at the same time, and great pressure is applied to the server.
Disclosure of Invention
In view of the above, the present invention provides a terminal microservice apparatus and method, and an electronic device, which can effectively relieve server pressure by sending a data request to a server at regular time and caching returned response data through the terminal microservice.
Based on the above purpose, the present invention provides a terminal micro-service device, including:
the configuration module is used for respectively configuring configuration information of data sending requests of all the functional components, and the configuration information comprises sending frequency and sending time;
the message sending module is used for sending a data request according to the configuration information of each functional component;
the message receiving module is used for receiving response data;
the cache module is used for caching the response data;
and the component management module is used for maintaining each functional component, and each functional component loads the response data from the cache module.
Optionally, the terminal microserver further includes:
the component management module comprises a component list consisting of the functional components;
and the input module is used for respectively configuring the configuration information of each functional component according to the component list.
The embodiment of the invention also provides a terminal micro-service method, which comprises the following steps:
respectively configuring configuration information of data sending requests of all functional components, wherein the configuration information comprises sending frequency and sending time;
sending a data request according to the configuration information of each functional component;
receiving response data;
caching the response data;
and each functional component loads the cached response data.
Optionally, the configuration information is configured by inputting, or is preset.
The embodiment of the invention also provides electronic equipment which comprises a memory, a processor and a computer program which is stored on the memory and can run on the processor, wherein the processor realizes the terminal micro-service method when executing the program.
It can be seen from the above that, according to the terminal microservice apparatus and method and the electronic device provided by the present invention, each functional component of the terminal is independent into microservice, the time for each functional component to send a data request to the server can be flexibly configured, and the response data returned by the server can be cached, so that the components can be loaded and used within a certain time. The invention sends the data request to the server at regular time through each functional component, thereby not only ensuring the data loading function of each functional component, but also greatly reducing the data interaction pressure of the server and improving the data utilization efficiency.
Drawings
In order to more clearly illustrate the embodiments of the present invention or the technical solutions in the prior art, the drawings used in the description of the embodiments or the prior art will be briefly described below, it is obvious that the drawings in the following description are only some embodiments of the present invention, and for those skilled in the art, other drawings can be obtained according to the drawings without creative efforts.
FIG. 1 is a diagram illustrating a terminal and a server in the prior art;
fig. 2 is a schematic diagram of a terminal and a server according to an embodiment of the present invention;
FIG. 3 is a schematic structural diagram of a terminal microserver according to an embodiment of the present invention;
fig. 4 is a flowchart illustrating a terminal microservice method according to an embodiment of the present invention.
Detailed Description
In order to make the objects, technical solutions and advantages of the present invention more apparent, the present invention is described in further detail below with reference to specific embodiments and the accompanying drawings.
It should be noted that all expressions using "first" and "second" in the embodiments of the present invention are used for distinguishing two entities with the same name but different names or different parameters, and it should be noted that "first" and "second" are merely for convenience of description and should not be construed as limitations of the embodiments of the present invention, and they are not described in any more detail in the following embodiments.
Fig. 2 is a schematic structural diagram of a terminal and a server according to an embodiment of the present invention, and fig. 3 is a schematic structural diagram of a terminal microserver according to an embodiment of the present invention. As shown in the figure, the terminal microserver device provided in the embodiment of the present invention includes:
the configuration module is used for respectively configuring configuration information of data requests sent by all the functional components to the server, and the configuration information comprises sending frequency, sending time and the like;
the message sending module is used for sending a data request to the server according to the configuration information of each functional component;
the message receiving module is used for receiving response data returned by the server;
the cache module is used for caching the response data returned by the server;
and the component management module is used for maintaining each functional component, and each functional component loads data from the cache module.
In the embodiment of the invention, the terminal micro-service device is realized based on a micro-service architecture, each original functional component of the terminal is independent into a micro-service, the configuration information of each functional component can be flexibly configured through a configuration module, namely the time (time and frequency) of sending a data request to a server by each functional component is flexibly configured, and response data returned by the server can be cached so as to be loaded and used by the components within a certain time. Therefore, when each functional component is loaded, the data request is actively sent to the server, and the data request is changed into the data request sent to the server by each functional component at regular time, so that the data loading function of each functional component can be ensured, and the data interaction pressure of the server can be greatly reduced.
For example, it is set that the class information component sends a data request to the server every 10 minutes, and stores the response data returned by the server each time in the cache module, and the class information component loads the data directly from the cache module within 10 minutes from the sending of the data request this time to the sending of the data request next time, without sending the data request to the server every time the data request is loaded.
In the embodiment of the present invention, the terminal microserver device further includes:
the component management module comprises a component list consisting of all functional components;
and the input module is used for respectively configuring the configuration information of each functional component according to the component list.
In the embodiment of the invention, the configuration information of each functional component can be configured by inputting, can be respectively preset according to the specific use condition of each functional component, can also be set according to a specific algorithm, is flexible to configure, and can reasonably utilize server resources.
Fig. 4 is a flowchart illustrating a terminal microservice method according to an embodiment of the present invention. As shown in the figure, the terminal microservice method of the embodiment of the present invention includes:
s10: respectively configuring configuration information of each functional component for sending a data request to a server;
the configuration information comprises sending frequency, sending time and the like, and can be configured through input or preset according to the specific use condition of each functional component.
S11: sending a data request to a server according to the configuration information of each functional component;
s12: receiving response data returned by the server;
s13: caching response data returned by the server;
s14: each functional component loads the cached response data.
Based on the above purpose, the embodiment of the present invention further provides an embodiment of an apparatus for a terminal microservice method. The device comprises:
one or more processors, and a memory.
The execution process state obtaining module may further include: an input device and an output device.
The processor, memory, input device, and output device may be connected by a bus or other means.
The memory, which is a non-volatile computer-readable storage medium, may be used to store non-volatile software programs, non-volatile computer-executable programs, and modules, such as program instructions/modules (e.g., the configuration module, the message sending module, the message receiving module, and the component management module shown in fig. 3) corresponding to the terminal microservice method in the embodiment of the present invention. The processor executes various functional applications and data processing of the server by running the nonvolatile software programs, instructions and modules stored in the memory, that is, the terminal microservice method of the above-described method embodiment is realized.
The memory may include a storage program area and a storage data area, wherein the storage program area may store an operating system, an application program required for at least one function; the storage data area may store data created according to use of an apparatus performing the terminal micro service method, and the like. Further, the memory may include high speed random access memory, and may also include non-volatile memory, such as at least one magnetic disk storage device, flash memory device, or other non-volatile solid state storage device. In some embodiments, the memory optionally includes memory remotely located from the processor, and these remote memories may be connected to the member user behavior monitoring device via a network. Examples of such networks include, but are not limited to, the internet, intranets, local area networks, mobile communication networks, and combinations thereof.
The input device may receive input numeric or character information and generate key signal inputs related to user settings and function control of the device performing the terminal microservice method. The output device may include a display device such as a display screen.
The one or more modules are stored in the memory and, when executed by the one or more processors, perform the terminal microservice method of any of the above method embodiments. The technical effect of the embodiment of the device for executing the terminal micro-service method is the same as or similar to that of any method embodiment.
The embodiment of the invention also provides a non-transitory computer storage medium, wherein the computer storage medium stores computer executable instructions, and the computer executable instructions can execute the processing method of the list item operation in any method embodiment. Embodiments of the non-transitory computer storage medium may be the same or similar in technical effect to any of the method embodiments described above.
Finally, it should be noted that, as will be understood by those skilled in the art, all or part of the processes in the methods of the above embodiments may be implemented by a computer program that can be stored in a computer-readable storage medium and that, when executed, can include the processes of the embodiments of the methods described above. The storage medium may be a magnetic disk, an optical disk, a Read-Only Memory (ROM), a Random Access Memory (RAM), or the like. The technical effect of the embodiment of the computer program is the same as or similar to that of any of the method embodiments described above.
Furthermore, the apparatuses, devices, etc. described in the present disclosure may be various electronic terminal devices, such as a mobile phone, a Personal Digital Assistant (PDA), a tablet computer (PAD), a smart television, etc., and may also be large terminal devices, such as a server, etc., and therefore the scope of protection of the present disclosure should not be limited to a specific type of apparatus, device. The client disclosed by the present disclosure may be applied to any one of the above electronic terminal devices in the form of electronic hardware, computer software, or a combination of both.
Furthermore, the method according to the present disclosure may also be implemented as a computer program executed by a CPU, which may be stored in a computer-readable storage medium. The computer program, when executed by the CPU, performs the above-described functions defined in the method of the present disclosure.
Further, it should be appreciated that the computer-readable storage media (e.g., memory) described herein can be either volatile memory or nonvolatile memory, or can include both volatile and nonvolatile memory. By way of example, and not limitation, nonvolatile memory can include Read Only Memory (ROM), Programmable ROM (PROM), Electrically Programmable ROM (EPROM), Electrically Erasable Programmable ROM (EEPROM), or flash memory. Volatile memory can include Random Access Memory (RAM), which can act as external cache memory. By way of example and not limitation, RAM is available in a variety of forms such as synchronous RAM (DRAM), Dynamic RAM (DRAM), Synchronous DRAM (SDRAM), double data rate SDRAM (DDR SDRAM), Enhanced SDRAM (ESDRAM), Synchronous Link DRAM (SLDRAM), and Direct Rambus RAM (DRRAM). The storage devices of the disclosed aspects are intended to comprise, without being limited to, these and other suitable types of memory.
The apparatus of the foregoing embodiment is used to implement the corresponding method in the foregoing embodiment, and has the beneficial effects of the corresponding method embodiment, which are not described herein again.
Those of ordinary skill in the art will understand that: the discussion of any embodiment above is meant to be exemplary only, and is not intended to intimate that the scope of the disclosure, including the claims, is limited to these examples; within the idea of the invention, also features in the above embodiments or in different embodiments may be combined, steps may be implemented in any order, and there are many other variations of the different aspects of the invention as described above, which are not provided in detail for the sake of brevity.
In addition, well known power/ground connections to Integrated Circuit (IC) chips and other components may or may not be shown within the provided figures for simplicity of illustration and discussion, and so as not to obscure the invention. Furthermore, devices may be shown in block diagram form in order to avoid obscuring the invention, and also in view of the fact that specifics with respect to implementation of such block diagram devices are highly dependent upon the platform within which the present invention is to be implemented (i.e., specifics should be well within purview of one skilled in the art). Where specific details (e.g., circuits) are set forth in order to describe example embodiments of the invention, it should be apparent to one skilled in the art that the invention can be practiced without, or with variation of, these specific details. Accordingly, the description is to be regarded as illustrative instead of restrictive.
While the present invention has been described in conjunction with specific embodiments thereof, many alternatives, modifications, and variations of these embodiments will be apparent to those of ordinary skill in the art in light of the foregoing description. For example, other memory architectures (e.g., dynamic ram (dram)) may use the discussed embodiments.
The embodiments of the invention are intended to embrace all such alternatives, modifications and variances that fall within the broad scope of the appended claims. Therefore, any omissions, modifications, substitutions, improvements and the like that may be made without departing from the spirit and principles of the invention are intended to be included within the scope of the invention.

Claims (5)

1. A terminal micro-service device, comprising:
the configuration module is used for respectively configuring configuration information of data sending requests of all the functional components, and the configuration information comprises sending frequency and sending time;
the message sending module is used for sending a data request according to the configuration information of each functional component;
the message receiving module is used for receiving response data;
the cache module is used for caching the response data;
and the component management module is used for maintaining each functional component, and each functional component loads the response data from the cache module.
2. The terminal microservice apparatus of claim 1, further comprising:
the component management module comprises a component list consisting of the functional components;
and the input module is used for respectively configuring the configuration information of each functional component according to the component list.
3. A terminal micro-service method is characterized by comprising the following steps:
respectively configuring configuration information of data sending requests of all functional components, wherein the configuration information comprises sending frequency and sending time;
sending a data request according to the configuration information of each functional component;
receiving response data;
caching the response data;
and each functional component loads the cached response data.
4. The terminal microservice method of claim 3, wherein the configuration information is configured by input or is preset.
5. An electronic device comprising a memory, a processor and a computer program stored on the memory and executable on the processor, characterized in that the processor implements the method according to any of claims 3 to 4 when executing the program.
CN201810974622.2A 2018-08-24 2018-08-24 Terminal micro-service device and method and electronic equipment Pending CN110895474A (en)

Priority Applications (1)

Application Number Priority Date Filing Date Title
CN201810974622.2A CN110895474A (en) 2018-08-24 2018-08-24 Terminal micro-service device and method and electronic equipment

Applications Claiming Priority (1)

Application Number Priority Date Filing Date Title
CN201810974622.2A CN110895474A (en) 2018-08-24 2018-08-24 Terminal micro-service device and method and electronic equipment

Publications (1)

Publication Number Publication Date
CN110895474A true CN110895474A (en) 2020-03-20

Family

ID=69784912

Family Applications (1)

Application Number Title Priority Date Filing Date
CN201810974622.2A Pending CN110895474A (en) 2018-08-24 2018-08-24 Terminal micro-service device and method and electronic equipment

Country Status (1)

Country Link
CN (1) CN110895474A (en)

Citations (8)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN1776664A (en) * 2003-08-13 2006-05-24 索尼株式会社 System, method, equipment and program for distributing network communication data
JP2010122956A (en) * 2008-11-20 2010-06-03 Nippon Telegr & Teleph Corp <Ntt> Service component management system, operation control server, profile server, and service component management method
CN101753461A (en) * 2010-01-14 2010-06-23 中国建设银行股份有限公司 Method for realizing load balance, load balanced server and group system
CN104184765A (en) * 2013-05-23 2014-12-03 阿里巴巴集团控股有限公司 Request control method, client apparatus and server-side apparatus
CN106021445A (en) * 2016-05-16 2016-10-12 努比亚技术有限公司 Cached data loading method and apparatus
CN106254529A (en) * 2016-09-20 2016-12-21 郑州云海信息技术有限公司 A kind of client-side data cache method and apparatus
CN107623729A (en) * 2017-09-08 2018-01-23 华为技术有限公司 A kind of caching method, equipment and cache service system
US20180075231A1 (en) * 2016-09-14 2018-03-15 Oracle International Corporation Single sign-on functionality for a multi-tenant identity and data security management cloud service

Patent Citations (8)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN1776664A (en) * 2003-08-13 2006-05-24 索尼株式会社 System, method, equipment and program for distributing network communication data
JP2010122956A (en) * 2008-11-20 2010-06-03 Nippon Telegr & Teleph Corp <Ntt> Service component management system, operation control server, profile server, and service component management method
CN101753461A (en) * 2010-01-14 2010-06-23 中国建设银行股份有限公司 Method for realizing load balance, load balanced server and group system
CN104184765A (en) * 2013-05-23 2014-12-03 阿里巴巴集团控股有限公司 Request control method, client apparatus and server-side apparatus
CN106021445A (en) * 2016-05-16 2016-10-12 努比亚技术有限公司 Cached data loading method and apparatus
US20180075231A1 (en) * 2016-09-14 2018-03-15 Oracle International Corporation Single sign-on functionality for a multi-tenant identity and data security management cloud service
CN106254529A (en) * 2016-09-20 2016-12-21 郑州云海信息技术有限公司 A kind of client-side data cache method and apparatus
CN107623729A (en) * 2017-09-08 2018-01-23 华为技术有限公司 A kind of caching method, equipment and cache service system

Similar Documents

Publication Publication Date Title
CN104965848B (en) A kind of front end resource loading method and device
CN110830280B (en) Micro-service gateway device and method and electronic equipment
CN109391673B (en) Method, system and terminal equipment for managing update file
CN110838071B (en) Policy data processing method, device and server
CN111385137A (en) Terminal awakening method, server and electronic equipment
CN112153465B (en) Image loading method and device
US20140324368A1 (en) Test method, test system and electronic device employing the same
CN110781139A (en) Teaching plan resource management system and method and electronic equipment
CN110895474A (en) Terminal micro-service device and method and electronic equipment
CN111352993A (en) Cross-platform data synchronization method and device and electronic equipment
CN110806910A (en) Method and system for optimizing carousel map and electronic equipment
CN111190529B (en) Keyboard input method and device and electronic equipment
CN112149392A (en) Rich text editing method and device
CN107547437B (en) Application identification method and device
CN111200621A (en) Ad hoc network method and device, and electronic device
CN110765738A (en) System and method for generating card number and electronic equipment
CN114124883B (en) Data access method and device based on cloud storage address, computer equipment and medium
CN110912959B (en) Equipment access method and device, management and control system and electronic equipment
CN112839071B (en) Training system, training data access method and device, electronic equipment and medium
CN111212016B (en) Cross-site request processing method and device and electronic equipment
CN111062189B (en) Data analysis method and device and electronic equipment
CN111327645A (en) Network sharing method and device and electronic equipment
CN114679302B (en) Method, device, equipment and storage medium for docking single sign-on system
CN111090432A (en) Interface processing method and device and electronic equipment
CN111158569A (en) Erasing operation method and device and electronic equipment

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
RJ01 Rejection of invention patent application after publication

Application publication date: 20200320

RJ01 Rejection of invention patent application after publication