Electronic device for controlling execution of web application and operation method thereof
By pre-connecting with web servers before execution, the electronic device minimizes startup delays of web applications on smart TVs, improving performance in diverse network environments.
Patent Information
- Application Number
- PCT/KR2025/008100
- Authority / Receiving Office
- WO · WO
- Patent Type
- Applications
- Current Assignee / Owner
- Priority Date
- 2024-08-07
- Filing Date
- 2025-06-12
- Publication Date
- 2026-02-12
AI Technical Summary
Smart TVs experience delayed application execution due to slow internet speeds, which diminishes their value in environments with suboptimal connectivity.
An electronic device performs pre-connection with web servers included in a pre-connection server list before initiating web application execution, establishing communication channels in parallel with initialization operations to expedite resource retrieval.
This approach reduces the startup time of web applications by allowing immediate data transmission and reception from pre-connected servers, enhancing the performance of smart TVs in varying network conditions.
Smart Images

Figure KR2025008100_12022026_PF_FP_ABST
Abstract
Description
Electronic device for controlling execution of web application and method of operation thereof
[0001] The present disclosure relates to an electronic device for controlling the execution of a web application and a method of operating the same.
[0002] Web applications are software programs accessible through a web browser. Web applications can run over the Internet. They can provide various services based on the interaction between a server and a client. For example, when you access a web address (e.g., a website) through a browser, the website's web server may provide the corresponding web application. The web application displays a screen provided by the web server, and when you select a function (e.g., an icon) displayed on the screen or enter values into an input field, the data is transmitted back to the web server.
[0003] Web applications are used in various forms, including portal sites, online shopping malls, social networks, e-mail services, and video streaming platforms.
[0004] Recently, a variety of smart TVs (also known as Internet TVs) have been released, allowing users to connect to the Internet and view a variety of digital content. Unlike conventional TVs, smart TVs can run a variety of applications, including an operating system and a web browser. Web applications are a prime example.
[0005] Smart TVs can be used to install and use a variety of web applications, allowing access to movies, TV shows, news, live streaming services, games, and more. However, because many web applications rely on an internet connection, smart TVs can be significantly affected by internet speeds. In environments with slow internet speeds, application execution can be delayed, which can diminish the value of smart TVs.
[0006] An electronic device according to one embodiment of the present disclosure comprises: a communication module; a memory storing at least one program; and at least one processor electrically connected to the memory and executing at least one command of the program stored in the memory, wherein the at least one processor: performs at least one initialization operation for executing the first web application through a first thread in response to a start request of the first web application, while performing a pre-connection to at least one web server included in a first pre-connection server list corresponding to the first web application through a second thread operating in parallel with the first thread.
[0007] In one embodiment, the pre-connection may enable a communication connection to be established to the at least one web server before a web resource request to the at least one web server is made.
[0008] A method of an electronic device according to another embodiment of the present disclosure may include an operation of performing a pre-connection to at least one web server included in a first pre-connection server list corresponding to the first web application through a second thread operating in parallel with the first thread while the processor of the electronic device performs at least one initialization operation for executing the first web application through a first thread in response to a start request of the first web application.
[0009] In one embodiment, the pre-connection may enable a communication connection to be established to the at least one web server before a web resource request to the at least one web server is made.
[0010] In connection with the description of the drawings, the same or similar reference numerals may be used for the same or similar components.
[0011] FIG. 1 illustrates an electronic device and web servers according to one embodiment.
[0012] FIG. 2 is an example of a web application start screen of an electronic device according to one embodiment.
[0013] FIG. 3 is an example of a list of pre-connected servers of a web application, according to one embodiment.
[0014] FIG. 4 is a flowchart of an operation of an electronic device controlling the start execution of a web application according to one embodiment.
[0015] FIG. 5 is a flowchart of operations of multiple threads upon startup of a web application of an electronic device, according to one embodiment.
[0016] FIG. 6 is an example of network thread operation upon startup of a web application in an electronic device, according to one embodiment.
[0017] FIG. 7 is an example of data communication time between an electronic device (101) and a web server according to one embodiment.
[0018] FIG. 8 is another example of network thread operation upon startup of a web application in an electronic device, according to one embodiment.
[0019] FIG. 9 is an example of an operation of an electronic device storing a list of pre-connected servers for a web application, according to one embodiment.
[0020] FIG. 10 is a flowchart of an operation of an electronic device processing a URL request of a web application according to one embodiment.
[0021] FIG. 11 is an example of updating a pre-connection server list for a web application in an electronic device, according to one embodiment.
[0022] FIG. 12 is a block diagram including components of an electronic device according to one embodiment.
[0023] Hereinafter, embodiments of the present disclosure will be described in detail with reference to the drawings so that those skilled in the art can easily implement the present disclosure. However, the present disclosure may be implemented in various different forms and is not limited to the embodiments described herein. In connection with the description of the drawings, the same or similar reference numerals may be used for identical or similar components. Furthermore, in the drawings and related descriptions, descriptions of well-known functions and configurations may be omitted for clarity and conciseness.
[0024] An embodiment of the present disclosure is described below with reference to the attached drawings.
[0025] FIG. 1 illustrates an electronic device and web servers according to one embodiment.
[0026] According to one embodiment, an electronic device (101) may include one or more web applications and may be connected to web servers via a wireless communication network (102). A web application is a software application that can be accessed and used via a web browser. The web application is based on a client-server model, and a client device (e.g., the electronic device (101)) may access an application hosted on a server (e.g., web servers 103a, 103b, 103c, 103d) via a web browser to use various functions. For example, a web application that provides over-the-top (OTT) content may provide various types of content (e.g., movies, dramas, sports, or games) to the electronic device (101), which is a client device, by using one or more web servers (e.g., Apache HTTP server, Nginx, LiteSpeed, Caddy, or Microsoft Internet Information Services).
[0027] According to one embodiment, the electronic device (101) may be a display device such as a TV, but is not limited thereto. For example, the electronic device (301) may be a mobile device, a wearable device, a tablet, a desktop, a laptop, or a game console.
[0028] According to one embodiment, a web server (103a, 103b, 103c, or 103d) may receive a web resource request from a client device (e.g., electronic device (101)) based on a communication protocol that supports a web browser, and may transmit the corresponding web resource to the client device (101) in response to the request.
[0029] According to one embodiment, a web resource may be defined by a protocol used to communicate with a web browser. The types of web resources may include, for example, hypertext markup language (HTML) files, cascading style sheets (CSS) files, JavaScript files, image files, video files, audio files, document files, icon files, font files, asynchronous JavaScript and XML (AJAX) requests, or application programming interface (API) endpoints. Some web resources may include requests for one or more other web resources. For example, an HTML file may further include at least one of an image file, a document file, or a font file.
[0030] According to one embodiment, the types of communication protocols supported by the web browser may include Hypertext Transfer Protocol (HTTP), Hypertext Transfer Protocol Secure (HTTPS), File Transfer Protocol (FTP), Secure File Transfer Protocol (SFTP), WebSocket, HTTP / 2, or HTTP / 3. The types of communication protocols may be added as communication technology develops, and the specifications of the communication protocols may be changed, added, or deleted as communication technology develops.
[0031] According to one embodiment, the electronic device (101) may establish a communication channel with at least one of the web servers (103a to 103d) based on a protocol (e.g., HTTPS) that supports a web browser using a communication interface while executing a web application, and may perform data communication (e.g., web resource request or web resource transmission / reception) through the established communication channel. Depending on the communication environment of the wireless network (102), if the communication connection speed with the web server is slow, the execution speed of the web application may also be affected.
[0032] According to one embodiment, in order to stably execute a web application even in various wireless network (102) environments, the electronic device (101) may perform a communication connection in advance with at least some of at least one web server corresponding to at least one web resource request before at least one web resource request required for launching the web application occurs. For example, the electronic device (101) may parse a first web resource (e.g., a Home URL request) corresponding to the start screen of the first web application upon launching the first web application, and render the start screen of the first web application. The electronic device (101) may initiate a pre-connection with at least some of the at least one web server prior to parsing the first web resource, in response to at least one web resource request extracted while parsing the first web resource. In the present disclosure, establishing a communication connection only with web servers included in a pre-connection list before retrieving or parsing a web resource may be referred to as a “pre-connection.” Preconnection can be performed to pre-establish a network layer connection with a web server without downloading or parsing the actual resources, and can also be distinguished from prefetching or preloading, which pre-fetch resources.
[0033] An electronic device (101) according to an embodiment of the present disclosure is not limited by the type or standard of a communication protocol, and can perform pre-connection to some web servers regardless of the type or standard of the communication protocol. In response to the start of a web application, the electronic device (101) can pre-establish a communication connection only to at least one web server included in a pre-connected web server list, and then, in response to a web resource request for an already connected web server, can immediately receive a web resource from the corresponding web server. Before a web resource request is extracted, the electronic device (101) can establish a communication channel in advance with the web server corresponding to the web resource. During the launching process according to the previous start of the web application, the electronic device (101) can store the web servers that issued the web resource request in a pre-connected web server list. The electronic device (101) can perform pre-connection using the pre-connected web server list stored by the previous start at the next start of the web application.
[0034] According to one embodiment, an electronic device (101) may include one or more web applications, and the web applications may request or transmit / receive web resources with one or more web servers based on a protocol that supports a web browser. In the present disclosure, for convenience of explanation, "web resource request or web resource transmission / reception" may be referred to as "data communication." A "communication connection" with a web server may refer to "establishing a communication channel between a web server and a client device" prior to data communication. The electronic device (101) performing a "pre-connection" to some web servers may refer to establishing only a communication connection to the first web server before a web resource request to the first web server is generated. The web resource request may be extracted by parsing a Home URL request that is called upon the start of a web application.
[0035] According to one embodiment, after performing a pre-connection, the electronic device (101) can immediately request / receive a web resource without a communication connection process (already performed) for a web server that is already connected to the communication connection at the time of processing the web resource request.
[0036] FIG. 2 is an example of a web application start screen of an electronic device according to one embodiment.
[0037] According to one embodiment, the electronic device (101) may include one or more web applications and display a start screen in response to the execution of each web application. The start screen may be a single web resource. For example, the start screen may be written in HTML format. In response to the launch of each web application, the electronic device (101) may parse a designated web resource and display a start screen.
[0038] Referring to FIG. 2, the electronic device (101) can output a first screen (210) including a plurality of icons (211 to 216) corresponding to a plurality of applications (App1 to App6) through a display. The types of applications may vary, and at least some of the plurality of applications may be web applications. For example, the first application (App1) may be a web application.
[0039] According to one embodiment, in response to a request (e.g., click) for execution of a first icon (211) corresponding to a first application (App1), the electronic device (101) may start execution of the first application (App1). According to one embodiment, the electronic device (101) may perform various initializations as a series of operations for starting execution of the first application (App1), and when the initialization is completed (launch completed), may output a second screen (220) including a user interface. The second screen may be referred to as a start screen or home screen of the first application (App1).
[0040] The second screen (220) may be determined by a default web resource (e.g., a Home URL request) designated in response to the first application (App1). The default web resource for each application may be created and modified by the developer who created and distributed the application.
[0041] The second screen (220) may include various user interfaces corresponding to various functions of the first application (App1), and corresponds to a start screen that is in a standby state waiting for user input in response to an execution request of the first application.
[0042] Referring to FIG. 2, the second screen (220) may include a plurality of distinct areas. For example, the second screen (220) may include a first portion (221) that displays icons corresponding to a menu, a second portion (222) that displays a preview of the first content, a third portion (223) that displays advertisements, or a fourth portion (224) that displays icons corresponding to the content. Some of these may include a user interface. Some of these may perform data communication with a web server through a web resource request to perform rendering for the corresponding portion. For example, icons of the first portion (221) (e.g., search, home screen movement, movie content display, user switching) may perform specific functions in response to user input. The second portion (222) may correspond to a function of playing the first content in response to user input. The first content may be received from a web server through a web resource request that requests the first content from the web server. The third section (223) may correspond to a function of moving to a product homepage or product sales page corresponding to the displayed advertisement. The fourth section (224) may include icons (2241, 2242, 2243) corresponding to contents, and may provide a function of playing contents corresponding to the selected icon in response to a user input selecting each icon. Each content may be received from each web server by each web resource request. For the first content corresponding to the first icon (2241) highlighted among the icons displayed in the fourth section (224), a preview photo or video of the first content may be displayed in the second section (222). The contents and corresponding icons displayed through the fourth section (224) may be changed, and may be configured to display the next or previous item in response to a user input.
[0043] In one embodiment, while displaying a start screen (e.g., a second screen (220)) in response to a request to start execution of a web application (e.g., a first application (App1)), the electronic device (101) may perform data communication with at least one web server based on one or more web resource requests included in a basic web resource (e.g., a Home URL request). A series of control operations for executing the web application and displaying the start screen may be composed of commands programmed by the manufacturer who created and distributed the web application. For example, the basic web resource may be written as an HTML file for displaying the start screen of the web application, and the HTML file may further include one or more web resources, each of which may perform data communication with a web server. According to one embodiment, the electronic device (101) may control the execution (initial execution) of the web application in addition to the control operations determined in response to the execution of the web application. For example, the electronic device (101) may perform a communication connection in advance before a web resource request occurs to at least one web server that performed data communication in a previous start execution while executing a web application to display a start screen, and may receive a web resource from the pre-connected web server in response to the occurrence of a web resource request.
[0044] FIG. 3 is an example of a list of pre-connected servers of a web application, according to one embodiment.
[0045] According to one embodiment, the electronic device (101) may store and manage information about one or more web servers accessed while displaying a start screen including a user interface in response to the start execution of a web application (hereinafter, referred to as a pre-connected server list).
[0046] Referring to FIG. 3, an electronic device (101) according to one embodiment may display a start screen by parsing a basic web resource (e.g., a home page (home URL)) in response to the start execution of a first web application. The start screen (home screen) may be a single screen or may be multiple screens displayed consecutively without user input. For example, the electronic device (101) may display a first page (310a) and a second page (310b) consecutively at a predetermined time interval (e.g., 2 seconds) without user input.
[0047] In one embodiment, the web server accessed by the web application may vary in type and configuration. For example, the web server may provide content, provide security-related functions, provide technical backend services, manage configuration files / settings, etc., provide user authentication, login management, account management, etc., monitor and manage errors, or host or manage software development kit (SDK) configuration files. In various embodiments, the start screen of the web application may include various web resources through data communication with various types of web servers.
[0048] According to one embodiment, the electronic device (101) may perform data communication with a first web server (103a) and a second web server (103b) based on web resource requests extracted while parsing a first page (310a). According to one embodiment, the electronic device (101) may, after parsing the first page (310a), identify a second page (310b) referenced from the first page (310a). According to one embodiment, the electronic device (101) may perform data communication with a third web server (103c) based on web resource requests extracted while parsing a second page (310b).
[0049] According to one embodiment, the electronic device (101) may store the first web server (103a), the second web server (103b), and the third web server (103c) accessed while parsing the first page (310a) and the second page (310b) in a pre-connected server list (330) for the first web application.
[0050] According to one embodiment, the electronic device (101) may store a pre-connected server list (330) in memory. According to one embodiment, the memory may be a separate storage device or non-volatile memory so that the pre-connected server list can be maintained even when the execution of the first web application is terminated.
[0051] According to one embodiment, the electronic device (101) can minimize the start execution time of a web application based on a pre-connection server list (330) for the web application. According to one embodiment, in response to a start execution request of a web application, the electronic device (101) can check the pre-connection server list (330) before a request (URL request) to a web server is generated, and can communicate and connect with web servers in advance. As part of the process of requesting a web resource, the URL request can perform an operation of retrieving data from a web server or transmitting data to the web server using a specific URL (uniform resource locator). In the present disclosure, the URL request may be referred to as a web resource request.
[0052] According to one embodiment, the electronic device (101) can immediately transmit and receive data from a pre-connected web server in response to a request to the web server, thereby reducing the overall startup execution time of the web application.
[0053] According to one embodiment, the electronic device (101) may include one or more web applications, and may separately store and manage a list of pre-connected servers for each web application. The basic web resources of the web application (e.g., web resources for the start screen) may be defined and modified by the developer who creates and distributes the web application. For example, the advertising content included in the start screen of the first web application may be updated every advertising contract cycle, and the real-time broadcast content included in the start screen of the first web application may be updated according to the scheduled sports event schedule. In various cases, a portion of the start screen of the web application may be modified. According to one embodiment, the electronic device (101) may update and manage the list of pre-connected servers for every start execution of the web application.
[0054] FIG. 4 is a flowchart of an operation of an electronic device controlling the start execution of a web application according to one embodiment.
[0055] According to one embodiment, the electronic device (101) may control at least one operation included in the start execution of the web application in response to a request to start the web application. Hereinafter, with reference to FIG. 4, a series of operations of the electronic device (101) according to a user input for the execution of the first web application will be described. As an example, the description of each operation of FIG. 4 may be described with reference to FIG. 3 as well.
[0056] Referring to FIG. 4, in operation S410, an electronic device (101) according to one embodiment may connect to a home page (Home URL) corresponding to the first web application in response to a start request of the first web application. The home page is intended to display a home screen (or, start screen), and the home screen may represent an initial basic screen of the first web application in a user input waiting state.
[0057] According to one embodiment, the electronic device (101) can perform operations S420 and S430 simultaneously through parallel processing. For example, in response to a first web application execution request, the electronic device (101) can create a browser thread and a network thread, respectively, and cause the browser thread to perform operation S430, and cause the network thread to perform operation S420.
[0058] In operation S420, the electronic device (101) according to one embodiment can check the pre-connection list for the first web application in the memory. If the pre-connection list exists, the electronic device (101) can initiate a communication connection to a web server within the pre-connection list (operation S421). If the pre-connection list for the first web application does not exist or the pre-connection list does not contain web server information, the electronic device (101) can terminate the operation for the web server pre-connection. For example, the electronic device (101) can check the pre-connection list (300) for the first web application, and the pre-connection list (330) can include a first web server (103a), a second web server (103b), and a third web server (103c).
[0059] In operation S421, an electronic device (101) according to one embodiment may initiate a communication connection to at least one web server based on a pre-connection list of the first web application. According to one embodiment, the pre-connection process may only establish data communication without a request for transmitting or receiving data (web resources) between the electronic device (101) and the web server. For example, when communicating with a web server based on the HTTPS protocol, the electronic device (101) may perform domain address verification (e.g., domain name service (DNS) lookup), communication connection verification (e.g., transmission control protocol (TCP) handshake), and communication security connection (e.g., transport layer security (TLS)) for web servers on the pre-connection list. According to one embodiment, after performing a pre-connection to a web server, the electronic device (101) may immediately respond to a URL request for the corresponding web server based on parsing of the basic web resource (Home URL), thereby providing a state in which data can be immediately transmitted and received. For example, the electronic device (101) may perform a communication connection to a first web server (103a), a second web server (103b), and a third web server (103c). According to one embodiment, the electronic device (101) may establish a communication channel with a web server in advance for data transmission and reception.
[0060] In operation S430, the electronic device (101) according to one embodiment may parse a web resource (e.g., a page) for a Home URL. Some types of web resources may include requests for other web resources. Additional URL requests may occur while the electronic device (101) parses the web resource. For example, referring to FIG. 3 , while the electronic device (101) parses a first page (310a), web resource requests (URL requests) for a first web server (103a) and a second web server (103b) may occur sequentially.
[0061] In operation S440, the electronic device (101) according to one embodiment can detect whether another web resource request (URL request) occurs while parsing a web resource.
[0062] In operation S450, when a URL request occurs, the electronic device (101) according to one embodiment can check whether a web server corresponding to the requested URL request is currently connected. The electronic device (101) according to one embodiment can check whether a web server corresponding to the requested URL request is included in a pre-connection server list. For example, referring to FIG. 3, when a URL request for a third web server (103c) occurs on a second page (310b), the electronic device (101) according to one embodiment can check whether the third web server (103c) is included in the pre-connection server list (330) to check the current connection state. The electronic device (101) according to one embodiment can check whether a web server corresponding to the requested URL request is currently connected through a communication module.
[0063] In operation S460, the electronic device (101) according to one embodiment can transmit and receive data (e.g., web resources) directly from a web server corresponding to the requested URL request if the web server is currently connected.
[0064] In operation S451, the electronic device (101) according to one embodiment may initiate a communication connection to a web server corresponding to the requested URL request if the web server is not currently connected. For example, when the electronic device (101) establishes a communication connection with the web server based on the HTTPS protocol, the electronic device (101) may perform a DNS lookup, TCP handshake, and TLS process for the web server. Thereafter, the electronic device (101) may transmit and receive data from the web server (operation S460).
[0065] In operation S470, the electronic device (101) according to one embodiment parses the resources required for connection to the home URL, obtains all data required for rendering the home screen from web servers, and when the initialization process for the first web application is completed, the electronic device can display the home screen (start screen) through the display.
[0066] FIG. 5 is a flowchart of operations of multiple threads upon startup of a web application of an electronic device, according to one embodiment.
[0067] According to one embodiment, the electronic device (101) or the processor (hereinafter, “processor”) of the electronic device (101) may create a plurality of threads in response to a start request for a web application and control the plurality of threads to perform various initialization operations related to the web application, respectively. Hereinafter, with reference to FIG. 5, an embodiment in which the processor of the electronic device (101) performs an initialization operation by executing a web application will be described.
[0068] In operation 501, the processor may control the creation of a browser thread (510), a network thread (520), and a renderer thread (530) in response to a launch request of a web application to perform various initialization operations required for executing the web application. Since each thread (510, 520, 530) performs work in parallel, more than one thread may be executing at the same time.
[0069] At operation 511, the processor may control the browser thread (510) to initiate initialization operations related to the browser. In one embodiment, the browser thread (510) may perform a series of operations to launch an Internet web browser (e.g., a home URL) corresponding to the web application. For example, the browser thread (510) may perform various initializations related to the web application, web engine initialization, and web application window settings.
[0070] At operation 521, the processor may control a network thread (520) to be created (forked) from a browser thread (510) and to initiate an initialization operation related to a network. According to one embodiment, the network thread (520) may, in response to a web resource request (e.g., a URL request), communicate with a web server corresponding to the web resource request to receive data (e.g., a web page). When the network thread (520) completes the initialization operation predetermined by operation 521, the network thread (520) may enter a waiting state (network idle) until receiving another web resource request (e.g., a URL request).
[0071] At operation 531, the processor may control the browser thread (510) to fork a renderer thread (530) and initiate initialization operations related to rendering. According to one embodiment, the renderer thread (530) may perform operations for parsing a page (web resource) received from a web server and displaying it on the screen. The renderer thread (530) may request a network thread (520) if there is a new URL request while parsing the page.
[0072] At operation 522, the network thread (520) enters a waiting state (T) after the network initialization operation is completed. network_Idle ), a pre-communication connection can be established for one or more web servers included in the pre-connection server list corresponding to the web application. For example, when the network thread (520) communicates with a web server based on the HTTPS protocol, the network thread (520) can only perform DNS lookup, TCP handshake, and TLS processes in advance for the first web server included in the pre-connection server list. Since the network thread (520) only establishes a communication connection without transmitting or receiving data with the web server, it can perform a communication connection with a plurality of web servers in a relatively short time. According to one embodiment, the network thread (520) enters a data transmission / reception standby state with the web server connected to the communication, and when a web resource request (e.g., URL request) for the web server is received, the network thread (520) can immediately transmit and receive data (e.g., web resource). However, in the case of a pre-connection, since there is no data transmission / reception request, unlike a URL request by page parsing, the network thread (520) only performs a communication connection with the web server, and the data transmission / reception operation is not included in the operation 522.
[0073] In operation 523, the browser thread (510) may request a home screen (or, may be referred to as a home page) corresponding to the web application to the network thread (520) during the browser initialization operation (Home URL request).
[0074] In operation 524, the network thread (520) may receive data (home page) from the home web server in response to the home screen request. According to one embodiment, the network thread (520) may transmit the received home page to the renderer thread (530) (operation 532). According to one embodiment, when the data transmission and reception with the home web server is completed, the network thread (520) returns to the network waiting state (T network_Idle ) can be. Since the work of each thread is parallel, if the network thread (520) receives a home URL request by operation 523 before the communication connection to the web servers included in the pre-connection server list is completed in operation 522, the communication connection to some of the web servers included in the pre-connection server list may not be established. In this case, the network thread (520) can continue to perform the pre-communication connection work for the web servers remaining in the pre-connection server list after operation 524.
[0075] At operation 532, the renderer thread (530) may parse the received home page. In one embodiment, if there is an additional URL request while the renderer thread (530) is parsing the home page, the renderer thread (530) may request the network thread (520) (operation 525).
[0076] In operation 525, the network thread (520) may, in response to receiving an additional URL request, establish a communication connection with the web server corresponding to the additional URL if the web server is included in the pre-connected server list, thereby establishing a data transmission and reception state. According to one embodiment, the network thread (520) may receive data (additional page) from the web server corresponding to the additional URL and transmit it to the renderer thread (530) (operation 533).
[0077] At operation 533, the renderer thread (530) may parse the received additional page. In one embodiment, once parsing of the additional page is completed, the renderer thread (530) may continue parsing the remainder of the home page (operation 532).
[0078] At operation 534, the renderer thread (530) may compose (render) the home screen based on the received resources to display the home screen once parsing for the home page is completed.
[0079] At operation 512, the browser thread (510) may display the home screen through the browser once rendering for the home screen is completed.
[0080] According to one embodiment, when a home screen (start screen) is displayed in response to a start request from a web application, initialization may be completed (operation 505).
[0081] At step 513, the browser thread (510) may be placed in a state waiting for a user input request. In one embodiment, the start screen may include various user interfaces and may execute various functions in response to user input.
[0082] FIG. 6 is an example of network thread operation upon startup of a web application in an electronic device, according to one embodiment.
[0083] Hereinafter, with reference to FIG. 6, a series of operations performed by a network thread (520) in response to a start request for a web application in an electronic device (101) according to one embodiment will be described. As an example, the description of each operation in FIG. 6 may be described with reference to FIG. 3 and FIG. 5 together.
[0084] A network thread (520) according to one embodiment may be generated by a processor of an electronic device (101). The network thread (520) may perform a series of tasks related to network initialization in response to a start request of a first web application. While parsing the home page of the first web application (e.g., the first page (310a) of FIG. 3) in the renderer thread (530), one or more URL requests (e.g., the second web server (103b) of FIG. 3, the third web server (130c) of FIG. 3, the second page (310b) of FIG. 3) may be identified. The network thread (520) may receive and process one or more URL requests from the renderer thread (530).
[0085] In steps 611, 612, and 613, the network thread (520) may initiate a pre-connection with the first web server, the second web server, and the third web server included in the first pre-connection server list (330) corresponding to the first web application at the creation time (T0). For example, when communicating with a web server based on the HTTPS protocol, the network thread (520) may perform DNS lookup, TCP handshake, and TLS operations to establish a communication connection with the first web server, the second web server, and the third web server.
[0086] FIG. 7 is an example of data communication time between an electronic device (101) and a web server according to one embodiment.
[0087] According to one embodiment, the communication time between the electronic device (101) and the web server is the connection time (T c ) and data transmission time (T d ) can be distinguished. Communication connection time (T c ) refers to the time it takes for an electronic device (101) to complete connection setup to start communication with a web server, and may include, for example, network connection setup, TCP / IP connection setup, SSL / TLS handshake, etc. when communicating with a web server based on the HTTPS protocol. Data communication time (T d ) refers to the time from when the connection is established until actual data transmission occurs, and may include the time it takes for data packets to be sent, received, and processed.
[0088] According to one embodiment, the communication time (710) between the electronic device (101) and the first web server is a communication connection time (T) including DNS, TCP, and TLS operation times when communicating with the web server based on the HTTPS protocol. c ) and data communication time (T) for data communication with the first web server by URL request d1 ) can be distinguished. According to one embodiment, the communication time (720) between the electronic device (101) and the second web server is a communication connection time (T ) including DNS, TCP, and TLS operation times when communicating with the web server based on the HTTPS protocol. c ) and data communication time (T) for communicating data with the second web server by URL request d2 ) can be distinguished. According to one embodiment, the communication time (730) between the electronic device (101) and the third web server is a communication connection time (T ) including DNS, TCP, and TLS operation times when communicating with the web server based on the HTTPS protocol. c) and data communication time (T) for communicating data with a third-party web server by URL request d3 ) can be distinguished.
[0089] According to one embodiment, the data communication time (T) between the electronic device (101) and each web server d1 , T d2 , T d3 ) may be different from each other because they are proportional to the amount of each data (e.g., page). It may be partially affected by the network communication environment or the delay time of the web server, but compared to the data communication times, the communication connection time (T) between the electronic device (101) and each web server c ) can be substantially identical.
[0090] According to one embodiment, the communication connection time (T c ) are data communication times (T d1 , T d2 , T d3 ) can be relatively shorter than the network thread (520). When the network thread (520) is busy, the relatively short communication connection time (T c ) can also be a burden on the network, and the communication connection time (T c ) can have a significant impact on subsequent operations (e.g. parsing, rendering) after the communication connection is established.
[0091] Referring back to FIG. 6, in operations 611, 612, and 613, the network thread (520) generated by the processor of the electronic device (101) may initiate a pre-connection with web servers included in the first pre-connection server list. According to one embodiment, the network thread (520) may pre-establish a communication connection to the first web server included in the first pre-connection server list immediately at a time point (T0) generated by the start of the first web application (operation 611). Before a first URL request to the first web server occurs, the network thread (520) may complete the communication connection to the first web server. The network thread (520) may immediately establish data communication with the first web server at a time point (T1) at which the first URL request to the first web server occurs.
[0092] In one embodiment, a URL request may be received from at least one of a browser thread (510) or a renderer thread (530) that is working in parallel with a network thread (520).
[0093] In operation 621, the network thread (520) is already in a communication connection with the first web server, so it can immediately receive data in response to the first URL request (T d1 within the time).
[0094] In operation 622, the network thread (520) is already in a communication connection with the second web server, so it can immediately receive data in response to the second URL request (T d2 within the time).
[0095] In operation 623, the network thread (520) is already in a communication connection with the third web server, so it can immediately receive data in response to the third URL request (T d3 within the time).
[0096] The initialization of the first web application can be completed within the initialization time Tn. According to one embodiment, in response to a URL request, the data communication time (T d1 , T d2 , T d3 ) can have the effect of reducing the overall initialization time (T0~Tn) of the first web application.
[0097] FIG. 8 is another example of network thread operation upon startup of a web application in an electronic device, according to one embodiment.
[0098] Hereinafter, with reference to FIG. 8, a series of operations performed by a network thread (520) in response to a start request for a web application in an electronic device (101) according to one embodiment will be described. For convenience of explanation, the description will focus on differences from the embodiment described in FIG. 6.
[0099] Referring to FIGS. 6 and 8 together, in operations 811, 812, and 813, an electronic device (101) according to an embodiment may perform pre-connection to a first web server, a second web server, and a third web server included in a first pre-connection server list corresponding to the first web application in response to a start request of the first web application. Operations 811, 812, and 813 may be described corresponding to operations 611, 612, and 613 of FIG. 6, respectively.
[0100] In operation 821, according to one embodiment, the network thread (520) may perform data communication directly with the first web server with which communication is already connected in response to the first URL request (T d1 ). Actions 821 and 822 can be described as corresponding to actions 621 and 622 of FIG. 6, respectively.
[0101] In operation 823, according to one embodiment, the network thread (520) may receive a fourth URL request at a third time point (T3) before data reception with the second web server is completed. The network thread (520) may execute a series of tasks according to the fourth URL request after operation 822 is completed. According to one embodiment, after data reception with the second server is completed (T3'), the network thread (520) may identify a fourth web server corresponding to the fourth URL request and establish a communication connection with the fourth web server (T c ) When the network thread (520) is connected to the fourth web server, it can receive data from the fourth web server (T d4 ). For example, when the network thread (520) communicates with a web server based on the HTTPS protocol, it may sequentially perform DNS lookup, TCP handshake, TLS, and data reception tasks for the fourth web server. According to one embodiment, since the fourth URL request is not included in the first pre-connection server list, a communication connection to the fourth web server could not be established in the network standby state.
[0102] In operation 824, according to one embodiment, the network thread (520) may receive a third URL request at a fourth time point (T2) before the data reception with the second web server by operation 823 is completed. The network thread (520) may execute a series of tasks according to the third URL request after the completion of operation 823. According to one embodiment, the network thread (520) may start tasks for processing the third URL request after operation 823 is completed (T4'). According to one embodiment, the network thread (520) may, in response to the third URL request, immediately perform data communication with the third web server with which it is already communicating (T d3 ). Action 824 can be described in correspondence to action 623 of FIG. 6.
[0103] Unlike FIG. 6, FIG. 8 illustrates that the initialization time (Tm) of the first web application may take longer than the initialization time (Tn). Referring to FIG. 8, in addition to the simple addition of URL requests to be processed, delays may also occur during the process of processing the added URL requests. In one embodiment, even though parallel processing is possible between threads, if there is a delay in the interaction between threads, the overall initialization time may increase. For example, if there is a delay in loading a URL page in the network thread (520), parsing the URL page in the renderer thread (530) may also be delayed.
[0104] FIG. 9 is an example of an operation of an electronic device managing a list of pre-connected servers for a web application, according to one embodiment.
[0105] Hereinafter, with reference to FIG. 9, an operation (operations 931 to 934) for managing a list of pre-connected servers will be described based on a step (operations 911 to 917) in which an electronic device (101) or a processor (hereinafter, “processor”) of the electronic device (101) performs a series of operations for displaying a home page in response to a start request of a web application according to an embodiment. The processor according to an embodiment can process at least some of operations 911 to 917 and operations 931 to 934 in parallel through a plurality of threads.
[0106] In one embodiment, the processor may store information about the web servers accessed in a pre-connected server list while displaying the home page in response to a start request of the first web application. At least a portion of the start screen of the first web application may change over time. For example, the start screen of the first web application may be updated by the developer who creates and distributes the web application. In one embodiment, the processor may check whether the pre-connected server list of the first web application is updated every time the first web application is started.
[0107] In operation 911, according to one embodiment, the processor may start a first web application.
[0108] In operation 931, according to one embodiment, the processor may load a first pre-connection server list (URL Info) pre-stored in memory at the beginning of the first web application startup through a thread (e.g., a network thread) separate from the thread (e.g., a browser thread) performing operation 911. The first pre-connection server list may include information (URL requests) about web servers accessed during an initialization step in a previous execution of the first web application. The processor may initiate a pre-connection based on the first pre-connection server list. The pre-connection server list may be stored separately for each web application and may be included in a non-volatile memory or storage medium.
[0109] In operation 912, according to one embodiment, the processor may process a request for a home URL corresponding to a first web application. The processor may receive a home page (home screen or start screen) from a home web server corresponding to the home URL and parse it.
[0110] In operation 913, according to one embodiment, the processor may perform a series of tasks for creating a home browser (WRT (web rendering thread) Browser Context) through a browser thread, a network thread, or a renderer thread.
[0111] In operation 932, according to one embodiment, the processor may apply pre-connection to web servers included in the first pre-connection server list via a network thread (apply pre-connect URL). For example, the processor may attempt pre-connection to web servers included in the first pre-connection server list loaded via an idle network thread immediately after the browser context is created by the browser thread.
[0112] In operations 914 and 915, according to one embodiment, the processor may sequentially receive and process web resource requests (a first URL request and a second URL request). Web servers corresponding to the first URL request and the second URL request may be included in a first pre-connected server list. According to one embodiment, the processor may quickly load pages from the pre-connected web server.
[0113] In operation 933, according to one embodiment, the processor may collect requested web resource (e.g., URL) information during a launching operation following the start of a first web application (collect URL). According to one embodiment, the processor may store and manage the collected web resource information as a pre-connection server list. According to one embodiment, the processor may limit the number of web servers to initiate pre-connection. The first pre-connection server list may include a predetermined number of URL information. If the number of web servers performing pre-connection is large, performance degradation due to pre-connection may occur. According to one embodiment, the processor may determine the limit of the first pre-connection server list by considering the number of web servers used in the launching process following the start of a web application and the performance of pre-connection.
[0114] At operation 916, the processor according to one embodiment may complete all initialization for the first web application, output a home screen (start screen), and wait for user input.
[0115] In operation 917, the processor according to one embodiment may, in response to a user input terminating the first web application or activating another application, transition the first web application to a background state (app suspend).
[0116] In operation 934, according to one embodiment, the processor may store the first pre-connected server list collected by operation 933 in memory (store URL Info) after operation 916 or after operation 917. The first pre-connected server list may be stored in non-volatile memory or a separate storage device so that it can be loaded upon the next start-up execution of the first web application.
[0117] According to one embodiment, the processor can maintain and update the first pre-connection server list by performing operations 931, 932, 933, and 934 for each execution of the first web application.
[0118] According to one embodiment, the processor may, upon initial execution of the first web application, create a new list of first pre-connection servers. Since the pre-connection process cannot be performed, operations 933 and 934 may be performed.
[0119] FIG. 10 is a flowchart of an operation of an electronic device processing a URL request of a web application according to one embodiment.
[0120] According to one embodiment, an electronic device (101) or a processor (hereinafter, “processor”) of the electronic device (101) may establish a communication connection with web servers included in a pre-connected server list at the beginning of a web application initialization, and may immediately receive data from already connected web servers at the time of processing a URL request generated during a page parsing process. Hereinafter, a URL request processing operation according to execution of a web application in an electronic device (101) according to one embodiment will be described. As an example, each operation of FIG. 10 may be described with reference to FIG. 8.
[0121] In operation S1010, a processor according to one embodiment may detect the occurrence of a URL request. For example, the processor may receive the first URL request, the second URL request, the fourth URL request, or the third URL request of FIG. 8.
[0122] In operation S1020, according to one embodiment, the processor may identify a web server corresponding to a URL request and determine whether the web server is connected. For example, as shown in FIG. 8, the processor may identify a first web server corresponding to a first URL request and determine that the first web server is connected. As another example of FIG. 8, the processor may identify a fourth web server corresponding to a fourth URL request and determine that the fourth web server is not connected.
[0123] In operation S1021, according to one embodiment, the processor may receive data immediately from the web server corresponding to the requested URL in response to identifying that the web server is connected. For example, referring to FIG. 8, the processor may receive data from the first web server immediately at the time of the first URL request (T1).
[0124] In operation S1030, in one embodiment, the processor, in response to identifying that the web server corresponding to the requested URL is not connected, may establish a communication connection with the corresponding web server and then perform data communication. For example, referring to FIG. 8, in response to a fourth URL request, the processor may establish a communication connection with a fourth web server and then receive data from the fourth web server (operation 823).
[0125] In operation S1040, the processor according to one embodiment may, after establishing a communication connection through a URL request, add URL information about a web server receiving data to a list of pre-connected servers. The processor according to one embodiment may collect and store information about web servers connected during the initial loading process of a web application, and apply this information to pre-connection for the next execution of the web application.
[0126] FIG. 11 is an example of updating a pre-connection server list for a web application in an electronic device, according to one embodiment.
[0127] An electronic device (101) according to one embodiment may store and update a list of pre-connection servers to apply information about web servers accessed during the initial loading process for each execution of a web application as pre-connection targets for the next execution. As an example, this can be described with reference to FIG. 8.
[0128] Referring to FIG. 11, the first pre-connection server list (1110) for the first web application may include a first web server (URL request), a second web server (URL request), and a third web server (URL request). The web servers included in the first pre-connection server list (1110) may correspond to web servers accessed in a previous execution of the first web application. The order in which they are stored in the first pre-connection server list (1110) may be the order in which each web server is accessed during the execution of the web application. For example, the first web server may be the web server accessed first during the execution of the first web application.
[0129] According to one embodiment, the electronic device (101) may update the first pre-connected server list (1120) by adding a fourth web server to reflect the current execution of the first web application. For example, referring to FIG. 8, the electronic device (101) according to one embodiment may receive a fourth URL request at time T3 and perform data communication with the fourth web server. When the initialization of the first web application is completed for the fourth web server that is not pre-connected, or when it enters the background state, the electronic device (101) may store the pre-connected server list (1120) with the fourth web server added in the memory.
[0130] According to one embodiment, an electronic device (101) may remove a web server from the first pre-connected server list (1110) if the web server is included in the first pre-connected server list (1110) and has been pre-connected in the current execution of the first web application but a corresponding URL request has not occurred.
[0131] FIG. 12 is a block diagram including components of an electronic device according to one embodiment.
[0132] An electronic device (101) according to one embodiment may include at least some of a processor (110), a memory (120), a communication interface (130), a display (140), or a speaker (150).
[0133] The processor (110) may, for example, execute software (e.g., a program) to control at least one other component (e.g., a hardware or software component) of the electronic device (101) connected to the processor (110) and perform various data processing or calculations. According to one embodiment, as at least a part of the data processing or calculation, the processor (110) may store a command or data received from another component (e.g., a communication interface (130)) in a volatile memory, process the command or data stored in the volatile memory, and store result data in a non-volatile memory. According to one embodiment, the processor (110) may include a main processor (e.g., a central processing unit or an application processor) or an auxiliary processor (e.g., a graphics processing unit, a neural processing unit (NPU), an image signal processor, a sensor hub processor, or a communication processor) that can operate independently or together therewith.
[0134] The memory (120) can store various data used by at least one component (e.g., a processor (110) or a communication interface (130)) of the electronic device (101). The data can include, for example, software (e.g., a program) and input data or output data for commands related thereto. The memory (120) can include volatile memory or non-volatile memory.
[0135] The program may be stored as software in the memory (120) and may include, for example, an operating system, middleware, or an application. In one example, the memory (120) may store various information or data related to the operation of the electronic device (101) and may store at least one program.
[0136] The communication interface (130) may include a wireless communication module (e.g., a cellular communication module, a short-range wireless communication module, or a global navigation satellite system (GNSS) communication module) or a wired communication module (e.g., a local area network (LAN) communication module or a power line communication module). For example, the communication interface (130) may be implemented with at least one or a combination of a digital modem, a radio frequency (RF) modem, an antenna circuit, a WiFi chip, and related software and / or firmware. Any of these communication modules may communicate with an external electronic device (e.g., a server (103a)) via a short-range communication network (e.g., Bluetooth, WiFi (wireless fidelity) direct, or IrDA (infrared data association)) or a long-range communication network (e.g., a legacy cellular network, a 5G network, a next-generation communication network, the Internet, or a computer network (e.g., a LAN or a WAN)).
[0137] The wireless communication module can support 5G networks and next-generation communication technologies beyond 4G networks, such as new radio access technology (NR). NR access technology can support high-speed transmission of high-capacity data (eMBB (enhanced mobile broadband)), minimizing terminal power and connecting multiple terminals (mMTC (massive machine type communications)), or high reliability and low latency communications (URLLC (ultra-reliable and low-latency communications)). The wireless communication module can support high-frequency bands (e.g., mmWave bands) to achieve high data rates, for example.
[0138] The display (140) can visually provide information to an external party (e.g., a user) of the electronic device (101). The display (140) may include, for example, a display, a holographic device, or a projector, and a control circuit for controlling the device. In one embodiment, the display (140) may include a touch sensor configured to detect a touch, or a pressure sensor configured to measure the strength of a force generated by the touch.
[0139] The speaker (150) can output sound. When playing various contents provided by the electronic device (101), sound can be output through the speaker (150).
[0140] According to one embodiment, the processor (110) of the electronic device (101) may initiate a pre-connection to at least one web server included in a first pre-connection server list corresponding to the first web application through a second thread operating in parallel with the first thread while performing at least one initialization operation for executing the first web application through a first thread in response to a start request of the first web application.
[0141] In one embodiment, the pre-connection may enable establishing a communication connection to the at least one web server before a web resource request is made to the at least one web server.
[0142] In one embodiment, the second thread may be a network thread.
[0143] According to one embodiment, the at least one processor (110) may be controlled to establish a pre-connection by performing a communication connection to the at least one web server included in the first pre-connection server list in response to the network thread becoming idle after completing network initialization.
[0144] In one embodiment, the first thread may be a browser thread.
[0145] According to one embodiment, the browser thread may transmit a first web resource request corresponding to the start screen of the first web application to the second thread during a browser initialization operation, receive the first web resource through the second thread, render the start screen based on the first web resource, and display the start screen of the first web application through the display (140).
[0146] According to one embodiment, the operation of performing a pre-connection to at least one web server included in the first pre-connection server list corresponding to the first web application through the second thread may cause the at least one processor (110) to perform at least one of domain address verification (DNS (domain name service) lookup), communication connection verification (TCP (transmission control protocol) handshake), or communication security connection (TLS (transport layer security)) for the at least one web server based on the HTTPS protocol.
[0147] According to one embodiment, the at least one processor (110) may, in response to the second thread receiving a first web resource request from the first thread, identify whether a communication connection has been established with a first web server corresponding to the first web resource request.
[0148] According to one embodiment, the at least one processor (110) may control the second thread to receive the first web resource indicated in the first web resource request from the first web server in response to the first web server being identified as being in a communication connection.
[0149] According to one embodiment, the at least one processor (110) may control the second thread to receive the first web resource after initiating a communication connection to the first web server in response to identifying that the first web server is not in a communication connection.
[0150] According to one embodiment, the at least one processor (110) may control the second thread to transmit a first web resource received from the first web server to a third thread, and the third thread may transmit a second web resource request that occurs while parsing the first web resource to the second thread.
[0151] According to one embodiment, the at least one processor (110) may collect first information for at least one web resource request that occurs until the at least one initialization is completed, the first information including information about a web server that initiated a communication connection in response to the at least one web resource request, and reflect the first information in the first pre-connection server list.
[0152] According to one embodiment, the at least one processor (110) may store the first pre-connection server list in the memory (120) at the time when the initialization of the first web application is completed or at the time when the first web application enters the background state.
[0153] In one embodiment, the memory may be non-volatile memory or a separate storage device.
[0154] According to one embodiment, the start screen of the first web application includes at least one user interface, and the start screen may include one or multiple consecutive screens.
[0155] According to one embodiment, the method of the electronic device (101) may include an operation in which the processor (110) of the electronic device (101) performs at least one initialization operation for executing the first web application through a first thread in response to a start request of the first web application, and an operation in which, while the first thread performs the at least one initialization operation, the second thread operating in parallel with the first thread performs a pre-connection to at least one web server included in a first pre-connection server list corresponding to the first web application.
[0156] In one embodiment, the pre-connection may be establishing a communication connection to the at least one web server before a web resource request is made to the at least one web server.
[0157] In one embodiment, the second thread may be a network thread.
[0158] According to one embodiment, the processor (110) of the electronic device (101) may initiate a communication connection to the at least one web server included in the first pre-connection server list in response to the network thread becoming idle after completing network initialization, thereby establishing a pre-connection.
[0159] In one embodiment, the first thread may be a browser thread.
[0160] According to one embodiment, the processor (110) of the electronic device (101) may transmit a first web resource request corresponding to the start screen of the first web application to the second thread during a browser initialization operation through the browser thread, receive the first web resource through the second thread, render the start screen based on the first web resource, and display the start screen through the display (140) of the electronic device.
[0161] According to one embodiment, the operation of performing a pre-connection to at least one web server included in the first pre-connection server list corresponding to the first web application through the second thread may cause the processor (110) of the electronic device (101) to perform at least one of domain address verification (DNS (domain name service) lookup), communication connection verification (TCP (transmission control protocol) handshake), or communication security connection (TLS (transport layer security)) for the at least one web server included in the first pre-connection server list based on the HTTPS protocol.
[0162] According to one embodiment, the processor (110) of the electronic device (101) may further include an operation of identifying whether a communication connection with a first web server corresponding to the first web resource request has been established in response to the second thread receiving a first web resource request from the first thread, and controlling the second thread to receive a first web resource indicated in the first web resource request from the first web server in response to identifying that the first web server is connected.
[0163] According to one embodiment, the processor (110) of the electronic device (101) may further include an operation of initiating a communication connection to the first web server through the second thread and then receiving the first web resource from the first web server in response to identifying that the first web server is not connected.
[0164] According to one embodiment, the method may further include controlling the second thread to transmit a first web resource received from the first web server to a third thread, and causing the third thread to transmit a second web resource request that occurs while parsing the first web resource to the second thread.
[0165] According to one embodiment, the processor (110) of the electronic device (101) may further include an operation of collecting first information for at least one web resource request that occurs until at least one initialization of the first web application is completed, the first information including information about at least one web server that initiates a communication connection according to the web resource request, and an operation of reflecting the first information in the first pre-connection server list.
[0166] According to one embodiment, the processor (110) of the electronic device (101) may further include an operation of storing the first pre-connection server list in the memory (120) of the electronic device at a time when the initialization of the first web application is completed or at a time when the first web application enters a background state.
[0167] According to one embodiment, the memory (120) may be a non-volatile memory or a separate storage device.
[0168] According to one embodiment, the start screen of the first web application includes at least one user interface, and the start screen may include one or multiple consecutive screens.
[0169] The terminology used herein is not intended to limit the described technical features to the embodiments, but should be understood to encompass various modifications, equivalents, or substitutes of the described embodiments. In connection with the description of the drawings, similar reference numerals may be used for similar or related components. The singular form of a noun corresponding to an item may include one or more of the items, unless the context clearly dictates otherwise. In this document, phrases such as "A or B," "at least one of A and B," "at least one of A or B," "A, B, or C," "at least one of A, B, and C," and "at least one of A, B, or C" each include any one of the items listed together in that phrase, or all possible combinations thereof. Terms such as "first," "second," or "first" or "second" may be used to distinguish the corresponding components from other corresponding components, and do not limit the corresponding components in any other respect (e.g., importance or order). When a component (e.g., a first component) is referred to as being “coupled” or “connected” to another component (e.g., a second component), with or without the terms “functionally” or “communicatively,” it means that the component can be connected to the other component directly (e.g., wired), wirelessly, or through a third component.
[0170] The term "module" used in the embodiments of this document may include a unit implemented in hardware, software, or firmware, and may be used interchangeably with terms such as logic, logic block, component, or circuit. A module may be an integral component, or a minimum unit or part of such a component that performs one or more functions. For example, according to one embodiment, a module may be implemented in the form of an application-specific integrated circuit (ASIC).
[0171] One embodiment may be implemented as software (e.g., a program (140)) including one or more instructions stored in a storage medium (e.g., an internal memory (136) or an external memory (138)) readable by a machine (e.g., an electronic device (101)). For example, a processor (e.g., a processor (120)) of the machine (e.g., an electronic device (101)) may call at least one instruction among the one or more instructions stored from the storage medium and execute it. This enables the machine to operate to perform at least one function according to the at least one called instruction. The one or more instructions may include code generated by a compiler or code executable by an interpreter. The machine-readable storage medium may be provided in the form of a non-transitory storage medium. Here, 'non-transitory' simply means that the storage medium is a tangible device and does not contain signals (e.g., electromagnetic waves), and the term does not distinguish between cases where data is stored semi-permanently or temporarily on the storage medium.
[0172] The method according to various embodiments may be provided as a computer program product. The computer program product may be traded as a commodity between a seller and a buyer. The computer program product may be distributed in the form of a machine-readable storage medium (e.g., compact disc read-only memory (CD-ROM)), or may be distributed online (e.g., downloaded or uploaded) through an application store (e.g., Play Store™) or directly between two user devices (e.g., smartphones). In the case of online distribution, at least a portion of the computer program product may be temporarily stored or temporarily generated in a machine-readable storage medium, such as the memory of a manufacturer's server, an application store's server, or an intermediary server.
[0173] According to one embodiment, each component (e.g., a module or a program) of the above-described components may include one or more entities, and some of the entities may be separated and placed in other components. According to one embodiment, one or more other components or operations may be added. Alternatively or additionally, a plurality of components (e.g., a module or a program) may be integrated into a single component. In this case, the integrated component may perform one or more functions of each of the plurality of components identically or similarly to those performed by the corresponding component among the plurality of components prior to the integration. According to one embodiment, the operations performed by a module, program, or other component may be executed sequentially, in parallel, iteratively, or heuristically, or one or more of the operations may be executed in a different order, or one or more other operations may be added.
Claims
1. In electronic devices, memory for storing at least one program; and At least one processor electrically connected to the memory and executing at least one instruction of a program stored in the memory, At least one processor of the above: In response to a start request of a first web application, while performing at least one initialization operation for executing the first web application through a first thread, initiating a pre-connection to at least one web server included in a first pre-connection server list corresponding to the first web application through a second thread operating in parallel with the first thread, and An electronic device that establishes a communication connection to the at least one web server through the pre-connection before a web resource request to the at least one web server is made.
2. In paragraph 1, The second thread above is a network thread, An electronic device wherein said at least one processor controls, in response to said network thread becoming idle after completing network initialization, to establish a communication connection with said at least one web server through said pre-connection.
3. In paragraph 1, Including more displays, The first thread above is a browser thread, At least one processor, Through the above browser thread, a first web resource request corresponding to the start screen of the first web application is transmitted to the second thread during the browser initialization operation, Receive the first web resource through the second thread, Rendering the start screen based on the first web resource, and An electronic device that displays the above start screen through the above display.
4. In paragraph 1, An electronic device wherein said at least one processor performs at least one of domain address verification (DNS (domain name service) lookup), communication connection verification (TCP (transmission control protocol) handshake), or communication security connection (TLS (transport layer security)) for said at least one web server based on said pre-connection and HTTPS protocol.
5. In paragraph 1, The at least one processor identifies whether a communication connection with a first web server corresponding to the first web resource request has been established based on the second thread receiving the first web resource request from the first thread, An electronic device, in response to identifying that a communication connection with the first web server has been established, receiving a first web resource indicated in the first web resource request from the first web server through the second thread.
6. In paragraph 5, At least one processor, An electronic device that initiates a communication connection with the first web server through the second thread and then receives the first web resource from the first web server based on identifying that a communication connection with the first web server has not been established.
7. In paragraph 5 or 6, At least one processor, Through the second thread, the first web resource is transferred to the third thread, An electronic device that transmits a second web resource request that occurs while parsing the first web resource to the second thread through the third thread.
8. In paragraph 1, The at least one processor collects first information about at least one web resource request that occurs until the initialization of the first web application is completed, wherein the information about the at least one web resource request includes information about at least one web server corresponding to each of the at least one web resource requests. An electronic device that reflects the first information in the first pre-connection server list.
9. In paragraph 8, At least one processor, Store the first pre-connection server list in the memory at the time when the initialization of the first web application is completed or at the time when the first web application enters the background state, An electronic device wherein the above memory is a non-volatile memory or a separate storage device.
10. In paragraph 3, The start screen of the first web application includes at least one user interface, An electronic device, wherein the above start screen comprises one or more consecutive screens.
11. In the method of an electronic device, An operation of initiating a pre-connection to at least one web server displayed in a first pre-connection server list corresponding to the first web application through a second thread operating in parallel with the first thread while the processor of the electronic device performs at least one initialization operation for executing the first web application through a first thread in response to a start request of the first web application, and A method for establishing a communication connection to the at least one web server through the pre-connection before a web resource request to the at least one web server is made.
12. In paragraph 11, The second thread above is a network thread, A method further comprising, in response to the network thread becoming idle after completing network initialization, establishing a communication connection with the at least one web server through the pre-connection.
13. In paragraph 11, The first thread above is a browser thread, An action of transmitting a first web resource request corresponding to the start screen of the first web application to the second thread during a browser initialization operation through the browser thread; An action of receiving a first web resource through the second thread; An operation of rendering the start screen based on the first web resource; and A method further comprising an action of displaying the start screen through a display of the electronic device.
14. In paragraph 11, An operation of identifying whether a communication connection with a first web server corresponding to the first web resource request has been established based on the second thread receiving the first web resource request from the first thread; A method further comprising, in response to identifying that a communication connection with the first web server has been established, receiving a first web resource indicated in the first web resource request from the first web server through the second thread.
15. In paragraph 14, A method further comprising an operation of initiating a communication connection with the first web server through the second thread and then receiving the first web resource from the first web server based on identifying that a communication connection with the first web server has not been established.
Citation Information
Patent Citations
Methods and apparatus for implementing pages in mobile applications, and computer-readable storage media
CN107368560B
Time series data asynchronous processing method
CN118277128A
Progressive prefetching
US20220405342A1
Systems and methods for pushing firmware binaries using nested multi-threader operations
US20230367585A1
Accelerating connections to a host server
US20240073274A1