CN116980464A - Page processing method, device, equipment and storage medium - Google Patents

Page processing method, device, equipment and storage medium Download PDF

Info

Publication number
CN116980464A
CN116980464A CN202211406600.9A CN202211406600A CN116980464A CN 116980464 A CN116980464 A CN 116980464A CN 202211406600 A CN202211406600 A CN 202211406600A CN 116980464 A CN116980464 A CN 116980464A
Authority
CN
China
Prior art keywords
target page
configuration file
rendering
access request
target
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
CN202211406600.9A
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.)
Tencent Technology Shenzhen Co Ltd
Original Assignee
Tencent Technology Shenzhen 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 Tencent Technology Shenzhen Co Ltd filed Critical Tencent Technology Shenzhen Co Ltd
Priority to CN202211406600.9A priority Critical patent/CN116980464A/en
Publication of CN116980464A publication Critical patent/CN116980464A/en
Pending legal-status Critical Current

Links

Classifications

    • HELECTRICITY
    • H04ELECTRIC COMMUNICATION TECHNIQUE
    • H04LTRANSMISSION OF DIGITAL INFORMATION, e.g. TELEGRAPHIC COMMUNICATION
    • H04L67/00Network arrangements or protocols for supporting network services or applications
    • H04L67/2866Architectures; Arrangements
    • H04L67/30Profiles
    • HELECTRICITY
    • H04ELECTRIC COMMUNICATION TECHNIQUE
    • H04LTRANSMISSION OF DIGITAL INFORMATION, e.g. TELEGRAPHIC COMMUNICATION
    • H04L67/00Network arrangements or protocols for supporting network services or applications
    • H04L67/01Protocols
    • H04L67/02Protocols based on web technology, e.g. hypertext transfer protocol [HTTP]

Landscapes

  • Engineering & Computer Science (AREA)
  • Computer Networks & Wireless Communication (AREA)
  • Signal Processing (AREA)
  • Information Transfer Between Computers (AREA)
  • Information Retrieval, Db Structures And Fs Structures Therefor (AREA)

Abstract

The embodiment of the application discloses a page processing method, a device, equipment and a storage medium, which can be applied to the fields of computer technology, artificial intelligence and the like. The method comprises the following steps: acquiring at least one access request, and determining a configuration file of a target page accessed by each access request from an external storage space; creating a local folder corresponding to each target page, and adding the configuration file of each target page into the corresponding local folder; rendering the configuration file of each target page based on the file address of the local folder corresponding to the target page, and returning the rendering result to the client so that the client displays the target page based on the rendering result; and returning the configuration file of the target page to the client in response to not returning the rendering result to the client, so that the client renders the configuration file of the target page and displays the target page based on the rendering result. By adopting the embodiment of the application, the page rendering efficiency can be improved, and the applicability is high.

Description

Page processing method, device, equipment and storage medium
Technical Field
The present application relates to the field of artificial intelligence, and in particular, to a method, an apparatus, a device, and a storage medium for processing a page.
Background
With the development of scientific technology, the software technology and hardware technology of computers and mobile terminals have advanced significantly. Because of the wide application of the internet technology, people can obtain a large amount of information from different pages through the network under the condition of no home departure, thereby providing help for work and study and enriching the daily life of people.
The rendering process of the page is involved in accessing the page. In the conventional rendering mode, configuration files required by each page in the rendering process need to be stored in a local folder associated with the page, and the configuration files of the corresponding page need to be acquired through a fixed path for rendering independently in the rendering process, so that the rendering efficiency is low.
Disclosure of Invention
The embodiment of the application provides a page processing method, a device, equipment and a storage medium, which can improve page rendering efficiency and have high applicability.
In a first aspect, an embodiment of the present application provides a page processing method, where the method includes:
acquiring at least one access request, and determining a configuration file of a target page accessed by each access request from an external storage space;
Creating a local folder corresponding to each target page, and adding a configuration file of each target page into the corresponding local folder;
for each target page, determining the file address of the local folder corresponding to the target page, rendering the configuration file in the local folder corresponding to the target page based on the file address, and returning the rendering result corresponding to the target page to the client accessing the target page, so that the client accessing the target page displays the target page based on the rendering result corresponding to the target page; and responding to that the rendering result corresponding to the target page is not returned to the client accessing the target page, and returning the configuration file of the target page to the client accessing the target page, so that the client accessing the target page renders the configuration file of the target page and displays the target page based on the obtained rendering result.
In a second aspect, an embodiment of the present application provides a page processing method, where the method includes:
sending at least one access request, wherein each access request is used for enabling a server to determine the file address of a local folder corresponding to a target page accessed by the access request, rendering a configuration file in the local folder corresponding to the target page based on the file address, determining and adding the configuration file of each target page from an external storage space to the local folder corresponding to the target page by the server, and creating the local folder corresponding to each target page by the server;
And for each target page, responding to the rendering result which is not returned by the server and corresponds to the target page, acquiring a configuration file of the target page returned by the server, rendering the configuration file of the target page, and displaying the target page based on the obtained rendering result.
In a third aspect, an embodiment of the present application provides a page processing apparatus, including:
the request acquisition module is used for acquiring at least one access request, and determining a configuration file of a target page accessed by each access request from an external storage space;
the file processing module is used for creating a local folder corresponding to each target page and adding the configuration file of each target page into the corresponding local folder;
and for each target page, the page rendering module is used for determining the file address of the local folder corresponding to the target page, rendering the configuration file in the local folder corresponding to the target page based on the file address, returning the rendering result corresponding to the target page to the client accessing the target page, so that the client accessing the target page displays the target page based on the rendering result corresponding to the target page, and returning the configuration file of the target page to the client accessing the target page in response to not returning the rendering result corresponding to the target page to the client accessing the target page, so that the client accessing the target page renders the configuration file of the target page and displays the target page based on the obtained rendering result.
Optionally, for each target page, the rendering result corresponding to the target page is not returned to the client accessing the target page, including at least one of the following:
the rendering of the configuration file in the local folder corresponding to the target page fails;
and successfully rendering the configuration file in the local folder corresponding to the target page, and returning the rendering result corresponding to the target page to the process interruption of the client accessing the target page.
Optionally, for each of the above access requests, the access request carries an access address and target version information of a target page accessed by the access request, and when the request acquisition module determines, from the external storage space, a configuration file of the target page accessed by the access request, the request acquisition module is configured to:
determining a configuration file corresponding to the access address from an external storage space;
responding to the version information of the configuration file corresponding to the access address and the target version information to be consistent, and determining the configuration file corresponding to the access address as the configuration file of the target page accessed by the access request;
and in response to the fact that the version information of the configuration file corresponding to the access address is inconsistent with the target version information, updating the configuration text corresponding to the access address based on the target version information, and determining the updated configuration file as the configuration file of the target page accessed by the access request.
Optionally, for each target page, when the page rendering module renders the configuration file in the local folder corresponding to the target page based on the file address, the page rendering module is configured to:
and transmitting the file address into a rendering application, so that the rendering application obtains the configuration file of the target page based on the file address and renders the configuration file of the target page, wherein the server side comprises a rendering frame, the rendering application is deployed in the rendering frame, and the rendering application supports the running scene of the configuration file of any target page.
Optionally, for each of the access requests, the file processing module is further configured to:
and acquiring the configuration file of the target page accessed by the access request from the client corresponding to the access request in response to the fact that the configuration file of the target page accessed by the access request is not determined from the external storage space.
In a fourth aspect, an embodiment of the present application provides a page processing apparatus, including:
the request sending module is used for sending at least one access request, each access request is used for enabling a server to determine the file address of a local folder corresponding to a target page accessed by the access request, rendering a configuration file in the local folder corresponding to the target page based on the file address, determining and adding the configuration file of each target page from an external storage space to the local folder corresponding to the target page by the server, and creating the local folder corresponding to the target page by the server;
The page display module is configured to obtain a rendering result corresponding to each target page returned by the server, display a corresponding target page based on the rendering result corresponding to each target page, and for each target page, respond to the rendering result corresponding to the target page not returned by the server, obtain a configuration file of the target page returned by the server, render the configuration file of the target page, and display the target page based on the obtained rendering result.
Optionally, for each target page, the rendering result corresponding to the target page is not returned to the client accessing the target page, including at least one of the following:
the rendering of the configuration file in the local folder corresponding to the target page fails;
and successfully rendering the configuration file in the local folder corresponding to the target page, and returning the rendering result corresponding to the target page to the process interruption of the client accessing the target page.
Optionally, for each of the access requests, the page display module is further configured to:
responding to the failure of sending the access request, and determining a configuration file of a target page accessed by the access request from the external storage space;
And rendering the configuration file of the target page, and displaying the target page based on the obtained rendering result.
Optionally, when the request sending module sends at least one access request, the request sending module is configured to:
and sending at least one access request to a proxy server so that the proxy server sends the at least one access request to the server.
Optionally, the apparatus further includes a file update module, for each of the target pages, the file update module is configured to:
responding to the debugging operation aiming at the target page, and adjusting the configuration file of the target page based on the debugging operation to obtain a target configuration file;
and updating the configuration file of the target page in the external storage space based on the target configuration file.
In a fifth aspect, an embodiment of the present application provides an electronic device, including a processor and a memory, where the processor and the memory are connected to each other;
the memory is used for storing a computer program;
the processor is configured to execute the page processing method provided in the first aspect and/or the second aspect of the embodiment of the present application when the computer program is invoked.
In a sixth aspect, embodiments of the present application provide a computer readable storage medium storing a computer program for execution by a processor to implement the page processing method provided in the first and/or second aspects of the embodiments of the present application.
In a seventh aspect, embodiments of the present application provide a computer program product comprising a computer program which, when executed by a processor, implements the page processing method provided in the first and/or second aspects of the embodiments of the present application.
In the embodiment of the application, when the server side obtains at least one access request sent by the client side, a local folder can be created for the target pages accessed by each access request in real time, and the corresponding configuration files are added into the local folder from the external storage space, so that the rendering of the configuration files of a plurality of target pages in the corresponding text folders can be realized at the same time, and the rendering efficiency is improved.
Drawings
In order to more clearly illustrate the technical solutions of the embodiments of the present application, the drawings that are needed in the embodiments will be briefly described below, and it is obvious that the drawings in the following description are only some embodiments of the present application, and other drawings may be obtained according to these drawings without inventive effort for a person skilled in the art.
FIG. 1 is a schematic diagram of a scenario of a page processing method according to an embodiment of the present application;
FIG. 2 is a schematic flow chart of a page processing method according to an embodiment of the present application;
FIG. 3 is a schematic diagram of a scenario of a page processing method according to an embodiment of the present application;
FIG. 4 is another schematic flow chart of a page processing method according to an embodiment of the present application;
fig. 5 is a schematic view of a scenario of a micro front-end application provided by an embodiment of the present application;
FIG. 6 is a schematic diagram of another scenario of a page processing method according to an embodiment of the present application;
FIG. 7 is a schematic diagram of a flowchart of an update profile according to an embodiment of the present application;
FIG. 8 is a schematic diagram of a page processing apparatus according to an embodiment of the present application;
FIG. 9 is another schematic diagram of a page processing apparatus according to an embodiment of the present application;
fig. 10 is a schematic structural diagram of an electronic device according to an embodiment of the present application.
Detailed Description
The following description of the embodiments of the present application will be made clearly and completely with reference to the accompanying drawings, in which it is apparent that the embodiments described are only some embodiments of the present application, but not all embodiments. All other embodiments, which can be made by those skilled in the art based on the embodiments of the application without making any inventive effort, are intended to be within the scope of the application.
Referring to fig. 1, fig. 1 is a schematic view of a scenario of a page processing method according to an embodiment of the present application. The page processing method shown in fig. 1 may be applied to a server, and in particular, may be applied to a rendering frame deployed in the server, and executed by a rendering application in the rendering frame.
As shown in fig. 1, the server 10 may receive at least one access request. Each access request is used to access a target page, and each access request may be sent by the same client, or may be sent by a different client, which is not limited herein.
After obtaining at least one access request, the server 10 may determine, from the external storage space 20, a configuration file of a target page accessed by each access request. After the server 10 obtains n access requests, the configuration file 1 of the target page accessed by the access request 1, the configuration files 2, … of the target page accessed by the access request 2, and the configuration file n of the target page accessed by the access request n may be determined from the external storage space, respectively.
Further, the server 10 may create a corresponding local folder for the target pages accessed by each access request, and add the configuration file of each target page to the corresponding local folder. A local folder 1 is created for the target page accessed by the access request 1 and a configuration file 1 is added to the local folder 1, a local folder 2 is created for the target page accessed by the access request 2 and a configuration file 2 is added to the local folder 2, a local folder n is created for the target page accessed by the access request n and a configuration file n is added to the local folder n.
Further, for each target page, the server 10 may determine a file address of a local folder corresponding to the target page, further render the configuration file of the target page based on the file address, and return the obtained rendering result to the client accessing the target page, so that the client accessing the target page displays the target page based on the received rendering result.
For example, the server 10 may render the configuration file 1 in the local file 1 to obtain the rendering result 1, and return the rendering result 1 to the client that sends the access request 1, so that the client that sends the access request 1 displays the target page accessed by the access request 1 based on the rendering result 1. The server 10 may render the configuration file 2 in the local file 2 to obtain a rendering result 2, and return the rendering result 2 to the client sending the access request 2, so that the client sending the access request 2 displays the target page accessed by the access request 2 based on the rendering result 2. The server 10 may render the configuration file n in the local file n to obtain a rendering result n, and return the rendering result n to the client sending the access request n, so that the client sending the access request n displays the target page accessed by the access request n based on the rendering result n.
For each target page, if the rendering result corresponding to the target page is not returned to the client accessing the target page by the server 10, the configuration file of the target page is returned to the client accessing the target page, so that the client accessing the target page renders the configuration file of the target page and displays the target page based on the rendering result.
For example, the server 10 fails to render the configuration file 1 in the local file 1 based on the file address of the local folder 1, or fails to return the rendering result 1 after the rendering is successful to the corresponding client, and the server 10 returns the configuration file 1 to the corresponding client, so that the client renders the received configuration file 1, and displays the corresponding target page based on the rendering result 1.
The server 10 may simultaneously respond to at least one access request, and simultaneously render the configuration file of the target page accessed by each access request, so as to return the rendering result corresponding to each access request to the corresponding client.
The server 10 may be a server or a terminal device with data processing capability. The server may be a server cluster or a distributed system formed by a plurality of physical servers, and may also be a cloud server for providing cloud services, cloud databases, cloud computing, cloud functions, cloud storage, network services, cloud communication, middleware services, domain name services, security services, basic cloud computing services such as big data and artificial intelligent platforms, for example, an internet of things edge cloud platform, a cloud computing platform, and the like.
The client may be, but is not limited to, a smart phone, a tablet computer, a notebook computer, a desktop computer, a smart display, a wearable electronic device (e.g., a smart watch), a vehicle-mounted terminal, a smart home appliance (e.g., a smart television), an AR/VR device, etc.
The external storage space may be a Database (Database), a cloud storage (cloud storage), a content delivery network (Content Delivery Network, CDN), or a Blockchain (Blockchain), which may be specifically determined based on the actual application scenario requirements, which is not limited herein.
The database may be considered as an electronic file cabinet, i.e. a place for storing electronic files, and may be a relational database (SQL database) or a non-relational database (NoSQL database), which is not limited herein, and may be used to store configuration files of each target page in the present application.
Blockchains are novel application modes of computer technologies such as distributed data storage, point-to-point transmission, consensus mechanisms, encryption algorithms, and the like. Blockchains are essentially a de-centralized database, which is a string of data blocks that are generated in association using cryptographic methods. In the embodiment of the application, each data block in the blockchain can store the configuration file of each target page. Cloud storage is a new concept which extends and develops in the concept of cloud computing, and refers to that a large number of storage devices (storage devices are also called storage nodes) of different types in a network are combined to work cooperatively through application software or application interfaces through functions of cluster application, grid technology, distributed storage file systems and the like, so that configuration files of all target pages are stored together.
The CDN is a distributed content distribution network constructed on a data network, and has the functions of overcoming the defects of insufficient output bandwidth and concurrency capacity of a single-machine system by adopting a server cluster technology, greatly improving the number of concurrent flows supported by the system and reducing or avoiding adverse effects caused by single-point failure. The CDN uses global load balancing technology to direct the data acquisition request to the latest server which works normally, and the server directly responds to the data acquisition request. When no corresponding data exists in the server, the corresponding data can be automatically grabbed from the original server according to the configuration and returned. In the embodiment of the present application, the configuration file of each target page may be stored in a server corresponding to each target page in the CDN.
Referring to fig. 2, fig. 2 is a flow chart of a page processing method according to an embodiment of the application. The page processing method shown in fig. 2 may be applied to a server, and specifically may include the following steps:
step S21, at least one access request is acquired, and a configuration file of a target page accessed by each access request is determined from an external storage space.
In some possible embodiments, each access request is used to access a target page, and each target page may be a web page or a front-end application program built based on any technical stack and/or any front-end framework, and the like, and may be specifically determined based on actual application scenario requirements, which is not limited herein.
Among them, front-end applications include, but are not limited to, communication applications, social applications, entertainment applications, office applications, or resource exchange applications, without limitation.
The access requests acquired by the server side originate from at least one client side, for example, at least one access request sent by different client sides can be acquired simultaneously, or at least one access request sent by the same client side can be acquired simultaneously.
When the server side obtains the access request, the server side can directly and simultaneously obtain at least one access request sent by at least one client side.
Or when the server side acquires the access request, the server side can acquire at least one access request forwarded by the proxy server at the same time, and each access request forwarded by the proxy server originates from at least one client side.
At this time, each access request is sent to the proxy server by the corresponding client, and the proxy server forwards the received access request to the server.
Each access request may be sent by the client after the browser receives the input access address for the target page, for example, the client sends the access request for accessing the target page after receiving the input website of the target page through the browser. Alternatively, each access request may be sent by the client after the browser responds to the opening operation for the target page, for example, the client sends an access request for accessing a certain item detail page in the shopping website front page after the browser responds to the opening operation for the item detail page.
In some possible embodiments, the configuration file of each target page may be pre-stored to an external storage space by the client, and the configuration files of different target pages may be pre-stored to the same or different external storage spaces, which may be specifically determined based on the actual application scenario requirements, without limitation.
The configuration file of each target page includes, but is not limited to, code required for running and constructing the target page, executable files in various formats, relevant page components, and the like.
The external storage space includes, but is not limited to, a database, a CDN, a cloud storage, a blockchain, or the like, which is not limited herein.
After receiving at least one access request, a configuration file for a target page accessed by each access request may be determined from the external storage space.
Specifically, for each access request, the access request may carry a page identifier of the target page accessed, and further, a configuration file associated with the page identifier may be determined from an external storage space, and the configuration file associated with the page identifier may be determined as the configuration file of the target page accessed by the access request.
The page identifier of each target page may be an identifier uniquely associated with the target page, or may be page description information of the target page, or the like, which may be specifically determined based on the actual application scenario requirement, and is not limited herein.
Optionally, for each access request, the access request may carry access address or route information of the accessed target page, and further, a configuration file of the target page corresponding to the access address or route information may be determined from the external storage space, and the configuration file of the target page corresponding to the access address or route information may be determined as the configuration file of the target page accessed by the access request.
Optionally, the configuration file of each target page in the external storage space is the configuration file of the latest version of the corresponding target page. For each access request, the access request may carry the access address and the target version information of the target page accessed by the access request. Based on this, after the access request is acquired, a configuration file corresponding to the access address carried by the access request may be determined from the external storage space.
Further, the version information of the configuration file corresponding to the access address carried by the access request can be compared with the target version information carried by the access request, and if the version information is consistent with the target version information, the configuration file corresponding to the access address carried by the access request is the configuration file of the target page accessed by the access request.
If the version information of the configuration file corresponding to the access address carried by the access request is inconsistent with the target version information carried by the access request, the configuration file corresponding to the access address in the external storage space is indicated not to be updated in time, and at the moment, the configuration file corresponding to the access address in the external storage space can be updated based on the target version information, that is, the configuration file corresponding to the access address in the external storage space is updated in version, and the updated configuration file is determined to be the configuration file of the target page accessed by the access request.
Optionally, the external storage space stores a configuration file for each version of each target page. For each access request, the access request may carry the access address and the target version information of the target page accessed by the access request.
Based on the above, after the access request is acquired, the configuration file of each version corresponding to the access address carried by the access request can be determined from the external storage space, and then the configuration file consistent with the target version information carried by the access request is determined and is determined as the configuration file of the target page accessed by the access request.
Step S22, creating a local folder corresponding to each target page, and adding the configuration file of each target page to the corresponding local folder.
The page processing method provided by the embodiment of the application can be specifically executed by the rendering frame of the server side, and the rendering frame is provided with the rendering application. Wherein, the rendering application supports the running scene of a plurality of target pages, so the client can complete a plurality of page rendering operations based on the rendering application.
In the conventional rendering mode, the configuration file required by each page in the rendering process is separately stored in a local folder associated with the page, so that the configuration file of the corresponding page is acquired through a fixed path and rendered when the rendering is performed. And for each page, an operation scene corresponding to the page needs to be built in advance, and then the configuration file of the page is rendered based on the operation scene of the page to obtain a rendering result.
Because the service end in the embodiment of the application executes the rendering process based on the rendering application compatible with various operation scenes, after determining the configuration file of the target page accessed by each access request from the external storage space, if the configuration file of the target page accessed by each access request is stored in the local folder corresponding to the rendering application, the configuration file of the target page accessed by each access request cannot be read normally.
Thus, after determining the configuration file of the target page accessed by an access request from the external storage space, a local folder may be created for the target page corresponding to the access request, and the configuration file of the target page corresponding to the access request may be added to the corresponding local folder.
Alternatively, after each access request is obtained, a target page accessed by the access request may be determined and a local folder may be created for the target page. After determining the configuration file of the target page from the external storage space, the configuration file of the target page is added to the corresponding local folder.
Each target page corresponds to a different local folder, and each local folder has an independent file address.
Step S23, for each target page, determining the file address of the local folder corresponding to the target page, rendering the configuration file in the local folder corresponding to the target page based on the file address, returning the rendering result corresponding to the target page to the client accessing the target page, so that the client accessing the target page displays the target page based on the rendering result of the target page, and in response to not returning the rendering result corresponding to the target page to the client accessing the target page, returning the configuration file of the target page to the client accessing the target page, so that the client accessing the target page renders the configuration file of the target page and displays the target page based on the obtained rendering result.
In some possible embodiments, for each target page accessed by the access request, a file address of a local folder corresponding to the target page may be determined, and then a corresponding configuration file may be obtained and rendered according to the determined file address.
Specifically, the file address corresponding to the target page may be transferred into the rendering logic of the rendering application, and the rendering logic reads the configuration file of the target page from the file address corresponding to the target page and renders the configuration file.
The server side comprises a rendering frame, the rendering application is deployed in the rendering frame, and the rendering application supports running scenes of configuration files of any target page.
Wherein, before rendering based on the rendering logic of the rendering application, it may be detected in advance whether the rendering logic supports the file address of the local folder corresponding to the incoming target page. If not, the rendering logic may be modified to support the file address of the local folder corresponding to the incoming target page.
Wherein the rendering logic may be modified in advance to read the local address of the latest local folder each time before rendering based on the rendering logic of the rendering application.
In some possible embodiments, for each access request, if the configuration file of the target page accessed by the access request is not determined from the external storage space, the configuration file of the target page accessed by the access request is obtained from the client corresponding to the access request, and then the configuration file of the target page accessed by the access request is rendered.
For each access request, if the configuration file of the target page accessed by the access request is not determined from the external storage space, the instruction information may be sent to the client corresponding to the access request, so as to instruct the client corresponding to the access request to send the configuration file of the target page accessed by the access request to the server.
In the embodiment of the present application, the process of rendering the configuration file of each target page by the server may be referred to as server-side rendering (SSR), that is, the rendering process is completed at the server, and the client only needs to receive the rendering result.
In some possible embodiments, for each target page, if the server side does not return the rendering result corresponding to the target page to the client side accessing the target page, the server side returns the configuration file of the target page to the client side accessing the target page, the client side accessing the target page renders the configuration file of the target page, and the target page is displayed based on the obtained rendering result.
The process that the server sends the configuration file to the corresponding client to be rendered by the client may be referred to as client-side rendering (CSR), that is, the rendering process is completed by the client.
Taking an access request as an example, the client sends the access request to the server, and the server renders the configuration file of the target page accessed by the access request based on an SSR rendering mode, but does not return the rendering result to the client. At this time, the server sends the configuration file of the target page accessed by the access request to the client, the client renders the received configuration file to obtain a rendering result, and the corresponding target page is displayed based on the rendering result.
For each target page, the server side does not return the rendering result corresponding to the target page to the client side accessing the target page, and may fail to render the configuration file in the local folder corresponding to the target page for the server side.
And for each target page, if the service end fails to render the configuration file in the local folder corresponding to the target page, returning the configuration file in the local folder corresponding to the target page to the client accessing the target page, so that the client accessing the target page renders the configuration file corresponding to the target page, and displaying the target page based on the rendering result.
The failure of the server to render the configuration file corresponding to the target page includes, but is not limited to, termination of the rendering process, failure of reading the configuration file, network error, or a part of codes in the configuration file needs to be run at the client, which can be specifically determined based on the actual application scene requirement, without limitation.
For each target page, the server does not return the rendering result corresponding to the target page to the client accessing the target page, and may succeed in rendering the configuration file in the local folder corresponding to the target page for the server, but the process of returning the rendering result corresponding to the target page to the client accessing the target page is interrupted.
If the server side finishes rendering the configuration file of the target page and obtains a rendering result, but interrupts the process of returning the rendering result of the target page to the corresponding client side, the server side can also return the configuration file in the local folder corresponding to the target page to the client side accessing the target page, so that the client side accessing the target page renders the configuration file corresponding to the target page, and displays the target page based on the rendering result.
For each target page, the process that the server returns the rendering result corresponding to the target page to the client accessing the target page is interrupted, which may be a network error, a client refusing to receive, etc., without limitation.
Optionally, for each target page, if the server side does not return the rendering result corresponding to the target page to the client side accessing the target page, the server side may return indication information to the client side accessing the target page to indicate the client side to obtain the configuration file corresponding to the target page from the external storage space and render the configuration file, so as to display the target page according to the rendering result.
The following describes a page processing method provided in the embodiment of the present application further by taking an example that a client sends an access request to a server with reference to fig. 3, and fig. 3 is a schematic view of a scenario of the page processing method provided in the embodiment of the present application.
As shown in fig. 3, the client sends an access request to the server, and the server determines, according to an access address of an accessed target page carried by the access request, a configuration file of the target page accessed by the access request from an external storage space (CDN). And meanwhile, determining whether the configuration file needs to be updated according to the target version information carried by the access request.
Under the condition that the configuration file of the target page does not need to be updated, a corresponding local folder is created for the target page, and meanwhile, the determined configuration file is added into the local folder, so that the file address of the local folder is transmitted into rendering logic of a rendering application, and the configuration file of the target page is rendered in an SSR rendering mode to obtain a rendering result.
Under the condition that the configuration file of the target page needs to be updated, the configuration file can be updated according to the requirement that the version information of the updated configuration file is consistent with the target version information carried by the access request. And the local folder is further created for the target page, and the updated configuration file is added into the local folder, so that the file address of the local folder is transmitted into the rendering logic of the rendering application, and the updated configuration file of the target page is rendered in an SSR rendering mode to obtain a rendering result.
Further, if the service end fails to render the configuration file of the target page in an SSR rendering mode, the configuration file of the target page is rendered in a CSR rendering mode. The server returns the configuration file in the local folder corresponding to the target page to the client, and the client renders the configuration file of the target page to obtain a rendering result.
If the server side renders the configuration file of the target page based on the SSR rendering mode to obtain a rendering result, the rendering result is returned to the client side so that the client side and the received rendering result display the target page. If the server fails to render the configuration file of the target page in an SSR rendering mode, the client can display the target page based on a rendering result obtained by rendering the configuration file of the target page.
If the process of returning the rendering result corresponding to the target page to the client is interrupted, the server returns the configuration file of the target page to the client, so that the client renders the received configuration file and displays the target page based on the rendering result.
Referring to fig. 4, fig. 4 is another flow chart of the page processing method according to the embodiment of the present application. The page processing method shown in fig. 4 may be applied to a client, and specifically may include the following steps:
and step S41, at least one access request is sent, and each access request is used for enabling the server side to determine the file address of the local folder corresponding to the target page accessed by the access request, and rendering the configuration file in the local folder corresponding to the target page based on the file address.
In some possible embodiments, each access request is used to access a target page, and each target page may be a web page or a front-end application program built based on any technical stack and/or any front-end framework, and the like, and may be specifically determined based on actual application scenario requirements, which is not limited herein.
The at least one access request sent by the client may be an access request sent by the same server, or may be an access request sent to a plurality of servers. For example, the client may send at least one service request to one server at the same time, or may send an access request to a different server, without limitation.
The client may send an access request after receiving an input access address for a target page, e.g., the client receives an input address of the target page through the browser and then sends an access request for accessing the target page. Alternatively, the client may send an access request for accessing the target page after the browser responds to the open operation for the target page, e.g., the client sends an access request for accessing a news detail page in a news website after the browser responds to the open operation for the news detail page.
In the embodiment of the present application, the client may pre-store the configuration file of each target page to the external storage space, where the configuration file of each target page includes, but is not limited to, code required for running and constructing the target page, executable files in various formats, relevant page components, and the like, and is not limited herein.
The external storage space includes, but is not limited to, a database, a CDN, a cloud storage, a blockchain, or the like, which is not limited herein.
In some possible embodiments, each of the target pages may be a micro-front-end application. Because each micro-front-end application corresponds to a respective port, accessing each micro-front-end application typically needs to be solved by a dynamic port, but the dynamic port makes it difficult to implement debugging of each micro-front-end application. Therefore, when sending the access request, the access request can be sent to the proxy server, the reverse proxy server exposes a port to the client, and the client can quickly send the access request to the corresponding server through the proxy server.
The micro front-end is a micro service-like architecture, and applies the micro service concept to the browser end, namely, converting a Web page from a single application into a plurality of small front-end applications to be aggregated into one application. Each micro front-end application can be independently operated, independently developed and independently deployed.
Fig. 5 is a schematic view of a scenario of a micro front-end application according to an embodiment of the present application, as shown in fig. 5. For a single-page Web application (single page Web application, SPA), the single-page Web application may be decoupled to obtain multiple applications (e.g., application a-application E), where application a-application E is a sub-application of the single-page Web application, and each application may be referred to as a micro-front-end application. Based on the method, the development isolation and deployment isolation of the current micro front-end application can be realized, the overall development and deployment efficiency is improved, and meanwhile, each micro front-end application can be quickly accessed to reduce the data volume of rendering.
The continuous integration of the base page to each micro front end application is always a main pain point of the micro front end landing, and various problems need to be solved in the integration process, such as: application discovery, sub-application management, inter-application communication, pattern representation difference and the like. Therefore, in the embodiment of the application, a standardized continuous integration component can be packaged for the micro front-end application, and the base page can realize continuous integration of the micro front-end application only by distributing a father route for each micro front-end application.
In some possible embodiments, for each access request sent by the client, the access request is used for enabling the server to determine a file address of a local folder corresponding to a target page accessed by the access request, and rendering a configuration file in the local folder corresponding to the target page based on the file address.
The configuration file server side of each target page determines from an external storage space and adds the configuration file server side to a text file corresponding to the target page, and a local folder corresponding to each target page is created by the server side.
That is, after each time the client sends an access request to the server, the server may determine a configuration file of a target page accessed by the access request from an external storage space, and create a local folder for the target page to add the configuration file of the target page to the local folder, so as to render the configuration file in the local folder based on a file address of the local folder.
Optionally, for each access request, the access request may carry an access address or routing information of the target page accessed by the access request, and after the client sends the access request, the server may determine a configuration file of the target page corresponding to the access address or routing information from the external storage space, and determine the configuration file of the target page corresponding to the access address or routing information as the configuration file of the target page accessed by the access request.
Optionally, the configuration file of each target page in the external storage space is the configuration file of the latest version of the corresponding target page. For each access request, the access request may carry the access address and the target version information of the target page accessed by the access request. Based on the above, after the client sends the access request, the server may determine a configuration file corresponding to the access address carried by the access request from the external storage space, and update, based on the target version information, the configuration file corresponding to the access address in the external storage space to obtain a configuration file corresponding to the target page and having version information consistent with the target version information when version information of the configuration file corresponding to the access address is inconsistent with the target version information carried by the access request.
Optionally, the external storage space stores a configuration file for each version of each target page. For each access request, the access request may carry the access address and the target version information of the target page accessed by the access request. Based on the above, after the client sends the access request, the server can determine the configuration file of each version corresponding to the access address carried by the access request from the external storage space, further determine the configuration file consistent with the target version information carried by the access request from the configuration file, and determine the configuration file as the configuration file of the target page accessed by the access request.
Step S42, obtaining a rendering result corresponding to each target page returned by the server, displaying the corresponding target page based on the rendering result of each target page, and for each target page, responding to the rendering result corresponding to the target page not returned by the server, obtaining a configuration file of the target page returned by the server, rendering the configuration file of the target page, and displaying the target page based on the obtained rendering result.
In some possible embodiments, for each access request, if the client receives a rendering result of a target page accessed by the access request, the client may directly display the target page based on the rendering result. That is, the target page accessed by the access request is rendered by the server, and the client only needs to analyze and display the rendering result.
In some possible embodiments, for each access request, if the server side does not determine the configuration file of the target page accessed by the access request from the external storage space, the client side may receive the configuration file of the target page returned by the server side, so as to render the received configuration file to obtain a rendering result, and display the target page accessed by the access request based on the rendering result.
In some possible embodiments, for each target page accessed by the access request, if the server side does not return the rendering result corresponding to the target page, the client side may obtain the configuration file of the target page returned by the server side, and render the received configuration file by the client side to obtain the rendering result of the target page, so as to display the target page based on the rendering result of the target page.
For each target page, the server side does not return the rendering result corresponding to the target page to the client side accessing the target page, and may fail to render the configuration file in the local folder corresponding to the target page for the server side.
The failure of the server to render the configuration file corresponding to the target page includes, but is not limited to, termination of the rendering process, failure of reading the configuration file, network error, or a part of codes in the configuration file needs to be run at the client, which can be specifically determined based on the actual application scene requirement, without limitation.
For each target page, the process that the server returns the rendering result corresponding to the target page to the client accessing the target page is interrupted, which may be a network error, a client refusing to receive, etc., without limitation.
Optionally, each access request sent by the client to the server may have a sending failure, that is, a failure in accessing the target page. In this case, the client may directly determine the configuration file of the target page accessed by the access request from the external storage space, and further render the configuration file of the target page, so as to display the target page according to the obtained rendering result.
The page processing method provided by the embodiment of the present application is further described below with reference to fig. 6, in which an access request is sent by a client to a server, and fig. 6 is another schematic view of the page processing method provided by the embodiment of the present application.
As shown in fig. 6, the client sends an access request to the server, and in case of successfully sending the access request, the server determines a configuration file of a target page accessed by the access request from an external storage space (CDN). And simultaneously, creating a corresponding local folder for the target page, and adding the determined configuration file into the local folder, so that the file address of the local folder is transmitted into rendering logic of the rendering application to render the configuration file of the target page in an SSR rendering mode to obtain a rendering result.
If the server side adopts an SSR rendering mode to successfully render the configuration file of the target page and successfully return the rendering result of the target page, the server side can display the target page according to the received rendering result.
If the server fails to render the configuration file of the target page by adopting an SSR rendering mode or fails to return the rendering result of the target page, the client can receive the configuration file of the target page returned by the server and render the configuration file of the target page by the client to obtain the rendering result, so that the target page is displayed based on the rendering result of the target page.
Under the condition that the access request is not successfully sent, the client can directly determine the configuration file of the target page accessed by the access request from an external storage space (CDN) and directly render the determined configuration file of the target page, so that the target page is displayed according to the rendering result.
In some possible implementations, for each target page that the client can access, the client can modify the configuration file for each target page.
Specifically, for each target page, in response to a debug operation for the target page, a configuration file of the target is also adjusted based on the debug operation to obtain a target configuration file.
The debugging operation for each target page may be an adjustment operation for a style, a content, and a layout of the target page, or may be an operation such as upgrading a function or a code of the target page, which may be specifically determined based on an actual application scenario requirement, and is not limited herein.
In this case, the configuration file of the target page may be adjusted accordingly based on the debug operation for the target page to obtain the target configuration file.
Further, the configuration file of the target page in the external storage space may be updated based on the target configuration file, such as replacing the configuration file of the target page in the CDN with a newly determined target configuration file, and so on. The client may thus display the debugged target page the next time the target page is accessed.
When the configuration file of any target page is updated, the version information and other information of the target page can be updated together, so that the updated configuration file can be quickly determined from the external storage space next time.
Referring to fig. 7, fig. 7 is a schematic diagram of a flow frame for updating a configuration file according to an embodiment of the present application. As shown in fig. 7, if the client needs to debug a target page and issue a corresponding test version page, the client may respond to the debug operation for the target page and adjust the configuration file of the target page based on the adjust operation to obtain a target configuration file.
Under the condition that each target page is a micro front-end application, each micro front-end application can be managed based on a micro front-end large-bin architecture. The micro front end large bin architecture gathers multiple micro front end applications of the same project under a single large bin project, and development and deployment are performed under a large bin dimension instead of a single micro front end application.
Under the micro front end large bin architecture, different micro front end applications can be attributed to different functional modules and branches according to the association relation among the micro front end applications and the types of the micro front end applications, so that the management of each micro front end application is facilitated.
Under the micro front end large bin architecture, the configuration file of each micro front end application can be associated with a public dependency package (such as a public tool library and the like) required by the micro front end application, and the public dependency package is directly obtained according to the association relation between the micro front end application and the public dependency package when the configuration file of each micro front end application is debugged, so that the micro front end application is debugged quickly.
The client can update the public dependency package corresponding to each micro front-end application in real time, so that the latest public dependency package can be adopted all the time when the micro front-end application is debugged.
Based on the above, when the target page is debugged, the module and the branch of the target page under the micro front end large bin architecture can be determined, so that the target page can be quickly debugged, and a target configuration file can be obtained. The client may then upload the target configuration file to the CDN to update the original configuration file.
In the embodiment of the application, the server side can execute the rendering process based on the rendering application compatible with various running scenes, so that the server side can directly render the configuration file of the page constructed based on any technical stack and/or front-end frame based on the rendering application, a new running environment is not required to be created for the newly developed page, and the progressive upgrading of the page can be realized while the workload of software development is reduced. Under the condition that each page is a micro front-end application, independent quotation, debugging and release of different micro front-end applications can be realized through a micro front-end large bin architecture, the page management efficiency and stability are improved, and the applicability is high. For the server, when the server acquires at least one access request sent by the client, a local folder can be created for the target pages accessed by each access request in real time, and corresponding configuration files are added into the local folder from an external storage space, so that the rendering of the configuration files of a plurality of target pages can be realized at the same time, and the rendering efficiency is improved.
The rendering process related to the embodiment of the application can be realized based on Cloud Computing (Cloud Computing) Technology in the field of Cloud Technology (Cloud Technology) so as to improve rendering efficiency.
The cloud technology is a hosting technology for unifying serial resources such as hardware, software, network and the like in a wide area network or a local area network to realize calculation, storage, processing and sharing of data. Cloud computing is a computing model, and is a product of fusion of traditional computer and network technology development such as Grid computing (Grid computing), distributed computing (Distributed Computing), parallel computing (Parallel Computing), utility computing (Utility Computing), network storage (Network Storage Technologies), virtualization (Virtualization), load balancing (Load Balance), and the like. Cloud computing distributes computing tasks on a resource pool formed by a large number of computers, so that various application systems can acquire computing power, storage space and information service according to requirements. The network providing the resources is called a ' cloud ', the resources in the cloud ' are infinitely expandable and available at any time, used on demand, expanded at any time, paid for use on demand.
The process of determining the configuration file of the target page accessed by each access request from the external storage space in the embodiment of the application can be realized based on a file search model. Wherein the file lookup model may be implemented based on machine learning techniques in artificial intelligence. Artificial intelligence is the theory, method, technique and application system that uses a digital computer or a digital computer-controlled machine to simulate, extend and expand human intelligence, sense the environment, acquire knowledge and use the knowledge to obtain optimal results. In other words, artificial intelligence is an integrated technology of computer science that attempts to understand the essence of intelligence and to produce a new intelligent machine that can react in a similar way to human intelligence. Artificial intelligence, i.e. research on design principles and implementation methods of various intelligent machines, enables the machines to have functions of sensing, reasoning and decision. The machine learning is a training process of specially researching how a computer simulates or realizes the learning behavior of human beings to acquire new knowledge or skills, and reorganizing the existing knowledge structure to continuously improve the performance of the machine learning, so as to realize a file searching model capable of automatically determining configuration files.
Referring to fig. 8, fig. 8 is a schematic structural diagram of a page processing apparatus according to an embodiment of the present application. The page processing device provided by the embodiment of the application comprises:
a request acquisition module 81, configured to acquire at least one access request, and determine, from an external storage space, a configuration file of a target page accessed by each of the access requests;
a file processing module 82, configured to create a local folder corresponding to each of the target pages, and add a configuration file of each of the target pages to the corresponding local folder;
for each target page, the page rendering module 83 is configured to determine a file address of a local folder corresponding to the target page, render a configuration file in the local folder corresponding to the target page based on the file address, return a rendering result corresponding to the target page to a client accessing the target page, so that the client accessing the target page displays the target page based on the rendering result corresponding to the target page, and return the configuration file of the target page to the client accessing the target page in response to not returning the rendering result corresponding to the target page to the client accessing the target page, so that the client accessing the target page renders the configuration file of the target page and displays the target page based on the obtained rendering result.
In some possible embodiments, for each target page, the rendering result corresponding to the target page is not returned to the client accessing the target page, including at least one of the following:
the rendering of the configuration file in the local folder corresponding to the target page fails;
and successfully rendering the configuration file in the local folder corresponding to the target page, and returning the rendering result corresponding to the target page to the process interruption of the client accessing the target page.
In some possible embodiments, for each of the above access requests, the access request carries an access address and target version information of a target page accessed by the access request, where the request obtaining module 81 is configured to, when determining, from an external storage space, a configuration file of the target page accessed by the access request:
determining a configuration file corresponding to the access address from an external storage space;
responding to the version information of the configuration file corresponding to the access address and the target version information to be consistent, and determining the configuration file corresponding to the access address as the configuration file of the target page accessed by the access request;
and in response to the fact that the version information of the configuration file corresponding to the access address is inconsistent with the target version information, updating the configuration text corresponding to the access address based on the target version information, and determining the updated configuration file as the configuration file of the target page accessed by the access request.
In some possible embodiments, for each target page, when the page rendering module 83 renders the configuration file in the local folder corresponding to the target page based on the file address, the method is used to:
and transmitting the file address into a rendering application, so that the rendering application obtains the configuration file of the target page based on the file address and renders the configuration file of the target page, wherein the server side comprises a rendering frame, the rendering application is deployed in the rendering frame, and the rendering application supports the running scene of the configuration file of any target page.
In some possible embodiments, for each of the access requests, the file processing module 82 is further configured to:
and acquiring the configuration file of the target page accessed by the access request from the client corresponding to the access request in response to the fact that the configuration file of the target page accessed by the access request is not determined from the external storage space.
In a specific implementation, the device may execute an implementation manner provided by each step in fig. 2 through each built-in functional module, and specifically may refer to an implementation manner provided by each step, which is not described herein.
Referring to fig. 9, fig. 9 is another schematic structural diagram of a page processing apparatus according to an embodiment of the present application. The page processing device provided by the embodiment of the application comprises:
a request sending module 91, configured to send at least one access request, where each access request is used to enable a server to determine a file address of a local folder corresponding to a target page accessed by the access request, render a configuration file in the local folder corresponding to the target page based on the file address, determine and add the configuration file of each target page from an external storage space to the local folder corresponding to the target page by the server, and create the local folder corresponding to each target page by the server;
the page display module 92 is configured to obtain a rendering result corresponding to each target page returned by the server, display a corresponding target page based on the rendering result corresponding to each target page, and for each target page, obtain a configuration file of the target page returned by the server and render the configuration file of the target page in response to the server not returning the rendering result corresponding to the target page, and display the target page based on the obtained rendering result.
In some possible embodiments, for each target page, the rendering result corresponding to the target page is not returned to the client accessing the target page, including at least one of the following:
the rendering of the configuration file in the local folder corresponding to the target page fails;
and successfully rendering the configuration file in the local folder corresponding to the target page, and returning the rendering result corresponding to the target page to the process interruption of the client accessing the target page.
In some possible embodiments, for each of the access requests, the page display module 92 is further configured to:
responding to the failure of sending the access request, and determining a configuration file of a target page accessed by the access request from the external storage space;
and rendering the configuration file of the target page, and displaying the target page based on the obtained rendering result.
In some possible embodiments, when the request sending module 91 sends at least one access request, it is configured to:
and sending at least one access request to a proxy server so that the proxy server sends the at least one access request to the server.
In some possible implementations, the apparatus further includes a file update module, for each of the target pages, configured to:
responding to the debugging operation aiming at the target page, and adjusting the configuration file of the target page based on the debugging operation to obtain a target configuration file;
and updating the configuration file of the target page in the external storage space based on the target configuration file.
In a specific implementation, the device may execute an implementation manner provided by each step in fig. 4 through each built-in functional module, and specifically may refer to an implementation manner provided by each step, which is not described herein.
Referring to fig. 10, fig. 10 is a schematic structural diagram of an electronic device according to an embodiment of the present application. As shown in fig. 10, the electronic device 1000 in the present embodiment may include: processor 1001, network interface 1004, and memory 1005, and in addition, the electronic device 1000 may further include: an object interface 1003, and at least one communication bus 1002. Wherein the communication bus 1002 is used to enable connected communication between these components. The object interface 1003 may include a Display (Display) and a Keyboard (Keyboard), and the optional object interface 1003 may further include a standard wired interface and a wireless interface. The network interface 1004 may optionally include a standard wired interface, a wireless interface (e.g., WI-FI interface). The memory 1005 may be a high-speed RAM memory or a non-volatile memory (NVM), such as at least one disk memory. The memory 1005 may also optionally be at least one storage device located remotely from the processor 1001. As shown in fig. 10, an operating system, a network communication module, an object interface module, and a device control application may be included in the memory 1005, which is one type of computer-readable storage medium.
In the electronic device 1000 shown in fig. 10, the network interface 1004 may provide a network communication function; while object interface 1003 is primarily an interface for providing input to an object; while processor 1001 acts as a server, it may be configured to invoke the device control application stored in memory 1005 to implement:
acquiring at least one access request, and determining a configuration file of a target page accessed by each access request from an external storage space;
creating a local folder corresponding to each target page, and adding a configuration file of each target page into the corresponding local folder;
for each target page, determining the file address of the local folder corresponding to the target page, rendering the configuration file in the local folder corresponding to the target page based on the file address, and returning the rendering result corresponding to the target page to the client accessing the target page, so that the client accessing the target page displays the target page based on the rendering result corresponding to the target page; and responding to that the rendering result corresponding to the target page is not returned to the client accessing the target page, and returning the configuration file of the target page to the client accessing the target page, so that the client accessing the target page renders the configuration file of the target page and displays the target page based on the obtained rendering result.
In some possible embodiments, for each target page, the rendering result corresponding to the target page is not returned to the client accessing the target page, including at least one of the following:
the rendering of the configuration file in the local folder corresponding to the target page fails;
and successfully rendering the configuration file in the local folder corresponding to the target page, and returning the rendering result corresponding to the target page to the process interruption of the client accessing the target page.
In some possible embodiments, for each of the above access requests, the access request carries an access address and target version information of a target page accessed by the access request, and the processor 1001 is configured to:
determining a configuration file corresponding to the access address from an external storage space;
responding to the version information of the configuration file corresponding to the access address and the target version information to be consistent, and determining the configuration file corresponding to the access address as the configuration file of the target page accessed by the access request;
and in response to the fact that the version information of the configuration file corresponding to the access address is inconsistent with the target version information, updating the configuration text corresponding to the access address based on the target version information, and determining the updated configuration file as the configuration file of the target page accessed by the access request.
In some possible embodiments, for each of the target pages, the processor 1001 is configured to:
and transmitting the file address into a rendering application, so that the rendering application obtains the configuration file of the target page based on the file address and renders the configuration file of the target page, wherein the server side comprises a rendering frame, the rendering application is deployed in the rendering frame, and the rendering application supports the running scene of the configuration file of any target page.
In some possible embodiments, for each of the access requests, the processor 1001 is further configured to:
and acquiring the configuration file of the target page accessed by the access request from the client corresponding to the access request in response to the fact that the configuration file of the target page accessed by the access request is not determined from the external storage space.
When the processor 1001 acts as a client, it may be used to invoke a device control application stored in the memory 1005 to implement:
sending at least one access request, wherein each access request is used for enabling a server to determine the file address of a local folder corresponding to a target page accessed by the access request, rendering a configuration file in the local folder corresponding to the target page based on the file address, determining and adding the configuration file of each target page from an external storage space to the local folder corresponding to the target page by the server, and creating the local folder corresponding to each target page by the server;
And for each target page, responding to the rendering result which is not returned by the server and corresponds to the target page, acquiring a configuration file of the target page returned by the server, rendering the configuration file of the target page, and displaying the target page based on the obtained rendering result.
In some possible embodiments, for each target page, the rendering result corresponding to the target page is not returned to the client accessing the target page, including at least one of the following:
the rendering of the configuration file in the local folder corresponding to the target page fails;
and successfully rendering the configuration file in the local folder corresponding to the target page, and returning the rendering result corresponding to the target page to the process interruption of the client accessing the target page. In some possible embodiments, for each of the access requests, the processor 1001 is further configured to:
responding to the failure of sending the access request, and determining a configuration file of a target page accessed by the access request from the external storage space;
And rendering the configuration file of the target page, and displaying the target page based on the obtained rendering result.
In some possible embodiments, the processor 1001 is configured to:
and sending at least one access request to a proxy server so that the proxy server sends the at least one access request to the server.
In some possible embodiments, for each of the target pages, the processor 1001 is configured to:
responding to the debugging operation aiming at the target page, and adjusting the configuration file of the target page based on the debugging operation to obtain a target configuration file;
and updating the configuration file of the target page in the external storage space based on the target configuration file.
It should be appreciated that in some possible embodiments, the processor 1001 may be a central processing unit (central processing unit, CPU), which may also be other general purpose processors, digital signal processors (digital signal processor, DSP), application specific integrated circuits (application specific integrated circuit, ASIC), off-the-shelf programmable gate arrays (field-programmable gate array, FPGA) or other programmable logic devices, discrete gate or transistor logic devices, discrete hardware components, or the like. A general purpose processor may be a microprocessor or the processor may be any conventional processor or the like. The memory may include read only memory and random access memory and provide instructions and data to the processor. A portion of the memory may also include non-volatile random access memory. For example, the memory may also store information of the device type.
In a specific implementation, the electronic device 1000 may execute, through each functional module built in the electronic device, an implementation manner provided by each step in fig. 2 and/or fig. 4, and specifically, the implementation manner provided by each step may be referred to, which is not described herein again.
The embodiment of the present application further provides a computer readable storage medium, where a computer program is stored and executed by a processor to implement the method provided by each step in fig. 2 and/or fig. 4, and specifically, the implementation manner provided by each step may be referred to, which is not described herein.
The above-mentioned computer readable storage medium may be the page processing apparatus provided in any of the foregoing embodiments or an internal storage unit of the electronic device, for example, a hard disk or a memory of the electronic device. The computer readable storage medium may also be an external storage device of the electronic device, such as a plug-in hard disk, a Smart Media Card (SMC), a Secure Digital (SD) card, a flash card (flash card) or the like, which are provided on the electronic device. The computer readable storage medium may also include a magnetic disk, an optical disk, a read-only memory (ROM), a random access memory (random access memory, RAM), or the like. Further, the computer-readable storage medium may also include both an internal storage unit and an external storage device of the electronic device. The computer-readable storage medium is used to store the computer program and other programs and data required by the electronic device. The computer-readable storage medium may also be used to temporarily store data that has been output or is to be output.
Embodiments of the present application provide a computer program product comprising a computer program for executing the method provided by the steps of fig. 2 and/or fig. 4 by a processor.
The terms first, second and the like in the claims and in the description and drawings are used for distinguishing between different objects and not for describing a particular sequential order. Furthermore, the terms "comprise" and "have," as well as any variations thereof, are intended to cover a non-exclusive inclusion. For example, a process, method, system, article, or electronic device that comprises a list of steps or elements is not limited to the list of steps or elements but may, alternatively, include other steps or elements not listed or inherent to such process, method, article, or electronic device. Reference herein to "an embodiment" means that a particular feature, structure, or characteristic described in connection with the embodiment may be included in at least one embodiment of the application. The appearances of the phrase in various places in the specification are not necessarily all referring to the same embodiment, nor are separate or alternative embodiments mutually exclusive of other embodiments. Those of skill in the art will explicitly and implicitly appreciate that the embodiments described herein may be combined with other embodiments. The term "and/or" as used in the present specification and the appended claims refers to any and all possible combinations of one or more of the associated listed items, and includes such combinations.
Those of ordinary skill in the art will appreciate that the elements and algorithm steps described in connection with the embodiments disclosed herein may be embodied in electronic hardware, in computer software, or in a combination of the two, and that the elements and steps of the examples have been generally described in terms of function in the foregoing description to clearly illustrate the interchangeability of hardware and software. Skilled artisans may implement the described functionality in varying ways for each particular application, but such implementation decisions should not be interpreted as causing a departure from the scope of the present application.
The foregoing disclosure is illustrative of the present application and is not to be construed as limiting the scope of the application, which is defined by the appended claims.

Claims (15)

1. A method of page processing, the method comprising:
acquiring at least one access request, and determining a configuration file of a target page accessed by each access request from an external storage space;
creating a local folder corresponding to each target page, and adding a configuration file of each target page into the corresponding local folder;
For each target page, determining a file address of a local folder corresponding to the target page, rendering a configuration file in the local folder corresponding to the target page based on the file address, and returning a rendering result corresponding to the target page to a client accessing the target page so that the client accessing the target page displays the target page based on the rendering result corresponding to the target page; and responding to that the rendering result corresponding to the target page is not returned to the client accessing the target page, and returning the configuration file of the target page to the client accessing the target page, so that the client accessing the target page renders the configuration file of the target page and displays the target page based on the obtained rendering result.
2. The method of claim 1, wherein for each target page, the rendering result corresponding to the target page is not returned to the client accessing the target page, comprising at least one of:
the rendering of the configuration file in the local folder corresponding to the target page fails;
and successfully rendering the configuration file in the local folder corresponding to the target page, and returning the rendering result corresponding to the target page to the process interruption of the client accessing the target page.
3. The method according to claim 1, wherein for each of the access requests, the access request carries an access address and target version information of a target page accessed by the access request, and the determining a profile of the target page accessed by the access request from the external storage space includes:
determining a configuration file corresponding to the access address from an external storage space;
responding to the version information of the configuration file corresponding to the access address and the target version information to be consistent, and determining the configuration file corresponding to the access address as the configuration file of the target page accessed by the access request;
and responding to the inconsistent version information of the configuration file corresponding to the access address and the target version information, updating the configuration text corresponding to the access address based on the target version information, and determining the updated configuration file as the configuration file of the target page accessed by the access request.
4. The method according to claim 1, wherein for each target page, the rendering the configuration file in the local folder corresponding to the target page based on the file address includes:
The file address is transmitted into a rendering application, so that the rendering application obtains the configuration file of the target page based on the file address and renders the configuration file of the target page, the server side comprises a rendering frame, the rendering application is deployed in the rendering frame, and the rendering application supports the running scene of the configuration file of any target page.
5. The method of claim 1, wherein for each of the access requests, the method further comprises:
and responding to the fact that the configuration file of the target page accessed by the access request is not determined from the external storage space, and acquiring the configuration file of the target page accessed by the access request from the client corresponding to the access request.
6. A method of page processing, the method comprising:
sending at least one access request, wherein each access request is used for enabling a server to determine the file address of a local folder corresponding to a target page accessed by the access request, rendering a configuration file in the local folder corresponding to the target page based on the file address, determining and adding the configuration file of each target page from an external storage space to the local folder corresponding to the target page by the server, and creating the local folder corresponding to each target page by the server;
And acquiring a rendering result corresponding to each target page returned by the server, displaying the corresponding target page based on the rendering result corresponding to each target page, and for each target page, responding to the rendering result corresponding to the target page not returned by the server, acquiring a configuration file of the target page returned by the server, rendering the configuration file of the target page and displaying the target page based on the obtained rendering result.
7. The method of claim 6, wherein for each target page, the rendering result corresponding to the target page is not returned to the client accessing the target page, comprising at least one of:
the rendering of the configuration file in the local folder corresponding to the target page fails;
and successfully rendering the configuration file in the local folder corresponding to the target page, and returning the rendering result corresponding to the target page to the process interruption of the client accessing the target page.
8. The method of claim 6, wherein for each of the access requests, the method further comprises:
responding to the failure of sending the access request, and determining a configuration file of a target page accessed by the access request from the external storage space;
And rendering the configuration file of the target page, and displaying the target page based on the obtained rendering result.
9. The method of claim 6, wherein the sending at least one access request comprises:
and sending at least one access request to a proxy server, so that the proxy server sends the at least one access request to the server.
10. The method of claim 6, wherein for each of the target pages, the method further comprises:
responding to the debugging operation aiming at the target page, and adjusting the configuration file of the target page based on the debugging operation to obtain a target configuration file;
and updating the configuration file of the target page in the external storage space based on the target configuration file.
11. A page processing apparatus, characterized in that the page processing apparatus comprises:
the request acquisition module is used for acquiring at least one access request, and determining a configuration file of a target page accessed by each access request from an external storage space;
the file processing module is used for creating a local folder corresponding to each target page and adding the configuration file of each target page into the corresponding local folder;
And for each target page, the page rendering module is used for determining the file address of the local folder corresponding to the target page, rendering the configuration file in the local folder corresponding to the target page based on the file address, returning the rendering result corresponding to the target page to the client accessing the target page, so that the client accessing the target page displays the target page based on the rendering result corresponding to the target page, and returning the configuration file of the target page to the client accessing the target page in response to the fact that the rendering result corresponding to the target page is not returned to the client accessing the target page, so that the client accessing the target page renders the configuration file of the target page and displays the target page based on the obtained rendering result.
12. A page processing apparatus, characterized in that the page processing apparatus comprises:
the request sending module is used for sending at least one access request, each access request is used for enabling a server to determine the file address of a local folder corresponding to a target page accessed by the access request, rendering a configuration file in the local folder corresponding to the target page based on the file address, determining the configuration file of each target page from an external storage space by the server and adding the configuration file of each target page to the local folder corresponding to the target page, and creating the local folder corresponding to each target page by the server;
The page display module is used for acquiring a rendering result corresponding to each target page returned by the server, displaying the corresponding target page based on the rendering result corresponding to each target page, and for each target page, responding to the rendering result corresponding to the target page not returned by the server, acquiring a configuration file of the target page returned by the server, rendering the configuration file of the target page and displaying the target page based on the obtained rendering result.
13. An electronic device comprising a processor and a memory, the processor and the memory being interconnected;
the memory is used for storing a computer program;
the processor is configured to perform the method of any of claims 1 to 5 or the method of any of claims 6-10 when the computer program is invoked.
14. A computer readable storage medium, characterized in that the computer readable storage medium stores a computer program, which is executed by a processor to implement the method of any one of claims 1 to 10.
15. A computer program product, characterized in that the computer program product comprises a computer program which, when executed by a processor, implements the method of any one of claims 1 to 10.
CN202211406600.9A 2022-11-10 2022-11-10 Page processing method, device, equipment and storage medium Pending CN116980464A (en)

Priority Applications (1)

Application Number Priority Date Filing Date Title
CN202211406600.9A CN116980464A (en) 2022-11-10 2022-11-10 Page processing method, device, equipment and storage medium

Applications Claiming Priority (1)

Application Number Priority Date Filing Date Title
CN202211406600.9A CN116980464A (en) 2022-11-10 2022-11-10 Page processing method, device, equipment and storage medium

Publications (1)

Publication Number Publication Date
CN116980464A true CN116980464A (en) 2023-10-31

Family

ID=88481954

Family Applications (1)

Application Number Title Priority Date Filing Date
CN202211406600.9A Pending CN116980464A (en) 2022-11-10 2022-11-10 Page processing method, device, equipment and storage medium

Country Status (1)

Country Link
CN (1) CN116980464A (en)

Similar Documents

Publication Publication Date Title
CN106843828B (en) Interface display and loading method and device
US8868637B2 (en) Page rendering for dynamic web pages
CN103473696A (en) Method and system for collecting, analyzing and distributing internet business information
US11436066B2 (en) System for offline object based storage and mocking of rest responses
AU2013213683B2 (en) A method and system of application development for multiple device client platforms
CN107291744A (en) It is determined that and with the method and device of the relationship between application program
US9350738B2 (en) Template representation of security resources
US20150149888A1 (en) Systems and methods for executing aspects of a document
US11809429B2 (en) Method for processing model parameters, and apparatus
CN110225087A (en) Cloud access method, device and storage medium based on global load balancing
US20210377182A1 (en) Mobile supercloud computing system and method
CN112463808A (en) Data processing method and device of target cluster and server
US8719708B2 (en) Systems and methods for dynamic historical browsing
CN116980464A (en) Page processing method, device, equipment and storage medium
CN115811481A (en) Interactive service testing method and device, computer equipment and storage medium
RajKumar et al. Integrated educational information systems for disabled schools via a service bus using SOA
CN111581578A (en) Interface request processing method and device
CN113900959B (en) Software testing method, device, equipment and storage medium
CN117076401A (en) Container file transmission method, device, equipment and storage medium
US10936794B2 (en) High-performance web-based cloud services system and method using data link redirection
Luu et al. Spark Streaming
Mrozek et al. Azure Cloud Services
KR20240067674A (en) Container-based dynamic workload processing system, apparatus and method considering data local information
CN118748674A (en) Asynchronous file downloading method, device and equipment
CN117914721A (en) Java-based call substitute service system construction method and device

Legal Events

Date Code Title Description
PB01 Publication
PB01 Publication