Data processing method and device, electronic equipment and storage medium

By extracting the processing policy identification and target data information from the user input information, adaptively determine the data storage type and operation type, solving the high learning cost and application difficulties of configuring data processing logic in different scenarios, and simplifying the data operation process and The effect of reducing learning difficulty.

CN119440400APending Publication Date: 2025-02-14CHENGDU CELIS TECH CO LTD
View PDF 5 Cites 0 Cited by

Patent Information

Application Number
CN202411431023.8
Authority / Receiving Office
CN · China
Patent Type
Applications(China)
Current Assignee / Owner
Filing Date
2024-10-14
Publication Date
2025-02-14

AI Technical Summary

Technical Problem

In the prior art, users need to configure data processing logic corresponding to different storage methods in different scenarios, resulting in high learning costs and difficult application.

Method used

By obtaining user input information, extracting processing policy identification and target data information, determining the data storage type and data operation type corresponding to the processing policy identification, based on the data storage strategy corresponding to the data storage type, and combining the target data information, performing the corresponding data operation type Data operation to obtain the data processing results corresponding to the user input information.

Benefits of technology

It realizes that the corresponding strategies can be used to perform data operations adaptively without understanding the specific data storage strategy in different scenarios, reducing the learning cost and application difficulty of configuring different storage methods in different scenarios.

✦ Generated by Eureka AI based on patent content.

Smart Images

  • Figure CN119440400A_ABST
    Figure CN119440400A_ABST
Patent Text Reader

Abstract

The invention relates to a data processing method and device, electronic equipment and a storage medium, and the data processing method comprises the steps: obtaining user input information, and extracting a processing strategy identifier and target data information from the user input information, so as to determine a data storage type and a data operation type corresponding to the processing strategy identifier; based on a data storage strategy corresponding to the data storage type, in combination with the target data information, executing a data operation corresponding to the data operation type to obtain a data processing result corresponding to the user input information; therefore, the data operation can be executed by adaptively adopting the data storage strategy according to the information input by the user, and the technical problems of high learning cost and difficult application caused by the fact that the user needs to configure data processing logics corresponding to different storage modes in different scenes in the prior art are solved; the learning cost and the application difficulty of configuring data processing logic corresponding to different storage modes in different scenes can be effectively reduced.
Need to check novelty before this filing date? Find Prior Art

Description

Technical Field

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

[0002] With the development of the Internet, the speed of developing various programs is also accelerating. In the process of program development, there will be many storage scenarios corresponding to businesses. Different businesses need to rely on different storage forms. The existing storage forms include memory storage, hard disk storage, system setting storage, system property storage, etc. Each storage form has its own unique set of execution logic. When users are developing programs, if they need to perform related storage operations, they need to understand the execution logic related to the storage form that needs to be applied in the scenario and perform adaptive configuration. For example, the memory storage scenario needs to configure global variables for storage operations, the hard disk storage scenario needs to configure the mobile terminal key-value storage library (Mmap MemoryKey-Value, MMKV) interface for storage operations, and the system property storage scenario needs to configure the system property manager (SystemProperties) for storage operations; that is, the execution logic of different storage forms needs to adopt different encoding logic, so that users need to configure the data processing logic corresponding to different storage methods in different scenarios, which has the problems of high learning cost and difficult application. Summary of the invention

[0003] In order to solve the technical problems of high learning cost and application difficulty that users in the existing related technologies need to configure data processing logic corresponding to different storage methods in different scenarios, the present application provides a data processing method, device, electronic device and storage medium.

[0004] In a first aspect, the present application provides a data processing method, comprising:

[0005] Get user input information;

[0006] Extracting a processing strategy identifier and target data information from the user input information;

[0007] Determine the data storage type and data operation type corresponding to the processing strategy identifier;

[0008] Based on the data storage strategy corresponding to the data storage type and in combination with the target data information, the data operation corresponding to the data operation type is performed to obtain a data processing result corresponding to the user input information.

[0009] Optionally, the data storage strategy corresponding to the data storage type is performed in combination with the target data information to obtain a data processing result corresponding to the user input information, including:

[0010] Determine the data storage strategy corresponding to the data storage type;

[0011] Extracting storage location information from the target data information;

[0012] According to the data storage strategy, the data operation is performed at the storage location corresponding to the storage location information to obtain a data processing result corresponding to the user input information.

[0013] Optionally, performing the data operation at the storage location corresponding to the storage location information according to the data storage strategy to obtain a data processing result corresponding to the user input information includes:

[0014] When the data operation is a write operation, extracting the data to be written from the target data information;

[0015] According to the data storage strategy, the data to be written is written to the storage location to obtain the data processing result.

[0016] Optionally, performing the data operation at the storage location corresponding to the storage location information according to the data storage strategy to obtain a data processing result corresponding to the user input information includes:

[0017] Based on the data storage strategy and the data operation, determining a target storage strategy class;

[0018] According to the target storage policy class, the data operation is performed at the storage location to obtain the data processing result.

[0019] Optionally, extracting a processing strategy identifier and target data information from the user input information includes:

[0020] Extracting business scenario information and target data information from the user input information;

[0021] Determine an adaptive data storage strategy based on the business scenario information and the target data information;

[0022] The policy identifier corresponding to the adapted data storage policy is determined as the processing policy identifier.

[0023] Optionally, the determining an adapted data storage strategy based on the business scenario information and the target data information includes:

[0024] Determine business scenario screening conditions based on the business scenario information;

[0025] Based on the target data information, determining a target data screening condition;

[0026] A preset data storage strategy that meets the business scenario screening condition and the target data screening condition is determined as the adapted data storage strategy.

[0027] Optionally, determining the data storage type and data operation type corresponding to the processing strategy identifier includes:

[0028] Extracting a data storage identifier and a data operation identifier from the processing strategy identifier;

[0029] Determine the data storage type corresponding to the data storage identifier;

[0030] Determine the data operation type corresponding to the data operation identifier.

[0031] In a second aspect, the present application provides a data processing device, comprising:

[0032] The acquisition module is used to obtain user input information;

[0033] An extraction module, used to extract a processing strategy identifier and target data information from the user input information;

[0034] A determination module, used to determine the data storage type and data operation type corresponding to the processing strategy identifier;

[0035] The data operation module is used to perform the data operation corresponding to the data operation type based on the data storage strategy corresponding to the data storage type and in combination with the target data information, so as to obtain the data processing result corresponding to the user input information.

[0036] In a third aspect, an electronic device is provided, comprising a processor, a communication interface, a memory and a communication bus, wherein the processor, the communication interface and the memory communicate with each other via the communication bus;

[0037] Memory, used to store computer programs;

[0038] The processor is used to implement the data processing method described in any one of the first aspects when executing the program stored in the memory.

[0039] According to a fourth aspect, a computer-readable storage medium is provided, on which a computer program is stored. When the computer program is executed by a processor, the data processing method according to any one of the first aspects is implemented.

[0040] The embodiment of the present application obtains user input information and extracts a processing strategy identifier and target data information from the user input information to determine the data storage type and data operation type corresponding to the processing strategy identifier, and then executes the data operation corresponding to the data operation type based on the data storage strategy corresponding to the data storage type in combination with the target data information to obtain a data processing result corresponding to the user input information; thereby, the data storage strategy can be adaptively adopted to execute data operations according to the user input information, which solves the technical problem of high learning cost and application difficulty that users need to configure data processing logic corresponding to different storage methods in different scenarios in the existing related technologies, and can effectively reduce the learning cost and application difficulty of configuring data processing logic corresponding to different storage methods in different scenarios. BRIEF DESCRIPTION OF THE DRAWINGS

[0041] The accompanying drawings, which are incorporated in and constitute a part of this specification, illustrate embodiments consistent with the invention and, together with the description, serve to explain the principles of the invention.

[0042] In order to more clearly illustrate the embodiments of the present invention or the technical solutions in the prior art, the drawings required for use in the embodiments or the description of the prior art will be briefly introduced below. Obviously, for ordinary technicians in this field, other drawings can be obtained based on these drawings without paying any creative labor.

[0043] Figure 1 A flowchart of a data processing method provided in an embodiment of the present application;

[0044] Figure 2 A schematic diagram of the structure of a data processing device provided in an embodiment of the present application;

[0045] Figure 3 A schematic diagram of the structure of an electronic device provided in an embodiment of the present application. DETAILED DESCRIPTION

[0046] In order to make the purpose, technical solution and advantages of the embodiments of the present application clearer, the technical solution in the embodiments of the present application will be clearly and completely described below in conjunction with the drawings in the embodiments of the present application. Obviously, the described embodiments are part of the embodiments of the present application, not all of the embodiments. Based on the embodiments in the present application, all other embodiments obtained by ordinary technicians in this field without making creative work are within the scope of protection of this application.

[0047] When existing programs are running, data operations are inevitably required, and data operations are closely related to data storage methods. For example, existing data includes SharedPreference hard disk storage, MMKV hard disk storage, system attribute hard disk storage, system setting hard disk storage, global variable memory storage, etc. Different storage methods require different instruction logic for processing. For example, SharedPreferences hard disk storage is a lightweight storage method used to store a small amount of data, such as user settings. The writing process is: when writing data to SharedPreferences, the data will be serialized and stored in an XML file, usually stored in the internal storage / data / data / your_package_name / shared_prefs / directory.

[0048] MMKV hard disk storage is a storage method based on memory-mapped files. The writing process is as follows: when writing data, MMKV writes the data directly to the file through memory mapping. This method has fast reading and writing speeds and supports atomic operations. The reading process is as follows: the reading speed is fast because the data is directly mapped to the memory and does not need to be serialized and deserialized like SharedPreferences.

[0049] System property hard disk storage is a mechanism for storing small amounts of system configuration information. Its writing process is as follows: writing system properties requires specific permissions and is usually used for system-level configuration. The write operation will directly modify the system property file; the reading process is as follows: reading system properties usually requires root permissions, or through specific system services; system setting hard disk storage is used to store system and application setting information. Its writing process is as follows: writing system settings usually requires system permissions, and the data will be stored in the system settings database. Its reading process is as follows: reading system settings can be done through ContentResolver. For applications, they can usually only access their own settings; global variables in memory storage are variables defined in the program and accessible throughout the program's entire running cycle. Its writing process is as follows: writing global variables is to modify the value of the variable directly in memory, which is fast, but the data will be lost after the program ends. Its reading process is as follows: reading global variables is just as fast because they are stored in memory; the deletion process is as follows: deleting a global variable usually means setting the variable to null or reassigning a value. It can be seen that when performing data processing, different execution logics need to be adopted according to different storage methods, so that when users configure data processing, they need to learn and understand the instruction logic related to data operations corresponding to different data storage methods. However, with the continuous increase in data storage scenarios and the continuous acceleration of program development, users need to configure data processing logic corresponding to different storage methods in different scenarios, which leads to technical problems such as high learning cost and difficult application.

[0050] In order to solve the technical problems of high learning cost and difficult application in the prior art that users need to configure data processing logic corresponding to different storage methods in different scenarios, the present application provides a data processing method, device, electronic device and storage medium, which obtains user input information and extracts processing strategy identifier and target data information from the user input information to determine the data storage type and data operation type corresponding to the processing strategy identifier, and then performs the data operation corresponding to the data operation type based on the data storage strategy corresponding to the data storage type and the target data information to obtain the data processing result corresponding to the user input information; thereby, the data storage strategy can be adaptively adopted to perform data operations according to the user input information, which solves the technical problems of high learning cost and difficult application in the prior art that users need to configure data processing logic corresponding to different storage methods in different scenarios, and can effectively reduce the learning cost and application difficulty of configuring data processing logic corresponding to different storage methods in different scenarios.

[0051] Figure 1A flow chart of a method for determining a verification method provided in an embodiment of the present application. The method can be applied to one or more electronic devices such as a client and a server. In addition, the execution subject of the method can be hardware or software. When the above-mentioned execution subject is hardware, the execution subject can be one or more of the above-mentioned electronic devices. For example, a single electronic device can execute the method, or a plurality of electronic devices can cooperate with each other to execute the method. When the above-mentioned execution subject is software, the method can be implemented as a plurality of software or software modules, or as a single software or software module. No specific limitation is made herein.

[0052] like Figure 1 As shown, the present application discloses an embodiment, and provides a data processing method, which may specifically include the following steps:

[0053] Step S110: Obtain user input information.

[0054] Among them, user input information can represent information input by the user according to data processing requirements. Specifically, the user can input user input information according to the requirements of the application scenario. For example, when the user needs to store data through system attributes, the user can enter the system attribute hard disk storage corresponding user input information. That is, the user input information in this embodiment can be code or instructions, etc., and this embodiment does not make specific limitations on this.

[0055] Step S120: extracting the processing strategy identifier and target data information from the user input information.

[0056] Specifically, after obtaining user input information, the processing strategy identifier and target data information can be extracted from the user input information. The processing strategy identifier can represent an identifier used to mark the processing strategy to be adopted, and the target data information can represent the data that needs to perform related data processing operations.

[0057] Specifically, the processing strategies in this embodiment may be strategies corresponding to different storage methods, and the processing strategy identifier is an identifier used to mark each processing strategy, such as the SharedPreference hard disk storage processing strategy corresponding to the SharedPreference hard disk storage method, the MMKV hard disk storage processing strategy corresponding to the MMKV hard disk storage method, the system attribute hard disk storage processing strategy corresponding to the system attribute hard disk storage method, the system setting hard disk storage processing strategy corresponding to the system setting hard disk storage method, and the global variable memory storage processing strategy corresponding to the global variable memory storage method. The processing strategy identifier corresponding to the system setting hard disk storage processing strategy may be Storage Manager, and other processing strategies may also be configured with their corresponding identifiers respectively, which is not specifically limited in this embodiment.

[0058] Step S130: Determine the data storage type and data operation type corresponding to the processing strategy identifier.

[0059] Specifically, after determining the processing strategy identifier, the data storage type and data operation type corresponding to the processing strategy identifier can be determined, where the data storage type can indicate the storage type required for data processing of the current user input information, such as SharedPreference hard disk storage type, MMKV hard disk storage type, system property hard disk storage type, system setting hard disk storage type, global variable memory storage type, etc., and the data operation type can indicate the operation type for data processing, such as read operation type, write operation type, delete operation type, etc.

[0060] Step S140: Based on the data storage strategy corresponding to the data storage type and in combination with the target data information, a data operation corresponding to the data operation type is performed to obtain a data processing result corresponding to the user input information.

[0061] Specifically, after determining the data storage type and the data operation type, the data storage strategy corresponding to the data storage type can be determined. The data storage strategy can represent a storage strategy corresponding to the data storage type that is pre-configured, such as a SharedPreference hard disk storage processing strategy corresponding to the SharedPreference hard disk storage type, an MMKV hard disk storage processing strategy corresponding to the MMKV hard disk storage type, a system attribute hard disk storage processing strategy corresponding to the system attribute hard disk storage type, a system setting hard disk storage processing strategy corresponding to the system setting hard disk storage type, and a global variable memory storage processing strategy corresponding to the global variable memory storage type; thereby, based on the data storage strategy and in combination with the target data information, the data operation corresponding to the data operation type can be executed, that is, the data operation is executed in combination with the target data information under the data storage strategy, and then the data storage strategy matching the user input information can be used to execute the relevant data operation; subsequently, based on the result of the data operation, the data processing result corresponding to the user input information can be obtained, and the data processing result can represent the specific execution result of the data operation, such as execution success, execution failure, execution exception, etc., which is not specifically limited in this embodiment.

[0062] Specifically, in one example, when a user wants to store data through system properties, for example, the user needs to write the version number of the current system, the user input information entered at this time is: Storage Manager.put(Type.SystemProperties, "ro.build.version.release", 11), and the processing strategy identifier extracted from the user input information is "Storage Manager.put" and the target data information "(Type.SystemProperties, "ro.build.version.release", 11)", and it is determined that the data storage type corresponding to the processing strategy identifier "Storage Manager.put" is Storage Manager, that is, the system sets the hard disk storage type, and the data operation type is put, that is, the write operation type. At this time, based on the data storage type Storage The data storage strategy corresponding to the Manager, that is, the hard disk storage processing strategy set by the system, is combined with the target data information "(Type.SystemProperties, "ro.build.version.release", 11)" to execute the write data operation corresponding to the data operation type, that is, through the hard disk storage processing strategy set by the system, the system property with the key value of "ro.build.version.release" and the value of "11" is written to the local storage, and then the data processing result corresponding to the user input information is obtained.

[0063] When the user wants to obtain data through system properties, for example, the user needs to obtain the version number of the current system, the user input information entered at this time is: StorageManager.get(Type.SystemProperties, ""ro.build.version.release"",-1), from which the processing strategy identifier extracted is "StorageManager.get" and the target data information "(Type.SystemProperties,

[0064] ""ro.build.version.release"",-1)", determine that the data storage type corresponding to the processing strategy identifier "StorageManager.put" is Storage Manager, that is, the system-set hard disk storage type, and the data operation type is get, that is, the acquisition operation type. At this time, based on the data storage strategy corresponding to the data storage type Storage Manager, that is, the system-set hard disk storage processing strategy, combined with the target data information "(Type.SystemProperties, ""ro.build.version.release"",-1)", the acquisition data operation corresponding to the data operation type can be performed, that is, through the system-set hard disk storage processing strategy, the system property with the key value of "ro.build.version.release" is obtained. If no value is obtained, the default value is -1, and then the data processing result corresponding to the user input information is obtained.

[0065] In addition, when the user wants to delete data through system properties, for example, the user needs to delete the version number of the current system, the user input information entered at this time is: StorageManager.clear(Type.SystemProperties,“ro.build.version.release”), and the processing strategy identifier extracted from the user input information is “StorageManager.clear” and the target data information “(Type.SystemProperties,“ro.build.version.release”)”, and it is determined that the data storage type corresponding to the processing strategy identifier “Storage Manager.clear” is Storage Manager, that is, the system-set hard disk storage type, and the data operation type is clear, that is, the deletion operation type. At this time, based on the data storage policy corresponding to the data storage type Storage Manager, that is, the system-set hard disk storage processing policy, combined with the target data information “(Type.SystemProperties,“ro.build.version.release”)”, the deletion data operation corresponding to the data operation type can be performed, that is, through the system-set hard disk storage processing policy, the system property with the key value of “ro.build.version.release” is deleted from the local, and then the data processing result corresponding to the user input information is obtained.

[0066] It can be seen that the present application obtains user input information and extracts the processing strategy identifier and target data information from the user input information to determine the data storage type and data operation type corresponding to the processing strategy identifier, and then executes the data operation corresponding to the data operation type based on the data storage policy corresponding to the data storage type and in combination with the target data information to obtain the data processing result corresponding to the user input information; when the user needs to perform a data storage operation, there is no need to understand the specific data storage strategies, but the corresponding data storage strategy can be adaptively adopted to perform the data operation by directly including the processing strategy identifier in the user input information, which solves the technical problems of high learning cost and difficult application in the existing related technology that users need to configure the data processing logic corresponding to different storage methods in different scenarios, and can effectively reduce the learning cost and difficulty of applying the data processing logic corresponding to different storage methods in different scenarios.

[0067] In an optional embodiment of the present application, step S140 performs a data operation corresponding to the data operation type based on the data storage strategy corresponding to the data storage type and in combination with the target data information to obtain a data processing result corresponding to the user input information. Specifically, it may include the following sub-steps: determining the data storage strategy corresponding to the data storage type; extracting storage location information from the target data information; and performing a data operation at the storage location corresponding to the storage location information in accordance with the data storage strategy to obtain a data processing result corresponding to the user input information.

[0068] In this embodiment, after determining the data storage type and the data operation type, the data storage strategy corresponding to the data storage type can be determined, and the storage location information can be extracted from the target data information. The storage location information can indicate the location information where data operations need to be performed, and the storage location information can be key location information, byte location information, etc.; thereby, according to the data storage strategy, data operations can be performed at the storage location corresponding to the storage location information to obtain the data processing results corresponding to the user input information.

[0069] Specifically, different data storage strategies need to use different execution logics to execute data operations. In this case, the execution operations corresponding to each data storage strategy can be pre-configured, such as by rewriting the editor corresponding to the data storage strategy. The following examples are used to illustrate the data storage operation (hereinafter referred to as "put"), data retrieval operation (hereinafter referred to as "get"), and data deletion operation (hereinafter referred to as "clear"):

[0070] Rewrite the put data operation of the editor Editor. The put data operation has three parameters in total, storage strategy Storage, storage Key value, and storage Value value. The implementation logic is to call the adaptation strategy of SharedPreference according to the type of value. For example, if the value is of String type, call the SharedPreference.putString method.

[0071] Rewrite the get data operation of the editor Editor. The get data operation has three parameters in total, storage strategy, storage key value, and default DefaultValue value. The implementation logic is to determine the adaptation strategy called by SharedPreference based on the passed in default DefaultValue value. For example, if DefaultValue is of String type, call the SharedPreference.getString method.

[0072] Rewrite the clear data operation of the editor Editor. The clear data operation has two parameters, storage type and storage key value. The implementation logic is to call the SharedPreferences.remove method and pass the key value in as a parameter. Of course, the above is only an example to illustrate the role. In the specific implementation, it can be adaptively adjusted according to the scenario and requirements. This embodiment does not make specific limitations on this.

[0073] It can be seen that in this embodiment, after determining the data storage type and data operation type corresponding to the user input information, data operations can be performed at the storage location corresponding to the storage location information according to the data storage strategy corresponding to the pre-configured data storage type, to obtain the data processing result corresponding to the user input information; thereby, the user does not need to understand the specific execution logic of each data storage strategy, and can directly include the processing strategy identifier in the user input information to adaptively adopt the corresponding data storage strategy to perform data operations, thereby realizing the decoupling of data policy logic and data management, which can effectively reduce the learning cost and application difficulty of the data processing logic corresponding to different storage methods configured in different scenarios.

[0074] In an optional embodiment of the present application, according to the data storage strategy, a data operation is performed at a storage location corresponding to the storage location information to obtain a data processing result corresponding to the user input information, which may specifically include the following sub-steps: when the data operation is a write operation, extracting the data to be written from the target data information; according to the data storage strategy, writing the data to be written to the storage location to obtain a data processing result.

[0075] In this embodiment, during the process of executing data operations, it can be determined whether the data operation is a write operation. If the data operation is a write operation, it means that the data needs to be written to the storage location corresponding to the storage location information. At this time, the data to be written can be extracted from the target data information. The data to be written can represent the data that needs to be written, so that the data to be written can be written to the storage location according to the data storage strategy to obtain the data processing result.

[0076] In one example, when the data storage strategy is a hard disk storage processing strategy set for the system, the value can be extracted from the target data information, and the data of the value can be used as the data to be written, and then the data to be written corresponding to the value can be written to the storage location. Of course, other data storage strategies can adopt their adapted write operations. This embodiment is only for illustrative purposes and is not specifically limited.

[0077] In an optional embodiment of the present application, according to the data storage strategy, data operations are performed at the storage location corresponding to the storage location information to obtain a data processing result corresponding to the user input information. Specifically, the following sub-steps may be included: based on the data storage strategy and data operations, a target storage policy class is determined; based on the target storage policy class, data operations are performed at the storage location to obtain a data processing result.

[0078] In this embodiment, in the process of executing data operations according to the data storage strategy, the target storage policy class can be determined based on the data storage strategy and the data operation. The target storage policy class represents a pre-configured storage policy class, and specifically it can be an abstract class that takes the data storage strategy and the data operation as input. At this time, the abstract class can be converted into a specific policy class, and the specific policy class can be the relevant data operation of the pre-configured rewrite editor Editor in the aforementioned embodiment; thereby, data operations can be performed at the storage location according to the target storage policy class to obtain data processing results.

[0079] Specifically, when the user input information is: Storage Manager.put(Type.SystemProperties, "ro.build.version.release", 11), according to the processing strategy identifier "Storage Manager.put" in the user input information, it can be determined that the data storage strategy is the data storage strategy corresponding to the Storage Manager, that is, the system sets the hard disk storage processing strategy, and the data operation put can be determined as the data acquisition operation. At this time, the data storage strategy and the data operation can be used as the abstract class of the input, that is, "Storage Manager.put" can be used as the abstract class, and the preset conversion relationship can be installed to convert it into a specific target storage strategy class, and then the target storage strategy class can be instantiated, so that the target storage strategy class can be applied to the program to implement the installation system setting hard disk storage processing strategy to perform the acquisition operation, and then obtain the data processing result. That is, different storage strategies can be called in different business scenarios, achieving the effect of decoupling data logic and data management.

[0080] In an optional embodiment of the present application, step S120 extracts a processing strategy identifier and target data information from user input information, and may specifically include the following sub-steps: extracting business scenario information and target data information from user input information; determining an adaptive data storage strategy based on the business scenario information and target data information; and determining the policy identifier corresponding to the adaptive data storage strategy as the processing strategy identifier.

[0081] In this embodiment, in the process of determining the processing strategy identifier and target data information, business scenario information and target data information can be extracted from the user input information, wherein the business scenario information can represent information used to indicate the business scenario, such as business identifier, business characteristics, business version and other information; thereby, an adaptive data storage strategy can be determined based on the business scenario information and target data information, and the adaptive data storage strategy can represent a data storage strategy that matches both the business scenario information and the target data information, and then the policy identifier corresponding to the adaptive data storage strategy can be determined as the processing strategy identifier.

[0082] Specifically, since different data storage strategies can be targeted at different business scenarios or data, for example, the system setting hard disk storage processing strategy is targeted at the system setting scenario. At this time, the business scenario targeted is the system setting scenario, and the data targeted is the coefficient setting related data. Therefore, this embodiment determines the adaptive data storage strategy that matches the business scenario information and target data information by extracting the business scenario information and target data information from the user input information, and can directly determine the processing strategy identifier that matches the current user input information; for example, the business scenario information in the user input information contains the system setting identifier, and the target data information contains the system setting data. At this time, the system setting hard disk storage processing strategy can be determined as the adaptive data storage strategy, and the system setting hard disk storage processing strategy identifier corresponding to the adaptive data storage strategy can be determined as the processing strategy identifier.

[0083] It can be seen that in this embodiment, the business scenario information and target data information in the user input information are adapted and analyzed to determine the adapted data storage strategy that matches the business scenario information and the target data information. This allows the user to perform data storage operations without having to understand the specific data storage strategies. Instead, the user can directly include the business scenario information and target data information associated with the business scenario in the user input information, and adaptively adopt the data storage strategy corresponding to the business scenario to perform data operations. This solves the technical problem of high learning cost and application difficulty that users need to configure data processing logic corresponding to different storage methods in different scenarios in the existing related technologies, and can effectively reduce the learning cost and application difficulty of configuring data processing logic corresponding to different storage methods for different scenarios.

[0084] In an optional embodiment of the present application, an adaptive data storage strategy is determined based on business scenario information and target data information, which may specifically include the following sub-steps: determining business scenario filtering conditions based on the business scenario information; determining target data filtering conditions based on the target data information; and determining a preset data storage strategy that meets the business scenario filtering conditions and the target data filtering conditions as an adaptive data storage strategy.

[0085] In this embodiment, in the process of determining an adaptive data storage strategy, business scenario information may be used to determine business scenario filtering conditions, which may represent conditions for filtering data storage strategies that match the business scenario information, and target data filtering conditions may be determined based on target data information, which may represent conditions for filtering data storage strategies that match the target data; thereby, the business scenario filtering conditions and the target data filtering conditions may be used to filter pre-configured preset data storage strategies, and the preset data storage strategies that meet the business scenario filtering conditions and the target data filtering conditions may be determined as adaptive data storage strategies.

[0086] In one example, when the business scenario information includes a system setting identifier, the system setting hard disk storage can be used as a business scenario screening condition, so that the business scenario screening condition can be used to screen and judge from the preset data storage strategy whether there is a preset system setting hard disk storage processing strategy; in addition, when the target data information includes system setting data, the system setting hard disk storage can be used as a business scenario screening condition, so that the target data screening condition can be used to screen and judge from the preset data storage strategy whether there is a preset system setting hard disk storage processing strategy; the above screening process based on the business scenario screening condition and the target data screening condition can be performed independently, that is, the preset data storage strategy can be screened according to the business scenario screening condition to obtain the first screening condition. Select the result, filter the preset data storage strategy according to the target data filtering condition, and obtain the second filtering result. Specifically, the preset data storage strategy can be determined according to the first filtering result and the second filtering result. For example, when the first filtering result is empty and the second filtering result is the hard disk storage processing strategy set by the system, it will be determined as the adaptive data storage strategy. It can also be determined as the adaptive data storage strategy when the first filtering result is the hard disk storage processing strategy set by the system and the second filtering result is empty. When the first filtering result and the second filtering result are different preset data storage strategies, an error prompt message can be output. When the first filtering result and the second filtering result are the same preset data storage strategy, the preset data storage strategy can be determined as the adaptive data storage strategy. Of course, the above is only an example for illustration. In the specific implementation, it can be adaptively adjusted according to the scenario and needs. This embodiment does not make specific limitations on this.

[0087] In an optional embodiment of the present application, step S130 determines the data storage type and data operation type corresponding to the processing strategy identifier, which may specifically include the following sub-steps: extracting the data storage identifier and the data operation identifier from the processing strategy identifier; determining the data storage type corresponding to the data storage identifier; determining the data operation type corresponding to the data operation identifier.

[0088] In this embodiment, in the process of determining the data storage type and the data operation type, the data storage identifier and the data operation identifier can be extracted from the processing strategy identifier. The data storage identifier can represent an identifier used to mark the data storage type, and the data operation identifier can represent an identifier used to mark the data operation type, so that the data storage type corresponding to the data storage identifier and the data operation type corresponding to the data operation identifier can be determined.

[0089] In one example, when the processing strategy identifier is "Storage Manager.put", the data storage identifier "Storage Manager" extracted at this time is the hard disk storage type set by the system, and the data operation identifier "put" extracted is the write operation type. Of course, the above is only an example for illustration, and it can be adaptively adjusted according to the scene and requirements during specific implementation, and this embodiment does not make specific limitations on this.

[0090] like Figure 2 As shown, the present application also discloses an embodiment, providing a data processing device, including:

[0091] The acquisition module 210 is used to acquire user input information;

[0092] An extraction module 220, used to extract a processing strategy identifier and target data information from the user input information;

[0093] A determination module 230, configured to determine a data storage type and a data operation type corresponding to the processing strategy identifier;

[0094] The data operation module 240 is used to perform the data operation corresponding to the data operation type based on the data storage strategy corresponding to the data storage type and in combination with the target data information, to obtain the data processing result corresponding to the user input information.

[0095] In an optional embodiment of the present application, the data operation module 240 may include:

[0096] A first determining unit, configured to determine the data storage strategy corresponding to the data storage type;

[0097] A first extraction unit, used to extract storage location information from the target data information;

[0098] The first data operation unit is used to perform the data operation at the storage location corresponding to the storage location information according to the data storage strategy to obtain a data processing result corresponding to the user input information.

[0099] In an optional embodiment of the present application, the first data operation unit may include:

[0100] A first extraction subunit, configured to extract the to-be-written data from the target data information when the data operation is a write operation;

[0101] The first writing subunit is used to write the data to be written into the storage location according to the data storage strategy to obtain the data processing result.

[0102] In an optional embodiment of the present application, the first data operation unit may include:

[0103] A first determination subunit is used to determine a target storage policy class based on the data storage policy and the data operation;

[0104] The first data operation subunit is used to perform the data operation at the storage location according to the target storage policy class to obtain the data processing result.

[0105] In an optional embodiment of the present application, the extraction module 220 may include:

[0106] A second extraction unit, configured to extract business scenario information and the target data information from the user input information;

[0107] A second determining unit, configured to determine an adapted data storage strategy based on the business scenario information and the target data information;

[0108] The third determining unit is used to determine the policy identifier corresponding to the adapted data storage policy as the processing policy identifier.

[0109] In an optional embodiment of the present application, the second determining unit may include:

[0110] A second determining subunit, configured to determine a business scenario screening condition based on the business scenario information;

[0111] A third determining subunit is used to determine a target data screening condition based on the target data information;

[0112] The fourth determining subunit is used to determine the preset data storage strategy that meets the business scenario screening condition and the target data screening condition as the adapted data storage strategy.

[0113] In an optional embodiment of the present application, the determination module 230 may include:

[0114] A third extraction unit, used to extract a data storage identifier and a data operation identifier from the processing strategy identifier;

[0115] A fourth determining unit, configured to determine the data storage type corresponding to the data storage identifier;

[0116] A fifth determining unit is used to determine the data operation type corresponding to the data operation identifier.

[0117] The implementation process of the functions and effects of each module in the above-mentioned device is specifically described in the implementation process of the corresponding steps in the above-mentioned method, which will not be repeated here.

[0118] like Figure 3 As shown, an embodiment of the present application provides an electronic device, including a processor 310, a communication interface 320, a memory 330 and a communication bus 340, wherein the processor 310, the communication interface 320, and the memory 330 communicate with each other through the communication bus 340;

[0119] Memory 330, for storing computer programs;

[0120] In one embodiment of the present application, the processor 310, when executing the program stored in the memory 330, implements the data processing method provided by any of the aforementioned method embodiments, by obtaining user input information and extracting the processing strategy identifier and the target data information from the user input information to determine the data storage type and the data operation type corresponding to the processing strategy identifier, and then based on the data storage strategy corresponding to the data storage type, in combination with the target data information, executes the data operation corresponding to the data operation type to obtain the data processing result corresponding to the user input information; when the user needs to perform a data storage operation, there is no need to understand the specific data storage strategies, but the user can directly include the processing strategy identifier in the user input information to adaptively adopt the corresponding data storage strategy to perform the data operation, which solves the technical problems of high learning cost and application difficulty that users need to configure data processing logic corresponding to different storage methods in different scenarios in the existing related technology, and can effectively reduce the learning cost and application difficulty of configuring data processing logic corresponding to different storage methods in different scenarios.

[0121] The embodiment of the present application also provides a computer-readable storage medium, on which a computer program is stored. When the computer program is executed by a processor, it implements a data processing method as provided in any of the aforementioned method embodiments, by obtaining user input information and extracting a processing strategy identifier and target data information from the user input information to determine the data storage type and data operation type corresponding to the processing strategy identifier, and then based on the data storage strategy corresponding to the data storage type, in combination with the target data information, executing the data operation corresponding to the data operation type, to obtain a data processing result corresponding to the user input information; when the user needs to perform a data storage operation, there is no need to understand the specific data storage strategies, but the corresponding data storage strategy can be adaptively adopted to perform the data operation by directly including the processing strategy identifier in the user input information, which solves the technical problems of high learning cost and application difficulty that users need to configure data processing logic corresponding to different storage methods in different scenarios in the existing related technology, and can effectively reduce the learning cost and application difficulty of configuring data processing logic corresponding to different storage methods in different scenarios.

[0122] It should be noted that, in this article, relational terms such as "first" and "second" are only used to distinguish one entity or operation from another entity or operation, and do not necessarily require or imply any such actual relationship or order between these entities or operations. Moreover, the terms "include", "comprise" or any other variants 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 further restrictions, the elements defined by the sentence "comprise a ..." do not exclude the existence of other identical elements in the process, method, article or device including the elements.

[0123] The above describes specific embodiments of the present specification. Other embodiments are within the scope of the appended claims. In some cases, the actions or steps recorded in the claims can be performed in an order different from that in the embodiments and still achieve the desired results. In addition, the processes depicted in the accompanying drawings do not necessarily require the specific order or continuous order shown to achieve the desired results. In some embodiments, multitasking and parallel processing are also possible or may be advantageous.

[0124] The foregoing is merely a specific embodiment of the present invention, which enables those skilled in the art to understand or implement the present invention. Various modifications to these embodiments will be apparent to those skilled in the art, and the general principles defined herein may be implemented in other embodiments without departing from the spirit or scope of the present invention. Therefore, the present invention will not be limited to the embodiments shown herein, but rather to the widest scope consistent with the principles and novel features claimed herein.

Claims

1. A data processing method, characterized in that: include: Get user input information; Extracting a processing strategy identifier and target data information from the user input information; Determine the data storage type and data operation type corresponding to the processing strategy identifier; Based on the data storage strategy corresponding to the data storage type and in combination with the target data information, the data operation corresponding to the data operation type is performed to obtain a data processing result corresponding to the user input information.

2. The data processing method according to claim 1, characterized in that: The data storage strategy corresponding to the data storage type is based on the target data information, and the data operation corresponding to the data operation type is performed to obtain the data processing result corresponding to the user input information, including: Determine the data storage strategy corresponding to the data storage type; Extracting storage location information from the target data information; According to the data storage strategy, the data operation is performed at the storage location corresponding to the storage location information to obtain a data processing result corresponding to the user input information.

3. The data processing method according to claim 2, characterized in that: The performing the data operation at the storage location corresponding to the storage location information according to the data storage strategy to obtain the data processing result corresponding to the user input information includes: In the case where the data operation is a write operation, extracting the data to be written from the target data information; According to the data storage strategy, the data to be written is written to the storage location to obtain the data processing result.

4. The data processing method according to claim 2, characterized in that: The performing the data operation at the storage location corresponding to the storage location information according to the data storage strategy to obtain the data processing result corresponding to the user input information includes: Based on the data storage strategy and the data operation, determining a target storage strategy class; According to the target storage policy class, the data operation is performed at the storage location to obtain the data processing result.

5. The data processing method according to claim 1, characterized in that: The step of extracting a processing strategy identifier and target data information from the user input information includes: Extracting business scenario information and target data information from the user input information; Determine an adaptive data storage strategy based on the business scenario information and the target data information; The policy identifier corresponding to the adapted data storage policy is determined as the processing policy identifier.

6. The data processing method according to claim 5, characterized in that: The determining of an adapted data storage strategy based on the business scenario information and the target data information includes: Determine business scenario screening conditions based on the business scenario information; Based on the target data information, determining a target data screening condition; A preset data storage strategy that meets the business scenario screening condition and the target data screening condition is determined as the adapted data storage strategy.

7. The data processing method according to any one of claims 1 to 6, characterized in that: Determining the data storage type and data operation type corresponding to the processing strategy identifier includes: Extracting a data storage identifier and a data operation identifier from the processing strategy identifier; Determine the data storage type corresponding to the data storage identifier; Determine the data operation type corresponding to the data operation identifier.

8. A data processing device, characterized in that: include: The acquisition module is used to obtain user input information; An extraction module, used to extract a processing strategy identifier and target data information from the user input information; A determination module, used to determine the data storage type and data operation type corresponding to the processing strategy identifier; The data operation module is used to perform the data operation corresponding to the data operation type based on the data storage strategy corresponding to the data storage type and in combination with the target data information, so as to obtain the data processing result corresponding to the user input information.

9. An electronic device, characterized in that: It includes a processor, a communication interface, a memory and a communication bus, wherein the processor, the communication interface and the memory communicate with each other through the communication bus; Memory, used to store computer programs; A processor, for implementing the data processing method according to any one of claims 1 to 7 when executing a program stored in a memory.

10. A computer-readable storage medium having a computer program stored thereon, characterized in that: When the computer program is executed by a processor, the data processing method according to any one of claims 1 to 7 is implemented.

Citation Information

Patent Citations

  • Data storage method, device and equipment and storage medium

    CN111858466A

  • Document storage method and device, electronic equipment and computer readable storage medium

    CN112416858A

  • Application data management method and system and computer equipment

    CN113835616A

  • Data storage method and device, electronic equipment and storage medium

    CN115344588A

  • Heterogeneous storage method, system and equipment for data and medium

    CN118296066A