CN117632545A - Data sharing method and device of business system and electronic equipment - Google Patents

Data sharing method and device of business system and electronic equipment Download PDF

Info

Publication number
CN117632545A
CN117632545A CN202311669304.2A CN202311669304A CN117632545A CN 117632545 A CN117632545 A CN 117632545A CN 202311669304 A CN202311669304 A CN 202311669304A CN 117632545 A CN117632545 A CN 117632545A
Authority
CN
China
Prior art keywords
application
data information
target sub
global data
vuex
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
CN202311669304.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.)
Zhongdian Jinxin Digital Technology Group Co ltd
Original Assignee
Zhongdian Jinxin Digital Technology Group 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 Zhongdian Jinxin Digital Technology Group Co ltd filed Critical Zhongdian Jinxin Digital Technology Group Co ltd
Priority to CN202311669304.2A priority Critical patent/CN117632545A/en
Publication of CN117632545A publication Critical patent/CN117632545A/en
Pending legal-status Critical Current

Links

Classifications

    • YGENERAL TAGGING OF NEW TECHNOLOGICAL DEVELOPMENTS; GENERAL TAGGING OF CROSS-SECTIONAL TECHNOLOGIES SPANNING OVER SEVERAL SECTIONS OF THE IPC; TECHNICAL SUBJECTS COVERED BY FORMER USPC CROSS-REFERENCE ART COLLECTIONS [XRACs] AND DIGESTS
    • Y02TECHNOLOGIES OR APPLICATIONS FOR MITIGATION OR ADAPTATION AGAINST CLIMATE CHANGE
    • Y02DCLIMATE CHANGE MITIGATION TECHNOLOGIES IN INFORMATION AND COMMUNICATION TECHNOLOGIES [ICT], I.E. INFORMATION AND COMMUNICATION TECHNOLOGIES AIMING AT THE REDUCTION OF THEIR OWN ENERGY USE
    • Y02D10/00Energy efficient computing, e.g. low power processors, power management or thermal management

Landscapes

  • Information Retrieval, Db Structures And Fs Structures Therefor (AREA)

Abstract

The application provides a data sharing method and device of a service system and electronic equipment. Wherein the business system is a micro front end framework based system, the method comprises: after a father application of a business system is in a login state, acquiring global data information of the system; based on the Vue framework, the system global data information is transferred to a target sub-application of the service system, so that the sharing of the system global data information is realized. According to the scheme, the cache of the system global data information is realized through the Vue framework, meanwhile, the complexity of communication before application is reduced by transmitting the system global data information to the target sub-application, and the sharing of the system global data information in the parent-child application is realized.

Description

Data sharing method and device of business system and electronic equipment
Technical Field
The present invention relates to the field of computer technologies, and in particular, to a data sharing method and apparatus for a service system, and an electronic device.
Background
With the continuous development of front-end technology, front-end applications of business systems are becoming more and more complex and bulky. While conventional monolithic applications often have difficulty in addressing such complexity and scale challenges, micro front-end architecture improves maintainability and scalability of front-end applications by splitting the front-end application into separate tiles so that each tile can be independently developed, deployed, and expanded.
Communication is needed between all applications in the micro front-end architecture to realize data sharing, but the communication complexity between all applications is high, and a specific data caching scheme is not available in the micro front-end architecture, so that the problem of difficult synchronization between data is caused.
Disclosure of Invention
In order to solve the above problems, the present application provides a method, an apparatus, and an electronic device for sharing data of a service system.
According to a first aspect of the present application, a data sharing method of a service system is provided, where the service system is a system based on a micro front end architecture. The method comprises the following steps:
acquiring system global data information after a father application of the service system is in a login state;
based on the Vue framework, the system global data information is transmitted to a target sub-application of the service system, so that the sharing of the system global data information is realized.
In some embodiments of the present application, based on the Vue framework, delivering the system global data information to a target sub-application of the business system includes:
and transmitting the system global data information to the target sub-application based on the Vuex state management library under the Vue framework.
As one example, the system global data information includes at least one of: temporary credentials of the user, user information, and dictionary information.
In some embodiments of the present application, the transferring the system global data information to the target sub-application based on the Vuex state management library under the Vue framework includes:
storing the system global data information in a Vuex store of the parent application;
determining a target sub-application matched with the current route based on a preset matching rule;
and transmitting the Vuex store to the target sub-application through tips.
As a possible implementation manner, the delivering the Vuex store to the target sub-application through tips includes:
judging whether the target sub-application is loaded successfully or not;
and if the target sub-application is loaded successfully, transmitting the Vuex store to the target sub-application through tips.
As an example, the delivering the Vuex store to the target sub-application via tips includes:
transmitting the Vuex store and the state update execution object to the target sub-application through tips; the state update execution object comprises a monitoring operation for notifying the child application in the business system of the message data of the parent application and an operation required to be executed when the message data changes.
In some embodiments of the present application, said delivering said Vuex store to said target sub-application via tips comprises:
determining target data information from the Vuex store based on the verification message sent by the target sub-application;
and transmitting the target data information to the target sub-application through tips.
According to a second aspect of the present application, there is provided a data sharing device of a service system, the service system being a system based on a micro front end architecture, the device comprising:
the acquisition module is used for acquiring system global data information after the father application of the service system is in a login state;
and the transmission module is used for transmitting the system global data information to a target sub-application of the service system based on the Vue framework so as to realize sharing of the system global data information.
As one example, the system global data information includes at least one of: temporary credentials of the user, user information, and dictionary information.
In some embodiments of the present application, the transfer module is specifically configured to:
and transmitting the system global data information to the target sub-application based on the Vuex state management library under the Vue framework.
In some embodiments of the present application, the transfer module includes:
a storage unit, configured to store the system global data information in a Vuex store of the parent application;
the matching unit is used for determining a target sub-application matched with the current route based on a preset matching rule;
and the transmission unit is used for transmitting the Vuex store to the target sub-application through tips.
As a possible implementation, the transfer unit is specifically configured to:
judging whether the target sub-application is loaded successfully or not;
and if the target sub-application is loaded successfully, transmitting the Vuex store to the target sub-application through tips.
As an example, the transfer unit is further configured to:
transmitting the Vuex store and the state update execution object to the target sub-application through tips; the state update execution object comprises a monitoring operation for notifying the child application in the business system of the message data of the parent application and an operation required to be executed when the message data changes.
In some embodiments of the present application, the transfer unit is further configured to:
determining target data information from the Vuex store based on the verification message sent by the target sub-application;
and transmitting the target data information to the target sub-application through tips.
According to a third aspect of the present application, there is provided an electronic device comprising: a processor, a memory communicatively coupled to the processor; the memory stores computer-executable instructions; the processor executes computer-executable instructions stored in the memory to implement the method of the first aspect described above.
According to a fourth aspect of the present application, there is provided a computer readable storage medium having stored therein computer executable instructions for carrying out the method of the first aspect described above when executed by a processor.
According to the technical scheme, after a father application in a business system based on a micro front end architecture is in a login state, system global data information is acquired, and based on a Vue framework, the system global data information is transferred to a target sub-application of the business system, so that sharing of the system global data information is realized. According to the scheme, the cache of the system global data information is realized through the Vue framework, meanwhile, the complexity of communication before application is reduced by transmitting the system global data information to the target sub-application, and the sharing of the system global data information in the parent-child application is realized.
Additional aspects and advantages of the application will be set forth in part in the description which follows and, in part, will be obvious from the description, or may be learned by practice of the application.
Drawings
The foregoing and/or additional aspects and advantages of the present application will become apparent and readily appreciated from the following description of the embodiments, taken in conjunction with the accompanying drawings, in which:
fig. 1 is a flowchart of a data sharing method of a service system according to an embodiment of the present application;
fig. 2 is a flowchart of another data sharing method of a service system according to an embodiment of the present application;
fig. 3 is a flowchart of a data sharing method of another service system according to an embodiment of the present application;
fig. 4 is a block diagram of a data sharing device of a service system according to an embodiment of the present application;
fig. 5 is a block diagram of an electronic device according to an embodiment of the present application.
Detailed Description
Embodiments of the present application are described in detail below, examples of which are illustrated in the accompanying drawings, wherein the same or similar reference numerals refer to the same or similar elements or elements having the same or similar functions throughout. The embodiments described below by referring to the drawings are exemplary and intended for the purpose of explaining the present application and are not to be construed as limiting the present application.
It should be noted that, with the continuous development of front-end technology, front-end applications of service systems become more and more complex and huge. While conventional monolithic applications often have difficulty in addressing such complexity and scale challenges, micro front-end architecture improves maintainability and scalability of front-end applications by splitting the front-end application into separate tiles so that each tile can be independently developed, deployed, and expanded.
Communication is needed between applications in the micro front-end architecture to realize data sharing, but the communication complexity between applications is high, and no specific data caching scheme exists in the micro front-end architecture.
In order to solve the above problems, the present application provides a method, an apparatus, and an electronic device for sharing data of a service system.
Fig. 1 is a flowchart of a data sharing method of a service system according to an embodiment of the present application. It should be noted that, the data sharing method of the service system in the embodiment of the present application may be applied to the data sharing device of the service system in the embodiment of the present application, and the device may be configured in an electronic device. The service system in the embodiment of the application is a system based on a micro front end architecture.
The micro front-end is an architecture similar to a micro service, and applies the micro service concept to the browser end, namely, a single-page front-end application is converted from a single application to an application which aggregates a plurality of small front-end applications into one. Each front-end application can also be independently developed and independently deployed. The micro front end architecture aims to solve the problem that the single application cannot be maintained after being changed from a common application to a boulder application due to the increase and transition of participating personnel and teams in a relatively long time span. The realization of the micro front end means the splitting of the front end application, so that the development efficiency can be improved, and the independent development and independent deployment of the application can be realized. The current micro front end architecture scheme includes: single-spa, qiankun, micro-app, etc. The service system in the embodiment of the present application may be a system based on any of the foregoing micro front end architectures. As shown in fig. 1, the method may include the steps of:
step 101, after the father application of the service system is in a login state, acquiring the global data information of the system.
In some embodiments of the present application, the business system may be a bank counter system, or may be a system of other business scenarios, which is not limited herein. The service system can be a system which is changed from a single-page front-end application system to a system which aggregates a plurality of small-sized front-end applications into one based on a micro front-end architecture. When the user accesses the service system, the father application is loaded to enter the login authentication page, authentication login is carried out through the modes of passwords, fingerprints, face recognition and the like, and after the father application of the service system is in a login state, the global data information of the system can be obtained through the corresponding interface.
The global data information of the system includes data that can be used by both the parent application and the child application, for example, login information, geographic location information, user information, and the like. As one example, the system global data information may include at least one of: temporary credentials of the user, user information, and dictionary information. The temporary credentials of the user refer to a global token generated when the user logs in. The user information may include basic information of the user's name, gender, age, engaged industry, etc., and may also include user information related to the business, such as user credit, number of user transactions, etc. Dictionary information refers to static data of some front-end pages in parent applications and child applications in a business system, such as option content of a drop-down option in a page, for example: the content of gender options, nationality options, currency options, etc.
Step 102, based on the Vue framework, the system global data information is transferred to a target sub-application of the service system, so as to realize sharing of the system global data information.
It should be noted that, the Vue framework is a set of progressive frameworks for constructing a user interface, and a state management library, a component library, a data acquisition library and the like can be corresponding under the framework.
In some embodiments of the present application, the system global data information may be transferred to the target sub-application of the service system based on the state management library under the Vue framework, so as to implement sharing of the system global data information. The state management library under the Vue framework comprises a Vuex state management library, a Pinia state management library and the like. For example, the system global data information can be cached based on the Vuex state management library, and the cached system global data information is transferred to a target sub-application of the service system.
The complexity of communication between parent and child applications is high because there is no specific data caching scheme in the micro-front-end architecture. In the embodiment of the application, the system global data information is cached based on the Vue framework and is transferred to the target sub-application, so that the sharing of the system global data information is realized.
The target sub-application refers to a target sub-application corresponding to a triggering operation of a user. For example, if the parent application interface includes icons of the respective child applications, the user clicks an icon of a child application through the terminal interface, and the child application clicked by the user is the target child application. As an example, the target sub-application may be determined by way of route matching.
As one possible implementation, the process of delivering the system global data information to the target sub-application of the business system based on the Vue framework may include: and storing the system global data information in a parent application based on a vuex state management library under the Vue framework, and then communicating the parent application and the child application through tips to transfer the system global data information to a target child application.
In some embodiments of the present application, since the automatic loading scheme may cause a problem of cache loss when the parent-child application is switched, in order to avoid the above problem, the target-child application may be loaded by adopting a manual loading manner. Taking a business system as a qiankun micro front end architecture as an example, when a route is matched with a target sub-application, information of the target sub-application can be searched, the sub-application can be loaded and displayed under a designated node by manually loading the loadmicro app, and when no registered micro-application exists in a tab, the corresponding micro-application is deleted, so that memory overflow is prevented.
According to the data sharing method of the service system, after the father application in the service system based on the micro front end architecture is in a login state, system global data information is obtained, and based on the Vue framework, the system global data information is transferred to the target sub-application of the service system, so that sharing of the system global data information is achieved. According to the scheme, the cache of the system global data information is realized through the Vue framework, meanwhile, the complexity of communication before application is reduced by transmitting the system global data information to the target sub-application, and the sharing of the system global data information in the parent-child application is realized.
Fig. 2 is a flowchart of another data sharing method of a service system according to an embodiment of the present application. As shown in fig. 2, the method comprises the steps of:
step 201, after the father application of the service system is in the login state, the global data information of the system is obtained.
Step 202, based on the Vuex state management library under the Vue framework, the system global data information is transferred to the target sub-application to realize sharing of the system global data information.
It should be noted that Vuex is a state management library developed specifically for vue.js applications, which uses all component states of a centralized storage management application and ensures that the states change in a predictable manner with corresponding rules. That is, the Vuex stores all variables shared by a plurality of components in one object, and then places the object in the top-level Vue instance, so that other components can be used, and the greatest characteristic is responsive.
The complexity of communication between parent and child applications is high because there is no specific data caching scheme in the micro-front-end architecture. In the embodiment of the application, the system global data information is cached based on the Vuex state management library and is transferred to the target sub-application, so that the sharing of the system global data information is realized.
As one possible implementation, the process of delivering the system global data information to the target sub-application of the business system based on the Vuex state management mode may include: and storing the system global data information in the parent application through the vuex state management library, and then communicating the parent application and the child application through tips to transfer the system global data information to the target child application.
According to the data sharing method of the service system, after the father application in the service system based on the micro front end architecture is in a login state, system global data information is obtained, and based on the Vuex state management library, the system global data information is transferred to the target sub-application of the service system, so that sharing of the system global data information is achieved. According to the scheme, the system global data information is cached through the Vuex state management library, meanwhile, the complexity of communication before application is reduced by transmitting the system global data information to the target sub-application, and sharing of the system global data information in the parent-child application is realized.
Fig. 3 is a flowchart of a data sharing method of another service system according to an embodiment of the present application. As shown in fig. 3, based on the above embodiment, step 202 in fig. 2, the implementation process of transferring the system global data information to the target sub-application based on the Vuex state management library under the Vue framework may include the following steps:
in step 301, system global data information is stored in the Vuex store of the parent application.
In some embodiments of the present application, the system global data information may be managed in a parent application by means of Vuex, and the system global data information is stored in a Vuex store of the parent application.
The state object is defined in the Vuex store and used for system global data information. The state object may create different properties to store different data. For example, user and dictionary attributes may be created for storing user information and dictionary information, respectively. The Vuex store defines a fields method for updating stored data. For example, if the system global data information includes user information and dictionary information, two methods of the setUser and setDictionary may be created for updating the data of the user attribute and the data of the dictionary attribute, respectively. In addition, the method of the component can use dispatch to trigger corresponding actions, then make asynchronous requests in the actions, and call corresponding alternatives to update data in state after the requests are successful. This maintains the synchronicity of the changes while implementing the operations of asynchronously requesting and updating the data in state.
Step 302, determining a target sub-application matched with the current route based on a preset matching rule.
The current route refers to the route accessed by the current user. In the micro front-end architecture, a route matching rule of the sub-application is also set when registering the sub-application, so that the current route can be matched with the preset route matching rule of each sub-application, and if the current route is successfully matched with the route matching rule of the sub-application A, the target sub-application is determined to be the sub-application A.
Step 303, transfer the Vuex store to the target sub-application via tips.
Taking the qiankun micro front end architecture as an example, transmitting the Vuex store to the target sub-application through tips, receiving the Vuex store in the life cycle mount of the target sub-application, and mounting the Vuex store on the Vue prototype of the target sub-application to realize sharing of the Vuex store of the shared father application of the target sub-application, thereby realizing sharing of global data information, namely realizing data communication.
In some embodiments of the present application, an implementation of delivering a Vuex store to a target sub-application via tips may include: judging whether the target sub-application is loaded successfully or not; if the target sub-application is loaded successfully, the Vuex store is transferred to the target sub-application through tips. If the target sub-application fails to be loaded, the corresponding error report page can be displayed based on preset logic.
In some embodiments of the present application, the implementation of delivering the Vuex store to the target sub-application via tips may be: transmitting the Vuex store and the state update execution object to a target sub-application through tips; the state update execution object comprises a monitoring operation for notifying a child application in the service system of message data of a parent application and an operation required to be executed when the message data changes.
In other embodiments of the present application, the implementation of delivering the Vuex store to the target sub-application via tips may also be: determining target data information from the Vuex store based on the verification message sent by the target sub-application; the target data information is passed to the target sub-application via tips.
It can be understood that the target sub-application may only need a part of data in the global data information of the system, and after the target sub-application is triggered, a verification message can be sent to the main application to inform the main application of the data information required by the main application through the verification message, and the data information required by the target sub-application is subjected to data sharing based on the verification information, so that the efficiency of data information sharing is improved. The target data information refers to data information required by the target sub-application. For example, the verification message includes identification information corresponding to the data information required by the target sub-application, and based on the verification message, the target data information required by the target sub-application can be determined from the system global data information stored in the Vuex store.
Next, taking the qiankun micro front end architecture as an example, the global state object state in the qiankun micro front end architecture may store message data that the child application notifies the parent application. After the parent application is loaded, the state can be transferred to the initglobal state function as a parameter, and the state update execution object, namely actions, is returned. The initglobal state function contains three methods, setGlobalState, onGlobalStateChange and offglobal statechange, respectively. The setGlobal State is used for storing data in the global state object state, and the child application can use the method to send the data to the parent application so as to realize sharing of the data. The onGlobal stateChange is used for monitoring the change of the global state of the parent application, the child application can register a callback function by using the method, and when the global state of the parent application sends the change, the callback function can be triggered, and the child application can acquire the latest global state by using the method. The offGlobalStateChange is used for canceling the monitoring of the global state change of the parent application so as to avoid unnecessary resource waste.
According to the data sharing method of the business system, the system global data information is stored in the Vuex store of the parent application, the target sub-application matched with the current route is determined based on the preset matching rule, and the Vuex store is transferred to the target sub-application through the tips, so that data sharing of the system global data information in the parent application is achieved.
In order to achieve the above embodiments, the present application provides a data sharing device of a service system.
Fig. 4 is a block diagram of a data sharing device of a service system according to an embodiment of the present application. It should be noted that, the service system in the embodiment of the present application is a system based on a micro front end framework. As shown in fig. 4, the apparatus includes:
an obtaining module 410, configured to obtain global data information of the system after a parent application of the service system is in a login state;
and the transfer module 420 is configured to transfer the system global data information to a target sub-application of the service system based on the Vue framework, so as to realize sharing of the system global data information.
As one example, the system global data information includes at least one of: temporary credentials of the user, user information, and dictionary information.
In some embodiments of the present application, the transfer module 420 is specifically configured to:
based on the Vuex state management library under the Vue framework, the system global data information is transferred to the target sub-application.
In some embodiments of the present application, the transfer module 420 includes:
a storage unit 421, configured to store the system global data information in a Vuex store of the parent application;
a matching unit 422, configured to determine a target sub-application that matches the current route based on a preset matching rule;
a transferring unit 423, configured to transfer the Vuex store to the target sub-application through tips.
As a possible implementation, the transferring unit 423 is specifically configured to:
judging whether the target sub-application is loaded successfully or not;
if the target sub-application is loaded successfully, the Vuex store is transferred to the target sub-application through tips.
As an example, the transfer unit 423 is also specifically configured to:
transmitting the Vuex store and the state update execution object to a target sub-application through tips; the state update execution object comprises a monitoring operation for notifying a child application in the service system of message data of a parent application and an operation required to be executed when the message data changes.
In some embodiments of the present application, the transfer unit 423 is further configured to:
determining target data information from the Vuex store based on the verification message sent by the target sub-application;
the target data information is passed to the target sub-application via tips.
It should be noted that the explanation of the implementation of the data sharing method of the service system is also applicable to the data sharing device of the service system in the embodiment of the present application, and is not repeated here.
According to the data sharing device of the service system, after the father application in the service system based on the micro front end architecture is in a login state, system global data information is obtained, and based on the Vue framework, the system global data information is transferred to the target sub-application of the service system, so that sharing of the system global data information is achieved. According to the scheme, the cache of the system global data information is realized through the Vue framework, meanwhile, the complexity of communication before application is reduced by transmitting the system global data information to the target sub-application, and the sharing of the system global data information in the parent-child application is realized.
To achieve the above embodiments, the present application also proposes an electronic device and a computer-readable storage medium.
Fig. 5 is a block diagram of an electronic device according to an embodiment of the present application. Electronic devices are intended to represent various forms of digital computers, such as laptops, desktops, workstations, personal digital assistants, servers, blade servers, mainframes, and other appropriate computers. The electronic device may also represent various forms of mobile devices, such as personal digital assistants, cellular telephones, smartphones, and other similar computing devices. The components shown herein, their connections and relationships, and their functions, are meant to be exemplary only, and are not meant to limit implementations of the application described and/or claimed herein.
As shown in fig. 5, the apparatus 500 includes a computing unit 501 that can perform various suitable actions and processes according to a computer program stored in a Read Only Memory (ROM) 502 or a computer program loaded from a storage unit 508 into a Random Access Memory (RAM) 503. In the RAM 503, various programs and data required for the operation of the device 500 can also be stored. The computing unit 501, ROM 502, and RAM 503 are connected to each other by a bus 504. An input/output (I/O) interface 505 is also connected to bus 504.
Various components in the device 500 are connected to the I/O interface 505, including: an input unit 506 such as a keyboard, a mouse, etc.; an output unit 507 such as various types of displays, speakers, and the like; a storage unit 508 such as a magnetic disk, an optical disk, or the like; and a communication unit 509 such as a network card, modem, wireless communication transceiver, etc. The communication unit 509 allows the device 500 to exchange information/data with other devices via a computer network such as the internet and/or various telecommunication networks.
The computing unit 501 may be a variety of general and/or special purpose processing components having processing and computing capabilities. Some examples of computing unit 501 include, but are not limited to, a Central Processing Unit (CPU), a Graphics Processing Unit (GPU), various specialized Artificial Intelligence (AI) computing chips, various computing units running machine learning model algorithms, a Digital Signal Processor (DSP), and any suitable processor, controller, microcontroller, etc. The computing unit 501 performs the various methods and processes described above, such as the data sharing method of the business system. For example, in some embodiments, the data sharing method of the business system may be implemented as a computer software program tangibly embodied on a machine-readable medium, such as storage unit 508. In some embodiments, part or all of the computer program may be loaded and/or installed onto the device 500 via the ROM 502 and/or the communication unit 509. When the computer program is loaded into RAM 503 and executed by the computing unit 501, one or more steps of the data sharing method of the business system described above may be performed. Alternatively, in other embodiments, the computing unit 501 may be configured to perform the data sharing method of the business system in any other suitable way (e.g. by means of firmware).
Various implementations of the systems and techniques described here above may be implemented in digital electronic circuitry, integrated circuit systems, field Programmable Gate Arrays (FPGAs), application Specific Integrated Circuits (ASICs), application Specific Standard Products (ASSPs), systems On Chip (SOCs), load programmable logic devices (CPLDs), computer hardware, firmware, software, and/or combinations thereof. These various embodiments may include: implemented in one or more computer programs, the one or more computer programs may be executed and/or interpreted on a programmable system including at least one programmable processor, which may be a special purpose or general-purpose programmable processor, that may receive data and instructions from, and transmit data and instructions to, a storage system, at least one input device, and at least one output device.
Program code for carrying out methods of the present application may be written in any combination of one or more programming languages. These program code may be provided to a processor or controller of a general purpose computer, special purpose computer, or other programmable data processing apparatus such that the program code, when executed by the processor or controller, causes the functions/operations specified in the flowchart and/or block diagram to be implemented. The program code may execute entirely on the machine, partly on the machine, as a stand-alone software package, partly on the machine and partly on a remote machine or entirely on the remote machine or server.
In the context of this application, a machine-readable medium may be a tangible medium that can contain, or store a program for use by or in connection with an instruction execution system, apparatus, or device. The machine-readable medium may be a machine-readable signal medium or a machine-readable storage medium. The machine-readable medium may include, but is not limited to, an electronic, magnetic, optical, electromagnetic, infrared, or semiconductor system, apparatus, or device, or any suitable combination of the foregoing. More specific examples of a machine-readable storage medium would include an electrical connection based on one or more wires, a portable computer diskette, a hard disk, a Random Access Memory (RAM), a read-only memory (ROM), an erasable programmable read-only memory (EPROM or flash memory), an optical fiber, a portable compact disc read-only memory (CD-ROM), an optical storage device, a magnetic storage device, or any suitable combination of the foregoing.
To provide for interaction with a user, the systems and techniques described here can be implemented on a computer having: a display device (e.g., a CRT (cathode ray tube) or LCD (liquid crystal display) monitor) for displaying information to a user; and a keyboard and pointing device (e.g., a mouse or trackball) by which a user can provide input to the computer. Other kinds of devices may also be used to provide for interaction with a user; for example, feedback provided to the user may be any form of sensory feedback (e.g., visual feedback, auditory feedback, or tactile feedback); and input from the user may be received in any form, including acoustic input, speech input, or tactile input.
The systems and techniques described here can be implemented in a computing system that includes a background component (e.g., as a data server), or that includes a middleware component (e.g., an application server), or that includes a front-end component (e.g., a user computer having a graphical user interface or a web browser through which a user can interact with an implementation of the systems and techniques described here), or any combination of such background, middleware, or front-end components. The components of the system can be interconnected by any form or medium of digital data communication (e.g., a communication network). Examples of communication networks include: local Area Networks (LANs), wide Area Networks (WANs), and the internet.
The computer system may include a client and a server. The client and server are typically remote from each other and typically interact through a communication network. The relationship of client and server arises by virtue of computer programs running on the respective computers and having a client-server relationship to each other.
It should be appreciated that various forms of the flows shown above may be used to reorder, add, or delete steps. For example, the steps described in the present application may be performed in parallel, sequentially, or in a different order, provided that the desired results of the technical solutions of the present application are achieved, and are not limited herein.
The above embodiments do not limit the scope of the application. It will be apparent to those skilled in the art that various modifications, combinations, sub-combinations and alternatives are possible, depending on design requirements and other factors. Any modifications, equivalent substitutions and improvements made within the spirit and principles of the present application are intended to be included within the scope of the present application.

Claims (10)

1. A data sharing method of a service system, wherein the service system is a system based on a micro front end architecture, the method comprising:
acquiring system global data information after a father application of the service system is in a login state;
based on the Vue framework, the system global data information is transmitted to a target sub-application of the service system, so that the sharing of the system global data information is realized.
2. The method of claim 1, wherein the delivering the system global data information to the target sub-application of the business system based on the Vue framework comprises:
and transmitting the system global data information to the target sub-application based on the Vuex state management library under the Vue framework.
3. The method of claim 2, wherein the transferring the system global data information to the target sub-application based on a Vuex state management library under the Vue framework comprises:
storing the system global data information in a Vuex store of the parent application;
determining a target sub-application matched with the current route based on a preset matching rule;
and transmitting the Vuex store to the target sub-application through tips.
4. The method of claim 3, wherein said passing said Vuex store to said target sub-application via tips comprises:
judging whether the target sub-application is loaded successfully or not;
and if the target sub-application is loaded successfully, transmitting the Vuex store to the target sub-application through tips.
5. The method of claim 3, wherein said passing said Vuex store to said target sub-application via tips comprises:
transmitting the Vuex store and the state update execution object to the target sub-application through tips; the state update execution object comprises a monitoring operation for notifying the child application in the business system of the message data of the parent application and an operation required to be executed when the message data changes.
6. The method of claim 3, wherein said passing said Vuex store to said target sub-application via tips comprises:
determining target data information from the Vuex store based on the verification message sent by the target sub-application;
and transmitting the target data information to the target sub-application through tips.
7. The method of any of claims 1-6, wherein the system global data information comprises at least one of: temporary credentials of the user, user information, and dictionary information.
8. A data sharing device of a service system, wherein the service system is a system based on a micro front end architecture, the device comprising:
the acquisition module is used for acquiring system global data information after the father application of the service system is in a login state;
and the transmission module is used for transmitting the system global data information to a target sub-application of the service system based on the Vue framework so as to realize sharing of the system global data information.
9. An electronic device, comprising: a processor, and a memory communicatively coupled to the processor;
the memory stores computer-executable instructions;
the processor executes computer-executable instructions stored in the memory to implement the method of any one of claims 1-7.
10. A computer readable storage medium having stored therein computer executable instructions which when executed by a processor are adapted to carry out the method of any one of claims 1-7.
CN202311669304.2A 2023-12-06 2023-12-06 Data sharing method and device of business system and electronic equipment Pending CN117632545A (en)

Priority Applications (1)

Application Number Priority Date Filing Date Title
CN202311669304.2A CN117632545A (en) 2023-12-06 2023-12-06 Data sharing method and device of business system and electronic equipment

Applications Claiming Priority (1)

Application Number Priority Date Filing Date Title
CN202311669304.2A CN117632545A (en) 2023-12-06 2023-12-06 Data sharing method and device of business system and electronic equipment

Publications (1)

Publication Number Publication Date
CN117632545A true CN117632545A (en) 2024-03-01

Family

ID=90026648

Family Applications (1)

Application Number Title Priority Date Filing Date
CN202311669304.2A Pending CN117632545A (en) 2023-12-06 2023-12-06 Data sharing method and device of business system and electronic equipment

Country Status (1)

Country Link
CN (1) CN117632545A (en)

Similar Documents

Publication Publication Date Title
CN111400000A (en) Network request processing method, device, equipment and storage medium
CN112269706A (en) Interface parameter checking method and device, electronic equipment and computer readable medium
CN112965799B (en) Task state prompting method and device, electronic equipment and medium
CN113946816A (en) Cloud service-based authentication method and device, electronic equipment and storage medium
CN117632545A (en) Data sharing method and device of business system and electronic equipment
CN116503005A (en) Method, device, system and storage medium for dynamically modifying flow
CN114510334A (en) Class instance calling method and device, electronic equipment and automatic driving vehicle
CN112925623A (en) Task processing method and device, electronic equipment and medium
CN114138397B (en) Page display method and device, electronic equipment and storage medium
CN115840604B (en) Data processing method, device, electronic equipment and computer readable storage medium
CN114268558B (en) Method, device, equipment and medium for generating monitoring graph
CN112527802B (en) Soft link method and device based on key value database
CN114500443B (en) Message pushing method, device, system, electronic equipment and storage medium
CN114095758B (en) Cloud image intercepting method and related device
CN110262756B (en) Method and device for caching data
CN116186450A (en) Micro front-end application system, application rendering method, device and storage medium
CN117931322A (en) Interface calling method and device of low-code platform and electronic equipment
CN116012158A (en) Service processing method, device, equipment and storage medium
CN114416040A (en) Page construction method, device, equipment and storage medium
CN115686911A (en) Server-side self-checking method and device, electronic equipment and storage medium
CN117670236A (en) Mobile-terminal-based to-be-handled flow approval method, device, equipment and medium
CN114564316A (en) Message pushing method, device, equipment and storage medium
CN116360892A (en) Function expansion method, device, equipment and medium of distributed service system
CN116599895A (en) Data transmission method, device, equipment and medium
CN117632343A (en) OCX module calling method, device, equipment and storage medium

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