CN114594979A - Resource file updating method and device, storage medium and terminal equipment - Google Patents

Resource file updating method and device, storage medium and terminal equipment Download PDF

Info

Publication number
CN114594979A
CN114594979A CN202210239502.4A CN202210239502A CN114594979A CN 114594979 A CN114594979 A CN 114594979A CN 202210239502 A CN202210239502 A CN 202210239502A CN 114594979 A CN114594979 A CN 114594979A
Authority
CN
China
Prior art keywords
file
directory
resource
resource file
target
Prior art date
Legal status (The legal status is an assumption and is not a legal conclusion. Google has not performed a legal analysis and makes no representation as to the accuracy of the status listed.)
Pending
Application number
CN202210239502.4A
Other languages
Chinese (zh)
Inventor
符建锋
Current Assignee (The listed assignees may be inaccurate. Google has not performed a legal analysis and makes no representation or warranty as to the accuracy of the list.)
Netease Hangzhou Network Co Ltd
Original Assignee
Netease Hangzhou Network Co Ltd
Priority date (The priority date is an assumption and is not a legal conclusion. Google has not performed a legal analysis and makes no representation as to the accuracy of the date listed.)
Filing date
Publication date
Application filed by Netease Hangzhou Network Co Ltd filed Critical Netease Hangzhou Network Co Ltd
Priority to CN202210239502.4A priority Critical patent/CN114594979A/en
Publication of CN114594979A publication Critical patent/CN114594979A/en
Pending legal-status Critical Current

Links

Images

Classifications

    • GPHYSICS
    • G06COMPUTING; CALCULATING OR COUNTING
    • G06FELECTRIC DIGITAL DATA PROCESSING
    • G06F8/00Arrangements for software engineering
    • G06F8/60Software deployment
    • G06F8/65Updates
    • G06F8/656Updates while running
    • GPHYSICS
    • G06COMPUTING; CALCULATING OR COUNTING
    • G06FELECTRIC DIGITAL DATA PROCESSING
    • G06F16/00Information retrieval; Database structures therefor; File system structures therefor
    • G06F16/10File systems; File servers
    • G06F16/16File or folder operations, e.g. details of user interfaces specifically adapted to file systems
    • GPHYSICS
    • G06COMPUTING; CALCULATING OR COUNTING
    • G06FELECTRIC DIGITAL DATA PROCESSING
    • G06F8/00Arrangements for software engineering
    • G06F8/70Software maintenance or management
    • G06F8/71Version control; Configuration management

Landscapes

  • Engineering & Computer Science (AREA)
  • Theoretical Computer Science (AREA)
  • General Engineering & Computer Science (AREA)
  • Software Systems (AREA)
  • Physics & Mathematics (AREA)
  • General Physics & Mathematics (AREA)
  • Computer Security & Cryptography (AREA)
  • Human Computer Interaction (AREA)
  • Data Mining & Analysis (AREA)
  • Databases & Information Systems (AREA)
  • Information Retrieval, Db Structures And Fs Structures Therefor (AREA)

Abstract

The embodiment of the application provides a resource file updating method, a resource file updating device, a storage medium and a terminal device, wherein the method comprises the following steps: acquiring an update resource file for updating a target system; if the updated resource file has an abnormal file, determining an abnormal directory in the abnormal file; searching a target directory corresponding to the abnormal directory in an original resource file currently used by a target system; and performing resource file updating operation on the original resource file based on the updated resource file, and skipping the resource file updating operation under the target directory. The minimum range of the current abnormal resources is analyzed, the minimum range is locked in the current correct version on the basis of normally updating the latest resources, and the rest of the normal resources can be updated and continue to the latest version.

Description

Resource file updating method and device, storage medium and terminal equipment
Technical Field
The present application relates to the field of electronic communications technologies, and in particular, to a method and an apparatus for updating a resource file, a storage medium, and a terminal device.
Background
The support of resource files cannot be removed in the process of internet development projects, the resource files are core contents of whole product display and expression, the size of the resource files is as small as a mapping of a button, and the size of the resource files is as large as a great 3D game scene, and the resource files belong to resource files. Once the resource file is in an irregular condition in the manufacturing process, certain negative effects can be brought to the development project, small effects can cause product error reporting, and large effects even cause the product to crash, so that the normalization of the resource file is one of the crucial factors in the project development flow. In order to ensure the normative of resources, project developers usually perform resource check on resource files, the check rule is the content summarized through experience accumulation in the process of project development, whether the resource files have abnormal problems or not can be found through the check, early warning is performed, the project developers are informed to timely process and repair the problems, and therefore the problems that the project development rhythm is slow and even the project development rhythm is blocked due to negative influence are avoided.
However, in the process of actual team development, it is difficult to avoid the problem of creating resource files, and when a general product obtains a resource update package of a certain version to update the product, a plurality of files in the resource update package are updated to the original resource file currently used in an orderly manner according to a predetermined order. If the files in the resource updating data packet have no abnormal problem, the product updating operation can be smoothly carried out, and if a certain file in the resource updating data packet has an abnormal problem, an error can be reported in the product updating, so that the product updating operation is interrupted, the subsequent file updating is influenced, and the product is broken down if the abnormal file is insist on being updated. I.e., stopping updating resources or insisting on updating erroneous resources are undesirable behaviors.
Disclosure of Invention
The embodiment of the application provides a resource file updating method, a resource file updating device, a resource file updating medium and a resource file updating device, wherein before a target system is updated with a resource file, the updated resource file is analyzed and judged in advance, whether the updated resource file is abnormal or not is determined in advance, an abnormal directory causing the abnormal updated resource file is found out, a target directory corresponding to the abnormal directory is searched in an original resource file currently used by the target system according to the found abnormal directory and is locked, and therefore when the original resource file is updated based on the updated resource file, the resource file updating operation under the target directory is skipped at the same time. The minimum range of the current abnormal resource is analyzed, the minimum range is locked at the current correct version on the basis of normally updating the latest resource, and the rest of the normal resources can be updated and continued to the latest version.
An embodiment of the present application provides a resource file updating method, including:
acquiring an update resource file for updating a target system;
if an abnormal file exists in the updated resource file, determining an abnormal directory in the abnormal file;
searching a target directory corresponding to the abnormal directory in an original resource file currently used by the target system;
and performing resource file updating operation on the original resource file based on the updated resource file, and skipping the resource file updating operation under the target directory.
In the resource file updating method according to the embodiment of the application, the updated resource file includes version information, target resource data and directory attribute information included in the target resource data;
the version information is used for indicating the version number of the updated resource file and whether the updated resource file has an abnormal file;
the target resource data is used for providing resources required by data updating operation;
the directory attribute information is used for indicating whether the directory contained in the target resource data is abnormal or not.
In the resource file updating method according to the embodiment of the present application, the method further includes:
and judging whether the updated resource file has the abnormal file or not according to the directory attribute information.
In the resource file updating method according to the embodiment of the present application, the method further includes:
receiving a file submission request, and acquiring target resource data carried by the file submission request;
and analyzing and judging the qualification of the target resource data, and adding corresponding version information to each target resource data according to the judgment result.
In the resource file updating method according to the embodiment of the present application, after the analyzing and determining the eligibility of the target resource data, the method further includes:
when the judgment result corresponding to the target resource data is that an abnormal file is contained, acquiring a file submitter corresponding to the target resource data;
determining the occurrence frequency of the same abnormal file from a file submission record, and taking a file submitter corresponding to the abnormal file appearing for the first time in the file submission process as a target submitter;
generating reminding information containing the target submitter;
and recording the reminding information to a database.
In the resource file updating method according to the embodiment of the present application, after the determining result corresponding to the target resource data is that an abnormal file is included, the method further includes:
acquiring a first directory in the target resource data, wherein the first directory is used for indicating a directory directly causing the update resource file to be abnormal;
the determining the exception directory in the exception file includes:
determining the first directory as the exception directory.
In the resource file updating method according to the embodiment of the present application, after the determining result corresponding to the target resource data is that an abnormal file is included, the method further includes:
judging whether a second directory of an incidence relation exists in the context of the first directory;
and when the second directory exists in the context of the first directory, determining the first directory and the second directory as the abnormal directory.
Correspondingly, another aspect of the embodiments of the present application further provides a resource file updating apparatus, including:
the first acquisition module is used for acquiring an update resource file for updating the target system;
an exception determining module, configured to determine an exception directory in the exception file if the update resource file has the exception file;
the target searching module is used for searching a target directory corresponding to the abnormal directory in an original resource file currently used by the target system;
and the resource updating module is used for performing resource file updating operation on the original resource file based on the updated resource file and skipping the resource file updating operation under the target directory.
Accordingly, another aspect of the embodiments of the present application further provides a computer-readable storage medium, where a plurality of instructions are stored, and the instructions are suitable for being loaded by a processor to perform the resource file updating method described above.
Correspondingly, another aspect of the embodiment of the present application further provides a terminal device, including a processor and a memory, where the memory stores multiple instructions, and the processor loads the instructions to execute the resource file updating method described above.
The embodiment of the application provides a resource file updating method, a resource file updating device, a storage medium and terminal equipment, wherein the method comprises the steps of obtaining an updated resource file for updating a target system; if an abnormal file exists in the updated resource file, determining an abnormal directory in the abnormal file; searching a target directory corresponding to the abnormal directory in an original resource file currently used by the target system; and performing resource file updating operation on the original resource file based on the updated resource file, and skipping the resource file updating operation under the target directory. According to the method and the device, before the resource file of the target system is updated, the updated resource file is analyzed and judged in advance, whether the updated resource file is abnormal or not is determined in advance, the abnormal directory causing the abnormal updated resource file is found out, the target directory corresponding to the abnormal directory is found out from the original resource file currently used by the target system according to the found abnormal directory, and locking is carried out, so that when the resource file updating operation is carried out on the original resource file based on the updated resource file, the resource file updating operation under the target directory is skipped at the same time. The minimum range of the current abnormal resource is analyzed, the minimum range is locked at the current correct version on the basis of normally updating the latest resource, and the rest of the normal resources can be updated and continued to the latest version.
Drawings
In order to more clearly illustrate the technical solutions in the embodiments of the present application, the drawings used in the description of the embodiments will be briefly introduced below. It is obvious that the drawings in the following description are only some embodiments of the application, and that for a person skilled in the art, other drawings can be derived from them without inventive effort.
Fig. 1 is a flowchart illustrating a resource file updating method according to an embodiment of the present application.
Fig. 2 is another schematic flow chart of a resource file updating method according to an embodiment of the present application.
Fig. 3 is another schematic flow chart of a resource file updating method according to an embodiment of the present application.
Fig. 4 is another schematic flow chart of a resource file updating method according to an embodiment of the present application.
Fig. 5 is another schematic flow chart of a resource file updating method according to an embodiment of the present application.
Fig. 6 is a schematic structural diagram of a resource file updating apparatus according to an embodiment of the present application.
Fig. 7 is another schematic structural diagram of a resource file updating apparatus according to an embodiment of the present application.
Fig. 8 is a schematic structural diagram of a terminal device according to an embodiment of the present application.
Detailed Description
The technical solutions in the embodiments of the present application will be clearly and completely described below with reference to the drawings in the embodiments of the present application. It is to be understood that the embodiments described are only a few embodiments of the present application and not all embodiments. All other embodiments, which can be derived by a person skilled in the art from the embodiments given herein without inventive step, are within the scope of the present application.
The embodiment of the application provides a resource file updating method, which can be applied to terminal equipment. The terminal equipment can be equipment such as a smart phone and a tablet computer.
In the process of actual team development, it is difficult to avoid the problem of creating resource files, and when a product is updated by obtaining a resource update data package of a certain version, a general product updates a plurality of files in the resource update data package in order on an original resource file currently used according to a predetermined order. If the files in the resource updating data packet have no abnormal problem, the product updating operation can be smoothly carried out, and if a certain file in the resource updating data packet has an abnormal problem, an error can be reported in the product updating, so that the product updating operation is interrupted, the subsequent file updating is influenced, and the product is broken down if the abnormal file is insist on being updated. I.e., stopping updating resources or insisting on updating erroneous resources are undesirable behaviors.
In order to solve the foregoing technical problem, an embodiment of the present application provides a resource file updating method. By using the resource file updating method provided by the embodiment of the application, the updated resource file can be analyzed and judged in advance before the resource file is updated on the target system, whether the updated resource file is abnormal or not is determined in advance, the abnormal directory causing the abnormal updated resource file is found out, the target directory corresponding to the abnormal directory is searched in the original resource file currently used by the target system according to the found abnormal directory and is locked, so that when the resource file updating operation is performed on the original resource file based on the updated resource file, the resource file updating operation under the target directory is skipped at the same time. The minimum range of the current abnormal resource is analyzed, the minimum range is locked at the current correct version on the basis of normally updating the latest resource, and the rest of the normal resources can be updated and continued to the latest version.
Referring to fig. 1, fig. 1 is a schematic flowchart illustrating a resource file updating method according to an embodiment of the present disclosure. The resource file updating method is applied to terminal equipment, and can comprise the following steps:
step 101, obtaining an update resource file for updating a target system.
It should be noted that, the support of the resource file cannot be removed in the internet development project process, the resource file is the core content of the whole product display and expression, the size of the resource file is as small as one button map, and the size of the resource file is as large as one ambitious 3D game scene, and the resource file belongs to the resource file. Once the resource file is in an irregular condition in the manufacturing process, certain negative effects can be brought to the development project, small effects can cause product error reporting, and large effects even cause the product to crash, so that the normalization of the resource file is one of the crucial factors in the project development flow. In order to ensure the normative of resources, project developers usually perform resource check on resource files, the check rule is the content summarized through experience accumulation in the process of project development, whether the resource files have abnormal problems or not can be found through the check, early warning is performed, the project developers are informed to timely process and repair the problems, and therefore the problems that the project development rhythm is slow and even the project development rhythm is blocked due to negative influence are avoided.
However, in the process of actual team development, it is difficult to avoid the problem of creating resource files, and when a general product obtains a resource update package of a certain version to update the product, a plurality of files in the resource update package are updated to the original resource file currently used in an orderly manner according to a predetermined order. If the files in the resource updating data packet have no abnormal problem, the product updating operation can be smoothly carried out, and if a certain file in the resource updating data packet has an abnormal problem, an error can be reported in the product updating, so that the product updating operation is interrupted, the subsequent file updating is influenced, and the product is broken down if the abnormal file is insist on being updated. I.e., stopping updating resources or insisting on updating erroneous resources are undesirable behaviors.
In order to solve the problems, the method analyzes and judges the updated resource file in advance before updating the resource file of the target system, determines whether the updated resource file is abnormal in advance, finds out an abnormal directory causing the abnormal updated resource file, searches a target directory corresponding to the abnormal directory in the original resource file currently used by the target system according to the found abnormal directory and locks the target directory, so that when the resource file updating operation is performed on the original resource file based on the updated resource file, the resource file updating operation under the target directory is skipped at the same time. The minimum range of the current abnormal resource is analyzed, the minimum range is locked at the current correct version on the basis of normally updating the latest resource, and the rest of the normal resources can be updated and continued to the latest version.
In this embodiment, based on the method provided in this embodiment, as shown in fig. 2, a user may send a resource update request from a database storing updated resource files on a terminal device through a preset control, a development team may uniformly place resources into a server-side (remote-side) warehouse for maintenance and management, a resource producer submits to the warehouse, and a resource consumer pulls from the warehouse, where the pulling process may be referred to as resource update for short.
The terminal equipment can determine whether the acquirer has the data acquisition permission or not according to the permission after receiving a data acquisition request sent by a user, and sends the updated resource file of the latest version stored in the database in advance to the terminal equipment where the user is located after determining that the acquirer has the data acquisition permission.
It should be noted that the updated resource file mentioned in the present embodiment specifically includes version information, target resource data, and directory attribute information included in the target resource data;
the version information is used for indicating the version number of the updated resource file and whether the updated resource file has an abnormal file; for example, when the updated resource file passes the check, the version number submitted this time will be subjected to database saving, which is temporarily marked as Vn; when the updated resource file is not checked to be passed, the version number submitted this time and the path error information output by checking are also stored in the database, which is temporarily recorded as the version number Vwn;
the target resource data is used for providing resources required by data updating operation, and is not limited herein;
the directory attribute information W is used to indicate whether the directory included in the target resource data is abnormal, and whether the directory included in the target resource data is abnormal can be distinguished through text identification and other forms.
It should be noted that the updated resource files stored in the database are uploaded to the database for storage at regular time by developers, and when the terminal device receives a file submission request, the target resource data carried in the file submission request is obtained first, the eligibility of the target resource data is analyzed and judged, and corresponding version information is added to each target resource data according to the judgment result. The target resource data is submitted and then the resource check is triggered, and the target resource data belongs to an automatic process and can be triggered through a hook function of version management or a schedule (form) function of timing check, so that the check can be ensured to be intervened in the first time, and the timeliness of a subsequent process is ensured.
The hook function is also called a hook function, before the system does not call the function, the hook program captures the message, the hook function obtains control right first, and the hook function can process (change) the execution behavior of the function and can also forcibly end the transfer of the message. In short, the program of the system is pulled out to become a code segment for self execution.
Resource check (resource check): the correctness of the resources is ensured, the related rules are summarized and arranged, the script or an external tool is used for judging and checking the resource application rules one by one to obtain the conclusion whether the resources meet the rules, and the whole process can be called as resource checking.
In some embodiments, after the analyzing determines eligibility of the target resource data, the method further comprises:
when the judgment result corresponding to the target resource data is that an abnormal file is contained, acquiring a file submitter corresponding to the target resource data;
determining the occurrence frequency of the same abnormal file from a file submission record, and taking a file submitter corresponding to the abnormal file appearing for the first time in the file submission process as a target submitter;
generating reminding information containing the target submitter;
and recording the reminding information to a database.
In this embodiment, it is mentioned above that the problem of creating the updated resource file is a frequent occurrence in the daily production process, and the updated resource file of the project development can be ensured to be maintained in a relatively smooth state by the above measures, but the subsequent problem of repairing the updated resource file is also very important. The core content of problem resource repair is efficient and accurate, the production level of a resource author is an influence factor, but the production level is not related to the scheme, so that the detailed description is omitted, and other factors can be improved through the system and the process.
Under normal conditions, if the problem of updating the resource file occurs after submission, the file submitter A can be taken as a responsible person to urge the responsible person to repair the problem, but in the actual production process, the submission frequency is uncontrollable, the situation of multiple submissions in a short time is possible, and if the submission actions all have the abnormal problem of updating the resource file and the abnormal contents are overlapped, the responsible person is not well positioned. Generally, the responsible person of the problem can be located according to the submitter, but if the submissions of a plurality of persons occur and the error occurs, the responsible person of the problem is not clearly located, so that the problem repairing progress is delayed.
According to the scheme, by introducing a link of analyzing the error content, the error content (namely the abnormal catalogue) can be decoupled and is corresponding to the submitter one by one, and the specific implementation also depends on the catalogue attribute information recorded in the database.
The analysis method mainly relies on directory attribute information for classification comparison, as shown in fig. 3, directory attribute information after each resource check is recorded in a format of (submitter: error text 1, error text 2 … …), when a result that a next updated resource file check fails comes, all file submitters and directory attribute information recorded before are traversed, and are compared with the directory attribute information of this time one by one, only newly generated directory attribute information falls under the name of the submitter of this time, and the record is cleared and reset after the resource check passes.
Through the analysis process, main responsible persons (namely target submitters) can be accurately positioned for all abnormal problems of the updated resource files, the responsibility of abnormal catalogues in target resource data to be submitted is attributed to the submitters who submit the abnormal catalogues for the first time, even feedback reminding (using a chat tool or a mail notification mechanism and the like) is carried out, the repairing progress is ensured, and in addition, under the condition that the problems are not effectively repaired after being reminded for many times, an additional alarm mechanism can be added, such as feedback to a superior supervisor and the like, so that the production link of a project team can be efficiently and iteratively promoted.
Step 102, if an abnormal file exists in the updated resource file, determining an abnormal directory in the abnormal file.
In this embodiment, whether an abnormal file exists in the updated resource file may be determined according to the directory attribute information.
In some embodiments, when the determination result corresponding to the target resource data includes an abnormal file, the method further includes:
and acquiring a first directory in the target resource data, wherein the first directory is used for indicating a directory directly causing the update resource file exception. At this time, the first directory is an exception directory.
In another embodiment, since there may be an update result of a resource file in an abnormal directory that affects a resource file in another directory in the normal resource update process, if the foregoing situation is ignored, and only the directory that directly causes the update resource file to be abnormal is marked as the abnormal directory, then the subsequent target system may also be caused to report an error or crash.
In order to avoid the above situation, as shown in fig. 4, the present solution determines whether the second directory of the association relationship exists in the context of the first directory, and when it is determined that the second directory exists in the context of the first directory, the first directory and the second directory are determined as the abnormal directory. For example, exception directory B2 appears after a commit, and B2 is referenced by directory C1, which also references directory C3, at which time directories C1/B2/C3 all belong to the exception directory.
Step 103, searching a target directory corresponding to the abnormal directory in the original resource file currently used by the target system.
In this embodiment, a target directory corresponding to the found abnormal directory is searched in an original resource file currently used by the target system according to the found abnormal directory, and locking is performed.
And 104, performing resource file updating operation on the original resource file based on the updated resource file, and skipping the resource file updating operation under the target directory.
In this embodiment, as shown in fig. 5, when performing a resource file update operation on an original resource file based on an updated resource file, the resource file update operation in a target directory is skipped at the same time. The minimum range of the current abnormal resource is analyzed, the minimum range is locked at the current correct version on the basis of normally updating the latest resource, and the rest of the normal resources can be updated and continued to the latest version.
All the above optional technical solutions may be combined arbitrarily to form optional embodiments of the present application, and are not described in detail herein.
In particular implementation, the present application is not limited by the execution sequence of the described steps, and some steps may be performed in other sequences or simultaneously without conflict.
As can be seen from the above, the resource file updating method provided in the embodiment of the present application obtains the updated resource file for updating the target system; if an abnormal file exists in the updated resource file, determining an abnormal directory in the abnormal file; searching a target directory corresponding to the abnormal directory in an original resource file currently used by the target system; and performing resource file updating operation on the original resource file based on the updated resource file, and skipping the resource file updating operation under the target directory. According to the method and the device, before the resource file of the target system is updated, the updated resource file is analyzed and judged in advance, whether the updated resource file is abnormal or not is determined in advance, the abnormal directory causing the abnormal updated resource file is found out, the target directory corresponding to the abnormal directory is found out from the original resource file currently used by the target system according to the found abnormal directory, and locking is carried out, so that when the resource file updating operation is carried out on the original resource file based on the updated resource file, the resource file updating operation under the target directory is skipped at the same time. The minimum range of the current abnormal resource is analyzed, the minimum range is locked at the current correct version on the basis of normally updating the latest resource, and the rest of the normal resources can be updated and continued to the latest version.
The embodiment of the application also provides a resource file updating device, and the resource file updating device can be integrated in the terminal equipment. The terminal equipment can be equipment such as a smart phone and a tablet computer.
Referring to fig. 6, fig. 6 is a schematic structural diagram of a resource file updating apparatus according to an embodiment of the present application. The resource file updating apparatus 30 may include:
a first obtaining module 31, configured to obtain an update resource file for updating a target system;
an exception determining module 32, configured to determine, if an exception file exists in the updated resource file, an exception directory in the exception file;
a target searching module 33, configured to search a target directory corresponding to the abnormal directory in an original resource file currently used by the target system;
and the resource updating module 34 is configured to perform a resource file updating operation on the original resource file based on the updated resource file, and skip the resource file updating operation in the target directory.
In some embodiments, the updated resource file includes version information, target resource data, and directory attribute information included in the target resource data; the version information is used for indicating the version number of the updated resource file and whether the updated resource file has an abnormal file; the target resource data is used for providing resources required by data updating operation; the directory attribute information is used for indicating whether the directory contained in the target resource data is abnormal or not.
In some embodiments, the apparatus further includes a first determining module, configured to determine whether the abnormal file exists in the updated resource file according to the directory attribute information.
In some embodiments, the apparatus further includes an information adding module, configured to receive a file submission request, and obtain target resource data carried in the file submission request; and analyzing and judging the qualification of the target resource data, and adding corresponding version information to each target resource data according to the judgment result.
In some embodiments, the apparatus further includes a responsibility following module, configured to, when a determination result corresponding to the target resource data is that an abnormal file is included, obtain a file submitter corresponding to the target resource data; determining the occurrence frequency of the same abnormal file from a file submission record, and taking a file submitter corresponding to the abnormal file appearing for the first time in the file submission process as a target submitter; generating reminding information containing the target submitter; and recording the reminding information to a database.
In some embodiments, the apparatus further includes a second obtaining module, configured to obtain a first directory in the target resource data, where the first directory is used to indicate a directory that directly causes the updated resource file to be abnormal.
In some embodiments, the exception determining module 32 is configured to determine the first directory as the exception directory.
In some embodiments, the apparatus further includes a second determining module, configured to determine whether a second directory of the association exists in the context of the first directory; and when the second directory exists in the context of the first directory, determining the first directory and the second directory as the abnormal directories.
In specific implementation, the modules may be implemented as independent entities, or may be combined arbitrarily and implemented as one or several entities.
As can be seen from the above, the resource file updating apparatus 30 provided in the embodiment of the present application obtains, by using the first obtaining module 31, an updated resource file for updating the target system; if an abnormal file exists in the updated resource file, the abnormal determining module 32 determines an abnormal directory in the abnormal file; the target searching module 33 searches a target directory corresponding to the abnormal directory in the original resource file currently used by the target system; the resource updating module 34 performs a resource file updating operation on the original resource file based on the updated resource file, and skips the resource file updating operation in the target directory.
Referring to fig. 7, fig. 7 is another schematic structural diagram of a resource file updating apparatus according to an embodiment of the present application, in which the resource file updating apparatus 30 includes a memory 120, one or more processors 180, and one or more applications, where the one or more applications are stored in the memory 120 and configured to be executed by the processor 180; the processor 180 may include a first acquisition module 31, an anomaly determination module 32, a target lookup module 33, and a resource update module 34. For example, the structures and connection relationships of the above components may be as follows:
the memory 120 may be used to store applications and data. The memory 120 stores applications containing executable code. The application programs may constitute various functional modules. The processor 180 executes various functional applications and data processing by running the application programs stored in the memory 120. Further, the memory 120 may include high speed random access memory, and may also include non-volatile memory, such as at least one magnetic disk storage device, flash memory device, or other volatile solid state storage device. Accordingly, the memory 120 may also include a memory controller to provide the processor 180 with access to the memory 120.
The processor 180 is a control center of the device, connects various parts of the entire terminal using various interfaces and lines, performs various functions of the device and processes data by running or executing an application program stored in the memory 120 and calling data stored in the memory 120, thereby monitoring the entire device. Optionally, processor 180 may include one or more processing cores; preferably, the processor 180 may integrate an application processor and a modem processor, wherein the application processor mainly processes an operating system, a user interface, an application program, and the like.
Specifically, in this embodiment, the processor 180 loads the executable code corresponding to the process of one or more application programs into the memory 120 according to the following instructions, and the processor 180 runs the application programs stored in the memory 120, thereby implementing various functions:
a first obtaining module 31, configured to obtain an update resource file for updating a target system;
an exception determining module 32, configured to determine, if an exception file exists in the updated resource file, an exception directory in the exception file;
a target searching module 33, configured to search a target directory corresponding to the abnormal directory in an original resource file currently used by the target system;
and the resource updating module 34 is configured to perform a resource file updating operation on the original resource file based on the updated resource file, and skip the resource file updating operation in the target directory.
In some embodiments, the updated resource file includes version information, target resource data, and directory attribute information included in the target resource data; the version information is used for indicating the version number of the updated resource file and whether an abnormal file exists in the updated resource file; the target resource data is used for providing resources required by data updating operation; the directory attribute information is used for indicating whether the directory contained in the target resource data is abnormal or not.
In some embodiments, the apparatus further includes a first determining module, configured to determine whether the updated resource file has the abnormal file according to the directory attribute information.
In some embodiments, the apparatus further includes an information adding module, configured to receive a file submission request, and obtain target resource data carried by the file submission request; and analyzing and judging the qualification of the target resource data, and adding corresponding version information to each target resource data according to the judgment result.
In some embodiments, the apparatus further includes a responsibility following module, configured to, when a determination result corresponding to the target resource data is that an abnormal file is included, obtain a file submitter corresponding to the target resource data; determining the occurrence frequency of the same abnormal file from a file submission record, and taking a file submitter corresponding to the abnormal file appearing for the first time in the file submission process as a target submitter; generating reminding information containing the target submitter; and recording the reminding information to a database.
In some embodiments, the apparatus further includes a second obtaining module, configured to obtain a first directory in the target resource data, where the first directory is used to indicate a directory that directly causes the updated resource file to be abnormal.
In some embodiments, the exception determining module 32 is configured to determine the first directory as the exception directory.
In some embodiments, the apparatus further includes a second determining module, configured to determine whether a second directory of an association exists in the context of the first directory; and when the second directory exists in the context of the first directory, determining the first directory and the second directory as the abnormal directory.
The embodiment of the application further provides the terminal equipment. The terminal equipment can be equipment such as a smart phone, a computer and a tablet computer.
Referring to fig. 8, fig. 8 is a schematic structural diagram of a terminal device according to an embodiment of the present application, where the terminal device may be used to implement the resource file updating method provided in the foregoing embodiment. The terminal device 1200 may be a smart phone or a tablet computer.
As shown in fig. 8, the terminal device 1200 may include an RF (Radio Frequency) circuit 110, a memory 120 including one or more computer-readable storage media (only one shown in the figure), an input unit 130, a display unit 140, a sensor 150, an audio circuit 160, a transmission module 170, a processor 180 including one or more processing cores (only one shown in the figure), and a power supply 190. Those skilled in the art will appreciate that the terminal device 1200 configuration shown in fig. 8 is not intended to be limiting of terminal device 1200 and may include more or fewer components than shown, or some components may be combined, or a different arrangement of components. Wherein:
the RF circuit 110 is used for receiving and transmitting electromagnetic waves, and performs interconversion between the electromagnetic waves and electrical signals, so as to communicate with a communication network or other devices. The RF circuitry 110 may include various existing circuit elements for performing these functions, such as an antenna, a radio frequency transceiver, a digital signal processor, an encryption/decryption chip, a Subscriber Identity Module (SIM) card, memory, and so forth. The RF circuitry 110 may communicate with various networks, such as the internet, an intranet, a wireless network, or with other devices over a wireless network.
The memory 120 may be configured to store a software program and a module, such as a program instruction/module corresponding to the resource file updating method in the foregoing embodiment, and the processor 180 executes various functional applications and data processing by operating the software program and the module stored in the memory 120, and may automatically select a vibration alert mode to update data according to a current scene where the terminal device is located, so as to ensure that scenes such as a conference and the like are not disturbed, ensure that a user can sense an incoming call, and improve intelligence of the terminal device. Memory 120 may include high speed random access memory and may also include non-volatile memory, such as one or more magnetic storage devices, flash memory, or other non-volatile solid-state memory. In some examples, the memory 120 may further include memory located remotely from the processor 180, which may be connected to the terminal device 1200 via a network. Examples of such networks include, but are not limited to, the internet, intranets, local area networks, mobile communication networks, and combinations thereof.
The input unit 130 may be used to receive input numeric or character information and generate keyboard, mouse, joystick, optical or trackball signal inputs related to user settings and function control. In particular, the input unit 130 may include a touch-sensitive surface 131 as well as other input devices 132. Touch-sensitive surface 131, also referred to as a touch display screen or touch pad, may collect touch operations by a user on or near the touch-sensitive surface 131 (e.g., operations by a user on or near touch-sensitive surface 131 using a finger, a stylus, or any other suitable object or attachment) and actuate the corresponding connection device according to a predetermined program. Alternatively, the touch sensitive surface 131 may comprise two parts, a touch detection means and a touch controller. The touch detection device detects the touch direction of a user, detects a signal brought by touch operation and transmits the signal to the touch controller; the touch controller receives touch information from the touch sensing device, converts the touch information into touch point coordinates, sends the touch point coordinates to the processor 180, and can receive and execute commands sent by the processor 180. Additionally, the touch-sensitive surface 131 may be implemented using various types of resistive, capacitive, infrared, and surface acoustic waves. In addition to the touch-sensitive surface 131, the input unit 130 may also include other input devices 132. In particular, other input devices 132 may include, but are not limited to, one or more of a physical keyboard, function keys (such as volume control keys, switch keys, etc.), a trackball, a mouse, a joystick, and the like.
The display unit 140 may be used to display information input by or provided to a user and various graphic user interfaces of the terminal apparatus 1200, which may be configured by graphics, text, icons, video, and any combination thereof. The Display unit 140 may include a Display panel 141, and optionally, the Display panel 141 may be configured in the form of an LCD (Liquid Crystal Display), an OLED (Organic Light-Emitting Diode), or the like. Further, the touch-sensitive surface 131 may cover the display panel 141, and when a touch operation is detected on or near the touch-sensitive surface 131, the touch operation is transmitted to the processor 180 to determine the type of the touch event, and then the processor 180 provides a corresponding visual output on the display panel 141 according to the type of the touch event. Although in FIG. 8, touch-sensitive surface 131 and display panel 141 are shown as two separate components to implement input and output functions, in some embodiments, touch-sensitive surface 131 may be integrated with display panel 141 to implement input and output functions.
The terminal device 1200 may also include at least one sensor 150, such as a light sensor, a motion sensor, and other sensors. Specifically, the light sensor may include an ambient light sensor that may adjust the brightness of the display panel 141 according to the brightness of ambient light, and a proximity sensor that may turn off the display panel 141 and/or the backlight when the terminal device 1200 is moved to the ear. As one of the motion sensors, the gravity acceleration sensor can detect the magnitude of acceleration in each direction (generally, three axes), can detect the magnitude and direction of gravity when the mobile phone is stationary, and can be used for applications of recognizing the posture of the mobile phone (such as horizontal and vertical screen switching, related games, magnetometer posture calibration), vibration recognition related functions (such as pedometer and tapping), and the like; as for other sensors such as a gyroscope, a barometer, a hygrometer, a thermometer, and an infrared sensor, which may be further configured in the terminal device 1200, detailed descriptions thereof are omitted.
The audio circuitry 160, speaker 161, microphone 162 may provide an audio interface between the user and the terminal device 1200. The audio circuit 160 may transmit the electrical signal converted from the received audio data to the speaker 161, and convert the electrical signal into a sound signal for output by the speaker 161; on the other hand, the microphone 162 converts the collected sound signal into an electric signal, converts the electric signal into audio data after being received by the audio circuit 160, and then outputs the audio data to the processor 180 for processing, and then to the RF circuit 110 to be transmitted to, for example, another terminal, or outputs the audio data to the memory 120 for further processing. The audio circuitry 160 may also include an earbud jack to provide communication of peripheral headphones with the terminal device 1200.
The terminal device 1200, which may assist the user in sending and receiving e-mails, browsing web pages, accessing streaming media, etc., through the transmission module 170 (e.g., Wi-Fi module), provides the user with wireless broadband internet access. Although fig. 8 shows the transmission module 170, it is understood that it does not belong to the essential constitution of the terminal device 1200, and may be omitted entirely as needed within the scope not changing the essence of the invention.
The processor 180 is a control center of the terminal device 1200, connects various parts of the entire mobile phone by using various interfaces and lines, and performs various functions of the terminal device 1200 and processes data by running or executing software programs and/or modules stored in the memory 120 and calling data stored in the memory 120, thereby performing overall monitoring of the mobile phone. Optionally, processor 180 may include one or more processing cores; in some embodiments, the processor 180 may integrate an application processor, which primarily handles operating systems, user interfaces, applications, etc., and a modem processor, which primarily handles wireless communications. It will be appreciated that the modem processor described above may not be integrated into the processor 180.
Terminal device 1200 also includes a power supply 190 for powering the various components, which in some embodiments may be logically coupled to processor 180 via a power management system to manage power discharge and power consumption via the power management system. The power supply 190 may also include any component including one or more of a dc or ac power source, a recharging system, a power failure detection circuit, a power converter or inverter, a power status indicator, and the like.
Although not shown, the terminal device 1200 may further include a camera (e.g., a front camera, a rear camera), a bluetooth module, and the like, which are not described in detail herein. Specifically, in this embodiment, the display unit 140 of the terminal device 1200 is a touch screen display, and the terminal device 1200 further includes a memory 120, and one or more programs, wherein the one or more programs are stored in the memory 120, and the one or more programs configured to be executed by the one or more processors 180 include instructions for:
the system comprises a first acquisition instruction, a first storage unit and a first processing unit, wherein the first acquisition instruction is used for acquiring an update resource file for updating a target system;
an exception determining instruction, configured to determine an exception directory in an exception file if the exception file exists in the updated resource file;
a target searching instruction, configured to search a target directory corresponding to the abnormal directory in an original resource file currently used by the target system;
and the resource updating instruction is used for carrying out resource file updating operation on the original resource file based on the updated resource file and skipping over the resource file updating operation under the target directory.
In some embodiments, the updated resource file includes version information, target resource data, and directory attribute information included in the target resource data; the version information is used for indicating the version number of the updated resource file and whether the updated resource file has an abnormal file; the target resource data is used for providing resources required by data updating operation; the directory attribute information is used for indicating whether the directory contained in the target resource data is abnormal or not.
In some embodiments, the program further includes a first determining instruction, configured to determine whether the exception file exists in the updated resource file according to the directory attribute information.
In some embodiments, the program further includes an information adding instruction, configured to receive a file submission request, and obtain target resource data carried by the file submission request; and analyzing and judging the qualification of the target resource data, and adding corresponding version information to each target resource data according to the judgment result.
In some embodiments, the program further includes a responsibility following instruction, configured to, when a determination result corresponding to the target resource data is that an abnormal file is included, obtain a file submitter corresponding to the target resource data; determining the occurrence frequency of the same abnormal file from a file submission record, and taking a file submitter corresponding to the abnormal file appearing for the first time in the file submission process as a target submitter; generating reminding information containing the target submitter; and recording the reminding information to a database.
In some embodiments, the program further includes second obtaining instructions for obtaining a first directory in the target resource data, the first directory indicating a directory that directly causes the updated resource file to be abnormal.
In some embodiments, the exception determining instruction is to determine the first directory to be the exception directory.
In some embodiments, the program further includes a second judgment instruction for judging whether a second directory of the association exists in the context of the first directory; and when the second directory exists in the context of the first directory, determining the first directory and the second directory as the abnormal directory.
The embodiment of the application also provides the terminal equipment. The terminal equipment can be equipment such as a smart phone and a tablet computer.
As can be seen from the above, an embodiment of the present application provides a terminal device 1200, where the terminal device 1200 executes the following steps: acquiring an update resource file for updating a target system; if an abnormal file exists in the updated resource file, determining an abnormal directory in the abnormal file; searching a target directory corresponding to the abnormal directory in an original resource file currently used by the target system; and performing resource file updating operation on the original resource file based on the updated resource file, and skipping the resource file updating operation under the target directory. According to the method and the device, before the resource file of the target system is updated, the updated resource file is analyzed and judged in advance, whether the updated resource file is abnormal or not is determined in advance, the abnormal directory causing the abnormal updated resource file is found out, the target directory corresponding to the abnormal directory is found out from the original resource file currently used by the target system according to the found abnormal directory, and locking is carried out, so that when the resource file updating operation is carried out on the original resource file based on the updated resource file, the resource file updating operation under the target directory is skipped at the same time. The minimum range of the current abnormal resource is analyzed, the minimum range is locked at the current correct version on the basis of normally updating the latest resource, and the rest of the normal resources can be updated and continued to the latest version.
An embodiment of the present application further provides a computer-readable storage medium, where a computer program is stored in the computer-readable storage medium, and when the computer program runs on a computer, the computer executes the resource file updating method according to any of the above embodiments.
It should be noted that, for the resource file updating method described in this application, a person skilled in the art may understand that all or part of the process of implementing the resource file updating method described in this application may be implemented by controlling related hardware through a computer program, where the computer program may be stored in a computer readable storage medium, such as a memory of a terminal device, and executed by at least one processor in the terminal device, and during the execution process, the process of implementing the embodiment of the resource file updating method may be included. The storage medium may be a magnetic disk, an optical disk, a Read Only Memory (ROM), a Random Access Memory (RAM), or the like.
For the resource file updating apparatus in the embodiment of the present application, each functional module may be integrated in one processing chip, or each module may exist alone physically, or two or more modules are integrated in one module. The integrated module can be realized in a hardware mode, and can also be realized in a software functional module mode. The integrated module, if implemented in the form of a software functional module and sold or used as a stand-alone product, may also be stored in a computer readable storage medium, such as a read-only memory, a magnetic or optical disk, or the like.
The resource file updating method, device, computer-readable storage medium and terminal device provided by the embodiments of the present application are described in detail above. The principle and the implementation of the present application are explained herein by applying specific examples, and the above description of the embodiments is only used to help understand the method and the core idea of the present application; meanwhile, for those skilled in the art, according to the idea of the present application, there may be variations in the specific embodiments and the application scope, and in summary, the content of the present specification should not be construed as a limitation to the present application.

Claims (10)

1. A resource file updating method is characterized by comprising the following steps:
acquiring an update resource file for updating a target system;
if an abnormal file exists in the updated resource file, determining an abnormal directory in the abnormal file;
searching a target directory corresponding to the abnormal directory in an original resource file currently used by the target system;
and performing resource file updating operation on the original resource file based on the updated resource file, and skipping the resource file updating operation under the target directory.
2. The resource file updating method according to claim 1, wherein the updated resource file includes version information, target resource data, and directory attribute information included in the target resource data;
the version information is used for indicating the version number of the updated resource file and whether the updated resource file has an abnormal file;
the target resource data is used for providing resources required by data updating operation;
the directory attribute information is used for indicating whether the directory contained in the target resource data is abnormal or not.
3. The resource file updating method of claim 2, wherein the method further comprises:
and judging whether the updated resource file has the abnormal file or not according to the directory attribute information.
4. The resource file updating method of claim 3, wherein the method further comprises:
receiving a file submission request, and acquiring target resource data carried by the file submission request;
and analyzing and judging the qualification of the target resource data, and adding corresponding version information to each target resource data according to the judgment result.
5. The resource file updating method of claim 4, wherein after the analyzing determines eligibility of the target resource data, the method further comprises:
when the judgment result corresponding to the target resource data is that an abnormal file is contained, acquiring a file submitter corresponding to the target resource data;
determining the occurrence frequency of the same abnormal file from a file submission record, and taking a file submitter corresponding to the abnormal file appearing for the first time in the file submission process as a target submitter;
generating reminding information containing the target submitter;
and recording the reminding information to a database.
6. The method for updating the resource file according to claim 4, wherein after the determining result corresponding to the target resource data is that the target resource data contains an abnormal file, the method further comprises:
acquiring a first directory in the target resource data, wherein the first directory is used for indicating a directory directly causing the update resource file to be abnormal;
the determining the exception directory in the exception file includes:
determining the first directory as the exception directory.
7. The method for updating the resource file according to claim 6, wherein after the determining result corresponding to the target resource data is that the target resource data contains an abnormal file, the method further comprises:
judging whether a second directory of an incidence relation exists in the context of the first directory;
and when the second directory exists in the context of the first directory, determining the first directory and the second directory as the abnormal directory.
8. A resource file updating apparatus, comprising:
the first acquisition module is used for acquiring an update resource file for updating the target system;
an exception determining module, configured to determine an exception directory in the exception file if the update resource file has the exception file;
the target searching module is used for searching a target directory corresponding to the abnormal directory in an original resource file currently used by the target system;
and the resource updating module is used for performing resource file updating operation on the original resource file based on the updated resource file and skipping the resource file updating operation under the target directory.
9. A computer-readable storage medium storing instructions adapted to be loaded by a processor to perform the resource file update method of any one of claims 1-7.
10. A terminal device comprising a processor and a memory, wherein the memory stores a plurality of instructions, and the processor loads the instructions to execute the resource file updating method according to any one of claims 1 to 7.
CN202210239502.4A 2022-03-11 2022-03-11 Resource file updating method and device, storage medium and terminal equipment Pending CN114594979A (en)

Priority Applications (1)

Application Number Priority Date Filing Date Title
CN202210239502.4A CN114594979A (en) 2022-03-11 2022-03-11 Resource file updating method and device, storage medium and terminal equipment

Applications Claiming Priority (1)

Application Number Priority Date Filing Date Title
CN202210239502.4A CN114594979A (en) 2022-03-11 2022-03-11 Resource file updating method and device, storage medium and terminal equipment

Publications (1)

Publication Number Publication Date
CN114594979A true CN114594979A (en) 2022-06-07

Family

ID=81817288

Family Applications (1)

Application Number Title Priority Date Filing Date
CN202210239502.4A Pending CN114594979A (en) 2022-03-11 2022-03-11 Resource file updating method and device, storage medium and terminal equipment

Country Status (1)

Country Link
CN (1) CN114594979A (en)

Similar Documents

Publication Publication Date Title
CN108089977B (en) Application program exception handling method and device and mobile terminal
CN109947650B (en) Script step processing method, device and system
CN108536594B (en) Page testing method and device and storage equipment
CN110196795B (en) Method and related device for detecting running state of mobile terminal application
CN111078556B (en) Application testing method and device
CN111666222A (en) Test method and related device
CN112231144A (en) Data processing method and device and electronic equipment
CN108874653B (en) Task testing method, tester, shared server and readable storage medium
CN115576600A (en) Code change-based difference processing method and device, terminal and storage medium
CN115952096A (en) Fault detection method, device, equipment and medium of data center software system
CN112000566A (en) Test case generation method and device
CN106709330B (en) Method and device for recording file execution behaviors
CN115600213A (en) Vulnerability management method, device, medium and equipment based on application program
CN115987786A (en) Configuration change method, system, terminal equipment and storage medium
CN114594979A (en) Resource file updating method and device, storage medium and terminal equipment
CN115589432A (en) Message push management method, device, medium and equipment
US11567822B2 (en) Method of monitoring closed system, apparatus thereof and monitoring device
CN106970814B (en) Processing method, device and system for software upgrading
CN115543841A (en) Data update test method, device, medium and equipment
CN115640081A (en) Business case decision method and device, electronic equipment and storage medium
CN114911994A (en) Database-based data matching method, device, medium and equipment
CN115658419A (en) Model data monitoring method, device, medium and equipment
CN115495383A (en) Data pushing method and device, storage medium and electronic equipment
CN116974846A (en) Abnormal data processing method and device, electronic equipment and storage medium
CN117435457A (en) Platform performance automatic test method, device, medium and equipment

Legal Events

Date Code Title Description
PB01 Publication
PB01 Publication
SE01 Entry into force of request for substantive examination
SE01 Entry into force of request for substantive examination