Dependency package configuration method, device, equipment and medium in big data platform

By obtaining and renaming conflicting dependency packages in the big data platform, the problem of dependency package name conflicts is solved, troubleshooting time is reduced, program update efficiency is improved, and the stability and efficient operation of the big data platform are ensured.

CN109284125BInactive Publication Date: 2024-08-30CHINA PING AN LIFE INSURANCE CO LTD
View PDF 2 Cites 0 Cited by

Patent Information

Application Number
CN201810919746.0
Authority / Receiving Office
CN · China
Patent Type
Patents(China)
Current Assignee / Owner
Filing Date
2018-08-14
Publication Date
2024-08-30
Estimated Expiration
Not applicable · inactive patent

AI Technical Summary

Technical Problem

In the big data platform, conflicts caused by the same name after dependent package version updates increase troubleshooting time and development cycle, affecting the efficiency of program updates.

Method used

By obtaining the configuration request of the project's dependency package, use the preset script to obtain the name table of the old version of the dependency package, match and rename the conflicting dependency package, and ensure that the new version of the dependency package has different names from the old version of the dependency package, thereby avoiding conflicts and configuring to big data in the platform.

Benefits of technology

It reduces the troubleshooting time caused by dependency package conflicts, improves the program update efficiency of the big data platform, and improves operational efficiency.

✦ Generated by Eureka AI based on patent content.

Smart Images

  • Figure CN109284125B
    Figure CN109284125B
Patent Text Reader

Abstract

The present invention discloses a dependency package configuration method, device, equipment and medium in a big data platform, wherein the dependency package configuration method in the big data platform comprises: obtaining a configuration request of a project dependency package, wherein the configuration request comprises the name of the project dependency package; obtaining the name of the old version dependency package in a big data program in the big data platform according to a preset script, and obtaining a name table of the old version dependency package; performing a matching query in the old version dependency package name table according to the name of the project dependency package, and taking the successfully matched project dependency package as a conflict dependency package; renaming the conflict dependency package to obtain a new version dependency package; and configuring the project dependency package and the new version dependency package in the big data program in the big data platform. The method can solve the conflict caused by the same name as the old version dependency package when configuring the new version dependency package in the big data platform, and improve the efficiency of various subsequent operations based on the big data platform.
Need to check novelty before this filing date? Find Prior Art

Description

Technical Field

[0001] The present invention relates to the field of computer technology, and in particular to a method, device, equipment and medium for configuring dependency packages in a big data platform. Background Art

[0002] At present, when the programs in the big data platform are running, the functions are implemented by different dependency packages. Since the versions of the dependency packages in the big data program will be updated according to the actual application situation, after the updated version, there will be conflicts with the old version of the dependency package because of the same name, which will cause the program in the big data platform to fail to run, increase the time for troubleshooting, and increase the development cycle. Summary of the invention

[0003] The embodiments of the present invention provide a method, apparatus, computer equipment and storage medium for configuring dependency packages in a big data platform to solve the problem of big data program running failure due to dependency package name conflict when configuring dependency packages.

[0004] A method for configuring dependency packages in a big data platform, comprising:

[0005] Obtain a configuration request for a project dependency package, wherein the configuration request includes a name of the project dependency package;

[0006] According to the preset script, the name of the old version dependency package is obtained in the big data program in the big data platform to obtain the old version dependency package name table;

[0007] Perform a match query in the old version dependency package name table according to the name of the project dependency package, and use the successfully matched project dependency package as the conflicting dependency package;

[0008] Rename the conflicting dependency package to obtain a new version dependency package;

[0009] The project dependency package and the new version dependency package are configured in the big data program in the big data platform.

[0010] A dependency package configuration device in a big data platform, comprising:

[0011] A configuration request acquisition module, used to acquire a configuration request of a project dependency package, wherein the configuration request includes a name of the project dependency package;

[0012] A dependency package name acquisition module is used to obtain the name of the old version dependency package in the big data program in the big data platform according to a preset script, and obtain an old version dependency package name table;

[0013] A query module, used to perform a matching query in the old version dependency package name table according to the name of the project dependency package, and use the successfully matched project dependency package as a conflicting dependency package;

[0014] A renaming module, used to rename the conflicting dependency package to obtain a new version of the dependency package;

[0015] A configuration module is used to configure the project dependency package and the new version dependency package in the big data program in the big data platform.

[0016] A computer device comprises a memory, a processor and a computer program stored in the memory and executable on the processor, wherein the processor implements the steps of the dependency package configuration method in the above-mentioned big data platform when executing the computer program.

[0017] A computer-readable storage medium stores a computer program, which, when executed by a processor, implements the steps of the dependency package configuration method in the above-mentioned big data platform.

[0018] The dependency package configuration method, device, computer equipment and storage medium in the above-mentioned big data platform, by searching for conflicting dependency packages according to the name of the current project dependency package before configuring the project dependency package, and renaming the conflicting dependency package to obtain a new version dependency package. Then the project dependency package and the new version dependency package are configured in the big data program in the big data platform. After the project dependency package is configured, the dependency package conflict problem caused by the same name of the project dependency package and the old version dependency package can be avoided, the troubleshooting time is reduced, the efficiency of program updates in the big data platform is improved, and the efficiency of various subsequent operations based on the big data platform is improved. BRIEF DESCRIPTION OF THE DRAWINGS

[0019] In order to more clearly illustrate the technical solutions of the embodiments of the present invention, the accompanying drawings required for use in the description of the embodiments of the present invention will be briefly introduced below. Obviously, the accompanying drawings in the following description are only some embodiments of the present invention. For ordinary technicians in this field, other accompanying drawings can be obtained based on these accompanying drawings without paying creative labor.

[0020] Figure 1 It is a schematic diagram of an application environment of a dependency package configuration method in a big data platform in one embodiment of the present invention;

[0021] Figure 2 It is a flow chart of a method for configuring a dependency package in a big data platform in one embodiment of the present invention;

[0022] Figure 3It is a flowchart for implementing step S30 in the method for configuring a dependency package in a big data platform in one embodiment of the present invention;

[0023] Figure 4 It is a flowchart for implementing step S32 in the method for configuring a dependency package in a big data platform in one embodiment of the present invention;

[0024] Figure 5 It is a flowchart for implementing step S40 in the method for configuring a dependency package in a big data platform in one embodiment of the present invention;

[0025] Figure 6 It is a flowchart for implementing step S50 in the method for configuring a dependency package in a big data platform in one embodiment of the present invention;

[0026] Figure 7 is another flow chart of a method for configuring a dependency package in a big data platform in one embodiment of the present invention;

[0027] Figure 8 It is a principle block diagram of a dependency package configuration device in a big data platform in one embodiment of the present invention;

[0028] Fig. 9 is a schematic diagram of a computer device in one embodiment of the present invention. DETAILED DESCRIPTION

[0029] The following will be combined with the drawings in the embodiments of the present invention to clearly and completely describe the technical solutions in the embodiments of the present invention. Obviously, the described embodiments are part of the embodiments of the present invention, not all of the embodiments. Based on the embodiments of the present invention, all other embodiments obtained by ordinary technicians in this field without creative work are within the scope of protection of the present invention.

[0030] The dependency package configuration method in the big data platform provided in this application can be applied to Figure 1 application environment. Among them, the big data platform refers to a platform used to store data from various databases in the service client cluster and perform operations such as calculation, analysis or processing on the data. The client (computer device) communicates with the server through the network. The client sends a configuration request for the project dependency package to the server. The server performs a matching query based on the configuration request, processes the project dependency package based on the matching query results, and finally sends it to the big data program in the big data platform. Among them, the client (computer device) can be but is not limited to various personal computers, laptops, smart phones, tablets and portable wearable devices. The server can be implemented with an independent server or a server cluster consisting of multiple servers.

[0031] In one embodiment, if Figure 2As shown, a dependency package configuration method in a big data platform is provided, and the method is applied in Figure 1 The server in the example is used as an example to illustrate the process, including the following steps:

[0032] S10: Obtain a configuration request for a project dependency package, where the configuration request includes a name of the project dependency package.

[0033] In this embodiment, a dependency package refers to a data package that can implement different functions in a big data program. A project dependency package refers to a dependency package that implements corresponding functions in different projects according to the specific needs of the project. It can be understood that there are some project dependency packages that update the functions implemented by the existing dependency packages in the big data program according to the specific needs of the actual project. Optionally, there is at least one project dependency package. A configuration request refers to a request to configure the project dependency package in the big data program after obtaining the project dependency package, and the configuration request includes the name of the project dependency package.

[0034] S20: According to a preset script, the names of the old version dependency packages are obtained in the big data program in the big data platform to obtain a table of old version dependency package names.

[0035] In this embodiment, the preset script refers to a pre-written program code. The old version dependency package refers to a dependency package that has been successfully configured in the current big data program. The old version dependency package name table refers to a data table for storing the names of the old version dependency packages obtained by the preset script in the big data program in the big data platform.

[0036] Specifically, the dependency package is configured in the big data program in the form of a jar package, that is, the suffix of the name of the dependency package is ".jar". Therefore, when writing the preset script, the name suffix of the dependency package, that is, ".jar", is used as a keyword to search in the big data program. If a file with the suffix ".jar" is found, the name of the jar package found is put into a newly created data table. After the query in the big data program is completed, the newly created data table is used as the old version dependency package name table.

[0037] S30: Perform a matching query in the old version dependency package name table according to the name of the project dependency package, and use the successfully matched project dependency package as a conflicting dependency package.

[0038] In this embodiment, a conflicting dependency package refers to a project dependency package whose name is the same as that in the old version dependency package name table. A successful match means that when a matching query is performed in the old version dependency package name table according to the name of the project dependency package, an old version dependency package with the same name as that of the project dependency package can be found in the old version dependency package name table.

[0039] Specifically, if the successfully matched project dependency package is directly configured in the big data program, there will be two dependency packages with the same name in the big data program. In this case, because the project dependency package and the old version dependency package have the same name, when the big data program uses the project dependency package, it will conflict with the old version dependency package. Therefore, the successfully matched project dependency package in the old version dependency package name table will be used as a conflicting dependency package to facilitate subsequent processing.

[0040] S40: Rename the conflicting dependency package to obtain a new version of the dependency package.

[0041] In this embodiment, the new version dependency package refers to a new version dependency package obtained by renaming the conflicting dependency package.

[0042] Specifically, after obtaining the conflicting dependency packages, a configuration file table is generated for each old version dependency package and each project dependency package in the big data program by creating a Maven tool. The Maven tool is a project management tool that includes a project object model and a dependency management system that can be used to view, manage and configure dependency package information.

[0043] In the Maven tool, the configuration information of the conflicting dependency package is obtained, and the configuration information includes the name of the conflicting dependency package. The name of the conflicting dependency package is obtained and modified from the configuration information to obtain a new version of the dependency package.

[0044] S50: configuring the project dependency package and the new version dependency package in the big data program in the big data platform.

[0045] Specifically, after renaming the conflicting dependency package to obtain a new version dependency package, the new version dependency package and the un-renamed project dependency package are configured in the big data program in the big data platform, so that the project dependency package and the new version dependency package can be used in the big data program.

[0046] In this embodiment, before configuring the project dependency package, the conflicting dependency package is searched according to the name of the current project dependency package, and the conflicting dependency package is renamed to obtain a new version dependency package. Then the project dependency package and the new version dependency package are configured in the big data program in the big data platform. After the project dependency package is configured, dependency package conflicts caused by the same name of the project dependency package and the old version dependency package can be avoided, which reduces the troubleshooting time, improves the efficiency of program updates in the big data platform, and further improves the efficiency of various subsequent operations based on the big data platform.

[0047] In one embodiment, if Figure 3As shown, in step S30, a matching query is performed in the old version dependency package name table according to the name of the project dependency package, and the successfully matched project dependency package is used as the conflicting dependency package, which specifically includes the following steps:

[0048] S31: Convert the name of the project dependency package into a matching string.

[0049] Specifically, the matching string refers to the string that needs to be matched. In this embodiment, the name of the project dependency package is used as the matching string. Optionally, when the name of the project dependency package is used as the matching string, the name of the project dependency package may not include the suffix of the dependency package. For example: if the name of the project dependency package is "ABC.jar", "ABC" can be used as the matching string to reduce the time of matching query and improve query efficiency.

[0050] S32: Perform a matching query in the old version dependent package name table according to the matching string.

[0051] In this embodiment, a regular expression can be used to match the matching string in the old version dependency package name table. Among them, a regular expression is also called a regular expression, which is a string matching pattern that can be used to check whether a data table contains a certain string and extract the string that meets the conditions. The condition for meeting the conditions is that the matching string is the same as the name of the old version dependency package in the old version dependency package name table. That is, a regular expression is used to match and query in the old version dependency package name table whether there is an old version dependency package name that is the same as the matching string. For example, the matching string is "ABC", that is, the condition that there is an old version dependency package name "ABC" in the old version dependency package name table, and this condition is used as the matching query condition of the regular expression to match the matching string.

[0052] S33: If there is an old version dependency package name that is identical to the matching string in the old version dependency package name table, it is determined that the project dependency package corresponding to the matching string is successfully matched in the old version dependency package name table.

[0053] Specifically, a successful match means that the name of the old version dependency package that is identical to the matching string is matched and queried in the old version dependency package name table. In step S32, a matching query is performed in the old version dependency package name table according to the matching string. If the name of the old version dependency package that is identical to the matching string is found in the old version dependency package name table, it means that the project dependency package corresponding to the matching string is matched successfully in the old version dependency package name table.

[0054] S34: The successfully matched project dependency package is used as the conflicting dependency package.

[0055] Specifically, the project dependency package corresponding to the successfully matched string in the old version dependency package name table is used as the conflicting dependency package.

[0056] In this embodiment, by using the name of the project dependency package as a matching string, and matching and querying in the old version dependency package name table based on the matching string, the successfully matched project dependency package is used as the conflicting dependency package. This can avoid conflicts in dependency package names caused by configuring the conflicting dependency package in the big data program, thereby improving the stability of the big data program.

[0057] In one embodiment, if Figure 4 As shown, in step S32, a matching query is performed in the old version dependent package name table according to the matching string, which specifically includes the following steps:

[0058] S321: Obtain the number of matching character strings.

[0059] In this embodiment, each project dependency package name corresponds to a matching string, and the number of the matching strings is the number of project dependency package names. After taking the project dependency package name as the matching string, the number of matching strings is obtained.

[0060] S322: If the number of matching strings is greater than 1, the matching strings are stored in a matching array, and the matching strings are numbered according to the number of matching strings.

[0061] In this embodiment, the matching array refers to a sequence of elements composed of matching character strings.

[0062] Specifically, if the number of matching strings is greater than 1, that is, there are multiple matching strings, the matching strings are placed in the matching array. After the matching strings are placed in the matching array, the matching strings are numbered, and each matching string corresponds to a number. For example, there are 4 matching strings in the matching array, namely matching string A, matching string B, matching string C, and matching string D. After the four matching strings are numbered, matching string A is numbered 0, matching string B is numbered 1, matching string C is numbered 2, and matching string D is numbered 3.

[0063] It should be noted that if the number of matching strings is equal to 1, there is no need to put the matching string into the matching array, and the matching string can be directly matched and queried in the old version dependency package name table.

[0064] S323: According to the order of numbers from small to large, each matching string in the matching array is cyclically matched and queried in the old version dependency package name table, and the matching strings that can match the names of the corresponding old version dependency packages in the old version dependency package name table are marked.

[0065] Specifically, according to the order of numbers from small to large, a matching query is performed in the old version dependency package name table for each matching string in the matching array. For example, if the matching strings are numbered starting from 0, a matching query is performed in the old version dependency package name table starting from the matching string corresponding to number 0. If the name of the old version dependency package corresponding to the matching string can be matched and queried in the old version dependency package name table, the matching string is marked, and the matching query for the matching string is ended. Among them, marking the matching string can be achieved by returning the number of the matching string. After obtaining the number, the corresponding matching string is obtained through the number. For example, if the matching string corresponding to number 0 is successfully queried, the number 0 is returned, that is, the marking of the matching string corresponding to number 0 is completed; if the name of the dependency package cannot be matched and queried in the old version dependency package name table, the matching query for the matching string is ended.

[0066] After a matching string matching query is completed, the number corresponding to the matching string is increased to point to the next number, and it is determined whether the increased number reaches the number threshold. If the increased number does not reach the number threshold, the matching string corresponding to the increased number is continued to be matched. If the increased number reaches the number threshold, the cyclic matching query operation is terminated. Among them, the number threshold is the largest number in the matching array.

[0067] S324: When the matching query of the matching string with the largest number is completed, all marked matching strings are output.

[0068] Specifically, after detecting that the matching query of the matching string with the largest number is completed, that is, after all matching string matching queries are completed, all marked matching strings are output by calling an output statement, wherein the output statement refers to a code statement pre-edited for outputting marked matching strings.

[0069] In this embodiment, by putting matching strings into a matching array and numbering them, performing matching queries on multiple matching strings in the order of the numbers according to a circular matching query method, and outputting the matching strings that have been successfully matched, the time for matching queries on multiple matching strings can be saved, thereby improving the efficiency of matching queries.

[0070] In one embodiment, if Figure 5 As shown, step S40, i.e. renaming the conflicting dependency package to obtain a new version dependency package, specifically includes the following steps:

[0071] S41: Obtain a configuration file table of conflicting dependency packages.

[0072] In this embodiment, the configuration file table refers to a data table that records the configuration information of each dependent package. The configuration information of the dependent package can be modified by modifying the data in the configuration file table. Among them, the configuration information includes the name and dependency relationship of the corresponding dependent package. It should be noted that the configuration file table of each dependent package is stored in the directory of the corresponding dependent package as an XML (Extensible Markup Language) file. For example, the configuration file table of a conflicting dependent package is "pom.xml", where pom is the abbreviation of Project Object Model (ProjectObject Model), which is a file in the Maven tool and is represented by an XML file.

[0073] Specifically, after using the Maven tool, a corresponding configuration file table is generated in each dependency package. After the configuration file table is generated, the configuration file table is obtained from the conflicting dependency package.

[0074] S42: Obtain the name of the conflicting dependency package in the configuration file table.

[0075] Specifically, obtain the element containing the name of the conflicting dependency package in the configuration file table, that is, <name> ...< / name> ,in, <name> ...< / name> The name of the conflicting dependency package is included in . Further, the name of the conflicting dependency package is obtained from the element.

[0076] S43: rename the name of the conflicting dependency package in the configuration file table to obtain a new version of the dependency package.

[0077] Specifically, after obtaining the element where the name of the conflicting dependency package is located in the configuration file table, the name of the conflicting dependency package is renamed in the element to make the name of the conflicting dependency package unique. After the name of the conflicting dependency package is renamed, a new version dependency package is obtained.

[0078] In this embodiment, the conflicting dependency package is renamed to obtain a new version dependency package, so that the name of the new version dependency package can be distinguished from the name of the conflicting old version dependency package. After the new version dependency package is configured in the big data program, it will not cause dependency package conflicts, thereby improving the stability of the big data program operation.

[0079] In one embodiment, if Figure 6 As shown, in step S50, the project dependency package and the new version dependency package are configured in the big data program, which specifically includes the following steps:

[0080] S51: The project dependency package and the new version dependency package are taken as dependency packages to be configured.

[0081] In this embodiment, the dependency package to be configured refers to a dependency package that needs to be configured in the big data program.

[0082] Specifically, the project dependency package and the new version dependency package are used as dependency packages to be configured. It should be noted that the project dependency package in this embodiment refers to a dependency package that is not successfully matched in the old version dependency package name table and does not need to be renamed.

[0083] S52: Upload the dependency package to be configured to the big data program in the big data platform.

[0084] Specifically, the Maven tool can be used to upload the dependency package to be configured to the big data program in the big data platform.

[0085] S53: taking the old version of the dependency package corresponding to the conflicting dependency package as the dependency package to be excluded, and obtaining a configuration file table of the dependency package to be excluded.

[0086] In this embodiment, the dependency package to be excluded refers to an old version dependency package that needs to be excluded from the big data program.

[0087] Specifically, a configuration file table of the dependency package to be excluded is obtained from the dependency package to be excluded.

[0088] S54: According to the dependency relationship in the configuration file table of the dependency package to be excluded, the configuration file table of the old version dependency package corresponding to the dependency package to be excluded is obtained as the configuration file table to be processed.

[0089] In this embodiment, the dependency relationship refers to the interdependence relationship between each dependency package, that is, each old version dependency package may depend on one or more other old version dependency packages, or be depended on by one or more other old version dependency packages. The old version dependency package corresponding to the dependency package to be excluded refers to the old version dependency package that has a dependency relationship with the dependency package to be excluded in the big data program, and the configuration file table to be processed is the configuration file table of the old version dependency package corresponding to the dependency package to be excluded.

[0090] Specifically, from the configuration file table in the dependency package to be excluded <dependencies> ...< / dependencies> The element obtains the dependency relationship of the dependency package to be excluded. According to the dependency relationship, the corresponding old version dependency package and the configuration file table of the old version dependency package are obtained in the big data program as the configuration file table to be processed.

[0091] S55: modify the dependency relationship in the table of configuration files to be processed, and exclude the dependency packages to be excluded from the big data program.

[0092] Specifically, in the table of configuration files to be processed <dependencies> ...< / dependencies> Elements in <exclusions> ...< / exclusions>Add the name of the dependency package to be excluded in the sub-element to exclude the old version of the dependency package corresponding to the conflicting dependency package from the big data program.

[0093] Furthermore, in the table of configuration files to be processed <dependencies> ...< / dependencies> Elements in <dependency> ...< / dependency> Add the name of the dependency package to be configured in the sub-element to specify that the big data program uses the dependency package to be configured.

[0094] For example, the existing dependency relationship is that the old version dependency package A depends on the old version dependency package B, and the old version dependency package B depends on the old version dependency package C. For the convenience of expression, it is expressed as A→B→C, where the old version dependency package B is the old version dependency package corresponding to the conflicting dependency package. Therefore, the conflicting project dependency package of the old version dependency package B is renamed to obtain the new version dependency package B'. And by modifying the dependency relationship between the old version dependency package A and the old version dependency package C, specify that the old version dependency package A and the old version dependency package C depend on the new version dependency package B', and exclude the old version dependency package B, that is, the modified dependency relationship is A→B'→C.

[0095] In this embodiment, by modifying the dependency relationship, the old version dependency package corresponding to the conflicting dependency package is excluded from the big data program, thereby improving the stability of the big data program operation.

[0096] In one embodiment, if Figure 7 As shown, after step S50, the dependency package configuration method in the big data platform further includes the following steps:

[0097] S61: Obtain dependency package relationships in a big data program in a big data platform.

[0098] In this embodiment, the dependency package relationship refers to the dependency relationship between each dependency package in the big data program. The dependency package relationship includes a normal relationship and a conflict relationship. The normal relationship means that there is no conflict between the dependency packages, and the conflict relationship means that there is a conflict between the dependency packages.

[0099] Specifically, a tool for viewing dependency package relationships, such as the IntelliJ IDEA tool, can be used to obtain dependency package relationships in a big data program.

[0100] S62: If it is detected that the dependency package relationship is a conflict relationship, a dependency package conflict message is generated and sent.

[0101] In this embodiment, the dependency package conflict message refers to a message triggered when a conflict relationship is detected in the dependency package relationship.

[0102] Specifically, when a conflict is detected in the dependency package relationship, a dependency package conflict message is generated with the name of the dependency package corresponding to the conflict relationship and sent to the client. It should be noted that this step is to further ensure that after the dependency package to be configured is configured in the big data program, it will not conflict with the old version of the dependency package, further ensuring the stability of the program.

[0103] In this embodiment, after the project dependency package and the new version dependency package are configured in the big data program in the big data platform, the dependency package relationship of the big data program is checked and verified. When a dependency package conflict occurs, the corresponding dependency package can be detected in time, thereby reducing the time for troubleshooting and improving the efficiency of the big data program operation.

[0104] It should be understood that the order of execution of the steps in the above embodiment does not necessarily mean the order of execution. The execution order of each process should be determined by its function and internal logic, and should not constitute any limitation on the implementation process of the embodiment of the present invention.

[0105] In one embodiment, a dependency package configuration device in a big data platform is provided, and the dependency package configuration device in the big data platform corresponds one-to-one to the dependency package configuration method in the big data platform in the above embodiment. Figure 8 As shown, the dependency package configuration device in the big data platform includes a dependency configuration request acquisition module 81, a dependency package name acquisition module 82, a query module 83, a renaming module 84 and a configuration module 85. The detailed description of each functional module is as follows:

[0106] A configuration request acquisition module 81 is used to acquire a configuration request of a project dependency package, where the configuration request includes the name of the project dependency package;

[0107] The dependency package name acquisition module 82 is used to acquire the name of the old version dependency package in the big data program in the big data platform according to a preset script, and obtain the old version dependency package name table;

[0108] A query module 83, used to perform a matching query in the old version dependency package name table according to the name of the project dependency package, and use the successfully matched project dependency package as a conflict dependency package;

[0109] A renaming module 84 is used to rename the conflicting dependency package to obtain a new version of the dependency package;

[0110] The configuration module 85 is used to configure the project dependency package and the new version dependency package in the big data program in the big data platform.

[0111] Preferably, the query module 83 includes:

[0112] A matching string submodule 831 is used to convert the name of the project dependency package into a matching string;

[0113] A matching query submodule 832 is used to perform a matching query in the old version dependent package name table according to the matching string;

[0114] The judgment submodule 833 is used to determine that the project dependency package corresponding to the matching string is successfully matched in the old version dependency package name table if the name of the old version dependency package that is the same as the matching string exists in the old version dependency package name table;

[0115] The conflict submodule 834 is used to use the successfully matched project dependency packages as conflict dependency packages.

[0116] Preferably, the matching query submodule 832 includes:

[0117] The quantity acquisition subunit 8321 is used to acquire the quantity of matching character strings;

[0118] The matching array subunit 8322 is used to store the matching strings into the matching array if the number of matching strings is greater than 1, and to number the matching strings according to the number of matching strings;

[0119] The matching query subunit 8323 is used to perform a cyclic matching query on each matching string in the matching array in the old version dependent package name table according to the order of numbers from small to large, and mark the matching string that can match the name of the corresponding old version dependent package in the old version dependent package name table;

[0120] The output subunit 8324 is used to output all marked matching strings when the matching query of the matching string with the largest number is completed.

[0121] Preferably, the renaming module 84 includes:

[0122] A first acquisition submodule 841 is used to acquire a configuration file table of a conflicting dependency package;

[0123] A name acquisition submodule 842 is used to acquire the name of the conflicting dependent package in the configuration file table;

[0124] The renaming submodule 843 is used to rename the name of the conflicting dependency package in the configuration file table to obtain a new version of the dependency package.

[0125] Preferably, the configuration module 85 includes:

[0126] The to-be-configured submodule 851 is used to use the project dependency package and the new version dependency package as the to-be-configured dependency packages;

[0127] The upload submodule 852 is used to upload the dependency package to be configured to the big data program in the big data platform;

[0128] The second acquisition submodule 853 is used to use the old version of the dependency package corresponding to the conflicting dependency package as the dependency package to be excluded, and obtain the configuration file table of the dependency package to be excluded;

[0129] The third acquisition submodule 854 is used to acquire the configuration file table of the old version of the dependency package corresponding to the dependency package to be excluded according to the dependency relationship in the configuration file table of the dependency package to be excluded, as the configuration file table to be processed;

[0130] The dependency modification submodule 855 is used to modify the dependency in the table of configuration files to be processed, and exclude the dependency packages to be excluded from the big data program.

[0131] Preferably, the dependency package configuration device in the big data platform further includes:

[0132] A dependency relationship acquisition module 86 is used to acquire dependency package relationships in a big data program in a big data platform;

[0133] The message sending module 87 is used to generate and send a dependency package conflict message if it is detected that the dependency package relationship is a conflict relationship.

[0134] For the specific definition of the dependency package configuration device in the big data platform, please refer to the definition of the dependency package configuration method in the big data platform above, which will not be repeated here. Each module in the dependency package configuration device in the above-mentioned big data platform can be implemented in whole or in part by software, hardware and a combination thereof. The above-mentioned modules can be embedded in or independent of the processor in the computer device in the form of hardware, or can be stored in the memory of the computer device in the form of software, so that the processor can call and execute the operations corresponding to the above modules.

[0135] In one embodiment, a computer device is provided. The computer device may be a server, and its internal structure diagram may be as follows: Fig. 9 As shown. The computer device includes a processor, a memory, a network interface and a database connected through a system bus. Among them, the processor of the computer device is used to provide computing and control capabilities. The memory of the computer device includes a non-volatile storage medium and an internal memory. The non-volatile storage medium stores an operating system, a computer program and a database. The internal memory provides an environment for the operation of the operating system and the computer program in the non-volatile storage medium. The database of the computer device is used to store configuration file tables of project dependency packages and old version dependency packages. The network interface of the computer device is used to communicate with an external terminal through a network connection. When the computer program is executed by the processor, a dependency package configuration method in a big data platform is implemented.

[0136] In one embodiment, a computer device is provided, including a memory, a processor, and a computer program stored in the memory and executable on the processor, wherein the processor implements the following steps when executing the computer program:

[0137] Obtain a configuration request for a project dependency package, wherein the configuration request includes a name of the project dependency package;

[0138] According to the preset script, the name of the old version dependency package is obtained in the big data program in the big data platform to obtain the old version dependency package name table;

[0139] Perform a match query in the old version dependency package name table according to the name of the project dependency package, and use the successfully matched project dependency package as the conflicting dependency package;

[0140] Rename the conflicting dependency package to obtain a new version dependency package;

[0141] The project dependency package and the new version dependency package are configured in the big data program in the big data platform.

[0142] In one embodiment, a computer readable storage medium is provided, on which a computer program is stored, and when the computer program is executed by a processor, the following steps are implemented:

[0143] Obtain a configuration request for a project dependency package, wherein the configuration request includes a name of the project dependency package;

[0144] According to the preset script, the name of the old version dependency package is obtained in the big data program in the big data platform to obtain the old version dependency package name table;

[0145] Perform a match query in the old version dependency package name table according to the name of the project dependency package, and use the successfully matched project dependency package as the conflicting dependency package;

[0146] Rename the conflicting dependency package to obtain a new version dependency package;

[0147] The project dependency package and the new version dependency package are configured in the big data program in the big data platform.

[0148] Those skilled in the art can understand that all or part of the processes in the above-mentioned embodiment methods can be completed by instructing the relevant hardware through a computer program, and the computer program can be stored in a non-volatile computer-readable storage medium. When the computer program is executed, it can include the processes of the embodiments of the above-mentioned methods. Among them, any reference to memory, storage, database or other media used in the embodiments provided in this application can include non-volatile and / or volatile memory. Non-volatile memory can include read-only memory (ROM), programmable ROM (PROM), electrically programmable ROM (EPROM), electrically erasable programmable ROM (EEPROM) or flash memory. Volatile memory can include random access memory (RAM) or external cache memory. As an illustration and not limitation, RAM is available in many forms, such as static RAM (SRAM), dynamic RAM (DRAM), synchronous DRAM (SDRAM), double data rate SDRAM (DDRSDRAM), enhanced SDRAM (ESDRAM), synchronous link (Synchlink) DRAM (SLDRAM), memory bus (Rambus) direct RAM (RDRAM), direct memory bus dynamic RAM (DRDRAM), and memory bus dynamic RAM (RDRAM).

[0149] Those skilled in the art can clearly understand that for the convenience and simplicity of description, only the division of the above-mentioned functional units and modules is used as an example. In actual applications, the above-mentioned functions can be distributed and completed by different functional units and modules as needed, that is, the internal structure of the device can be divided into different functional units or modules to complete all or part of the functions described above.

[0150] The embodiments described above are only used to illustrate the technical solutions of the present invention, rather than to limit the same. Although the present invention has been described in detail with reference to the aforementioned embodiments, those skilled in the art should understand that the technical solutions described in the aforementioned embodiments may still be modified, or some of the technical features may be replaced by equivalents. Such modifications or replacements do not deviate the essence of the corresponding technical solutions from the spirit and scope of the technical solutions of the embodiments of the present invention, and should all be included in the protection scope of the present invention.

Claims

1. A method for configuring dependency packages in a big data platform, characterized in that: The dependency package configuration method in the big data platform includes: Obtain a configuration request for a project dependency package, wherein the configuration request includes a name of the project dependency package; According to the preset script, the name of the old version dependency package is obtained in the big data program in the big data platform to obtain the old version dependency package name table; Perform a match query in the old version dependency package name table according to the name of the project dependency package, and use the successfully matched project dependency package as a conflict dependency package; The matching query is performed in the old version dependency package name table according to the name of the project dependency package, and the successfully matched project dependency package is used as the conflicting dependency package, including: Convert the name of the project dependency package into a matching string; Perform a matching query in the old version dependent package name table according to the matching string; If the name of the old version dependency package that is the same as the matching string exists in the old version dependency package name table, determining that the project dependency package corresponding to the matching string is successfully matched in the old version dependency package name table; The successfully matched project dependency packages are used as conflicting dependency packages; The performing a matching query in the old version dependent package name table according to the matching string includes: Get the number of matching strings; If the number of the matching strings is greater than 1, the matching strings are stored in a matching array, and the matching strings are numbered according to the number of the matching strings; According to the ascending order of the numbers, each matching string in the matching array is cyclically matched and queried in the old version dependent package name table, and the matching string that can match the name of the corresponding old version dependent package in the old version dependent package name table is marked; When the matching query of the matching string with the largest number is completed, all the marked matching strings are output; Rename the conflicting dependency package to obtain a new version dependency package; The step of renaming the conflicting dependency package to obtain a new version dependency package includes: Obtaining a configuration file table of the conflicting dependency package; Obtain the name of the conflicting dependency package in the configuration file table; Rename the name of the conflicting dependency package in the configuration file table to obtain the new version dependency package; The project dependency package and the new version dependency package are configured in the big data program in the big data platform.

2. The method for configuring dependency packages in a big data platform according to claim 1, characterized in that: The configuring the project dependency package and the new version dependency package in the big data program in the big data platform includes: The project dependency package and the new version dependency package are used as dependency packages to be configured; Uploading the dependency package to be configured to the big data program in the big data platform; The old version dependency package corresponding to the conflicting dependency package is used as a dependency package to be excluded, and a configuration file table of the dependency package to be excluded is obtained; According to the dependency relationship in the configuration file table of the dependency package to be excluded, obtaining the configuration file table of the old version dependency package corresponding to the dependency package to be excluded as the configuration file table to be processed; The dependency relationship in the table of configuration files to be processed is modified to exclude the dependency packages to be excluded from the big data program.

3. The method for configuring dependent packages in a big data platform according to claim 1, characterized in that: After the step of configuring the project dependency package and the new version dependency package in the big data program, the dependency package configuration method in the big data platform further includes: Obtaining dependency package relationships in a big data program in the big data platform; If it is detected that the dependency package relationship is a conflict relationship, a dependency package conflict message is generated and sent.

4. A dependency package configuration device in a big data platform, characterized in that: The dependency package configuration device in the big data platform includes: A configuration request acquisition module, used to acquire a configuration request of a project dependency package, wherein the configuration request includes a name of the project dependency package; A dependency package name acquisition module is used to obtain the name of the old version dependency package in the big data program in the big data platform according to a preset script, and obtain an old version dependency package name table; A query module, used to perform a matching query in the old version dependency package name table according to the name of the project dependency package, and use the successfully matched project dependency package as a conflicting dependency package; The query module includes: A matching string submodule, used to convert the name of the project dependency package into a matching string; A matching query submodule, used to perform a matching query in the old version dependent package name table according to the matching string; A judgment submodule, used for determining that the project dependency package corresponding to the matching string is successfully matched in the old version dependency package name table if the name of the old version dependency package that is the same as the matching string exists in the old version dependency package name table; The conflict submodule is used to treat the successfully matched project dependency packages as conflicting dependency packages; The matching query submodule includes: The quantity acquisition subunit is used to obtain the number of matching strings; The matching array subunit is used to store the matching strings into the matching array if the number of matching strings is greater than 1, and to number the matching strings according to the number of matching strings; The matching query subunit is used to perform a cyclic matching query on each matching string in the matching array in the old version dependent package name table according to the order of numbers from small to large, and mark the matching string that can match the name of the corresponding old version dependent package in the old version dependent package name table; The output subunit is used to output all marked matching strings when the matching query of the matching string with the largest number is completed; A renaming module, used to rename the conflicting dependency package to obtain a new version of the dependency package; The first acquisition submodule is used to obtain the configuration file table of the conflicting dependency package; The name acquisition submodule is used to obtain the name of the conflicting dependency package in the configuration file table; Rename submodule, which is used to rename the name of the conflicting dependency package in the configuration file table to obtain the new version of the dependency package; A configuration module is used to configure the project dependency package and the new version dependency package in the big data program in the big data platform.

5. A computer device comprising a memory, a processor, and a computer program stored in the memory and executable on the processor, characterized in that: When the processor executes the computer program, the steps of the dependency package configuration method in the big data platform as described in any one of claims 1 to 3 are implemented.

6. A computer-readable storage medium storing a computer program, characterized in that: When the computer program is executed by a processor, the steps of the dependency package configuration method in the big data platform as described in any one of claims 1 to 3 are implemented.

Citation Information

Patent Citations

  • Software dependency shading

    US20160328230A1

  • Query-based software dependency analysis

    US9323644B1