CN110569063A - sub-application APP generation method and generation device - Google Patents

sub-application APP generation method and generation device Download PDF

Info

Publication number
CN110569063A
CN110569063A CN201910814518.1A CN201910814518A CN110569063A CN 110569063 A CN110569063 A CN 110569063A CN 201910814518 A CN201910814518 A CN 201910814518A CN 110569063 A CN110569063 A CN 110569063A
Authority
CN
China
Prior art keywords
code set
target
middleware
app
library
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.)
Granted
Application number
CN201910814518.1A
Other languages
Chinese (zh)
Other versions
CN110569063B (en
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.)
58tongcheng Information Technology Co ltd
Original Assignee
Wuba 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 Wuba Co Ltd filed Critical Wuba Co Ltd
Priority to CN201910814518.1A priority Critical patent/CN110569063B/en
Publication of CN110569063A publication Critical patent/CN110569063A/en
Application granted granted Critical
Publication of CN110569063B publication Critical patent/CN110569063B/en
Active legal-status Critical Current
Anticipated expiration legal-status Critical

Links

Classifications

    • GPHYSICS
    • G06COMPUTING; CALCULATING OR COUNTING
    • G06FELECTRIC DIGITAL DATA PROCESSING
    • G06F8/00Arrangements for software engineering
    • G06F8/70Software maintenance or management
    • G06F8/71Version control; Configuration management
    • GPHYSICS
    • G06COMPUTING; CALCULATING OR COUNTING
    • G06FELECTRIC DIGITAL DATA PROCESSING
    • G06F8/00Arrangements for software engineering
    • G06F8/70Software maintenance or management
    • G06F8/72Code refactoring
    • YGENERAL TAGGING OF NEW TECHNOLOGICAL DEVELOPMENTS; GENERAL TAGGING OF CROSS-SECTIONAL TECHNOLOGIES SPANNING OVER SEVERAL SECTIONS OF THE IPC; TECHNICAL SUBJECTS COVERED BY FORMER USPC CROSS-REFERENCE ART COLLECTIONS [XRACs] AND DIGESTS
    • Y02TECHNOLOGIES OR APPLICATIONS FOR MITIGATION OR ADAPTATION AGAINST CLIMATE CHANGE
    • Y02DCLIMATE CHANGE MITIGATION TECHNOLOGIES IN INFORMATION AND COMMUNICATION TECHNOLOGIES [ICT], I.E. INFORMATION AND COMMUNICATION TECHNOLOGIES AIMING AT THE REDUCTION OF THEIR OWN ENERGY USE
    • Y02D10/00Energy efficient computing, e.g. low power processors, power management or thermal management

Landscapes

  • Engineering & Computer Science (AREA)
  • Software Systems (AREA)
  • General Engineering & Computer Science (AREA)
  • Theoretical Computer Science (AREA)
  • Physics & Mathematics (AREA)
  • General Physics & Mathematics (AREA)
  • Computer Security & Cryptography (AREA)
  • Stored Programmes (AREA)

Abstract

The application provides a generation method and a generation device of a sub-application program APP, wherein the method comprises the following steps: reading a first Podfile arranged in an entry project, and acquiring a target service code set which a target sub APP to be generated depends on; determining a target middleware code set and a target base library code set which are depended by the target sub APP to be generated according to the read target service code set which is depended by the target sub APP to be generated; and generating the target sub APP by using the target service code set, the target middleware code set and the target basic library code set which are depended by the target sub APP to be generated. In this way, the generated sub-APP can be prevented from carrying many irrelevant or repeated codes by using the code set instead of the service codes of each service as the granularity packing code.

Description

sub-application APP generation method and generation device
Technical Field
The present application relates to the field of communications technologies, and in particular, to a method and an apparatus for generating a sub-application APP.
Background
When a technician develops an APPlication (APP), there may be cases where multiple APPs are developed in parallel. These APPs may be independent of each other or may have various associations. For example, among multiple APPs developed in parallel, there may be corresponding sub-APPs in addition to the main APP. The main APP is a set of all services and service codes in the group; the sub-APP is a set composed of one or more services and service codes, such as a reduced APP (or a very fast APP), a vertical service APP, and an innovation APP. Since the main APP and the sub APP have an association relationship on the service and the service code, the sub APP can be generated by using the existing main APP service code. Therefore, APP research and development cost can be saved, and research and development efficiency is improved.
However, in practical applications, since the coupling of the service codes of each service is usually severe, even the service codes between different services may be coupled, when generating the sub-APP based on the main APP, if the sub-APP relates to multiple services, the service codes of each service and the codes coupled to the service codes need to be packed into the sub-APP, which may cause the generated sub-APP to carry many unrelated or repeated codes.
Disclosure of Invention
the application provides a generation method and a generation device of a sub-application program APP, so as to solve the problem that in the related technology, if a sub-APP relates to a plurality of services, service codes of each service and codes coupled with the service codes are required to be packaged into the sub-APP, so that the generated sub-APP can carry a lot of irrelevant or repeated codes.
In a first aspect, the present invention provides a method for generating a sub-application APP, including:
reading a first Podfile arranged in an entrance project, and obtaining a target service code set depended by a target sub APP to be generated, wherein the target service code set depended by the target sub APP to be generated is configured in the first Podfile, and the target service code set is at least one service code set contained in a service layer of a project library pool;
determining a target middleware code set and a target basic library code set which are depended by the target sub APP to be generated according to the read target service code set which is depended by the target sub APP to be generated, wherein the target middleware code set is at least one middleware code set contained in a middleware layer of the engineering library pool, and the target basic library code set is at least one basic library code set contained in a basic library layer of the engineering library pool;
And generating the target sub APP by utilizing the target business code set, the target middleware code set and the target basic library code set which are depended by the target sub APP to be generated.
optionally, the determining, according to the read target service code set on which the target sub APP to be generated depends, a target middleware code set and a target base library code set on which the target sub APP to be generated depends includes:
reading a second Podfile of the target service code set to obtain a first reading result;
Determining a first middleware code set, a second middleware code set and a first basic library code set which are depended by the target business code set according to the first reading result, wherein the first middleware code set and the second middleware code set are both middleware code sets in at least one middleware code set contained in the middleware layer, and the first basic library code set is a basic library code set in at least one basic library code set contained in the basic library layer;
reading a third Podfile of the first middleware code set to obtain a second reading result;
Determining a second basic library code set depended by the first middleware code set according to the second reading result, wherein the second basic library code set is a basic library code set in at least one basic library code set contained in the basic library layer;
determining the first set of middleware codes and the second set of middleware codes as the target set of middleware codes, and determining the first set of base library codes and the second set of base library codes as the target set of base library codes.
Optionally, the level of the business layer is higher than that of the middleware layer, and the level of the middleware layer is higher than that of the base library layer;
any two service code sets in at least one service code set contained in the service layer cannot be depended on each other;
Any two middleware code sets in at least one middleware code set contained in the middleware layer meet the one-way dependency criterion;
The one-way dependency criterion is satisfied between any two of at least one base library code set contained in the base library layer.
Optionally, the target sub APP to be generated is a target vertical service APP to be generated, where the main APP and the cross APP share a middleware code set and a basic library code set that the target vertical service APP to be generated depends on.
Optionally, the target vertical service APP to be generated and the middleware code set and the base library code set on which the target vertical service APP to be generated depends are not coupled to the unique code in the main APP or the unique code in the cross APP.
In a second aspect, the present invention further provides a device for generating a sub-application APP, including:
The system comprises a reading module, a processing module and a processing module, wherein the reading module is used for reading a first Podfile arranged in an entrance project and obtaining a target service code set depended by a target sub APP to be generated, the target service code set depended by the target sub APP to be generated is configured in the first Podfile, and the target service code set is at least one service code set contained in a service layer of a project library pool;
a determining module, configured to determine, according to the read target service code set that the target sub APP to be generated depends on, a target middleware code set and a target base library code set that the target sub APP to be generated depends on, where the target middleware code set is at least one middleware code set included in a middleware layer of the engineering library pool, and the target base library code set is at least one base library code set included in a base library layer of the engineering library pool;
And the generating module is used for generating the target sub APP by utilizing the target business code set, the target middleware code set and the target basic library code set which are depended by the target sub APP to be generated.
Optionally, the determining module includes:
The first reading submodule is used for reading the second Podfile of the target service code set to obtain a first reading result;
a first determining submodule, configured to determine, according to the first reading result, a first middleware code set, a second middleware code set, and a first basic library code set, where the target service code set depends on, where the first middleware code set and the second middleware code set are both middleware code sets in at least one middleware code set included in the middleware layer, and the first basic library code set is a basic library code set in at least one basic library code set included in the basic library layer;
the second reading submodule is used for reading the third Podfile of the first middleware code set to obtain a second reading result;
a second determining submodule, configured to determine, according to the second reading result, a second basic library code set on which the first middleware code set depends, where the second basic library code set is a basic library code set in at least one basic library code set included in the basic library layer;
a third determining submodule, configured to determine that the first middleware code set and the second middleware code set are the target middleware code set, and determine that the first base library code set and the second base library code set are the target base library code set.
Optionally, the level of the business layer is higher than that of the middleware layer, and the level of the middleware layer is higher than that of the base library layer;
Any two service code sets in at least one service code set contained in the service layer cannot be depended on each other;
Any two middleware code sets in at least one middleware code set contained in the middleware layer meet the one-way dependency criterion;
the one-way dependency criterion is satisfied between any two of at least one base library code set contained in the base library layer.
Optionally, the target sub APP to be generated is a target vertical service APP to be generated, where the main APP and the cross APP share a middleware code set and a basic library code set that the target vertical service APP to be generated depends on.
Optionally, the target vertical service APP to be generated and the middleware code set and the base library code set on which the target vertical service APP to be generated depends are not coupled to the unique code in the main APP or the unique code in the cross APP.
In a third aspect, the present invention further provides an electronic device, including:
a memory for storing program instructions;
And the processor is used for calling and executing the program instructions in the memory so as to realize the generation method of the sub application program APP.
in a fourth aspect, the present invention also provides a readable storage medium, comprising: the readable storage medium has stored therein a computer program which, when executed by at least one processor of the sub-application APP generating apparatus, executes the sub-application APP generating method described in the first aspect.
as can be seen from the foregoing technical solutions, in the sub-application APP generation method and the sub-application APP generation device provided in the embodiments of the present invention, a first Podfile set in an entry project is read, and an object service code set on which an object sub APP to be generated depends is obtained, where the object service code set on which the object sub APP to be generated depends is configured in the first Podfile, and the object service code set is at least one service code set included in a service layer of a project library pool; determining a target middleware code set and a target basic library code set which are depended by the target sub APP to be generated according to the read target service code set which is depended by the target sub APP to be generated, wherein the target middleware code set is at least one middleware code set contained in a middleware layer of the engineering library pool, and the target basic library code set is at least one basic library code set contained in a basic library layer of the engineering library pool; and generating the target sub APP by utilizing the target business code set, the target middleware code set and the target basic library code set which are depended by the target sub APP to be generated. In this way, a target service code set, a target middleware code set and a target base library code set, on which the target sub-APP to be generated depends, can be determined, and then the target sub-APP can be generated by using the determined target service code set, target middleware code set and target base library code set. And the generated sub APP can be prevented from carrying a plurality of unrelated or repeated codes by taking the code set instead of the service codes of each service as the granularity packaging code.
drawings
In order to more clearly explain the technical solution of the present application, the drawings needed to be used in the embodiments will be briefly described below, and it is obvious to those skilled in the art that other drawings can be obtained according to the drawings without creative efforts.
FIG. 1 is a flowchart of a method for generating a sub-application APP provided by the present invention;
FIG. 2 is an App factory architecture diagram provided by the present invention;
FIG. 3 is a flowchart of another method for generating a seed application APP provided by the present invention;
FIG. 4 is a schematic diagram of generating a target sub-APP provided by the present invention;
fig. 5 is a schematic diagram of generating a target vertical service APP according to the present invention;
fig. 6 is a structural diagram of a sub-application APP generation apparatus provided in the present invention;
FIG. 7 is a block diagram of another apparatus for generating a seed application APP provided in the present invention;
fig. 8 is a schematic diagram of a hardware structure of an electronic device according to the present invention.
Detailed Description
reference will now be made in detail to embodiments, examples of which are illustrated in the accompanying drawings. When the following description refers to the accompanying drawings, like numbers in different drawings represent the same or similar elements unless otherwise indicated. The embodiments described in the following examples do not represent all embodiments consistent with the present application. But merely as exemplifications of systems and methods consistent with certain aspects of the application, as recited in the claims.
Referring to fig. 1, fig. 1 is a flowchart of a method for generating a sub-application APP provided by the present invention. As shown in fig. 1, the method comprises the following steps:
step 101, reading a first Podfile arranged in an entry project, and obtaining a target service code set on which a target sub APP to be generated depends, wherein the target service code set on which the target sub APP to be generated depends is configured in the first Podfile, and the target service code set is at least one service code set included in a service layer of a project library pool.
In step 101, as shown in fig. 2, an App factory architecture diagram according to an embodiment of the present invention is provided. In fig. 2, the App factory can be divided into two levels: entry projects and project reservoir. And the portal project pod depends on the pod of the project library pool, and the pod code required by the APP where each portal project is located is configured through the podfile.
The portal project is mainly responsible for configuring the APP required code generated by the APP factory. The portal engineering comprises the functions of:
APPINfo: setting APP basic information. Such as APP name, package identifier (bundle identifier), version number, and certificate, among others.
Podfile: current APP's dependence on required engineering code.
sh an executable file (for local RD development debugging). Reading the podfile configuration, copying the code and configuration required by the APP, and then generating the code required by the APP.
Sh an executable file (for Jenkins service packaging). Reading the podfile configuration, copying the code and configuration required by the APP, and then generating the code required by the APP.
the engineering library pool is a total code set of the APP factory, codes required by each generated APP are obtained from the code set, and the code update in the research and development process can be synchronously updated to the code set. The engineering library pool can be divided into a business layer, a middleware layer and a basic library layer.
The service layer may include at least one service pod, that is, may include at least one service code set, and each service code set is divided according to a service type. For example, in fig. 2, the business layer may contain home page pod, tribal pod, issue pod, personal center pod, property pod, recruitment pod, used car pod, and so on.
Middleware layer, APP factory middleware service code. The general interpretation of middleware in the software domain is: a program connecting the software components and the application. The middleware here embodies connection and sharing: connected are a business layer and a basic library layer, and a common service embodied in the business layer is shared.
The middleware is divided into service middleware and standard middleware according to whether the service is strongly related or not. Service middleware: the middleware strongly related to the service is universal in a certain independent APP. Due to excessive dependence on other functions of the current APP, it is not applicable to other independent APPs. For example, in fig. 2, the service middleware may include RN extension middleware, general list middleware, and lifecycle middleware, etc.
standard middleware: middleware that is weakly related to traffic. The method is not only general in a certain independent APP, but also general in other independent APPs and weakly related to business in the APPs. For example, in fig. 2, the standard middleware may include RN base repository middleware, hop component middleware, network component middleware, and the like. In addition, as shown in fig. 2, it can be seen that two vertical lines are added to some standard middleware of the middleware layer, which means that the implementation of some functions of the standard middleware depends on the access APP, and only the interface protocol is opened. Take the RN base library as an example of standard middleware: the middleware contains all common, weakly traffic-related content for bearer pages and hot updates, but for some extended components (e.g., buried points) an open protocol is required for the access to implement, and this logic is not implemented in the middleware.
the base library layer, independent libraries that do not generate dependencies on other pod. Such as some open-source three-party libraries, are common base libraries. For example, in fig. 2, the base library layer may contain a picture library pod, a language identification pod, a map pod, and the like.
The first Podfile set in the entry project may be read to obtain the target service code set on which the target sub APP to be generated depends. And the target service code set is at least one service code set contained in a service layer of the engineering library pool. That is, the first Podfile set in the entry project may be read, and the target service pod on which the target sub APP to be generated depends is obtained, where the target service pod is at least one service pod included in the service layer of the project library pool.
Step 102, according to the read target service code set which the target sub APP to be generated depends on, determining a target middleware code set and a target basic library code set which the target sub APP to be generated depends on, wherein the target middleware code set is at least one middleware code set contained in a middleware layer of the engineering library pool, and the target basic library code set is at least one basic library code set contained in a basic library layer of the engineering library pool.
In step 102, a target middleware code set and a target base library code set, which are depended on by the target sub APP to be generated, may be determined according to the read target service code set, which is depended on by the target sub APP to be generated. The target middleware code set is at least one middleware code set contained in a middleware layer of the engineering library pool; the target base library code set is at least one base library code set contained in a base library layer of the engineering library pool. Namely, the target middleware pod and the target base library pod which are depended on by the target sub APP to be generated can be determined according to the read target service pod which is depended on by the target sub APP to be generated. The target middleware pod is at least one middleware pod contained in a middleware layer of the engineering pool; the target basic library pod is at least one basic library pod contained in the basic library layer of the engineering library pool.
Step 103, generating the target sub APP by using the target service code set, the target middleware code set and the target base library code set on which the target sub APP to be generated depends.
In step 103, a target sub APP may be generated by using a target service code set, a target middleware code set, and a target base library code set on which the target sub APP to be generated depends. Namely, the target sub APP can be generated by using the target service pod, the target middleware pod and the target base library pod which are depended by the target sub APP to be generated.
It should be noted that, in the related art, since the coupling of the service codes of each service is generally severe, even the service codes between different services may also be coupled, when a sub APP is generated based on a main APP, if the sub APP relates to multiple services, the service codes of each service and the codes coupled to the service codes need to be packed into the sub APP, which may cause the generated sub APP to carry many unrelated or repeated codes.
In the invention, the target service code set, the target middleware code set and the target basic library code set which are depended by the target sub APP to be generated can be determined, and then the target sub APP can be generated by utilizing the determined target service code set, target middleware code set and target basic library code set. And the generated sub APP can be prevented from carrying a plurality of unrelated or repeated codes by taking the code set instead of the service codes of each service as the granularity packaging code.
As can be seen from the foregoing technical solutions, in the method for generating a sub-application APP provided in the embodiment of the present invention, a first Podfile set in an entry project is read, and an object service code set on which an object sub-APP to be generated depends is obtained, where the object service code set on which the object sub-APP to be generated depends is configured in the first Podfile, and the object service code set is at least one service code set included in a service layer of a project library pool; determining a target middleware code set and a target basic library code set which are depended by the target sub APP to be generated according to the read target service code set which is depended by the target sub APP to be generated, wherein the target middleware code set is at least one middleware code set contained in a middleware layer of the engineering library pool, and the target basic library code set is at least one basic library code set contained in a basic library layer of the engineering library pool; and generating the target sub APP by utilizing the target business code set, the target middleware code set and the target basic library code set which are depended by the target sub APP to be generated. In this way, a target service code set, a target middleware code set and a target base library code set, on which the target sub-APP to be generated depends, can be determined, and then the target sub-APP can be generated by using the determined target service code set, target middleware code set and target base library code set. And the generated sub APP can be prevented from carrying a plurality of unrelated or repeated codes by taking the code set instead of the service codes of each service as the granularity packaging code.
Referring to fig. 3, fig. 3 is a flowchart of another method for generating a seed application APP according to the present invention. As shown in fig. 3, the method comprises the following steps:
step 301, reading a first Podfile arranged in an entry project, and obtaining a target service code set on which a target sub APP to be generated depends, where the target service code set on which the target sub APP to be generated depends is configured in the first Podfile, and the target service code set is at least one service code set included in a service layer of a project library pool.
In step 301, taking fig. 2 as an example, as shown in fig. 2, an App factory architecture diagram according to an embodiment of the present invention is provided. In fig. 2, the App factory can be divided into two levels: entry projects and project reservoir. And the portal project pod depends on the pod of the project library pool, and the pod code required by the APP where each portal project is located is configured through the podfile.
The engineering library pool can be divided into a business layer, a middleware layer and a basic library layer.
Optionally, the level of the business layer is higher than that of the middleware layer, and the level of the middleware layer is higher than that of the base library layer;
any two service code sets in at least one service code set contained in the service layer cannot be depended on each other;
Any two middleware code sets in at least one middleware code set contained in the middleware layer meet the one-way dependency criterion;
The one-way dependency criterion is satisfied between any two of at least one base library code set contained in the base library layer.
The level of the business layer is higher than that of the middleware layer, and the level of the middleware layer is higher than that of the basic library layer. As described above, the middleware is classified into service middleware and standard middleware according to whether it is strongly related to a service. Wherein the level of the business middleware is higher than the level of the standard middleware. It should be noted that a layer at a higher level may depend on a layer at a lower level, but a layer at a lower level cannot depend on a layer at a higher level. For example, the home page pod in the business layer may depend on the lifecycle pod in the middleware layer, but not vice versa, i.e., the lifecycle pod in the middleware layer cannot depend on the home page pod in the business layer.
any two service code sets in at least one service code set contained in the service layer cannot be depended on each other. For example, there is no dependency between a real estate pod and a recruitment pod contained in the business layer.
one-way dependency criteria are satisfied between any two middleware code sets of the at least one middleware code set included in the middleware layer. For example, the one-way dependency criterion is satisfied between the generic list service middleware and the lifecycle service middleware contained in the middleware layer. That is, if the generic list service middleware depends on the lifecycle service middleware, the lifecycle service middleware cannot depend on the generic list service middleware; alternatively, if the lifecycle services middleware relies on the generic list services middleware, the generic list services middleware cannot rely on the lifecycle services middleware.
one-way dependency criteria are satisfied between any two of the at least one set of base library code contained in the base library layer. For example, a one-way dependency criterion is satisfied between the photo library pod and the language identification pod contained in the base library layer. That is, at this time, if the picture library pod depends on the language identification pod, the language identification pod cannot depend on the picture library pod; alternatively, if the language identification pod depends on the photo gallery pod, the photo gallery pod cannot depend on the language identification pod.
it should be noted that interlayer dependency may also be implemented. For example, the business layer may rely on the base library layer.
the first Podfile set in the entry project may be read to obtain the target service code set on which the target sub APP to be generated depends. And the target service code set is at least one service code set contained in a service layer of the engineering library pool. As shown in fig. 4, to generate the target sub APP. The target sub-APP can be a rented house waistcoat bag APP. At this time, the first Podfile set in the entry project may be read, and the target service code set on which the renting house waistcoat packet APP to be generated depends is obtained. The target service code set on which the waistcoat packet APP to be generated depends is assumed to be a house code set in the service layer, namely a house pod.
Step 302, reading the second Podfile of the target service code set, and obtaining a first reading result.
in step 302, the second Podfile of the target service code set may be read to obtain a first read result. That is, the second Podfile of the property pod can be read to obtain the first reading result. Wherein, the second Podfile of the property pod is configured with the middleware pod and the foundation pod depending on the property pod.
Step 303, determining, according to the first reading result, a first middleware code set, a second middleware code set, and a first basic library code set, which are depended by the target service code set, where the first middleware code set and the second middleware code set are both middleware code sets in at least one middleware code set included in the middleware layer, and the first basic library code set is a basic library code set in at least one basic library code set included in the basic library layer.
In step 303, a first middleware code set, a second middleware code set and a first base library code set on which the target business code set depends may be determined according to the first reading result. The first middleware code set and the second middleware code set are both middleware code sets in at least one middleware code set contained in the middleware layer; the first set of base library codes is a set of base library codes of at least one set of base library codes included in the base library layer. That is, the first middleware pod, the second middleware pod and the first base library pod, on which the property pod depends, can be determined based on the first reading result. It should be noted that the first middleware pod has a base library pod depending on it, and the second middleware pod does not depend on any base library pod. As shown in fig. 4, the first middleware pod is a service middleware pod a and a service middleware pod B; the second middleware pod is a standard middleware pod C, a standard middleware pod D, and a standard middleware pod E. The first basal pool pod is basal pool pod F, basal pool pod G and basal pool pod H which are interlayer dependent on the house pod.
And step 304, reading the third Podfile of the first middleware code set to obtain a second reading result.
In step 304, the third Podfile of the first middleware code set may be read, and the second read result is obtained. That is, the third Podfile of the service middleware pod a and the third Podfile of the service middleware pod B can be read, and the second reading result is obtained. The third Podfile of the service middleware pod A is configured with a basic library pod which the service middleware pod A depends on; the third Podfile of the business middleware pod B is configured with the base pool pod on which the business middleware pod B depends.
step 305, determining a second basic library code set depended by the first middleware code set according to the second reading result, wherein the second basic library code set is a basic library code set in at least one basic library code set included in the basic library layer.
In step 305, a second base set of library codes on which the first set of middleware codes depends may be determined based on the second read. The second base library code set is a base library code set in at least one base library code set contained in the base library layer. That is, the second base pool pod depended on by the service middleware pod a and the second base pool pod depended on by the service middleware pod B can be determined according to the second reading result. Assuming that a second basic pool pod depended by the service middleware pod A is a basic pool pod F, a basic pool pod G and a basic pool pod H; the second base pool pod on which the business middleware pod B depends is the base pool pod G.
step 306, determining the first middleware code set and the second middleware code set as the target middleware code set, and determining the first base library code set and the second base library code set as the target base library code set, where the target middleware code set is at least one middleware code set included in a middleware layer of the engineering library pool, and the target base library code set is at least one base library code set included in a base library layer of the engineering library pool.
in step 306, the first set of middleware codes and the second set of middleware codes may be determined to be a target set of middleware codes, and the first set of base library codes and the second set of base library codes may be determined to be a target set of base library codes. The target middleware code set is at least one middleware code set contained in a middleware layer of the engineering library pool; the target base library code set is at least one base library code set contained in a base library layer of the engineering library pool. Namely, the service middleware pod A, the service middleware pod B, the standard middleware pod C, the standard middleware pod D and the standard middleware pod E can be determined as a target middleware code set; base library pod F, base library pod G, and base library pod H may be determined to be the target base library code set.
And 307, generating the target sub APP by using the target service code set, the target middleware code set and the target base library code set on which the target sub APP to be generated depends.
in step 307, the target sub APP may be generated by using the target service code set, the target middleware code set, and the target base library code set on which the target sub APP to be generated depends. Namely, the house armored bag APP can be generated by using the house pod, the service middleware pod A, the service middleware pod B, the standard middleware pod C, the standard middleware pod D, the standard middleware pod E, the foundation library pod F, the foundation library pod G and the foundation library pod H which are depended by the house armored bag APP to be generated.
optionally, the target sub APP to be generated is a target vertical service APP to be generated, where the main APP and the cross APP share a middleware code set and a basic library code set that the target vertical service APP to be generated depends on.
it should be noted that the target sub APP to be generated may be a target vertical service APP to be generated. The main APP and the cross APP share a middleware code set and a basic library code set which are depended by the target vertical service APP to be generated.
Optionally, the target vertical service APP to be generated and the middleware code set and the base library code set on which the target vertical service APP to be generated depends are not coupled to the unique code in the main APP or the unique code in the cross APP.
further, the target vertical service APP to be generated and the middleware code set and the base library code set on which the target vertical service APP to be generated depends are not coupled with the unique code in the main APP or the unique code in the cross APP. As shown in fig. 5, to generate the target vertical service APP. Therefore, the generated target vertical service APP can not carry some irrelevant unnecessary codes, and the packet size is favorably controlled.
According to the technical scheme, the method for generating the APP of the sub-application program is provided by the embodiment of the invention. The App factory can be divided into an upper layer and a lower layer: entry projects and project reservoir. The engineering library pool can be divided into a business layer, a middleware layer and a basic library layer, and each layer contained in the engineering library pool has a corresponding dependency criterion. The target business code set, the target middleware code set and the target basic library code set which are depended by the target sub APP to be generated can be determined, and then the target sub APP can be generated by utilizing the determined target business code set, the determined target middleware code set and the determined target basic library code set. The code set is used as the granularity packing code instead of the service code of each service, so that the generation of the sub-APP according to the requirement can be realized, the generated sub-APP is prevented from carrying a plurality of irrelevant or repeated codes, and the packet size is effectively controlled.
referring to fig. 6, fig. 6 is a structural diagram of a sub-application APP generating apparatus provided in the present invention. As shown in fig. 6, the sub-application APP generating apparatus 600 includes a reading module 601, a determining module 602, and a generating module 603, where:
A reading module 601, configured to read a first Podfile set in an entry project, and obtain a target service code set on which a target sub APP to be generated depends, where the target service code set on which the target sub APP to be generated depends is configured in the first Podfile, and the target service code set is at least one service code set included in a service layer of a project library pool;
A determining module 602, configured to determine, according to the read target service code set that the target sub APP to be generated depends on, a target middleware code set and a target base library code set that the target sub APP to be generated depends on, where the target middleware code set is at least one middleware code set included in a middleware layer of the engineering library pool, and the target base library code set is at least one base library code set included in a base library layer of the engineering library pool;
a generating module 603, configured to generate the target sub APP by using the target service code set, the target middleware code set, and the target base library code set that the target sub APP to be generated depends on.
optionally, as shown in fig. 7, the determining module 602 includes:
a first reading submodule 6021, configured to read the second Podfile of the target service code set, and obtain a first reading result;
A first determining sub-module 6022, configured to determine, according to the first reading result, a first middleware code set, a second middleware code set, and a first base library code set, where the first middleware code set and the second middleware code set are both middleware code sets in at least one middleware code set included in the middleware layer, and the first base library code set is a base library code set in at least one base library code set included in the base library layer;
The second reading submodule 6023 is configured to read the third Podfile of the first middleware code set, and obtain a second reading result;
a second determining submodule 6024, configured to determine, according to the second reading result, a second base library code set on which the first middleware code set depends, where the second base library code set is a base library code set in at least one base library code set included in the base library layer;
a third determining submodule 6025 is configured to determine the first set of middleware codes and the second set of middleware codes as the target set of middleware codes, and determine the first set of base library codes and the second set of base library codes as the target set of base library codes.
Optionally, the level of the business layer is higher than that of the middleware layer, and the level of the middleware layer is higher than that of the base library layer;
Any two service code sets in at least one service code set contained in the service layer cannot be depended on each other;
Any two middleware code sets in at least one middleware code set contained in the middleware layer meet the one-way dependency criterion;
The one-way dependency criterion is satisfied between any two of at least one base library code set contained in the base library layer.
Optionally, the target sub APP to be generated is a target vertical service APP to be generated, where the main APP and the cross APP share a middleware code set and a basic library code set that the target vertical service APP to be generated depends on.
optionally, the target vertical service APP to be generated and the middleware code set and the base library code set on which the target vertical service APP to be generated depends are not coupled to the unique code in the main APP or the unique code in the cross APP.
The sub-application APP generating apparatus 600 can implement each process implemented by the sub-application APP generating apparatus in the method embodiments of fig. 1 and fig. 3, and for avoiding repetition, details are not described here again. And sub-application APP generates device 600 can realize that the App mill can divide into upper and lower two-layer: entry projects and project reservoir. The engineering library pool can be divided into a business layer, a middleware layer and a basic library layer, and each layer contained in the engineering library pool has a corresponding dependency criterion. The target business code set, the target middleware code set and the target basic library code set which are depended by the target sub APP to be generated can be determined, and then the target sub APP can be generated by utilizing the determined target business code set, the determined target middleware code set and the determined target basic library code set. The code set is used as the granularity packing code instead of the service code of each service, so that the generation of the sub-APP according to the requirement can be realized, the generated sub-APP is prevented from carrying a plurality of irrelevant or repeated codes, and the packet size is effectively controlled.
Fig. 8 is a schematic diagram of a hardware structure of an electronic device according to an embodiment of the present invention. As shown in fig. 8, the electronic device includes:
a memory 801 for storing program instructions;
The processor 802 is configured to call and execute the program instructions in the memory to implement the sub-application APP generation method in the foregoing embodiment. Reference may be made in particular to the description in relation to the preceding embodiments.
in this embodiment, the processor 802 and the memory 801 may be connected by a bus or other means. The processor may be a general-purpose processor, such as a central processing unit, a digital signal processor, an application specific integrated circuit, or one or more integrated circuits configured to implement embodiments of the present invention. The memory may include volatile memory, such as random access memory; the memory may also include non-volatile memory, such as read-only memory, flash memory, a hard disk, or a solid state disk.
An embodiment of the present invention further provides a readable storage medium, including: the readable storage medium has stored therein a computer program, and when at least one processor of the sub-application APP generating apparatus executes the computer program, the sub-application APP generating apparatus executes the sub-application APP generating method described in the above-described embodiments.
The readable storage medium may be a magnetic disk, an optical disk, a read-only memory (ROM) or a Random Access Memory (RAM).
those skilled in the art will readily appreciate that the techniques of the embodiments of the present invention may be implemented as software plus a required general purpose hardware platform. Based on such understanding, the technical solutions in the embodiments of the present invention may be essentially or partially implemented in the form of a software product, which may be stored in a storage medium, such as ROM/RAM, magnetic disk, optical disk, etc., and includes several instructions for enabling a computer device (which may be a personal computer, a server, or a network device, etc.) to execute the method according to the embodiments or some parts of the embodiments.
the same and similar parts in the various embodiments in this specification may be referred to each other. In particular, for the embodiments of the sub-application APP generation apparatus, the electronic device, and the readable storage medium, since they are substantially similar to the embodiments of the method, the description is simple, and the relevant points can be referred to the description in the embodiments of the method.
The above-described embodiments of the present invention should not be construed as limiting the scope of the present invention.

Claims (12)

1. a method for generating a sub-application APP, comprising:
reading a first Podfile arranged in an entrance project, and obtaining a target service code set depended by a target sub APP to be generated, wherein the target service code set depended by the target sub APP to be generated is configured in the first Podfile, and the target service code set is at least one service code set contained in a service layer of a project library pool;
Determining a target middleware code set and a target basic library code set which are depended by the target sub APP to be generated according to the read target service code set which is depended by the target sub APP to be generated, wherein the target middleware code set is at least one middleware code set contained in a middleware layer of the engineering library pool, and the target basic library code set is at least one basic library code set contained in a basic library layer of the engineering library pool;
And generating the target sub APP by utilizing the target business code set, the target middleware code set and the target basic library code set which are depended by the target sub APP to be generated.
2. The method of claim 1, wherein the determining, according to the read target service code set on which the target sub APP to be generated depends, a target middleware code set and a target base library code set on which the target sub APP to be generated depends includes:
Reading a second Podfile of the target service code set to obtain a first reading result;
Determining a first middleware code set, a second middleware code set and a first basic library code set which are depended by the target business code set according to the first reading result, wherein the first middleware code set and the second middleware code set are both middleware code sets in at least one middleware code set contained in the middleware layer, and the first basic library code set is a basic library code set in at least one basic library code set contained in the basic library layer;
reading a third Podfile of the first middleware code set to obtain a second reading result;
determining a second basic library code set depended by the first middleware code set according to the second reading result, wherein the second basic library code set is a basic library code set in at least one basic library code set contained in the basic library layer;
determining the first set of middleware codes and the second set of middleware codes as the target set of middleware codes, and determining the first set of base library codes and the second set of base library codes as the target set of base library codes.
3. The method of claim 1 or 2, wherein the business layer is at a higher level than the middleware layer, which is at a higher level than the base library layer;
Any two service code sets in at least one service code set contained in the service layer cannot be depended on each other;
any two middleware code sets in at least one middleware code set contained in the middleware layer meet the one-way dependency criterion;
The one-way dependency criterion is satisfied between any two of at least one base library code set contained in the base library layer.
4. The method of claim 3, wherein the target sub-APP to be generated is a target vertical business APP to be generated, and wherein a main APP and a cross APP share a middleware code set and a base library code set on which the target vertical business APP to be generated depends.
5. The method of claim 4, wherein the target vertical business APP to be generated and the set of middleware code and base library code upon which the target vertical business APP to be generated depends are not coupled with unique code in the master APP or unique code in the cross APP.
6. a sub-application APP generation apparatus, comprising:
The system comprises a reading module, a processing module and a processing module, wherein the reading module is used for reading a first Podfile arranged in an entrance project and obtaining a target service code set depended by a target sub APP to be generated, the target service code set depended by the target sub APP to be generated is configured in the first Podfile, and the target service code set is at least one service code set contained in a service layer of a project library pool;
a determining module, configured to determine, according to the read target service code set that the target sub APP to be generated depends on, a target middleware code set and a target base library code set that the target sub APP to be generated depends on, where the target middleware code set is at least one middleware code set included in a middleware layer of the engineering library pool, and the target base library code set is at least one base library code set included in a base library layer of the engineering library pool;
and the generating module is used for generating the target sub APP by utilizing the target business code set, the target middleware code set and the target basic library code set which are depended by the target sub APP to be generated.
7. The sub-application APP generation apparatus of claim 6, wherein the determination module comprises:
the first reading submodule is used for reading the second Podfile of the target service code set to obtain a first reading result;
a first determining submodule, configured to determine, according to the first reading result, a first middleware code set, a second middleware code set, and a first basic library code set, where the target service code set depends on, where the first middleware code set and the second middleware code set are both middleware code sets in at least one middleware code set included in the middleware layer, and the first basic library code set is a basic library code set in at least one basic library code set included in the basic library layer;
the second reading submodule is used for reading the third Podfile of the first middleware code set to obtain a second reading result;
A second determining submodule, configured to determine, according to the second reading result, a second basic library code set on which the first middleware code set depends, where the second basic library code set is a basic library code set in at least one basic library code set included in the basic library layer;
A third determining submodule, configured to determine that the first middleware code set and the second middleware code set are the target middleware code set, and determine that the first base library code set and the second base library code set are the target base library code set.
8. The sub-application APP generation apparatus of claim 6 or 7, wherein the level of the business layer is higher than the level of the middleware layer, which is higher than the level of the base library layer;
Any two service code sets in at least one service code set contained in the service layer cannot be depended on each other;
Any two middleware code sets in at least one middleware code set contained in the middleware layer meet the one-way dependency criterion;
The one-way dependency criterion is satisfied between any two of at least one base library code set contained in the base library layer.
9. The sub-application APP generation apparatus of claim 8, wherein the target sub-APP to be generated is a target vertical business APP to be generated, wherein a main APP and a cross APP share a middleware code set and a base library code set on which the target vertical business APP to be generated depends.
10. the sub-application APP generation apparatus of claim 9, wherein the target vertical business APP to be generated and the set of middleware code and the set of base library code on which the target vertical business APP to be generated depends are not coupled with the unique code in the main APP or the unique code in the cross APP.
11. An electronic device, comprising:
A memory for storing program instructions;
A processor, configured to call and execute the program instructions in the memory to implement the sub-application APP generation method according to any one of claims 1 to 5.
12. A readable storage medium, in which a computer program is stored, wherein when the computer program is executed by at least one processor of a sub-application APP generation apparatus, the sub-application APP generation apparatus executes the sub-application APP generation method according to any one of claims 1 to 5.
CN201910814518.1A 2019-08-30 2019-08-30 Sub-application APP generation method and generation device Active CN110569063B (en)

Priority Applications (1)

Application Number Priority Date Filing Date Title
CN201910814518.1A CN110569063B (en) 2019-08-30 2019-08-30 Sub-application APP generation method and generation device

Applications Claiming Priority (1)

Application Number Priority Date Filing Date Title
CN201910814518.1A CN110569063B (en) 2019-08-30 2019-08-30 Sub-application APP generation method and generation device

Publications (2)

Publication Number Publication Date
CN110569063A true CN110569063A (en) 2019-12-13
CN110569063B CN110569063B (en) 2023-05-02

Family

ID=68777022

Family Applications (1)

Application Number Title Priority Date Filing Date
CN201910814518.1A Active CN110569063B (en) 2019-08-30 2019-08-30 Sub-application APP generation method and generation device

Country Status (1)

Country Link
CN (1) CN110569063B (en)

Cited By (4)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN111338651A (en) * 2020-02-19 2020-06-26 北京字节跳动网络技术有限公司 Method and device for providing downloaded resources and method and device for downloading resources
CN111399864A (en) * 2020-03-16 2020-07-10 北京五八信息技术有限公司 Android system application program basic package generation method and generation device
CN111984531A (en) * 2020-07-31 2020-11-24 五八有限公司 Code coupling detection method and device
CN112558944A (en) * 2021-02-26 2021-03-26 武汉木仓信息技术有限公司 App generation method and device, processing equipment and computer readable storage medium

Citations (16)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
US7131143B1 (en) * 2000-06-21 2006-10-31 Microsoft Corporation Evaluating initially untrusted evidence in an evidence-based security policy manager
WO2007064799A1 (en) * 2005-12-01 2007-06-07 Cassatt Corporation Automated deployment and configuration of applications in an autonomically controlled distributed computing system
US20120324069A1 (en) * 2011-06-17 2012-12-20 Microsoft Corporation Middleware Services Framework for On-Premises and Cloud Deployment
CN104572072A (en) * 2014-12-01 2015-04-29 北京百度网讯科技有限公司 MVC (model view controller) mode-based language transformation method and equipment for program
CN106528071A (en) * 2015-09-15 2017-03-22 阿里巴巴集团控股有限公司 Selection method and device for target code
CN106569794A (en) * 2016-09-23 2017-04-19 北京五八信息技术有限公司 Application developing device
US20170177319A1 (en) * 2015-12-21 2017-06-22 Quixey, Inc. Dependency-Aware Transformation Of Multi-Function Applications For On-Demand Execution
CN106919386A (en) * 2017-02-15 2017-07-04 北京航空航天大学 The method and apparatus of code is generated based on ARINC653 operating systems
US20170192773A1 (en) * 2015-12-31 2017-07-06 Kony, Inc. Mobile applications
CN106990960A (en) * 2017-03-28 2017-07-28 阿里巴巴集团控股有限公司 Code dispositions method and device
CN107179923A (en) * 2017-03-31 2017-09-19 腾讯科技(深圳)有限公司 Applied program processing method, device and computer equipment
US20170315786A1 (en) * 2016-04-27 2017-11-02 Adp, Llc User Interface Engine for Miniapp Development
CN109189374A (en) * 2018-06-22 2019-01-11 北京大学 Object formation code generating method and system based on object reference chain
CN109240839A (en) * 2018-09-26 2019-01-18 海南新软软件有限公司 A kind of separate traffic framework
CN109240666A (en) * 2018-06-22 2019-01-18 北京大学 Function call code generating method and system based on call stack and independent path
CN109614081A (en) * 2018-11-26 2019-04-12 Oppo广东移动通信有限公司 Browser implementation method, device and mobile terminal

Patent Citations (16)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
US7131143B1 (en) * 2000-06-21 2006-10-31 Microsoft Corporation Evaluating initially untrusted evidence in an evidence-based security policy manager
WO2007064799A1 (en) * 2005-12-01 2007-06-07 Cassatt Corporation Automated deployment and configuration of applications in an autonomically controlled distributed computing system
US20120324069A1 (en) * 2011-06-17 2012-12-20 Microsoft Corporation Middleware Services Framework for On-Premises and Cloud Deployment
CN104572072A (en) * 2014-12-01 2015-04-29 北京百度网讯科技有限公司 MVC (model view controller) mode-based language transformation method and equipment for program
CN106528071A (en) * 2015-09-15 2017-03-22 阿里巴巴集团控股有限公司 Selection method and device for target code
US20170177319A1 (en) * 2015-12-21 2017-06-22 Quixey, Inc. Dependency-Aware Transformation Of Multi-Function Applications For On-Demand Execution
US20170192773A1 (en) * 2015-12-31 2017-07-06 Kony, Inc. Mobile applications
US20170315786A1 (en) * 2016-04-27 2017-11-02 Adp, Llc User Interface Engine for Miniapp Development
CN106569794A (en) * 2016-09-23 2017-04-19 北京五八信息技术有限公司 Application developing device
CN106919386A (en) * 2017-02-15 2017-07-04 北京航空航天大学 The method and apparatus of code is generated based on ARINC653 operating systems
CN106990960A (en) * 2017-03-28 2017-07-28 阿里巴巴集团控股有限公司 Code dispositions method and device
CN107179923A (en) * 2017-03-31 2017-09-19 腾讯科技(深圳)有限公司 Applied program processing method, device and computer equipment
CN109189374A (en) * 2018-06-22 2019-01-11 北京大学 Object formation code generating method and system based on object reference chain
CN109240666A (en) * 2018-06-22 2019-01-18 北京大学 Function call code generating method and system based on call stack and independent path
CN109240839A (en) * 2018-09-26 2019-01-18 海南新软软件有限公司 A kind of separate traffic framework
CN109614081A (en) * 2018-11-26 2019-04-12 Oppo广东移动通信有限公司 Browser implementation method, device and mobile terminal

Cited By (7)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN111338651A (en) * 2020-02-19 2020-06-26 北京字节跳动网络技术有限公司 Method and device for providing downloaded resources and method and device for downloading resources
CN111338651B (en) * 2020-02-19 2023-04-21 北京字节跳动网络技术有限公司 Method and device for providing download resource, and method and device for downloading resource
CN111399864A (en) * 2020-03-16 2020-07-10 北京五八信息技术有限公司 Android system application program basic package generation method and generation device
CN111984531A (en) * 2020-07-31 2020-11-24 五八有限公司 Code coupling detection method and device
CN111984531B (en) * 2020-07-31 2022-01-28 五八有限公司 Code coupling detection method and device
CN112558944A (en) * 2021-02-26 2021-03-26 武汉木仓信息技术有限公司 App generation method and device, processing equipment and computer readable storage medium
CN112558944B (en) * 2021-02-26 2021-05-18 武汉木仓信息技术有限公司 App generation method and device, processing equipment and computer readable storage medium

Also Published As

Publication number Publication date
CN110569063B (en) 2023-05-02

Similar Documents

Publication Publication Date Title
CN110569063A (en) sub-application APP generation method and generation device
KR102024694B1 (en) Decentralized service platform using multiple service nodes based on block chain
CN111859470B (en) Business data chaining method and device
CN111552945B (en) Resource processing method, device and equipment
CN111651467B (en) Block chain node interface issuing and calling method and device
EP4044507A1 (en) Network resource management method and system, network equipment and readable storage medium
CN111369358B (en) Block chain consensus method and device and electronic equipment
CN110365724B (en) Task processing method and device and electronic equipment
CN105357233A (en) Remote call method and device
CN111523887B (en) Authority control method and device for intelligent contract read-only method and electronic equipment
US20180329641A1 (en) Multi-tier data synchronizer based on concurrent linked list
CN110162344B (en) Isolation current limiting method and device, computer equipment and readable storage medium
CN108390786B (en) Business operation and maintenance method and device and electronic equipment
CN113760543A (en) Resource management method and device, electronic equipment and computer readable storage medium
CN113079224A (en) Account binding method and device, storage medium and electronic equipment
CN110659019B (en) Parameter verification method, device and server
CN114925015A (en) Data processing method, device, equipment and medium based on multi-core processor
US20080271055A1 (en) Protocol for communication of data structures
CN112148351B (en) Cross-version compatibility method and system for application software
US20100205237A1 (en) Correlator system for web services
CN112738181B (en) Method, device and server for cluster external IP access
CN108228248A (en) A kind of determining method and apparatus of dependence
CN115604344B (en) Micro-service current limiting method and device
CN111651469B (en) Method and device for managing blockchain system contracts
CN114978686A (en) Digital asset chaining method and device

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
GR01 Patent grant
GR01 Patent grant
TR01 Transfer of patent right
TR01 Transfer of patent right

Effective date of registration: 20230927

Address after: Room 210-03, 2nd floor, block C, office building, Nangang Industrial Zone, Tianjin Binhai New Area Economic and Technological Development Zone, 300450

Patentee after: 58Tongcheng Information Technology Co.,Ltd.

Address before: Room 210-03, 2nd floor, block C, office building, Nangang Industrial Zone, Tianjin Binhai New Area Economic and Technological Development Zone, 300450

Patentee before: 58 Co.,Ltd.