A data processing method, system and storage medium

By detecting and storing instructions on the client, receiving and processing data and processing parameters of different object storage service providers, the problem of poor data display after object storage service providers is solved, and data switching and secure storage that is unaware of by users is realized.

CN119676311BActive Publication Date: 2025-05-23SHANGHAI JIAMIAN TECH INFORMATION SERVICE CO LTD
View PDF 2 Cites 0 Cited by

Patent Information

Application Number
CN202510193159.8
Authority / Receiving Office
CN · China
Patent Type
Patents(China)
Current Assignee / Owner
Filing Date
2025-02-21
Publication Date
2025-05-23
Estimated Expiration
2045-02-21

AI Technical Summary

Technical Problem

After switching between object storage service providers, the data display effect is poor, affecting the user's user experience.

Method used

By detecting viewing instructions and storage instructions, the client sends acquisition requests and storage requests to different servers, receives data and processing parameters, and processes data based on the received processing parameters to ensure that the data can be displayed normally after switching to the object storage service provider.

Benefits of technology

It realizes the switching of the user without perception of the object storage service provider when viewing the switched data on the client, improves the user experience and ensures that the data is stored safely during the switching process.

✦ Generated by Eureka AI based on patent content.

Smart Images

  • Figure CN119676311B_ABST
    Figure CN119676311B_ABST
Patent Text Reader

Abstract

The present application relates to the field of computer technology, and specifically to a data processing method, system and storage medium. When data is switched between object storage service providers, and a user needs to view the data after switching the object storage service provider, the electronic device can process the data with the processing parameters of the object storage service provider where the data sent by the configuration server is located, and display the processed data on the electronic device. In this way, the client can normally display the data before and after switching the object storage service provider. The user is unaware of the switching of the object storage service provider when viewing the data on the client, which improves the user experience.
Need to check novelty before this filing date? Find Prior Art

Description

Technical Field

[0001] The present application relates to the field of computer technology, and in particular to a data processing method, system and storage medium. Background Art

[0002] In the distributed architecture system of the modern Internet, electronic devices usually rely on object storage services (OSS) when performing large amounts of data transmission tasks (such as file uploads and log records). Different object storage service providers differ in terms of service quality, regional coverage, and data processing parameters. Therefore, for the flexibility of data storage, the distributed architecture system needs to be able to dynamically switch object storage service providers, that is, data can be transferred from the old object storage service provider to the new object storage service provider.

[0003] However, different object storage service providers may have different data processing parameters (such as different image cropping ratios, watermark styles, etc.). Data can only be displayed after being processed based on the data processing parameters of the object storage service provider where the data was located before switching the object storage service provider, and cannot be displayed after being processed based on the data processing parameters of the object storage service provider where the data was located after switching the object storage service provider. In this way, after switching the object storage service provider, the display effect of data on the electronic device is poor or cannot be displayed, which affects the user experience. Summary of the invention

[0004] In order to solve the problem of poor display effect of data after switching object storage service providers, embodiments of the present application provide a data processing method, system and storage medium.

[0005] In a first aspect, an embodiment of the present application provides a data processing method, which is applied to an electronic device, including:

[0006] At a first moment, when a first viewing instruction is detected, a first acquisition request is sent to the first server and the second server; the first viewing instruction indicates viewing the first data stored in the first server;

[0007] Receiving first data sent by a first server and a first processing parameter sent by a second server; the first processing parameter is a data processing parameter corresponding to the first server;

[0008] At the second moment, when a second viewing instruction is detected, a second acquisition request is sent to the third server and the second server; the second viewing instruction indicates viewing the second data stored in the third server, and the first moment and the second moment are different moments;

[0009] The second data sent by the third server and the second processing parameter sent by the second server are received; the second processing parameter is a data processing parameter corresponding to the third server.

[0010] In this way, the client can display the data of the switched object storage service provider normally, and the user is unaware of the switch of the object storage service provider when viewing the switched data on the client, thereby improving the user experience.

[0011] In a possible implementation of the first aspect, the method further includes:

[0012] At a third moment, when the first storage instruction is detected, the first data is sent to the first server; wherein the first storage instruction instructs the first server to store the first data; the third moment is earlier than the first moment;

[0013] At the fourth moment, when the second storage instruction is detected, the second data is sent to the first server and the third server; wherein the second storage instruction instructs the first server and the third server to store the second data respectively; the fourth moment is earlier than the second moment, and the fourth moment is later than the third moment.

[0014] In this way, while the data of the switched object storage service provider is securely stored, the client can normally display the data of the storage service provider before and after the switch. The user is unaware of the switching process when viewing the data of the switched object storage service provider on the client, which improves the user experience.

[0015] In a possible implementation of the first aspect, the method further includes:

[0016] At the fifth moment, when the third storage instruction is detected and the third server is normal, the third data continues to be sent to the third server, and the third data is stopped from being sent to the first server;

[0017] Among them, the third storage instruction instructs the third server to store the third data, and the fifth moment is later than the fourth moment.

[0018] In this way, when switching data to a new object storage service provider, while ensuring data security storage, the user can switch the object storage service provider without being aware of the process, thereby improving the user experience.

[0019] In a possible implementation of the first aspect, the method further includes:

[0020] At the sixth moment, when the fourth storage instruction is detected and the third server fails, the fourth data is stopped from being sent to the third server, and the fourth data is sent to the first server;

[0021] Among them, the fourth storage instruction instructs the first server to store fourth data, and the sixth moment is later than the fifth moment.

[0022] In this way, when switching object storage service providers, if the new object storage service provider fails, the data will continue to be written to the old object storage service provider, ensuring stable data storage, preventing the risk of data loss, and improving user satisfaction.

[0023] In a possible implementation of the first aspect, the method further includes:

[0024] After receiving the first data sent by the first server and the first processing parameter sent by the second server, processing the first data based on the first processing parameter and displaying the processed first data;

[0025] After receiving the second data sent by the third server and the second processing parameter sent by the second server, processing the second data based on the second processing parameter and displaying the processed second data;

[0026] The displayed contents of the processed first data and the processed second data are consistent.

[0027] In this way, at different times, the electronic device processes and displays data using the processing parameters of the server where the data is located. The electronic device can display data of switched object storage service providers normally, and the user is unaware of the switch of object storage service providers when viewing the switched data, thereby improving the user experience.

[0028] In a second aspect, an embodiment of the present application provides a data processing system, including an electronic device, a first server, a second server, and a third server, wherein the first server and the third server are servers of different operators, and the second server stores a first processing parameter corresponding to the first server and a second processing parameter corresponding to the third server;

[0029] When a first viewing instruction is detected at a first moment, the electronic device sends a first acquisition request to the first server and the second server; the first viewing instruction indicates viewing the first data stored in the first server;

[0030] The first server sends the first data to the electronic device in response to the first acquisition request, and the second server sends the first processing parameter to the electronic device in response to the first acquisition request;

[0031] The electronic device receives the first data sent by the first server and the first processing parameter sent by the second server;

[0032] When a second viewing instruction is detected at the second moment, the electronic device sends a second acquisition request to the third server and the second server; the second viewing instruction instructs viewing the second data stored in the third server;

[0033] The third server sends the second data to the electronic device in response to the second acquisition request, and the second server sends the second processing parameter to the electronic device in response to the second acquisition request;

[0034] The electronic device receives the second data sent by the third server and the second processing parameter sent by the second server.

[0035] In this way, the electronic device can display the data of the switched object storage service provider normally, and the user does not perceive the switching of the object storage service provider when viewing the switched data, thereby improving the user experience.

[0036] In a possible implementation of the second aspect, when the first storage instruction is detected at the third moment, the electronic device sends the first data to the first server;

[0037] The first server stores the first data in response to the first storage instruction; wherein the third time is earlier than the first time;

[0038] When the second storage instruction is detected at the fourth moment, the electronic device sends the second data to the first server and the third server;

[0039] The first server stores the second data in response to the second storage instruction;

[0040] The third server stores the second data in response to the second storage instruction;

[0041] Among them, the fourth moment is earlier than the second moment, and the fourth moment is later than the third moment.

[0042] In this way, while the data of the switched object storage service provider is securely stored, the client can normally display the data of the storage service provider before and after the switch. The user is unaware of the switching process when viewing the data of the switched object storage service provider on the client, which improves the user experience.

[0043] In a possible implementation of the second aspect, when the electronic device detects the third storage instruction at the fifth moment and the third server is normal, the electronic device sends the third data to the third server and stops sending the third data to the first server;

[0044] The third server stores the third data in response to the third storage instruction, and the fifth time is later than the fourth time.

[0045] In this way, when switching data to a new object storage service provider, while ensuring that the data is stably stored in the object storage service provider, a seamless data switching process is achieved, improving the user experience.

[0046] In a possible implementation of the second aspect, when the fourth storage instruction is detected at the sixth moment and the third server fails, the electronic device sends the fourth data to the first server and stops sending the fourth data to the third server;

[0047] The first server stores the fourth data in response to the fourth storage instruction, and the sixth time is later than the fourth time.

[0048] In this way, when switching object storage service providers, if the new object storage service provider fails, the data will continue to be written to the old object storage service provider, ensuring the safe storage of data, preventing the risk of data loss, and improving user satisfaction.

[0049] In a possible implementation of the second aspect, after receiving the first data sent by the first server and the first processing parameter sent by the second server, the electronic device processes the first data based on the first processing parameter and displays the processed first data;

[0050] After receiving the second data sent by the third server and the second processing parameter sent by the second server, the electronic device processes the second data based on the second processing parameter and displays the processed second data;

[0051] The displayed contents of the processed first data and the processed second data are consistent.

[0052] In this way, at different times, the electronic device processes and displays data using the processing parameters of the server where the data is located. The electronic device can display data normally when switching object storage service providers. Users are unaware of the switch of object storage service providers when viewing the switched data, thereby improving the user experience.

[0053] In a third aspect, an embodiment of the present application provides a server, which sends a first processing parameter to an electronic device in response to a first acquisition instruction sent by the electronic device; wherein the first processing parameter is a data processing parameter corresponding to the first server;

[0054] In response to the second acquisition instruction sent by the electronic device, a second processing parameter is sent to the electronic device; wherein the second processing parameter is a data processing parameter corresponding to the second server.

[0055] The first server and the third server are servers of different operators.

[0056] In this way, at different times, when data is switched to different object storage service providers, the configuration server can send the data processing parameters corresponding to the object storage service provider to the electronic device, and the electronic device displays the data according to the data processing parameters of the object storage service provider where the data is located. The electronic device can display the data of the switched object storage service provider normally, and the user is unaware of the switch of the object storage service provider when viewing the switched data, thereby improving the user experience.

[0057] In a fourth aspect, an embodiment of the present application provides a readable storage medium, on which instructions are stored. When the instructions are executed on an electronic device, the electronic device executes a data processing method as described in any one of the first aspects. BRIEF DESCRIPTION OF THE DRAWINGS

[0058] In order to more clearly illustrate the embodiments of the present application or the technical solutions in the prior art, the accompanying drawings are described below.

[0059] Figure 1 According to some embodiments of the present application, a schematic diagram of data dynamic object storage is shown;

[0060] Figure 2 According to some embodiments of the present application, a schematic diagram of switching an object storage service provider is shown;

[0061] Figure 3 According to some embodiments of the present application, a flow chart of a data processing method is shown;

[0062] Figure 4 According to some embodiments of the present application, a flow chart of a data processing method is shown;

[0063] Figure 5 According to some embodiments of the present application, a functional schematic diagram of a data processing system 300 is shown;

[0064] Figure 6 According to some embodiments of the present application, a structural schematic diagram of an electronic device 400 to which a data processing method is applicable is shown. DETAILED DESCRIPTION

[0065] In order to facilitate understanding of the solutions mentioned in the embodiments of the present application, the professional terms involved in the embodiments of the present application are explained below.

[0066] Object storage service: Object storage service (OSS) is a cloud storage architecture for storing and managing massive amounts of data. Object storage uses "objects" as the basic unit of storage. Each object contains the data itself, an object identifier, and object attributes (such as content type, access control list, etc.).

[0067] Dynamic object storage: Dynamic object storage can dynamically adjust the storage capacity of object storage service providers according to data storage needs. Dynamic object storage supports dynamic switching of data between multiple object storage service providers. For example, it supports transferring data from object storage service provider 1 to object storage service provider 2 in the example below.

[0068] Distributed architecture system: A distributed architecture system (DAS) consists of multiple independent computer nodes (such as servers, virtual machines, databases, etc.) distributed in different physical locations or virtual environments, communicating and collaborating through the network to jointly complete the overall functions of the distributed architecture system. In a distributed architecture system, each computer node is both a service provider and a service receiver.

[0069] It can be understood that the data processing method provided in the embodiment of the present application can be applied to any electronic device, including but not limited to a mobile station (MS), a mobile terminal (MT), etc. For example, the electronic device can be a mobile phone, a smart TV, a wearable device, a tablet computer (Pad), a desktop computer, a laptop computer, a virtual reality (VR) device, an augmented reality (AR) device, a terminal in industrial control, a terminal in self-driving, a terminal in remote medical surgery, a terminal in a smart grid, a terminal in transportation safety, a terminal in a smart city, a terminal in a smart home, etc. The embodiment of the present application does not limit the specific form of the electronic device.

[0070] It should be noted that the data involved in the embodiments of the present application may be image data, voice data, text data, etc., and is not limited here.

[0071] The following describes the process of data dynamic object storage with reference to the accompanying drawings.

[0072] Figure 1 The present invention is a schematic diagram of data dynamic object storage, wherein the client 100 may be the electronic device mentioned above, and the object storage service provider cluster 200 includes multiple object storage service providers, such as the first server and the third server mentioned above, and the Figure 1The object storage service provider shown is 1, object storage service provider 2, object storage service provider 3, ... object storage service provider N. Object storage service providers can support uploading, storing, and managing various types of data (such as files, pictures, videos, logs, etc.).

[0073] like Figure 1 As shown, when the client 100 detects a viewing instruction, for example, when the client 100 detects that the user opens the gallery to view a frame of a picture by voice input, touch input, etc., if the picture is stored in the object storage service provider 1, the client 100 sends a request to the object storage service provider 1 corresponding to the object storage service provider cluster 200, and the object storage service provider 1 can respond to the request and send the data corresponding to the picture to the client 100. The client 100 displays the picture data based on the corresponding data processing parameters sent by the object storage service provider 1. Among them, the storage rules of the object storage service provider whose data is stored in the storage service provider cluster 200 can be determined based on the regional coverage, storage service quality, and the file processing method of the object storage service provider, and can also be randomly determined from the object storage service provider cluster 200, without specific limitation.

[0074] In order to improve the flexibility of data storage in object storage service providers, in some embodiments, data can be dynamically switched between object storage service providers. Figure 2 is a schematic diagram of switching object storage service providers. Figure 2 As shown, at the first moment, the first data is stored on the object storage service provider 1. The client 100 can send a request to the object storage service provider 1 to obtain the first data. The object storage service provider 1 can send the first data to the client 100 in response to the request to obtain the first data. The client 100 can process the first data based on the corresponding data processing parameters sent by the object storage service provider 1, and display the processed first data.

[0075] At the second moment, the area coverage of object storage service provider 2 is wider, and client 100 is within the area coverage of object storage service provider 2, and the first data can be transferred from object storage service provider 1 to object storage service provider 2 to achieve better area coverage. At this time, client 100 can send a request to object storage service provider 2 to obtain the first data, and object storage service provider 2 can send the first data to client 100 in response to the request to obtain the first data.

[0076] However, due to the differences in data processing parameters (such as image cropping, watermark addition, etc.) corresponding to different object storage service providers, data can only be processed based on the data processing parameters corresponding to the object storage service provider where the data is located before switching the object storage service provider, and cannot be processed based on the data processing parameters corresponding to the object storage service provider where the data is located after switching the object storage service provider, that is, at the second moment, the client 100 still processes the first data based on the data processing parameters corresponding to the object storage service provider 1 and then displays it. This may cause some data that was originally stored in the object storage service provider 1 and then transferred to the object storage service provider 2 to not be displayed normally on the client 100 (such as inconsistent photo ratios, unable to display normally when opened, etc.), and thus, it is necessary to manually perform secondary processing on the data transferred to the object storage service provider 2. This will affect the user experience in scenarios where data frequently switches object storage service providers or complex data management.

[0077] Therefore, in order to solve the above problems, an embodiment of the present application provides a data processing method. When data is switched between object storage service providers, the data processing parameters corresponding to the object storage service provider where the data is located can be sent to the client 100 through the configuration server (corresponding to the second server). The client 100 can process the data based on the data processing parameters corresponding to the object storage service provider where the data is located and display it (that is, when the client 100 displays the data on the old object storage service provider, it can display the data based on the data processing parameters of the old object storage service provider sent by the configuration server; when the client 100 displays the data on the new object storage service provider, it can display the data based on the data processing parameters of the new object storage service provider sent by the configuration server). In this way, the client 100 can normally display the data before and after switching the object storage service provider. In addition, when the user views the data on the client 100, he or she will not be aware of the switching of the object storage service provider, thereby improving the user experience.

[0078] In addition, when there is a need to switch the object storage service provider during the data upload process, in order to ensure that the data can be safely switched to the new object storage service provider, the data is double-written within a certain period of time after the object storage service provider is switched, that is, the uploaded data is written to both the old object storage service provider and the new object storage service provider. And, after confirming that the new object storage service provider is running normally and the written data is stable (for example, the number of resources uploaded by the old object storage service provider and the new object storage service provider in the same period of time is stable within a certain threshold range), stop writing data to the old object storage service provider, write data only to the new object storage service provider, and complete the data switching between object storage service providers; when the switched new object storage service provider fails (for example, the data uploaded by the new object storage service provider in the same period of time is reduced, or the client displays abnormal data after switching the object storage service provider, etc.), the data is only written to the old object storage service provider, stop writing data to the new object storage service provider, and stop switching the data to the new object storage service provider.

[0079] In this way, when switching object storage service providers, data can be stored safely, and the client can display the data of the switched object storage service provider normally. In addition, when users view the data of the switched object storage service provider on the client, they will not be aware of the switching process, which can improve the user experience.

[0080] The following uses an example of an electronic device viewing data from different object storage service providers at different times to introduce the technical solution of the present application.

[0081] In some scenarios, the first server (or the old object storage service provider) may store the first data, and the third server (or the new object storage service provider) may store the second data. In addition, the second server may store the data processing parameters corresponding to the first server, i.e., the first processing parameters. The second server may also store the data processing parameters corresponding to the third server, i.e., the second processing parameters.

[0082] Figure 3 According to some embodiments of the present application, a flow chart of a data processing method is shown. The method can be executed by an electronic device, such as Figure 3 As shown, the method includes:

[0083] S101: At a first moment, the electronic device detects a first viewing instruction and sends a first acquisition request to a first server and a second server.

[0084] In some embodiments, the first moment may be a moment when the server is not switched, and the first viewing instruction may be a data viewing instruction issued by the electronic device to the first server.

[0085] It can be understood that the first acquisition request can be a request sent by the electronic device to the first server to obtain the first data, and a request sent by the electronic device to the second server to obtain the data processing parameters corresponding to the first server.

[0086] For example, when a user takes a picture, the electronic device can upload the picture to a corresponding server, such as a first server, in real time. When it is detected that the user views the first picture (for example, when it is detected that the user opens the first picture by voice input, touch input, etc.), the electronic device can detect a first viewing instruction instructing to view the first picture, and send a first acquisition request to the first server and the second server, instructing the electronic device to view the first picture on the first server based on the data processing parameters corresponding to the first server sent by the second server.

[0087] S102: The electronic device receives first data sent by the first server and a first processing parameter sent by the second server.

[0088] In response to the first acquisition request, the first server sends the first data to the electronic device, and the second server sends the data processing parameters corresponding to the first server (corresponding to the first processing parameters) to the electronic device. The electronic device receives the first data sent by the first server and the first processing parameters sent by the second server.

[0089] It can be understood that in some embodiments, the first processing parameter may be a processing parameter and a processing logic script on the first server (eg, a storage format of data on the first server, an encrypted JavaScript script, etc.).

[0090] It is understandable that when viewing the data stored in the first server, the second server can send the first processing parameter to the electronic device. When the electronic device displays the data stored in the first server, it can display the data based on the first processing parameter.

[0091] In some embodiments, the second server may also send the first processing parameter to a fourth server, and send the first processing parameter to the electronic device through the fourth server, where the fourth server may be a server that processes the first data (eg, uploads the first data to the first server).

[0092] For example, when a user views image data stored on a first server, the electronic device receives the image data sent by the first server, and after receiving the first processing parameters corresponding to the first server sent by the second server, the electronic device can process the image data (for example, image compression, watermark processing, image encryption) based on the first processing parameters corresponding to the first server, and display the image data on the electronic device.

[0093] S103: At a second moment, the electronic device detects a second viewing instruction and sends a second acquisition request to the third server and the second server.

[0094] It is understandable that since different servers of the same operator have the same data processing parameters, the first server and the third server may be servers of different operators. The first server may be a server storing data at the first moment, and the third server may be a server after data switching and storage.

[0095] In some embodiments, the second viewing instruction instructs the electronic device to view the second data stored on the third server. For example, when the user takes a picture, the electronic device can upload the picture to the corresponding server, such as the third server, in real time. When it is detected that the user views the first picture (for example, when it is detected that the user opens the first picture by voice input, touch input, etc.), the electronic device can detect the second viewing instruction instructing to view the first picture, instructing the electronic device to view the first picture stored on the third server.

[0096] It can be understood that the second time is later than the first time. The second time may be a time after the data switches to a server, and the second viewing instruction may be a viewing data instruction submitted to the third server.

[0097] It can be understood that the second acquisition request can be a request sent by the electronic device to the third server to obtain the second data, and a request sent by the electronic device to the second server to obtain the data processing parameters corresponding to the third server.

[0098] For example, when image data is stored on the first server, the image data is transferred to the third server because of the regional coverage range. When the electronic device detects an instruction to view the image data (for example, when it detects that the user opens the first image through voice input, touch input, etc.), the electronic device sends a request to the third server to obtain the image data, requesting to view the image data on the third server; and the electronic device sends a request to the second server to obtain the data processing parameters of the third server. The electronic device can process the image data (for example, image compression, watermark processing, image encryption) based on the data processing parameters corresponding to the third server, and display the image data on the electronic device.

[0099] S104: The electronic device receives the second data sent by the third server and the second processing parameter sent by the second server.

[0100] It can be understood that in response to the second acquisition request, the third server sends the second data to the electronic device, and the second server sends the data processing parameters corresponding to the third server (corresponding to the second processing parameters) to the electronic device. The electronic device receives the first data sent by the third server and the second processing parameters sent by the second server.

[0101] It is understandable that the second data in the third server is obtained by transferring the first data in the first server. In some embodiments, due to the different storage data types, storage structures and application requirements of the first server and the third server, the data needs to be transferred to a suitable server to ensure the integrity of the data.

[0102] For example, at a first moment, the image data is originally stored on the first server, and at a second moment, the image data has better regional coverage on the third server, so the storage location of the image data can be transferred from the first server to the third server to achieve better regional coverage. The image data transferred to the third server is the same as the image data on the first server.

[0103] It can be understood that the second processing parameter is a data processing parameter corresponding to the third server. For example, in some embodiments, the second processing parameter can be a processing parameter of the third server and a script of processing logic (such as a JavaScript script containing the storage format and encryption method of the data on the third server).

[0104] It can be understood that the second server stores data processing parameters corresponding to all servers, such as the first processing parameters corresponding to the first server and the second processing parameters corresponding to the third server. When viewing data, the second server can send the data processing parameters of the server where the data is located to the electronic device, and when the electronic device displays the data stored in a certain server, it can display the data based on the data processing parameters of the server where the data is located.

[0105] In some embodiments, the second server may also send the second processing parameter to a fourth server, and send the second processing parameter to the electronic device through the fourth server, where the fourth server may be a server that processes the second data (eg, uploads the second data to the third server).

[0106] For example, when a user views image data stored on a third server, the electronic device receives the image data sent by the third server, and receives a second processing parameter corresponding to the third server sent by the second server. The electronic device processes the image data (for example, image compression, watermark processing, image encryption) based on the second processing parameter corresponding to the third server, and displays the image data on the electronic device.

[0107] It can be understood that in response to the electronic device detecting requests to obtain data from different servers at different times, the second server can send the data processing parameters of the server where the data is located to the electronic device. That is, when the electronic device receives the first data sent by the first server, the electronic device processes the first data with the data processing parameters of the first server (corresponding to the first processing parameters), and displays the processed first data on the electronic device. When the electronic device receives the second data transferred to the third server, the electronic device processes the second data with the data processing parameters of the third server (corresponding to the second processing parameters), and displays the processed second data on the electronic device; it can be understood that the processed first data and the processed second data displayed on the electronic device are consistent.

[0108] For example, at the first moment, when the electronic device receives the picture data sent from the first server, the electronic device processes the picture data with the data processing parameters of the first server (corresponding to the first processing parameters), and displays the processed picture data on the electronic device; at the second moment, the picture data of the first server is transferred to the third server, and when the electronic device receives the picture data sent from the third server, the electronic device processes the picture data with the data processing parameters of the third server (corresponding to the second processing parameters), and displays the processed picture data on the electronic device. The processed picture data displayed on the electronic device at the first moment and the second moment are the same.

[0109] In this way, the client can display the data of the switched object storage service provider normally, and the user is unaware of the switching process when viewing the data of the switched object storage service provider on the client, thereby improving the user experience.

[0110] The following uses an example of an electronic device storing data from different object storage service providers at different times to introduce the technical solution of the present application.

[0111] At different times, the storage location of data is different. The data may be stored in the first server (or the old object storage service provider) or in the third server (or the new object storage service provider). In addition, the second server stores the data processing parameters corresponding to the first server (corresponding to the first processing parameters) and the data processing parameters corresponding to the third server (corresponding to the second processing parameters).

[0112] Figure 4 According to some embodiments of the present application, a schematic diagram of a data processing method is shown, and the execution subject of the method is an electronic device, such as Figure 4 As shown, the method includes:

[0113] S201: At a third moment, the electronic device detects a first storage instruction and sends first data to a first server.

[0114] It can be understood that the first storage instruction may be an instruction for the electronic device to store the first data to the first server.

[0115] For example, at the third moment, when the user takes a picture, the electronic device detects a first storage instruction (for example, the user opens cloud storage software, or the user sets automatic upload to the server), and the electronic device automatically uploads the picture data (as an example of the first data) to the first server.

[0116] It is understandable that different servers have differences in service quality, regional coverage, and file processing parameters. Therefore, for the flexibility of data storage, dynamic object storage needs to be able to switch between servers, that is, the content of the first server can be transferred to the third server. For example, if the data was originally on the first server, and the third server has better regional coverage, the dynamic object storage can transfer the data storage location from the first server to the third server.

[0117] At the same time, it can be understood that in some embodiments, if the first server can meet the storage requirements and the conditions in terms of storage capacity, performance, reliability and cost meet expectations, the data can continue to be stored on the first server without transferring the data to a new server.

[0118] For example, at the third moment, the first server can meet the storage demand, then the third moment may be the moment when the data is not switched to the server, and the first storage instruction may be an instruction to store data to the first server. The electronic device uploads the picture data to the first server, that is, the first server stores the picture data sent by the electronic device.

[0119] Meanwhile, it can be understood that the electronic device can view the first data only after the first data is stored in the first server, so the third moment is earlier than the first moment mentioned in S101 and S102.

[0120] S202: At a fourth moment, the electronic device detects a second storage instruction, and sends second data to the first server and the third server.

[0121] It is understandable that the fourth moment is later than the third moment. At the fourth moment, the first server cannot meet the storage demand (eg, the first server cannot meet the regional coverage). The fourth moment may be the moment when the data switches servers, that is, switches to the third server.

[0122] It can be understood that since different servers of the same operator have the same data processing parameters, the first server and the third server are servers of different operators.

[0123] It can be understood that the second storage instruction instructs the first server and the third server to store the second data, that is, the second storage instruction can be an instruction to store data to the first server and the third server at the same time. For example, at the fourth moment, when the user takes a picture, the electronic device detects the second storage instruction (for example, the user opens the cloud storage software, or the user sets automatic upload to the server), that is, the electronic device uploads the picture data (as an example of the second data) to the first server and the third server at the same time.

[0124] Meanwhile, it can be understood that the electronic device can view the second data only after the second data is stored in the third server, so the fourth moment is earlier than the second moment mentioned in S103 and S104.

[0125] In this way, when switching the object storage service provider, the data is written to both the first server and the third server. While switching the object storage service provider, the data is also guaranteed to be stored securely, the risk of data loss is prevented, and user satisfaction is improved.

[0126] S203: At the fifth moment, the electronic device detects the third storage instruction and, if the third server is normal, sends the third data to the third server.

[0127] It can be understood that the fifth moment is later than the fourth moment. If it is detected at the fifth moment that the data written to the first server and the third server are normal, it is determined that the third server is stable and the data can be transferred to the third server.

[0128] In some embodiments, the monitoring module of the object storage service provider (e.g., the first server and the third server) can monitor the stability of the server data storage within a certain period of time. When the monitoring module monitors that the number of resources uploaded by the first server and the third server under the same conditions (e.g., the same period of time, the same server storage capacity) is stable within a certain threshold range, the third server is determined to be in a normal state.

[0129] It can be understood that when the electronic device detects the third storage instruction and determines that the third server is normal, the electronic device sends the third data to the third server and stops sending the third data to the first server. The third storage instruction instructs the third server to store the third data.

[0130] For example, at the fourth moment, after the image data is transferred to the third server, the electronic device writes the image data to both the first server and the third server. At the fifth moment, if the third server is normal, the image data is only written to the third server and stops being written to the first server, completing the data switching on the server.

[0131] In some embodiments, after the electronic device sends the third data to the third server and stops sending the third data to the first server, the monitoring module of the third server can also monitor the stability of the data storage on the third server within a certain period of time. If the monitoring module of the third server monitors that the number of resources for data upload is stable within a certain threshold range under certain conditions (such as a certain period of time), the third server is determined to be in a normal state and the data continues to be written to the third server. If the monitoring module of the third server monitors that the number of resources for data upload is less than a certain threshold, or the data of the third server is displayed abnormally on the electronic device (such as the image data cannot be displayed, the loaded image data is not the original image, etc., the displayed photo ratio is different from that of the first server), the third server is determined to be in a fault state, the data writing to the third server is stopped, and the data is written to the first server.

[0132] In this way, when switching object storage service providers, while ensuring that data is stably stored in the object storage service provider, a seamless data switching process is achieved, improving the user experience.

[0133] S204: At the sixth moment, the electronic device detects the fourth storage instruction, and when the third server fails, sends fourth data to the first server.

[0134] In some embodiments, the monitoring module of the object storage service provider (e.g., the first server and the third server) can monitor the stability of the server data storage within a certain period of time. When the server monitoring module monitors that the number of resources uploaded by the third server under the same conditions (e.g., the same period of time, the same storage capacity) is less than a certain threshold, or the data of the third server is displayed abnormally on the electronic device (e.g., the image data cannot be displayed, the image data cannot load the original image, etc., and the displayed photo ratio is different from the photo display ratio of the first server), the third server is determined to be in a fault state.

[0135] It can be understood that the sixth moment is later than the fifth moment. At the fourth moment, it is detected that the data is written to the first server and the third server at the same time. At the sixth moment, the electronic device detects the fourth storage instruction (i.e., when the third server fails), the electronic device sends the fourth data to the first server and stops sending the fourth data to the third server, i.e., abandons transferring the fourth data to the third server. Among them, the fourth storage instruction instructs the first server to store the fourth data.

[0136] For example, at the fourth moment, the electronic device writes the picture data to both the first server and the third server. At the sixth moment, the third server fails, and the picture data is only written to the first server, stops writing to the third server, and gives up switching the picture data to the third server.

[0137] In this way, when switching object storage service providers, if the new object storage service provider fails, the data will continue to be written to the old object storage service provider, ensuring stable data storage, preventing the risk of data loss, and improving user satisfaction.

[0138] The various modules of the data processing system are described below.

[0139] Figure 5 is a functional schematic diagram of a data processing system 300, such as Figure 5 As shown, the data processing system 300 includes a configuration management module 301, a distributed server module 302, and a client module 303. The functions of each module are described below.

[0140] The configuration management module 301 includes data processing parameters of all object storage service providers (for example, the first processing parameter of the first server and the second processing parameter of the third server). When an electronic device views data stored by an object storage service provider, the configuration management module 301 can send the data processing parameters of the object storage service provider where the data is located to the electronic device. The electronic device processes the data (for example, image compression, watermark processing, image encryption) based on the data processing parameters of the corresponding object storage service provider and displays the data on the electronic device.

[0141] In some embodiments, the configuration management module 301 may also send the data processing parameters to a fourth server, and the data processing parameters are sent to the electronic device through the fourth server. When the electronic device displays the data stored in a certain object storage service provider, the data may be displayed based on the data processing parameters sent by the fourth server. The fourth server may be a server that processes the aforementioned first data and second data (for example, uploads the first data to the first server).

[0142] Specifically, the data processing parameters of the object storage service provider (such as the first processing parameter and the second processing parameter) can be the processing parameters and processing logic scripts on the object storage service provider (such as the storage format of the data on the first server, the JavaScript script of the encryption method, etc.). When the electronic device views the data stored by the object storage service provider, the configuration management module 301 can send the data processing parameters corresponding to the object storage service provider to the electronic device. When the electronic device displays the data stored in a certain object storage service provider, it can display the data based on the data processing parameters corresponding to the object storage service provider where the data is located sent by the configuration management module 301. When the user views the data of the switched object storage service provider on the client, he / she does not perceive the switching process, which improves the user's experience.

[0143] For example, when a user views image data on a third server on an electronic device, the configuration management module 301 can generate a JavaScript script containing processing parameters and processing logic using the data processing parameters of the third server (corresponding to the second processing parameters) and send it to the electronic device. The electronic device processes the image data using the JavaScript script containing the processing parameters and processing logic of the third server and displays the processed image data.

[0144] The distributed server module 302 may be composed of multiple independent computer nodes (such as servers, virtual machines, databases, etc.), which are distributed in different physical locations or virtual environments, communicate and collaborate through the network, and jointly complete the overall function of the distributed architecture system. In the distributed architecture system, each computer node is both a service provider and a service receiver.

[0145] The distributed server module 302 is the first server and the third server mentioned above, and for example Figure 1 The object storage service provider 1, object storage service provider 2, object storage service provider 3, ... object storage service provider N shown, the distributed server module 302 can be used to support users to upload, store and manage various types of data (such as files, pictures, videos, logs, etc.). For example, at the first moment, the picture data is originally stored on the object storage service provider 1, and at the second moment, the picture data is better in the regional coverage of the object storage service provider 2. The distributed server module 302 can transfer the storage location of the picture data from the object storage service provider 1 to the object storage service provider 2 through the network connection to achieve better regional coverage.

[0146] In some embodiments, the distributed server module 302 may also include a monitoring module 3021 for monitoring the stability of data storage of object storage service providers (e.g., the first server and the third server). When the monitoring module 3021 monitors that the number of resources uploaded by the first server and the third server under the same conditions (e.g., the same time period, the same server storage capacity) is stable within a certain threshold range, the third server is determined to be in a normal state. When the monitoring module 3021 monitors that the number of resources uploaded by the third server under the same conditions as the first server (e.g., the same time period, the same storage capacity) is less than a certain threshold, or the data on the third server is displayed abnormally on the electronic device (e.g., the image data cannot be displayed, the image data cannot load the original image, etc., the displayed photo ratio is different from the photo ratio stored on the old object storage service provider), the third server is determined to be in a fault state.

[0147] The client module 303 can be used to receive data from the object storage service provider, and process the data (such as image compression, watermark processing, image encryption) based on the processing parameters and processing logic script (such as JavaScript script) of the object storage service provider where the data is sent by the configuration management module 301 or the fourth server, and the processed data can be displayed normally on the client module 303 (electronic device).

[0148] To facilitate understanding of the technical solution of the embodiment of the present application, the electronic device 400 is taken as an example to illustrate the structure of an electronic device to which the data processing method provided in the embodiment of the present application is applicable.

[0149] For example, Figure 6 According to some embodiments of the present application, a structural schematic diagram of an electronic device 400 is shown.

[0150] like Figure 6 As shown, the electronic device 400 includes one or more processors 101, a system memory 102, a non-volatile memory (NVM) 103, a communication interface 104, an input / output (I / O) device 105, and a system control logic 106 for coupling the processor 101, the system memory 102, the non-volatile memory 103, the communication interface 104 and the input / output device 105. Among them:

[0151] The processor 101 can be used to control the electronic device 400 to execute the data processing method of the present application. The processor 101 may include one or more processing units, for example, a central processing unit (CPU), a graphics processing unit (GPU), a digital signal processor (DSP), a microprocessor (MCU), an artificial intelligence (AI) processor or a processing module or processing circuit of a programmable logic device (FPGA). The processor 101 may include one or more single-core or multi-core processors.

[0152] The processor 101 can be used to control the electronic device 400 to execute the data processing method of the present application. The processor 101 may include one or more processing units, for example, a central processing unit (CPU), a graphics processing unit (GPU), a digital signal processor (DSP), a microprocessor (MCU), an artificial intelligence (AI) processor or a processing module or processing circuit of a programmable logic device (field programmable gate array, FPGA). The processor 101 may include one or more single-core or multi-core processors. In some embodiments, the processor 101 may be used to execute the data processing method in the embodiment of the present invention.

[0153] The system memory 102 is a volatile memory, such as a random-access memory (RAM), a double data rate synchronous dynamic random access memory (DDR SDRAM), etc. The system memory is used to temporarily store data and / or instructions.

[0154] The non-volatile memory 103 may include one or more tangible, non-transitory computer-readable media for storing data and / or instructions. In some embodiments, the non-volatile memory 103 may include any suitable non-volatile memory such as a flash memory and / or any suitable non-volatile storage device, such as a hard disk drive (HDD), a compact disc (CD), a digital versatile disc (DVD), a solid-state drive (SSD), etc. In some embodiments, the non-volatile memory 103 may also be a removable storage medium, such as a secure digital (SD) memory card, etc.

[0155] In particular, the system memory 102 and the non-volatile memory 103 may respectively include: a temporary copy and a permanent copy of the instruction 107. The instruction 107 may include: when executed by the processor 101, the electronic device 400 implements the data processing method provided by each embodiment of the present application.

[0156] The communication interface 104 may include a transceiver for providing a wired or wireless communication interface for the electronic device 400, thereby communicating with any other suitable device through one or more networks. In some embodiments, the communication interface 104 may be integrated into other components of the electronic device 400, for example, the communication interface 104 may be integrated into the processor 101. In some embodiments, the electronic device 400 may communicate with other devices through the communication interface 104.

[0157] The input / output device 105 may include input devices such as a keyboard, a mouse, etc., and output devices such as a display, etc. A user may interact with the electronic device 400 through the input / output device 105 .

[0158] System control logic 106 may include any suitable interface controller to provide any suitable interface with other modules of electronic device 400. For example, in some embodiments, system control logic 106 may include one or more memory controllers to provide interfaces to system memory 102 and non-volatile memory 103.

[0159] In particular, the system control logic 106 can also be used to determine whether the server of the object storage service provider is in a normal state. The system control logic 106 determines whether the number of data resource uploads is within a set threshold range through parameters (such as data upload rate, etc.) collected by the sensor 108 within a preset time period, and then determines whether the server of the object storage service provider is in a normal state.

[0160] The sensor 108 monitors the data upload rate of the server of the object storage service provider at regular preset time intervals. By collecting the amount of data uploaded in the preset time period, the sensor module generates dynamic data of resource upload and transmits it to the system control logic 106 to determine whether the server of the object storage service provider is in a normal state.

[0161] In some embodiments, at least one of the processors 101 may be packaged together with the logic of one or more controllers for the system control logic 106 to form a system in package (SiP). In other embodiments, at least one of the processors 101 may also be integrated on the same chip with the logic of one or more controllers for the system control logic 106 to form a SoC.

[0162] Understandably, Figure 6 The structure of the electronic device 400 shown is only an example. In other embodiments, the electronic device 400 may include more or fewer components than shown, or combine some components, or split some components, or arrange the components differently. The components shown in the figure may be implemented in hardware, software, or a combination of software and hardware.

[0163] In some embodiments, the embodiments of the present application also provide a server, which sends a first processing parameter to the electronic device in response to a first acquisition instruction sent by the electronic device; wherein the first processing parameter is a data processing parameter corresponding to the first server; and sends a second processing parameter to the electronic device in response to a second acquisition instruction sent by the electronic device; wherein the second processing parameter is a data processing parameter corresponding to a third server, wherein the first server and the third server are servers of different operators.

[0164] In some embodiments, the embodiments of the present application also provide a readable storage medium, which stores at least one computer program instruction, at least one program, code set or instruction set. The at least one computer program instruction, at least one program, code set or instruction set is loaded and executed by the model training system to implement the data processing methods provided by the above-mentioned method embodiments.

[0165] The various embodiments of the mechanism disclosed in the present application can be implemented in hardware, software, firmware or a combination of these implementation methods. The embodiments of the present application can be implemented as a computer program or program code executed on a programmable system, which includes at least one processor, a storage system (including volatile and non-volatile memory and / or storage elements), at least one input device and at least one output device.

[0166] Program code may be applied to input instructions to perform the functions described herein and to generate output information. The output information may be applied to one or more output devices in a known manner. For purposes of this application, a processing system includes any system having a processor such as, for example, a digital signal processor (DSP), a microcontroller, an application specific integrated circuit (ASIC), or a microprocessor.

[0167] Program code can be implemented with high-level programming language or object-oriented programming language to communicate with the processing system. When necessary, program code can also be implemented with assembly language or machine language. In fact, the mechanism described in this application is not limited to the scope of any specific programming language. In either case, the language can be a compiled language or an interpreted language.

[0168] In some cases, the disclosed embodiments may be implemented in hardware, firmware, software, or any combination thereof. The disclosed embodiments may also be implemented as instructions carried or stored on one or more temporary or non-temporary machine-readable (e.g., computer-readable) storage media, which may be read and executed by one or more processors. For example, the instructions may be distributed over a network or through other computer-readable media. Therefore, a machine-readable medium may include any mechanism for storing or transmitting information in a machine (e.g., computer) readable form, including but not limited to floppy disks, optical disks, optical disks, read-only memories (CD-ROMs), magneto-optical disks, read-only memories (ROMs), random access memories (RAMs), erasable programmable read-only memories (EPROMs), electrically erasable programmable read-only memories (EEPROMs), magnetic or optical cards, flash memory, or a tangible machine-readable memory for transmitting information (e.g., carrier waves, infrared signals, digital signals, etc.) using the Internet in electrical, optical, acoustic, or other forms of propagation signals. Accordingly, machine-readable media include any type of machine-readable media suitable for storing or transmitting electronic instructions or information in a form readable by a machine (eg, a computer).

[0169] In the accompanying drawings, some structural or method features may be shown in a specific arrangement and / or order. However, it should be understood that such a specific arrangement and / or order may not be required. Instead, in some embodiments, these features may be arranged in a manner and / or order different from that shown in the illustrative drawings. In addition, the inclusion of structural or method features in a particular figure does not mean that such features are required in all embodiments, and in some embodiments, these features may not be included or may be combined with other features.

[0170] It should be noted that the units / modules mentioned in the various device embodiments of the present application are all logical units / modules. Physically, a logical unit / module can be a physical unit / module, or a part of a physical unit / module, or can be implemented as a combination of multiple physical units / modules. The physical implementation method of these logical units / modules themselves is not the most important. The combination of functions implemented by these logical units / modules is the key to solving the technical problems proposed by the present application. In addition, in order to highlight the innovative part of the present application, the above-mentioned device embodiments of the present application do not introduce units / modules that are not closely related to solving the technical problems proposed by the present application, which does not mean that there are no other units / modules in the above-mentioned device embodiments.

[0171] It should be noted that in the examples and description of this patent, the terms "include", "comprises" or any other variations thereof are intended to cover non-exclusive inclusion, so that a process, method, article or device including a series of elements includes not only those elements, but also other elements not explicitly listed, or also includes elements inherent to such process, method, article or device. In the absence of more restrictions, the elements defined by the sentence "comprises one" do not exclude the existence of other identical elements in the process, method, article or device including the elements.

[0172] Although the present application has been illustrated and described with reference to certain embodiments thereof, it will be apparent to those skilled in the art that various changes in form and details may be made therein without departing from the spirit and scope of the present application.

Claims

1. A data processing method, characterized in that: Used in electronic equipment, including: At a first moment, when a first viewing instruction is detected, a first acquisition request is sent to a first server and a second server; the first viewing instruction indicates viewing first data stored in the first server; receiving the first data sent by the first server and a first processing parameter sent by the second server; the first processing parameter is a data processing parameter corresponding to the first server; At a second moment, when a second viewing instruction is detected, a second acquisition request is sent to a third server and the second server; the second viewing instruction instructs viewing second data stored in the third server, the first moment and the second moment are different moments, and the first server and the third server are servers of different operators; receiving the second data sent by the third server and a second processing parameter sent by the second server; the second processing parameter is a data processing parameter corresponding to the third server; processing the first data based on the first processing parameter, and displaying the processed first data; processing the second data based on the second processing parameter, and displaying the processed second data; The displayed contents of the processed first data and the processed second data are consistent.

2. The method according to claim 1, characterized in that The method further comprises: At a third moment, when a first storage instruction is detected, the first data is sent to the first server; wherein the first storage instruction instructs the first server to store the first data; and the third moment is earlier than the first moment; At a fourth moment, when a second storage instruction is detected, the second data is sent to the first server and the third server; wherein the second storage instruction instructs the first server and the third server to store the second data respectively; the fourth moment is earlier than the second moment, and the fourth moment is later than the third moment.

3. The method according to claim 2, characterized in that The method further comprises: At a fifth moment, when a third storage instruction is detected and the third server is normal, continue to send the third data to the third server and stop sending the third data to the first server; The third storage instruction instructs the third server to store the third data, and the fifth moment is later than the fourth moment.

4. The method according to claim 3, characterized in that The method further comprises: At a sixth moment, when a fourth storage instruction is detected and the third server fails, stopping sending the fourth data to the third server and sending the fourth data to the first server; The fourth storage instruction instructs the first server to store the fourth data, and the sixth moment is later than the fifth moment.

5. A data processing system, characterized in that: The data processing system includes an electronic device, a first server, a second server and a third server, wherein the first server and the third server are servers of different operators, and the second server stores a first processing parameter corresponding to the first server and a second processing parameter corresponding to the third server; When a first viewing instruction is detected at a first moment, the electronic device sends a first acquisition request to the first server and the second server; The first viewing instruction instructs viewing the first data stored in the first server; The first server sends the first data to the electronic device in response to the first acquisition request, and the second server sends a first processing parameter to the electronic device in response to the first acquisition request; The electronic device receives the first data sent by the first server and the first processing parameter sent by the second server; When a second viewing instruction is detected at a second moment, the electronic device sends a second acquisition request to the third server and the second server; The second viewing instruction instructs viewing the second data stored in the third server; The third server sends the second data to the electronic device in response to the second acquisition request, and the second server sends a second processing parameter to the electronic device in response to the second acquisition request; The electronic device receives the second data sent by the third server and the second processing parameter sent by the second server; The electronic device processes the first data based on the first processing parameter and displays the processed first data; The electronic device processes the second data based on the second processing parameter and displays the processed second data; The displayed contents of the processed first data and the processed second data are consistent.

6. The system according to claim 5, characterized in that When the first storage instruction is detected at the third moment, the electronic device sends the first data to the first server; The first server stores the first data in response to the first storage instruction; The third moment is earlier than the first moment; When the second storage instruction is detected at the fourth moment, the electronic device sends the second data to the first server and the third server; The first server stores the second data in response to the second storage instruction; The third server stores the second data in response to the second storage instruction; The fourth moment is earlier than the second moment, and the fourth moment is later than the third moment.

7. The system according to claim 6, characterized in that When the electronic device detects the third storage instruction at the fifth moment and the third server is normal, the electronic device continues to send the third data to the third server and stops sending the third data to the first server; The third server stores the third data in response to the third storage instruction, and the fifth time is later than the fourth time.

8. The system according to claim 6, characterized in that When a fourth storage instruction is detected at a sixth moment and the third server fails, the electronic device sends fourth data to the first server and stops sending the fourth data to the third server; The first server stores the fourth data in response to the fourth storage instruction, and the sixth time is later than the fifth time.

9. A readable storage medium, characterized in that: The readable storage medium stores instructions, and when the instructions are executed on an electronic device, the electronic device executes the data processing method according to any one of claims 1 to 4.

Citation Information

Patent Citations

  • Data processing control method and device, computer equipment and storage medium

    CN116048817A

  • Card service processing system for docking multiple operators

    CN117156425A