Data uploading method and electronic equipment

By generating and identifying private data on electronic devices during cloud development and uploading it to the server with public data, the problem of data leakage in cloud development is solved and data security protection is achieved.

CN119449331APending Publication Date: 2025-02-14HUAWEI TECH CO LTD
View PDF 0 Cites 0 Cited by

Patent Information

Application Number
CN202310949721.6
Authority / Receiving Office
CN · China
Patent Type
Applications(China)
Current Assignee / Owner
Filing Date
2023-07-28
Publication Date
2025-02-14

AI Technical Summary

Technical Problem

During cloud development, the extended structured data uploaded by application developers may be accessed and modified by other application developers, resulting in data leakage.

Method used

By generating private data based on public data on an electronic device and uploading application identification, private data and public data to the server simultaneously, the server can identify and protect private data based on application identification to prevent it from being accessed by other applications.

Benefits of technology

It effectively avoids data leakage during cloud development and ensures the security of private data uploaded by application developers.

✦ Generated by Eureka AI based on patent content.

Smart Images

  • Figure CN119449331A_ABST
    Figure CN119449331A_ABST
Patent Text Reader

Abstract

The invention relates to the technical field of computers, and provides a data uploading method which is applied to electronic equipment and comprises the steps that a first request is sent to a server, the first request is used for obtaining first public data, and an object of the first public data comprises a first data model; receiving the first public data from the server; first private data of a first application is generated according to the first public data, the first private data belongs to the first data model, or the first private data belongs to a second data model, and the second data model is a newly added data model in the first public data; and uploading a first application identifier, the first private data and the first public data to the server, wherein the first application identifier is used for indicating that the first private data is the private data of the first application. The method can solve the problem of data leakage in the cloud development process.
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 method and electronic device for uploading data. Background Art

[0002] With the rapid development of cloud computing technology, cloud service providers have provided application developers with increasingly convenient data access methods; application developers can obtain public structured data from the cloud to develop various applications, and synchronize the data of the developed applications to cloud storage. This method can be called cloud development.

[0003] During the cloud development process, public structured data can be accessed and modified by different application developers. For example, application developer A obtains public structured data from the cloud and develops his own application based on the public structured data. During the development process, since public structured data usually cannot meet business needs, application developer A usually expands the data structure of public structured data according to the business needs of the application to be developed, and synchronizes the expanded structured data D1 to the cloud; however, the expanded structured data D1 uploaded by application developer A can be accessed and modified by other application users. For example, application developer B can access and modify the expanded structured data D1 uploaded by application developer A, resulting in the leakage of data uploaded by application developer A.

[0004] Therefore, how to solve the problem of data leakage in the cloud development process is an urgent problem that needs to be solved. Summary of the invention

[0005] In order to solve the problem of data leakage in the cloud development process, the embodiment of the present application provides a method and electronic device for uploading data. The technical solution is as follows:

[0006] In a first aspect, a method for uploading data is provided, which is applied to an electronic device, and the method includes: sending a first request to a server, the first request is used to obtain first public data, and the object of the first public data includes a first data model; receiving the first public data from the server; generating first private data of a first application based on the first public data, the first private data belongs to the first data model, or the first private data belongs to the second data model, and the second data model is a data model newly added to the first public data; uploading a first application identifier, the first private data and the first public data to the server, the first application identifier is used to indicate that the first private data is private data of the first application.

[0007] The above method can be executed by an electronic device, or by a module (such as a processor, a chip, or a chip system, etc.) applied to the electronic device, or by a logical node, a logical module, or software that can realize all or part of the functions of the electronic device. In the prior art, public data and private data generated based on public data are stored on a server. Based on factors such as privacy policy, the server cannot distinguish which data is public data and which data is private data, which may result in the private data of developer A being obtained by developer B. In the present application, after the electronic device generates the first private data of the first application based on the first public data, the first application identifier and the first private data are uploaded to the server at the same time. The server can identify the first private data as the private data of the first application based on the first application identifier. If other applications (for example, the second application) obtain public data, the server will not send the first private data to the second application, thereby avoiding data leakage in the cloud development process.

[0008] In an optional implementation, generating first private data of a first application based on first public data includes: adding a first field to a first data model of the first public data, and / or adding a second data model to the first public data to generate the first private data of the first application.

[0009] When an electronic device expands the first public data according to the business needs of the first application, it can add a first field to the first data model of the first public data, and / or add a second data model to the first public data to generate first private data; this method of extending the first public data not only expands the dimension of the method of generating private data, but also improves the flexibility of application developers in choosing the method of expanding the first public data.

[0010] In an optional implementation, a second request is sent to the server, where the second request is used to obtain the first private data and the first public data, and the second request includes the first application identifier;

[0011] First private data and first public data are received from a server.

[0012] The electronic device sends a second request including the first application identifier to the server, so that the server obtains the first private data and the first public data corresponding to the first application according to the first application identifier.

[0013] In an optional implementation, receiving first private data and first public data from a server includes:

[0014] A data message is received from a server, where the data message includes first private data and first public data corresponding to the first application.

[0015] Compared with a method of receiving the first private data and the first public data from the server separately, the electronic device can save communication resources by receiving the first private data and the first public data at one time through a data message.

[0016] In a second aspect, a method for receiving data is provided, which is applied to a server, and the method includes:

[0017] Receiving a first request from an electronic device, the first request is used to obtain first public data, and an object of the first public data includes a first data model;

[0018] In response to the first request, sending first public data;

[0019] A first application identifier, first private data and first public data are received from an electronic device, where the first application identifier is used to indicate that the first private data is private data of a first application, the first private data is data of the first application generated by the electronic device based on the first public data, and the first private data belongs to a first data model, or the first private data belongs to a second data model, and the second data model is a data model newly added to the first public data.

[0020] The above method can be executed by a server, or by a module (such as a processor, chip, or chip system, etc.) applied to the server, or by a logical node, logical module, or software that can realize all or part of the server functions. In the prior art, public data and private data generated based on public data are stored on the server. Based on factors such as privacy policy, the server cannot distinguish which data is public data and which data is private data, which may cause the private data of developer A to be obtained by developer B. In this application, after the electronic device generates the first private data of the first application based on the first public data, the first application identifier and the first private data are uploaded to the server at the same time; the server can identify the first private data as the private data of the first application based on the first application identifier. If other applications (for example, the second application) obtain public data, the server will not send the first private data to the second application, thereby avoiding data leakage in the cloud development process.

[0021] In an optional implementation, the method further includes: receiving a second request from the electronic device, the second request being used to obtain the first private data and the first public data, the second request including the first application identifier;

[0022] Acquire first public data and first private data corresponding to the first application according to the first application identifier;

[0023] The first public data and the first private data are sent to the electronic device.

[0024] In response to the second request, the server can accurately query the data accessible to the first application, such as the first public data and the first private data, according to the first application identifier.

[0025] In an optional implementation, sending the first public data and the first private data to the electronic device includes: assembling the first public data and the first private data into a data message;

[0026] Send data messages to electronic devices.

[0027] Compared with sending the first private data and the first public data to the electronic device separately, the server assembles the first public data and the first private data into a data message and sends it to the electronic device at one time, which can save communication resources.

[0028] In an optional implementation, the method further includes: receiving first application data from an electronic device, the first application data including a first application identifier, second public data, second private data, and business data;

[0029] Querying the first public data and the first private data according to the first application identifier;

[0030] When the first public data and the second public data are identical, and the first private data and the second private data are identical, it is determined to update previous business data of the first application according to the business data.

[0031] When an electronic device uploads first application data to a server, the server will query the first public data and the first private data that the first application can access based on the first application identifier, and determine whether to update the previous business data of the first application based on the comparison result of the first public data and the first private data with the second public data and the second private data, rather than directly updating the previous business data of the first application with the uploaded business data, thereby ensuring the security of the update of the first application data.

[0032] In an optional implementation, the first public data is structured data defined by a schema.

[0033] According to a third aspect, an electronic device is provided. The electronic device includes a processor and a memory, wherein the memory is used to store a computer program, and the processor is used to call and run the computer program from the memory, so that the electronic device executes any one of the methods in the first aspect.

[0034] In a fourth aspect, an electronic device is provided, the electronic device comprising a processor and a memory, the memory being used to store a computer program, and the processor being used to call and run the computer program from the memory, so that the electronic device executes any one of the methods in the second aspect.

[0035] In a fifth aspect, a computer-readable storage medium is provided, wherein the computer-readable storage medium stores a computer program, and when the computer program is executed by a processor, the processor executes any one of the methods in the first aspect.

[0036] In a sixth aspect, a computer-readable storage medium is provided, wherein the computer-readable storage medium stores a computer program, and when the computer program is executed by a processor, the processor executes any one of the methods in the second aspect.

[0037] In a seventh aspect, a computer program product is provided, the computer program product comprising: a computer program code, when the computer program code is executed by an electronic device, the electronic device executes any one of the methods in the first aspect.

[0038] In an eighth aspect, a computer program product is provided, the computer program product comprising: a computer program code, when the computer program code is executed by an electronic device, the electronic device executes any one of the methods in the second aspect. BRIEF DESCRIPTION OF THE DRAWINGS

[0039] Figure 1 A schematic diagram of a method for uploading data provided in an embodiment of the present application;

[0040] Figure 2 A schematic diagram of a system structure provided for an embodiment of the present application;

[0041] Figure 3 A schematic diagram of an interface provided in an embodiment of the present application;

[0042] Figure 4 Another interface schematic diagram provided for an embodiment of the present application;

[0043] Figure 5 A flowchart of another method for uploading data provided in an embodiment of the present application;

[0044] Figure 6 A schematic diagram of a process for assembling a data message provided in an embodiment of the present application;

[0045] Figure 7 A schematic diagram of a process for uploading application data provided in an embodiment of the present application;

[0046] Figure 8 A schematic diagram of another process of uploading data provided in an embodiment of the present application;

[0047] Fig. 9 A schematic diagram of a device 900 provided in an embodiment of the present application;

[0048] Fig.10 A schematic diagram of another device 1000 provided in an embodiment of the present application;

[0049] Fig.11 A schematic diagram of the structure of an electronic device provided in an embodiment of the present application. DETAILED DESCRIPTION

[0050] In the following description, specific details such as specific system structures, technologies, etc. are provided for the purpose of illustration rather than limitation, so as to provide a thorough understanding of the embodiments of the present application. However, it should be clear to those skilled in the art that the present application may also be implemented in other embodiments without these specific details. In other cases, detailed descriptions of well-known systems, devices, and methods are omitted to prevent unnecessary details from obstructing the description of the present application.

[0051] It should be understood that when used in the present specification and the appended claims, the term "comprising" indicates the presence of described features, wholes, steps, operations, elements and / or components, but does not exclude the presence or addition of one or more other features, wholes, steps, operations, elements, components and / or combinations thereof.

[0052] It should also be understood that the term “and / or” used in the specification and appended claims refers to any and all possible combinations of one or more of the associated listed items, and includes these combinations.

[0053] In addition, in the description of the present application specification and the appended claims, the terms "first", "second", "third", etc. are only used to distinguish the descriptions and cannot be understood as indicating or implying relative importance.

[0054] References to "one embodiment" or "some embodiments" etc. described in the specification of this application mean that one or more embodiments of the present application include specific features, structures or characteristics described in conjunction with the embodiment. Therefore, the statements "in one embodiment", "in some embodiments", "in some other embodiments", "in some other embodiments", etc. that appear in different places in this specification do not necessarily refer to the same embodiment, but mean "one or more but not all embodiments", unless otherwise specifically emphasized in other ways. The terms "including", "comprising", "having" and their variations all mean "including but not limited to", unless otherwise specifically emphasized in other ways.

[0055] The electronic device involved in this application can be a terminal device or an application server, and this application does not limit this.

[0056] The terminal device may include at least one of a mobile phone, a foldable electronic device, a tablet computer, a desktop computer, a laptop computer, a handheld computer, a notebook computer, an ultra-mobile personal computer (UMPC), a netbook, a cellular phone, a personal digital assistant (PDA), an artificial intelligence (AI) device, a wearable device, a vehicle-mounted device, a smart home device, or a smart city device. The embodiment of the present application does not impose any special restrictions on the specific type of the terminal device.

[0057] The server involved in this application may be a World Wide Web (Web) server or an application server (eg, a data management server), and this application does not limit this.

[0058] As described in the background technology, cloud service providers will provide application developers with more and more convenient data access methods, so that application developers can synchronize the structured data of the application end to the cloud. Since the public structured data obtained by application developers from the cloud cannot meet business needs, application developers need to expand the public structured data according to business needs. However, the data expanded by application developers and uploaded to the cloud will be accessed and modified by other application developers; therefore, how to solve the problem of data leakage in the cloud development process is an urgent problem to be solved.

[0059] Before introducing the method for uploading data provided by the present application, a brief description is first given of the execution subject involved in the embodiments of the present application. In the embodiments of the present application, an electronic device or a server is used as an example to illustrate the method provided by the present application, but the present application does not limit the execution subject.

[0060] For example, the execution subject involved in the embodiments of the present application may be an electronic device, or a chip, a chip system, or a processor applied to the electronic device, or a logical node, a logical module, or software that can realize all or part of the functions of the electronic device; the above-mentioned electronic device includes a terminal device or an application server; the terminal device may be a chip, a chip system, or a processor applied to the terminal, or a logical node, a logical module, or software that can realize all or part of the functions of the terminal. The application server may also be a chip, a chip system, or a processor applied to the application server, or a logical node, a logical module, or software that can realize all or part of the functions of the application server.

[0061] For another example, the execution subject of the method for receiving data provided in the present application may be a server, or a chip, a chip system, or a processor applied to a server, or a logical node, a logical module, or software that can implement all or part of the server functions. It should be noted that the server may be a Web server, a general server, a cloud server, or a cloud server cluster, and the present application does not limit this.

[0062] The following embodiments are described by taking as an example that the execution subject of the method 100 for uploading data is an electronic device (eg, a terminal device), and the execution subject of the method for receiving data is a server (eg, a cloud server).

[0063] Figure 1 A method for uploading data provided in an embodiment of the present application, the method 100 may specifically include S101, S102, S103 and S104.

[0064] S101, the electronic device sends a first request to the server, wherein the first request is used to obtain first public data, and the object of the first public data includes a first data model. Correspondingly, the server receives the first request from the electronic device.

[0065] The first request may be a separate request message or indication information carried in other request information.

[0066] The above server (e.g., cloud server) is used to manage the first public data and manage the private data uploaded by each application developer through an electronic device (e.g., terminal device). For example, the data management service module on the server can be used to manage the first public data and the first private data corresponding to the first application. For the description of the first private data, please refer to the following description.

[0067] The first public data may be structured data defined by a schema, or other available structured data, which is not limited in this application. The schema is used to organize objects in a database, and the objects in the schema include but are not limited to tables, indexes, data types, sequences, views, stored procedures, primary keys, and foreign keys.

[0068] For example, the first public data is structured data defined by a schema. When the electronic device queries the server for the first public data, the server returns the first public data to the electronic device in the form of a schema; for example, the server returns the first public data in the form of a schema S = {DM0: [P01, P02, P03], DM1: [P11, P12]}, wherein the schema S includes two data models DM0 and DM1, wherein DM0 includes three fields, namely P01, P02 and P03, and DM1 includes two fields, namely P11 and P12.

[0069] The object of the first public data includes at least one data model, each data model includes at least one field, wherein the data model includes but is not limited to tables, views and sequences; for example, the data model is a table structure, and the table structure includes three fields, namely name, contact information and date.

[0070] For example, the first public data includes a first data model, wherein the first data model may be a table structure, a view, etc., which is not limited in this application.

[0071] The electronic device sends a first request to the server. After receiving the first request, the server obtains the first public data and returns the first public data to the electronic device. For example, if an application developer wants to develop a first application, the application developer sends a first request to the server through the electronic device to query the first public data available to the first application; after the application developer queries the first public data through the electronic device, the application developer will check the object of the first public data and expand the object of the first public data according to the business needs of the first application; for example, the data model in the first public data is expanded or the field in the data model is expanded. The specific expansion method is described in detail below.

[0072] S102, the electronic device receives first public data from the server. Correspondingly, the server sends the first public data in response to the first request.

[0073] After receiving the first request sent by the electronic device, the server will respond to the first request, obtain the first public data in the data storage area (eg, the public data storage area), and send the first public data to the electronic device.

[0074] S103, the electronic device generates first private data of the first application according to the first public data, the first private data belongs to the first data model, or the first private data belongs to the second data model, and the second data model is a data model newly added to the first public data.

[0075] The first private data is a data object that is not included in the first public data and is expanded by the application developer according to the business requirements of the first application.

[0076] The first private data may refer to a field of private attributes newly added by the application developer in the first data model; and / or a second data model newly added in the first public data.

[0077] For example, the server returns to the electronic device the first public data schema S = {DM0: [P01, P02, P03], DM1: [P11, P12]}. After the electronic device receives the schema S returned by the server, the application developer can expand the first public data (e.g., schema S) according to the business needs of the first application, and set the expanded data objects as private attributes. For example, the application developer can add new fields to the first data model included in the first public data, and set the attributes of the newly added fields as private attributes; and / or add a new second data model to the first public data, and set the attributes of the newly added second data model as private attributes.

[0078] It should be noted that the application developer can add multiple fields to the first data model and set the attributes of the newly added multiple fields as private attributes, or add multiple data models to the first public data and set the attributes of the newly added multiple data models as private attributes, or add at least one field of private attributes to the first data model and at least one data model of private attributes to the first public data. This application does not limit this, and the application developer can expand the first public data according to the actual business needs of the first application.

[0079] It should also be noted that the data extended by the application developer on the first public data belongs to the private data of the first application, rather than public data; when extending the first public data, the application developer can define the extended data as a private attribute, so that even if the data with private attributes defined by the first application (i.e., private data) is uploaded to the server, other applications cannot access and modify the private data defined by the first application, thereby ensuring the security of the private data defined by the first application.

[0080] For example, the application developer queries schema S = {DM0: [P01, P02, P03], DM1: [P11, P12]} from the server. If the application developer wants to extend DM0 and define a field SP1 of a private attribute in DM0, the application developer can define the data of the public attributes and the data of the private attributes separately. For example, define the attributes of DM0: [P01, P02, P03] and DM1: [P11, P12] as public attributes, so that the P01, P02 and P03 fields in DM0 and the P11 and P12 fields in DM1 can be accessed by other applications. Define the field SP1 of the first application as a private attribute, so that other applications cannot access and modify the field SP1 of the first application.

[0081] In an optional implementation, even if the first application defines a private attribute field SP1, the second application can still define a private attribute field SP1 with the same name. Since the private attribute field usually allows the application to access and modify it, other applications cannot access and modify the private attribute fields of other applications. Therefore, different applications define private attribute fields so that different applications can enjoy their own independent namespaces, thereby avoiding data conflicts and overwriting problems in the access process of different applications, as well as the problem of unauthorized access to data across applications. It should be noted that the access process of different applications refers to different applications using the public data provided by the server to develop applications that meet their own business needs.

[0082] For example, the first application defines a private attribute field SP1 as its own extension field, and the second application also defines a private attribute field SP1 as its own extension field. Since the field SP1 defined by the first application and the field SP1 defined by the second application are both private attribute fields, the first application and the second application cannot access and modify the private attribute fields defined by each other, thereby avoiding the problem of data overwriting caused by different applications defining duplicate fields.

[0083] S104, the electronic device uploads the first application identifier, the first private data and the first public data to the server, the first application identifier is used to indicate that the first private data is the private data of the first application. Accordingly, the server receives the first application identifier, the first private data and the first public data from the electronic device.

[0084] The first application identifier may be a unique identifier (ID) assigned when the first application is put on the shelf, or may be a unique identifier ID that identifies the first application software package.

[0085] The first private data may be some fields of private attributes, or some data models of private attributes, or may be both fields of private attributes and data models of private attributes, which is not limited in this application.

[0086] For example, the first public data is table structure 1 and table structure 2, the first private data can be table structure 3, or the newly added field 1 and field 2 in table structure 1, or the newly added field 1 and field 2 in table structure 1 and the newly added table structure 3.

[0087] After the application developer expands the first public data according to the business needs of the first application, the first application identifier, the first private data and the first public data are uploaded to the server through the electronic device; after the server receives the first application identifier, the first private data and the first public data sent from the electronic device, the server can store the first private data in the private storage area according to the first application identifier, and store the first public data in the public storage area. When other applications query the first public data from the server, the server will obtain the first public data from the public storage area for other applications but will not obtain the first private data from the private storage area, because other applications do not have the right to access the first private data; when the first application queries the public data and private data of the first application from the server, the server will obtain the first private data from the private storage area and the first public data from the public storage area according to the first application identifier, and return the first private data and the first public data to the electronic device.

[0088] It can be seen from this that after the electronic device generates the first private data of the first application based on the first public data, it uploads the first application identifier and the first private data to the server at the same time. The server can identify that the first private data is the private data of the first application based on the first application identifier. If other applications (for example, the second application) obtain public data, the server will not send the first private data to the second application, thereby avoiding data leakage during cloud development.

[0089] In an optional implementation, the electronic device generates first private data of the first application based on the first public data, including: the electronic device adds a first field to the first data model of the first public data, and / or adds a second data model to the first public data to generate the first private data of the first application.

[0090] It should be noted that the application developer can add at least one field to the first public data through an electronic device, for example, the first field, where the first field can be a name, a date, or a contact number, etc. This application does not limit this. Since the applications developed by the application developer are different, the first field that needs to be added is also different.

[0091] The second data model may be a table structure, a view, etc. For example, the second data model is a table structure X, and the table structure X includes three fields, namely, device number, device type, and manufacturer.

[0092] For example, the first public data obtained by the electronic device from the server includes table structure 1 and table structure 2. The application developer adds field 1 (e.g., the first field) and field 2 (e.g., the second field) to table structure 1 through the electronic device according to the business needs of the first application, and defines the attributes of field 1 and field 2 as private attributes; field 1 and field 2 of the private attributes are the first private data of the first application.

[0093] For another example, the first public data obtained by the electronic device from the server includes table structure 1 and table structure 2. The application developer adds table structure 3 to the first public data through the electronic device according to the business needs of the first application, and defines the attributes of table structure 3 as private attributes; the table structure 3 of the private attributes is the first private data of the first application.

[0094] For another example, the first public data obtained by the electronic device from the server includes table structure 1 and table structure 2. The application developer adds table structure 3 to the first public data through the electronic device according to the business needs of the first application, and defines the attributes of table structure 3 as private attributes; at the same time, a new field X is added to table structure 2, and field X is defined as a private attribute. At this time, the table structure 3 of the private attribute and the field X of the private attribute are the first private data of the first application.

[0095] In this embodiment, when the electronic device expands the first public data according to the business needs of the first application, it can add a first field to the first data model of the first public data, and / or add a second data model to the first public data to generate the first private data; this method of extending the first public data not only expands the dimension of the method of generating private data, but also improves the flexibility of application developers in choosing the method of extending the first public data.

[0096] In an optional implementation, the method 100 further includes steps S201 and S202, wherein the specific steps of S201 and S202 are as follows:

[0097] S201: The electronic device sends a second request to the server, the second request is used to obtain the first private data and the first public data, and the second request includes a first application identifier. Correspondingly, the server receives the second request from the electronic device.

[0098] The second request includes the first application identifier and indication information, where the indication information is used to instruct the electronic device to obtain the first private data and the first public data.

[0099] The electronic device may send the second request to the server via a wireless network or the like, and correspondingly, the server may receive the second request via a wireless network or the like; the server determines the data accessible to the first application based on the first application identifier in the second request.

[0100] S202: The electronic device receives first private data and first public data from the server. Accordingly, the server obtains first public data and first private data corresponding to the first application according to the first application identifier, and sends the first public data and first private data to the electronic device.

[0101] Exemplarily, after receiving the second request, the server will determine which private data and public data the first application can access based on the first application identifier. For example, the server can determine that the first application can access the first private data and the first public data based on the first application identifier. At this time, the server will obtain the first private data from the private storage area and obtain the first public data from the public storage area; thereafter, the obtained first private data and first public data will be sent to the electronic device.

[0102] In this embodiment, the electronic device sends a second request including a first application identifier to the server, so that the server obtains the first private data and the first public data corresponding to the first application according to the first application identifier.

[0103] In an optional implementation, the electronic device receives the first private data and the first public data from the server, including: the electronic device receives a data message from the server, the data message including the first private data and the first public data corresponding to the first application. Correspondingly, the server sends the first public data and the first private data to the electronic device, including: the server assembles the first public data and the first private data into a data message, and sends the data message to the electronic device.

[0104] Among them, a data message is a data unit exchanged and transmitted in a network, that is, a data block to be sent by a station (for example, a server) at one time.

[0105] Exemplarily, after the server queries the first public data and the first private data according to the first application identifier, it can send the first public data and the first private data to the electronic device respectively in two times, or assemble the first private data and the first public data into a data message, and send the data message to the electronic device at one time. Correspondingly, the electronic device can receive the first private data and the first public data sent by the server in two times, or receive the data message sent by the server at one time.

[0106] In this embodiment, compared with a method of receiving the first private data and the first public data from the server separately, the electronic device receives the first private data and the first public data at one time through a data message, which can save communication resources.

[0107] In an optional implementation, the above-mentioned method for receiving data also includes: the server receives first application data from an electronic device, the first application data including a first application identifier, second public data, second private data and business data; the server queries the first public data and the first private data according to the first application identifier; when the first public data and the second public data are the same, and the first private data and the second private data are the same, the server determines to update the previous business data of the first application according to the business data.

[0108] Among them, business data is application data generated by the first application during the business operation process; the second public data can refer to the public data of the first application, for example, the second public data is table structure 1, and the second private data can refer to the field of the private attribute corresponding to the first application or the data model of the private attribute, for example, the second private data is field 1 newly added by the application developer in table structure 1, and / or, the Xth data model newly added on the basis of the second public data; the relevant description of the second public data can refer to the relevant description of the first public data, and the relevant description of the second private data can refer to the relevant description of the first private data, which will not be repeated here.

[0109] For example, the second public data of the first application includes the first data model and the second data model, wherein the first data model includes field 1 and field 2, the second data model includes field 3 and field 4, and the second private data includes field X1 and the Y1st data model, wherein field X1 is the field of the newly added private attribute in the first data model, and the Y1st data model is the data model of the newly added private attribute in the second public data; if the first public data includes the first data model and the second data model, wherein the first data model includes field 1 and field 2, the second data model includes field 3 and field 4, and the first private data includes field X1 and the Y1st data model, it means that the data of the second public data and the first public data are the same, and the data of the first private data and the second private data are the same, at this time, the server determines that the business data in the first application data can be used to update the previous business data of the first application. If the second public data is different from the first public data, and / or the second private data is different from the first private data, the server can determine not to update the previous business data of the first application according to the business data, and can also feedback error information to the electronic device to remind the electronic device that the upload of the first application data failed.

[0110] In this embodiment, when the electronic device uploads the first application data to the server, the server will first query the first public data and the first private data that the first application can access based on the first application identifier, and determine whether to update the previous business data of the first application based on the comparison result of the first public data and the first private data with the second public data and the second private data, rather than directly updating the previous business data of the first application with the uploaded business data, thereby ensuring the security of the update of the first application data.

[0111] The above describes the implementation of method 100 and the method for receiving data in detail. The following further describes the method 100 and the method for receiving data in combination with interface display and flow chart.

[0112] like Figure 2 As shown, a system architecture 200 suitable for the present application is shown; the system architecture 200 includes: a developer console 201, a schema management service module 202, a data uplink service module 203 and a data downlink service module 204, wherein the developer console 201 is used to provide application developers with functions such as adding, modifying, deleting and querying public data, private data, data models and fields; the schema management service module 202 is used to provide backend interface services to the developer console 201 (for example, managing the first public data and the first private data uploaded by the application developer through the electronic device), and also provides the data uplink service module 203 and the data downlink service module 204 with synchronization data field verification and application data read and write permission verification interface services; the data uplink service module 203 is used to save the synchronized uplink data from the electronic device; the data downlink service module 204 is used to provide query services to the electronic device, for example, the data downlink service module 204 can send the first public data and the first private data to the electronic device, or send a data message to the electronic device.

[0113] It should be noted that the developer console (console) 201, schema management service module 202, data uplink service module 203 and data downlink service module 204 can belong to functional modules on the same server, or to modules on different servers, or to functional modules on multiple servers in the same server cluster, and this application does not limit this.

[0114] For example, Figure 2As shown, the application developer logs in to the developer console 201 through an electronic device, and queries the first public data needed to be used (or needed to be accessed) for developing the first application on the interface of the developer console 201; the developer console 201 responds to the query request of the application developer and sends the query request to the schema management service module 202, wherein the query request includes the first application identifier; the schema management service module 202 queries the first public data and the first private data corresponding to the first application according to the first application identifier in the query request, and returns the first public data and the first private data to the schema management service module 202; the schema management service module 202 displays the first public data and the first private data on the interface of the developer console 201, so that the application developer can view the definition of the data objects in the first public data and the first private data. The user uses the terminal application (for example, the first application) to upload data to the server side or obtain data from the server side through the data uplink service module 203 or the data downlink service module 204.

[0115] For example, Figure 3 As shown, the application developer logs in to the developer console 201 through an electronic device; the application developer can edit query, modify, delete and other statements on the editing interface 301 of the developer console 201, and submit the edited statement through the submit button 302; the developer console 201 will respond to the edited statement and display the edited result corresponding to the edited statement (for example, the query result corresponding to the query statement) on the result display interface 303; the application developer can view the edited result on the result display interface 303. It should be noted that the programming language used for the edited statement can be the language defined by the developer console 201.

[0116] For example, Figure 4 As shown, the application developer enters a query statement on the editing interface 301, such as queryS... Figure 4 As shown in 401, the first public data and the first private data of the first application are queried; the developer console 201 sends the query request to the schema management service module 202, wherein the query request includes the first application identifier; the schema management service module 202 queries the first public data and the first private data that can be accessed and queried by the first application according to the first application identifier, and sends the first public data and the first private data to the developer console 201; the developer console 201 displays the first public data and the first private data on the result display interface 303, as shown in Figure 4 As shown in 402, it is convenient for application developers to view.

[0117] To facilitate understanding, the following Figures 5 to 8 The specific process steps of the method for uploading data are further explained.

[0118] like Figure 5 As shown, a flow chart of a method for uploading data applicable to the present application is shown, and the specific process steps are as follows:

[0119] It should be noted that if the schema S of the first public data contains two data models, namely DM0 and DM1, and application X has been connected and is to be connected to the first application, application X extends DM0 based on schema S, for example, private attribute SP1 is defined in DM0. The first public data stored on the server side are DM0 and DM1, and private data SP1 of application X; for example, the storage form of the first public data on the server side can be S={DM0:[<p01,v01> ,<p02,v02> ,<p03,v03> ,<A1|SP1,”this is private data of A1”> ]DM1:[<p11,v11> ,<p12,v12> ]}.

[0120] S501: A first application developer logs in to the developer console 201 and checks the schema S definition of the first public data.

[0121] S502: the developer console 201 sends a first query request to the schema management service module 202, where the first query request is used to query the Schema S definition.

[0122] S503: In response to the first query request, the schema management service module returns the definition of the schema S of the first public data to the developer console 201, for example, returns schema S = {DM0: [P01, P02, P03], DM1: [P11, P12]}.

[0123] S504: the developer console 201 displays the definition of the schema S of the first public data on the user interface, so that the first application developer can view the definition of the schema S.

[0124] S505: The first application developer expands DM0 on the editing interface of the developer console 201, for example, defines a field SP1 of a private attribute in DM0.

[0125] S506: The developer console 201 sends an update request to the schema management service module 202, and the update request is used to update the definition of schema S on the server side. The developer console 201 sends the first private data and the first public data of the first application developer's extension of schema S to the schema management service module 202; the schema management service module 202 updates the schema S on the server side using the first private data and the first public data; after the update, the schema S stored on the server side is as follows:

[0126] S={

[0127] public:{DM0:[P01,P02,P03],DM1:[P11,P12]}, / / Public attributes

[0128] A1:{DM0:[SP1]}, / / Private properties of application X

[0129] A2:{DM0:[SP1]} / / Private properties of the first application

[0130] }

[0131] S507: The user uses an electronic device to open the first application, and sends a second query request to the data downlink service module 204 through the first application. The second query request is used to query the first public data and the first private data corresponding to the first application. The second query request includes the first application identifier.

[0132] S508: The data downlink service module 204 forwards the second query request to the schema management service module 202.

[0133] S509: The schema management service module 202 queries the first application's permission to access private data and public data according to the first application identifier in the second query request, and returns the data structure of the private data and public data that the first application can specifically access to the data downlink service module 204.

[0134] S510: The data downlink service module 204 determines that the first application can query the first public data and the first private data belonging to the first application based on the data structure of the private data and public data that the first application can specifically access returned by the schema management service module 202, and assembles the first public data and the second public data into a data message.

[0135] For example, Figure 6As shown, the data downlink service module 204 reads the data structure of private data or public data that the first application can access, and determines whether to obtain data from the private storage area or the public storage area according to whether it is a data structure of private data. If the data downlink service module 204 reads the data structure of private data corresponding to the first application, the data downlink service module 204 obtains the first private data from the private storage area; if the data downlink service module 204 reads the data structure of public data corresponding to the first application, the data downlink service module 204 obtains the first public data from the public storage area; the data downlink service module 204 assembles the first public data and the first private data into a data message.

[0136] S511: The data downlink service module 204 returns the data message to the first application.

[0137] S512: When the user uses the first application, local service data will be updated, and the first application can update the server-side service data through the data uplink service module 203. For example, the first application sends a data update request to the data uplink service module 203, and the data update request includes the first application identifier.

[0138] It should be noted that, during the use of the first application, the business data will be stored according to the data structure defined by the first public data and the second public data corresponding to the first application. Therefore, when the first application uploads the first application data to the server, the server will perform field verification on the data structure defined by the first public data and the second public data where the business data in the first application data is stored.

[0139] S513: The data uplink service module 203 sends a third query request to the schema management service module 202 according to the data update request, wherein the third query request includes a first application identifier and is used to query the data structure of the first public data and the first private data corresponding to the first application.

[0140] S514 : The schema management service module 202 queries the data structure of the first public data and the first private data corresponding to the first application according to the first application identifier in the third query request, and sends the data structure of the first public data and the first private data corresponding to the first application to the data uplink service module 203 .

[0141] S515: The data uplink service module 203 compares and verifies the fields of the second public data and the second private data in the first application data that needs to be uploaded by the first application according to the data structures of the first public data and the first private data, wherein the first application data includes a first application identifier, second public data, second private data and business data; when the fields corresponding to the first public data and the second public data are the same, and the fields corresponding to the first private data and the second private data are the same, the data uplink service module 203 on the server side determines to update the previous business data of the first application according to the business data in the first application data.

[0142] For example, Figure 7 As shown, the data uplink service module 203 reads the first public data (or the first private data), and traverses the second public data (or the second private data) according to the first public data (or the first private data); when the second public data (or the second private data) does not have an unmatched data object (or data field or data model), the comparison ends; when the second public data (or the second private data) still has an unmatched data object, continue to traverse the second public data (or the second private data) according to the first public data (or the first private data); the data uplink service module 203 determines whether the field A or the data model A in the second private data (or the second public data) is private data according to the first private data (or the first public data); if the field A or the data model A is an object in the second private data, the field A or the data model A is stored in the private temporary buffer; otherwise, the field A or the data model A is stored in the public temporary buffer. After multiple rounds of traversal and comparison, if the object (also called data object or field or data model) in the second public data is the same as the object in the first public data, the business data corresponding to the second public data in the business data is updated to the business data corresponding to the first public data of the first application; if the object in the second public data is different from the object in the first public data, an alarm message of update failure is sent to the first application; similarly, if the object in the second private data is the same as the object in the first private data, the business data corresponding to the second private data in the business data is updated to the business data corresponding to the first private data of the first application; if the object in the second private data is different from the object in the first private data, an alarm message of update failure is sent to the first application.

[0143] It should be noted that, in another possible implementation, the first application developer adds a new data model of private attributes (for example, the second data model) based on the definition of schema S according to the first business requirement, that is, the first private data is the data model of the newly added private attributes; the first application developer uploads the first public data and the first private data (for example, the second data model) to the server through the data uplink service module 203. Figure 8 As shown in 801, when the first application uploads the first application data to the server, the data uplink service module 203 can first verify whether there is a data model of private attributes when verifying the data objects in the second private data (or the second public data) and the first private data (or the first public data). If there is a data model of private attributes, the data model of private attributes is stored in a private temporary buffer, and there is no need to verify and compare each field in the data model of private attributes with each field in the first private data; if there is no data model of private attributes, then execute Figure 7 The verification process shown.

[0144] Fig. 9 The present application provides a structural schematic diagram of a device 900 for uploading data; the device 900 includes: a transceiver module 901 and a processing module 902;

[0145] The transceiver module 901 is used to send a first request to the server, the first request is used to obtain first public data, the object of the first public data includes a first data model, and is also used to receive the first public data from the server, and is also used to upload the first application identifier, the first private data and the first public data to the server, the first application identifier is used to indicate that the first private data is private data of the first application.

[0146] The processing module 902 is used to generate first private data of the first application according to the first public data, where the first private data belongs to the first data model, or the first private data belongs to the second data model, where the second data model is a data model newly added to the first public data.

[0147] The specific method of executing the method of uploading data by the device 900 and the beneficial effects produced can be found in Figure 1 Related description in the method embodiment shown.

[0148] In the device 900, the processing module 902 is specifically used to: add a first field to a first data model of the first public data, and / or, add a second data model to the first public data, to generate first private data of the first application. The beneficial effects of this part can be seen from the above embodiments.

[0149] In the device 900, the transceiver module 901 is further used to: send a second request to the server, the second request is used to obtain the first private data and the first public data, the second request includes the first application identifier, and is further used to receive the first private data and the first public data from the server. The beneficial effects of this part can be referred to the above embodiments.

[0150] In the device 900, the transceiver module 901 is further used to: receive a data message from the server, the data message including the first private data and the first public data corresponding to the first application. The beneficial effects of this part can be referred to the above embodiments.

[0151] In the device 900, the first public data is structured data defined by a schema. The beneficial effects of this part can be seen from the above embodiments.

[0152] Fig.10 The present application provides a schematic structural diagram of a device 1000 for receiving data; the device 1000 includes: a transceiver module 1001 and a processing module 1002;

[0153] The transceiver module 1001 is used to receive a first request from an electronic device, where the first request is used to obtain first public data, and the object of the first public data includes a first data model; it is also used to send the first public data in response to the first request; it is also used to receive a first application identifier, first private data and first public data from the electronic device, where the first application identifier is used to indicate that the first private data is private data of the first application, the first private data is data generated by the electronic device for the first application based on the first public data, and the first private data belongs to the first data model, or the first private data belongs to the second data model, and the second data model is a data model newly added to the first public data.

[0154] The specific manner in which the device 1000 performs the method for receiving data and the beneficial effects produced can be found in Figure 1 Related description in the method embodiment shown.

[0155] In the device 1000, the transceiver module 1001 is also used to: receive a second request from the electronic device, the second request is used to obtain the first private data and the first public data, and the second request includes the first application identifier; and is also used to send the first public data and the first private data to the electronic device. The processing module 1002 is used to obtain the first public data and the first private data corresponding to the first application according to the first application identifier. The beneficial effects of this section can be referred to the above embodiments.

[0156] In the device 1000, the transceiver module 1001 is further used to: assemble the first public data and the first private data into a data message; and to send the data message to the electronic device. The beneficial effects of this part can be referred to the above embodiments.

[0157] In the device 1000, the transceiver module 1001 is also used to: receive first application data from the electronic device, the first application data including the first application identifier, the second public data, the second private data and the business data; the processing module 1002 is also used to: query the first public data and the first private data according to the first application identifier, and also to determine to update the previous business data of the first application according to the business data when the first public data and the second public data are the same, and the first private data and the second private data are the same. The beneficial effects of this part can be seen in the above embodiments.

[0158] In the device 1000 , the first public data is structured data defined by a schema.

[0159] Fig.11 A schematic diagram of the structure of another electronic device provided by the present application is shown. Fig.11 The dotted line in the figure indicates that the unit or the module is optional. The electronic device 1100 can be used to implement the method described in the above method embodiment. The electronic device 1100 can be a server or a chip (system).

[0160] The electronic device 1100 includes one or more processors 1101, and the one or more processors 1101 can support the electronic device 1100 to implement Figure 2 The method in the corresponding method embodiment. The processor 1101 can be a general-purpose processor or a special-purpose processor. For example, the processor 1101 can be a central processing unit (CPU). The CPU can be used to control the electronic device 1100, execute software programs, and process data of software programs. The electronic device 1100 can also include a communication unit 1105 to implement signal input (reception) and output (transmission).

[0161] The electronic device 1100 may be a chip (system) including a memory and a processor, wherein the processor is configured to execute a computer program stored in the memory to implement the methods shown in the above embodiments.

[0162] The communication unit 1105 may be an input and / or output circuit of the chip (system), or the communication unit 1105 may be a communication interface of the chip (system), and the chip (system) may be a component of the electronic device 1100 .

[0163] For another example, the communication unit 1105 may be a transceiver of the electronic device 1100 , or the communication unit 1105 may be a transceiver circuit of the electronic device 1100 .

[0164] The electronic device 1100 may include one or more memories 1102, on which a program 1104 is stored. The program 1104 can be executed by the processor 1101 to generate instructions 1103, so that the processor 1101 performs the method described in the above method embodiment according to the instructions 1103. Optionally, data may also be stored in the memory 1102. Optionally, the processor 1101 may also read the data stored in the memory 1102, and the data may be stored at the same storage address as the program 1104, or the data may be stored at a different storage address from the program 1104.

[0165] The processor 1101 and the memory 1102 may be provided separately or integrated together, for example, integrated on a system on chip (System On Chip, SOC) of the electronic device.

[0166] The specific manner in which the processor 1101 executes the method for creating data can refer to the relevant description in the method embodiment.

[0167] It should be understood that each step of the above method embodiment can be completed by a hardware-based logic circuit or a software-based instruction in the processor 1101. The processor 1101 can be a CPU, a digital signal processor (DSP), a field programmable gate array (FPGA), or other programmable logic devices, such as discrete gates, transistor logic devices, or discrete hardware components.

[0168] The present application also provides a computer program product, which, when executed by the processor 1101, implements the method of any method embodiment in the present application.

[0169] The computer program product may be stored in the memory 1102 , for example, a program 1104 , which is converted into an executable target file that can be executed by the processor 1101 after preprocessing, compiling, assembling, and linking.

[0170] The present application also provides a computer-readable storage medium on which a computer program is stored, and when the computer program is executed by a computer, the method of any method embodiment of the present application is implemented. The computer program can be a high-level language program or an executable target program.

[0171] The computer-readable storage medium is, for example, a memory 1102. The memory 1102 may be a volatile memory or a nonvolatile memory, or the memory 1102 may include both a volatile memory and a nonvolatile memory. Among them, the nonvolatile memory may be a read-only memory (ROM), a programmable read-only memory (PROM), an erasable programmable read-only memory (EPROM), an electrically erasable programmable read-only memory (EEPROM), or a flash memory. The volatile memory may be a random access memory (RAM), which is used as an external cache. By way of example and not limitation, many forms of RAM are available, such as static random access memory (SRAM), dynamic random access memory (DRAM), synchronous dynamic random access memory (SDRAM), double data rate synchronous dynamic random access memory (DDR SDRAM), enhanced synchronous dynamic random access memory (ESDRAM), synchronous link dynamic random access memory (SynchLinkDRAM, SLDRAM) and direct memory bus random access memory (Direct Rambus RAM, DRRAM).

[0172] Those skilled in the art can clearly understand that, for the convenience and brevity of description, the specific working process of the above-described devices and equipment and the technical effects produced can refer to the corresponding processes and technical effects in the aforementioned method embodiments, and will not be repeated here.

[0173] In several embodiments provided in the present application, the disclosed systems, devices and methods can be implemented in other ways. For example, some features of the method embodiments described above can be ignored or not executed. The device embodiments described above are merely schematic, and the splitting of the units is only a logical function splitting. There may be other splitting methods in actual implementation, and multiple units or components may be combined or integrated into another system. In addition, the coupling between the units or the coupling between the components may be direct coupling or indirect coupling, and the above coupling includes electrical, mechanical or other forms of connection.

[0174] The above embodiments are only used to illustrate the technical solutions of the present application, rather than to limit them. Although the present application is described in detail with reference to the above embodiments, a person skilled in the art should understand that the technical solutions described in the above embodiments can still be modified, or some of the technical features can be replaced by equivalents, and these modifications or replacements do not make the essence of the corresponding technical solutions deviate from the spirit and scope of the technical solutions of the embodiments of the present application, and should be included in the protection scope of the present application.

[0175] Finally, the above is only a specific implementation of the present application, but the protection scope of the present application is not limited thereto, and any changes or substitutions within the technical scope disclosed in the present application should be included in the protection scope of the present application. Therefore, the protection scope of the present application should be based on the protection scope of the claims.

Claims

1. A method for uploading data, characterized in that: Applied to electronic equipment, the method comprises: Sending a first request to a server, where the first request is used to obtain first public data, where an object of the first public data includes a first data model; receiving the first public data from the server; generating first private data of a first application according to the first public data, where the first private data belongs to the first data model, or the first private data belongs to a second data model, where the second data model is a data model newly added to the first public data; A first application identifier, the first private data, and the first public data are uploaded to the server, where the first application identifier is used to indicate that the first private data is private data of the first application.

2. The method according to claim 1, characterized in that The generating first private data of the first application according to the first public data includes: A first field is added to a first data model of the first public data, and / or a second data model is added to the first public data to generate first private data of the first application.

3. The method according to claim 1, characterized in that The method further comprises: Sending a second request to the server, where the second request is used to obtain the first private data and the first public data, and the second request includes a first application identifier; The first private data and the first public data are received from the server.

4. The method according to claim 3, characterized in that The receiving the first private data and the first public data from the server includes: A data message is received from the server, where the data message includes the first private data and the first public data corresponding to the first application.

5. A method for receiving data, characterized in that: Applied to a server, the method comprises: Receiving a first request from an electronic device, where the first request is used to obtain first public data, where an object of the first public data includes a first data model; In response to the first request, sending the first public data; Receive a first application identifier, first private data and the first public data from the electronic device, where the first application identifier is used to indicate that the first private data is private data of the first application, the first private data is data of the first application generated by the electronic device based on the first public data, and the first private data belongs to the first data model, or the first private data belongs to a second data model, and the second data model is a data model newly added to the first public data.

6. The method according to claim 5, characterized in that The method further comprises: receiving a second request from the electronic device, where the second request is used to obtain the first private data and the first public data, and the second request includes a first application identifier; Acquire the first public data and the first private data corresponding to the first application according to the first application identifier; The first public data and the first private data are sent to the electronic device.

7. The method according to claim 6, characterized in that The sending the first public data and the first private data to the electronic device includes: Assembling the first public data and the first private data into a data message; The data message is sent to the electronic device.

8. The method according to any one of claims 5 to 7, characterized in that The method further comprises: Receiving first application data from the electronic device, the first application data including a first application identifier, second public data, second private data and business data; querying the first public data and the first private data according to the first application identifier; When the first public data is identical to the second public data, and the first private data is identical to the second private data, it is determined to update previous business data of the first application according to the business data.

9. The method according to any one of claims 1 to 4 or 5 to 8, characterized in that The first public data is structured data defined by a schema.

10. An electronic device, characterized in that: The electronic device comprises a processor and a memory, wherein the memory is used to store a computer program, and the processor is used to call and run the computer program from the memory, so that the electronic device executes the method described in any one of claims 1 to 4 and / or 5 to 9.

11. A computer-readable storage medium, characterized in that: The computer-readable storage medium stores a computer program, and when the computer program is executed on an electronic device, the electronic device executes the method according to any one of claims 1 to 4 and / or 5 to 9.