CN110569063B - Sub-application APP generation method and generation device - Google Patents
Sub-application APP generation method and generation device Download PDFInfo
- Publication number
- CN110569063B CN110569063B CN201910814518.1A CN201910814518A CN110569063B CN 110569063 B CN110569063 B CN 110569063B CN 201910814518 A CN201910814518 A CN 201910814518A CN 110569063 B CN110569063 B CN 110569063B
- Authority
- CN
- China
- Prior art keywords
- code set
- target
- middleware
- app
- service
- 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.)
- Active
Links
Images
Classifications
-
- G—PHYSICS
- G06—COMPUTING; CALCULATING OR COUNTING
- G06F—ELECTRIC DIGITAL DATA PROCESSING
- G06F8/00—Arrangements for software engineering
- G06F8/70—Software maintenance or management
- G06F8/71—Version control; Configuration management
-
- G—PHYSICS
- G06—COMPUTING; CALCULATING OR COUNTING
- G06F—ELECTRIC DIGITAL DATA PROCESSING
- G06F8/00—Arrangements for software engineering
- G06F8/70—Software maintenance or management
- G06F8/72—Code refactoring
-
- Y—GENERAL 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
- Y02—TECHNOLOGIES OR APPLICATIONS FOR MITIGATION OR ADAPTATION AGAINST CLIMATE CHANGE
- Y02D—CLIMATE 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/00—Energy 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 seed application program APP generation method and a generation device, wherein the method comprises the following steps: reading a first Podfile arranged in an entrance project to obtain a target service code set on which a target sub-APP to be generated depends; according to the read target business code set relied by the target sub-APP to be generated, determining a target middleware code set and a target base code set relied by the target sub-APP to be generated; and generating the target sub-APP by utilizing the target service code set, the target middleware code set and the target base code set on which the target sub-APP to be generated depends. In this way, the code set is taken as the granularity packing code instead of the service codes of each service, so that the generated sub-APP can be prevented from carrying a plurality of irrelevant or repeated codes.
Description
Technical Field
The present application relates to the field of communications technologies, and in particular, to a method and an apparatus for generating an APP.
Background
When a technician develops an application program (APPlication, APP), there may be cases where multiple APP types are developed in parallel. The APPs may be independent of each other or may be associated with each other in various ways. For example, among a plurality of APP's developed in parallel, there may be a corresponding sub APP in addition to the main APP. The main APP is a set of all services and service codes in the group; sub-APP is a set of one or several of the services and service codes, such as simplified APP (or polar velocity APP), vertical service APP, and innovative APP. Because the main APP and the sub APP have an association relation in service and service codes, the sub APP can be generated by using the existing main APP service codes. Therefore, APP research and development cost can be saved, and research and development efficiency is improved.
However, in practical applications, since the situation of service code coupling of each service is usually serious, even the service codes of different services are coupled, when generating a sub-APP based on a main APP, if the sub-APP involves multiple services, the service codes of each service and the codes coupled with the service codes need to be packed into the sub-APP, which causes the generated sub-APP to carry many irrelevant or repeated codes.
Disclosure of Invention
The application provides a method and a device for generating a sub-application program APP, which are used for solving the problem that in the related art, if the sub-APP relates to a plurality of services, service codes of all the services and codes coupled with the service codes are packed into the sub-APP, so that the generated sub-APP can carry a plurality 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 to obtain a target service code set on which a target sub-APP to be generated depends, wherein the first Podfile is internally configured with 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 an engineering library pool;
Determining a target middleware code set and a target base library code set which are relied on by the target sub-APP to be generated according to the read target service code set which is relied on 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 base library code set is at least one base library code set contained in a base library layer of the engineering library pool;
and generating the target sub-APP by using the target service code set, the target middleware code set and the target base code set on which the target sub-APP to be generated depends.
Optionally, the determining, according to the read target service code set on which the target sub APP to be generated depends, the target middleware code set and the target base 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 base 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 middleware code sets in at least one middleware code set contained 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 contained in the base 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 on which the first middleware code set depends 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 service layer is higher than the level of the middleware layer, and the level of the middleware layer is higher than the level of the base library layer;
any two business code sets in at least one business code set contained in the business layer cannot be relied on;
any two middleware code sets in at least one middleware code set contained in the middleware layer meet a unidirectional dependency criterion;
the unidirectional dependency criterion is satisfied between any two of at least one set of base code contained in the base 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 base library code set on which the target vertical service APP to be generated depends.
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 with the unique codes in the main APP or the unique codes in the cross APP.
In a second aspect, the present invention further provides a device for generating an APP of a sub-application, 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 to obtain a target service code set on which a target sub-APP to be generated depends, wherein the first Podfile is internally configured with 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 an engineering library pool;
the determining module is used for 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, 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 base library code set is at least one base library code set contained in a base library layer of the engineering library pool;
The generating module is used for generating the target sub-APP by utilizing the target service code set, the target middleware code set and the target base code set, on which the target sub-APP to be generated depends.
Optionally, the determining module includes:
the first reading sub-module 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 base library code set on which the target service code set depends, 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 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 a second base library code set on which the first middleware code set depends according to the second reading result, 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;
And a third determining submodule, configured to determine the first middleware code set and the second middleware code set as the target middleware code set, and determine the first base library code set and the second base library code set as the target base library code set.
Optionally, the level of the service layer is higher than the level of the middleware layer, and the level of the middleware layer is higher than the level of the base library layer;
any two business code sets in at least one business code set contained in the business layer cannot be relied on;
any two middleware code sets in at least one middleware code set contained in the middleware layer meet a unidirectional dependency criterion;
the unidirectional dependency criterion is satisfied between any two of at least one set of base code contained in the base 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 base library code set on which the target vertical service APP to be generated depends.
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 with the unique codes in the main APP or the unique codes in the cross APP.
In a third aspect, the present invention also 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 sub-application program APP generation method.
In a fourth aspect, the present invention also provides a readable storage medium comprising: the readable storage medium stores a computer program, and when at least one processor of the sub-application APP generating device executes the computer program, the sub-application APP generating device executes the sub-application APP generating method according to the first aspect.
As can be seen from the above technical solution, in the sub-application APP generating method and the sub-application APP generating device provided by the embodiments of the present invention, a first Podfile set in an entry project is read to obtain a target service code set on which a target sub-APP to be generated depends, where the first Podfile is configured with 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 included in a service layer of a pool of engineering libraries; determining a target middleware code set and a target base library code set which are relied on by the target sub-APP to be generated according to the read target service code set which is relied on 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 base library code set is at least one base library code set contained in a base library layer of the engineering library pool; and generating the target sub-APP by using the target service code set, the target middleware code set and the target base code set on which the target sub-APP to be generated depends. In this way, the target business code set, the target middleware code set and the 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 business code set, target middleware code set and target base library code set. The code set is taken as the granularity packing code instead of the service codes of each service, so that the generated sub-APP can be prevented from carrying a plurality of irrelevant or repeated codes.
Drawings
In order to more clearly illustrate the technical solutions of the present application, the drawings that are needed in the embodiments will be briefly described below, and it will be obvious to those skilled in the art that other drawings can be obtained from these drawings without inventive effort.
FIG. 1 is a flowchart of a method for generating a sub-application APP provided by the invention;
FIG. 2 is a schematic diagram of an App factory architecture provided by the present invention;
FIG. 3 is a flowchart of another method for generating a seed application APP according to the present invention;
FIG. 4 is a schematic diagram of generating a target child APP according to 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 block diagram of a sub-application APP generation device provided by the present invention;
FIG. 7 is a block diagram of another seed application APP generation apparatus provided by 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 the embodiments, examples of which are illustrated in the accompanying drawings. When the following description refers to the accompanying drawings, the same numbers in different drawings refer to the same or similar elements, unless otherwise indicated. The embodiments described in the examples below do not represent all embodiments consistent with the present application. Merely as examples of systems and methods consistent with some aspects of the present application as detailed in the claims.
Referring to fig. 1, fig. 1 is a flowchart of a method for generating an APP of a sub-application program according to the present invention. As shown in fig. 1, the method comprises the following steps:
In step 101, as shown in fig. 2, an App factory architecture diagram provided in an embodiment of the present invention is shown. In fig. 2, the App plant can be divided into upper and lower layers: entrance projects and project library pools. The portal engineering pod relies on the pod of the engineering pool, and the pod code required by the APP where each portal engineering is located is configured through the podfile.
The portal engineering is mainly responsible for configuring the codes required by the APP generated by the APP factory. The entry engineering includes the functions of:
APPInfo: setting APP basic information. Such as APP name, package identification (bundle identifier), version number, certificate, etc.
Podfile: the current APP relies on the required engineering code.
Regen. Sh, an executable file (for local RD development tuning). And reading the podfile configuration, copying the codes and the configuration required by the APP, and then generating the codes required by the APP.
Reng_jenkins.sh an executable file (for Jenkins service package). And reading the podfile configuration, copying the codes and the configuration required by the APP, and then generating the codes required by the APP.
The engineering library pool is the total code set of the APP factory, the codes required by each generated APP are obtained from the code set, and the code update in the research and development process is synchronously updated into 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, 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 include a home page pod, a clan pod, a post pod, a personal center pod, a property pod, a recruitment pod, a second cart pod, and so forth.
Middleware layer, APP factory intermediate service code. The general explanation of middleware in the software domain is: programs that connect software components and applications. The middleware herein embodies the connection and sharing: connected are a business layer and a base library layer, sharing common services embodied in the business layer.
The middleware is divided into a business middleware and a standard middleware according to whether the middleware is strongly related to the business or not. Business middleware: middleware which is strongly related to the service is commonly used in a certain independent APP. It is not applicable to other independent APPs due to excessive reliance on other functions of the current APP. For example, in fig. 2, the service middleware may include RN extension middleware, general list middleware, and lifecycle middleware, etc.
Standard middleware: middleware related to weak business. Not only is common in one independent APP, but also is common in other independent APP, and is weakly related to the business in the APP. For example, in fig. 2, the standard middleware may include RN base library middleware, jump component middleware, network component middleware, and the like. In addition, as shown in fig. 2, it can be seen that some standard middleware of the middleware layer adds two vertical lines, which means that the implementation of some functions of this standard middleware depends on the access APP, and only the interface protocol is opened. Taking the standard middleware of the RN base pool as an example: the middleware contains all the common business-weak related content of the carrier page and the hot update, but for some extended components (e.g. buried points) an open protocol is needed for the access party to implement, and this logic is not implemented in the middleware.
The base library layer generates independent libraries that are not dependent on other pod. For example, some open-sourced three-party libraries are common base libraries. For example, in fig. 2, the base library layer may contain a photo library pod, a language recognition pod, a map pod, and the like.
And the first Podfile arranged in the entrance engineering can be read to obtain the target service code set on which the target sub APP to be generated depends. The method comprises the steps that a target service code set on which a target sub APP to be generated depends is configured in a first Podfile, wherein the target service code set is at least one service code set contained in a service layer of an engineering library pool. The first Podfile arranged in the entrance engineering can be read, and the target service pod on which the target sub APP to be generated depends is obtained, wherein the target service pod is at least one service pod contained in the service layer of the engineering library pool.
In step 102, a target middleware code set and a target base code set on which the target sub-APP to be generated depends may be determined according to the read target service code set on which the target sub-APP to be generated depends. 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. And determining the target middleware pod and the target base pod depending on the target sub APP to be generated according to the read target service pod depending on 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 library pool; the target base pool is at least one base pool pod contained in the base pool layer of the engineering pool.
And step 103, generating the target sub-APP by using the target service code set, the target middleware code set and the target base code set on which the target sub-APP to be generated depends.
In step 103, a target sub-APP may be generated using a target set of business codes, a target set of middleware codes, and a target set of base library codes on which the target sub-APP to be generated depends. The target sub APP can be generated by utilizing the target service pod, the target middleware pod and the target base library pod which are depended on by the target sub APP to be generated.
It should be noted that, in the related art, since the condition of service code coupling of each service is usually serious, even the service codes of different services are coupled, when generating a sub APP based on a main APP, if the sub APP involves multiple services, the service codes of each service and the codes coupled with the service codes need to be packed into the sub APP, which may cause the generated sub APP to carry many irrelevant or repeated codes.
In the invention, the target business code set, the target middleware code set and the target base library code set which are depended on 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, target middleware code set and target base library code set. The code set is taken as the granularity packing code instead of the service codes of each service, so that the generated sub-APP can be prevented from carrying a plurality of irrelevant or repeated codes.
As can be seen from the above technical solution, in the method for generating a sub-application APP provided by the embodiment of the present invention, a first Podfile set in an entry project is read to obtain a target service code set on which a target sub-APP to be generated depends, where the first Podfile is configured with 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 included in a service layer of an engineering library pool; determining a target middleware code set and a target base library code set which are relied on by the target sub-APP to be generated according to the read target service code set which is relied on 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 base library code set is at least one base library code set contained in a base library layer of the engineering library pool; and generating the target sub-APP by using the target service code set, the target middleware code set and the target base code set on which the target sub-APP to be generated depends. In this way, the target business code set, the target middleware code set and the 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 business code set, target middleware code set and target base library code set. The code set is taken as the granularity packing code instead of the service codes of each service, so that the generated sub-APP can be prevented from carrying a plurality of irrelevant or repeated codes.
Referring to fig. 3, fig. 3 is a flowchart of another method for generating a seed application APP provided by the present invention. As shown in fig. 3, the method comprises the following steps:
In step 301, still taking fig. 2 as an example, as shown in fig. 2, an App factory architecture diagram provided in an embodiment of the present invention is shown. In fig. 2, the App plant can be divided into upper and lower layers: entrance projects and project library pools. The portal engineering pod relies on the pod of the engineering pool, and the pod code required by the APP where each portal engineering 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 service layer is higher than the level of the middleware layer, and the level of the middleware layer is higher than the level of the base library layer;
any two business code sets in at least one business code set contained in the business layer cannot be relied on;
Any two middleware code sets in at least one middleware code set contained in the middleware layer meet a unidirectional dependency criterion;
the unidirectional dependency criterion is satisfied between any two of at least one set of base code contained in the base 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 base library layer. As described above, middleware is divided into service middleware and standard middleware according to whether it is strongly related to a service or not. Wherein the level of the business middleware is higher than that of the standard middleware. It should be noted that a layer of a higher level may depend on a layer of a lower level, but a layer of a lower level cannot depend on a layer of a higher level. For example, a top page pod in the business layer may depend on a lifecycle pod in the middleware layer, but not on the contrary, i.e., the lifecycle pod in the middleware layer cannot depend on the top 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 relied on. For example, the business layer cannot be relied upon between a house property pod and a recruitment pod.
Any two middleware code sets in at least one middleware code set contained in the middleware layer meet the unidirectional dependency criterion. For example, the middleware layer includes a generic list service middleware and a lifecycle service middleware that satisfy a unidirectional dependency criterion. If the universal list service middleware depends on the life cycle service middleware, the life cycle service middleware cannot depend on the universal list service middleware; alternatively, if the lifecycle service middleware relies on the generic list service middleware, the generic list service middleware cannot rely on the lifecycle service middleware.
Any two basic library code sets in at least one basic library code set contained in the basic library layer meet the unidirectional dependency criterion. For example, the unidirectional dependency criterion is satisfied between the picture library pod and the language recognition pod contained in the base library layer. Namely, if the picture library pod depends on the language identification pod at this time, the language identification pod cannot depend on the picture library pod; alternatively, if the language identification pod depends on the photo library pod, the photo library pod cannot depend on the language identification pod.
It should be noted that interlayer dependence may also be achieved. For example, the business layer may rely on the base library layer.
And the first Podfile arranged in the entrance engineering can be read to obtain the target service code set on which the target sub APP to be generated depends. The method comprises the steps that a target service code set on which a target sub APP to be generated depends is configured in a first Podfile, wherein the target service code set is at least one service code set contained in a service layer of an engineering library pool. As shown in fig. 4, a schematic diagram of the target child APP is generated. The target child APP can be a rental house waistcoat APP. At this time, the first Podfile set in the entrance engineering may be read to obtain the target service code set on which the rental car waistcoat APP to be generated depends. Assume that the target service code set on which the rental waistcoat APP to be generated depends is a property code set in the service layer, i.e., a property pod.
And step 302, reading the second Podfile of the target service code set to obtain a first reading result.
In step 302, a second Podfile of the set of target service codes may be read to obtain a first read result. I.e. the second Podfile of the property pod can be read, and the first reading result is obtained. Wherein the second Podfile of the property pod is configured with middleware pod on which the property pod depends and a base library pod.
In step 303, a first set of middleware codes, a second set of middleware codes, and a first set of base library codes on which the target set of business codes depends may be determined based on the first read result. The first middleware code set and the second middleware code set are middleware code sets in at least one middleware code set contained in a middleware layer; the first set of base library codes is a set of base library codes in at least one set of base library codes contained in the base library layer. The first middleware pod, the second middleware pod and the first base library pod on which the property pod depends can be determined according to the first reading result. It should be noted that the first middleware pod exists a base pod relied on, and the second middleware pod does not rely on any base 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 base pool pod is a base pool pod F, a base pool pod G and a base pool pod H on which the interlayer of the property pod depends.
And step 304, reading the third Podfile of the first middleware code set to obtain a second reading result.
In step 304, a third Podfile of the first set of middleware codes may be read to obtain a second read result. The third Podfile of the service middleware pod a and the third Podfile of the service middleware pod B can be read, and a second reading result can be obtained. The third Podfile of the service middleware pod a is configured with a base library pod on which the service middleware pod a depends; the third Podfile of the service middleware pod B is configured with the base library pod on which the service middleware pod B depends.
In step 305, a second set of base library codes on which the first set of middleware codes depends may be determined based on the second read result. 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. And determining a second base pool pod relied by the service middleware pod A and a second base pool pod relied by the service middleware pod B according to the second reading result. Assume that a second base pool pod on which the service middleware pod a depends is a base pool pod F, a base pool pod G, and a base pool pod H; the second base pool on which the service middleware pod B depends is base pool pod G.
In step 306, a first set of middleware codes and a second set of middleware codes may be determined as target sets of middleware codes, and a first set of base library codes and a second set of base library codes may be determined as target sets 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. 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 target middleware code sets; base library pod F, base library pod G, and base library pod H may be determined as the target base library code set.
In step 307, a target sub-APP may be generated using the target set of business codes, the target set of middleware codes, and the target set of base library codes on which the target sub-APP to be generated depends. The house property 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 base library pod F, the base library pod G and the base library pod H on which the house renting waistcoat APP to be generated depends can be utilized to generate the house renting waistcoat APP.
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 base library code set on which the target vertical service APP to be generated depends.
It should be noted that, the target sub APP to be generated may be the target vertical service APP to be generated. The method comprises the steps that a main APP and a cross APP share a middleware code set and a base code set which are depended on by a 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 with the unique codes in the main APP or the unique codes 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 codes in the main APP or the unique codes in the cross APP. As shown in fig. 5, a schematic diagram of the target vertical service APP is generated. In this way, the generated target vertical service APP does not carry unnecessary codes which are irrelevant, and is beneficial to controlling the size of the packet.
According to the technical scheme, the generation method of the sub-application program APP is provided. The App plant can be divided into two layers: entrance projects and project library pools. 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 corresponding dependency criteria. The target business code set, the target middleware code set and the 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 utilizing the determined target business code set, target middleware code set and target base library code set. The sub-APP can be generated according to the requirement by taking the code set instead of the service codes of each service as the granularity packing codes, so that the generated sub-APP is prevented from carrying a plurality of irrelevant or repeated codes, and the size of the packet is effectively controlled.
Referring to fig. 6, fig. 6 is a block diagram of an APP generating device for a sub application provided by the present invention. As shown in fig. 6, the sub-application APP generating device 600 includes a reading module 601, a determining module 602, and a generating module 603, wherein:
the reading module 601 is configured to read a first Podfile set in an entry project to obtain a target service code set on which a target sub APP to be generated depends, where the first Podfile is configured with 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 included in a service layer of an engineering library pool;
a determining module 602, configured to determine, 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, 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;
The generating module 603 is 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 on which the target sub-APP to be generated depends.
Optionally, as shown in fig. 7, the determining module 602 includes:
a first reading sub-module 6021, configured to read the second Podfile of the target service code set to obtain a first reading result;
a first determining submodule 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 on which the target service code set depends, 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;
a second reading submodule 6023 configured to read the third Podfile of the first middleware code set to obtain a second reading result;
a second determining submodule 6024, configured to determine, according to the second read 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 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 service layer is higher than the level of the middleware layer, and the level of the middleware layer is higher than the level of the base library layer;
any two business code sets in at least one business code set contained in the business layer cannot be relied on;
any two middleware code sets in at least one middleware code set contained in the middleware layer meet a unidirectional dependency criterion;
the unidirectional dependency criterion is satisfied between any two of at least one set of base code contained in the base 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 base library code set on which the target vertical service APP to be generated depends.
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 with the unique codes in the main APP or the unique codes in the cross APP.
The sub-application APP generating device 600 is capable of implementing each process implemented by the sub-application APP generating device in the method embodiment of fig. 1 and 3, and for avoiding repetition, a detailed description is omitted herein. And the APP generating device 600 may implement an APP factory that may be divided into two layers: entrance projects and project library pools. 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 corresponding dependency criteria. The target business code set, the target middleware code set and the 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 utilizing the determined target business code set, target middleware code set and target base library code set. The sub-APP can be generated according to the requirement by taking the code set instead of the service codes of each service as the granularity packing codes, so that the generated sub-APP is prevented from carrying a plurality of irrelevant or repeated codes, and the size of the packet 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;
A processor 802, configured to invoke and execute the program instructions in the memory, so as to implement the sub-application APP generation method in the foregoing embodiment. Reference may be made in particular to the relevant description of the previous 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.
The embodiment of the invention also provides a readable storage medium, which comprises: the readable storage medium stores a computer program therein, and when at least one processor of the sub-application APP generating device executes the computer program, the sub-application APP generating device executes the sub-application APP generating method described in the above embodiments.
The readable storage medium may be a magnetic disk, an optical disk, a read-only memory (ROM), a random-access memory (random access memory, RAM), or the like.
It will be apparent to those skilled in the art that the techniques of embodiments of the present invention may be implemented in software plus a necessary general purpose hardware platform. Based on such understanding, the technical solutions in the embodiments of the present invention may be embodied in essence or what contributes to the prior art in the form of a software product, which may be stored in a storage medium, such as a ROM/RAM, a magnetic disk, an optical disk, etc., including several instructions for causing a computer device (which may be a personal computer, a server, or a network device, etc.) to execute the method described in the embodiments or some parts of the embodiments of the present invention.
The same or similar parts between the various embodiments in this specification are referred to each other. In particular, for the sub-application APP generating apparatus, the electronic device and the readable storage medium embodiments, since they are substantially similar to the method embodiments, the description is relatively simple, and the relevant points are referred to the description in the method embodiments.
The embodiments of the present invention described above do not limit the scope of the present invention.
Claims (10)
1. A method for generating a seed application APP, comprising:
Reading a first Podfile arranged in an entrance project to obtain a target service code set on which a target sub-APP to be generated depends, wherein the first Podfile is internally configured with 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 an engineering library pool;
determining a target middleware code set and a target base library code set which are relied on by the target sub-APP to be generated according to the read target service code set which is relied on 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 base library code set is at least one base library code set contained in a base library layer of the engineering library pool;
generating the target sub-APP by utilizing the target service code set, the target middleware code set and the target base code set on which the target sub-APP to be generated depends;
the step of determining the target middleware code set and the target base code set which are depended on by the target sub-APP to be generated according to the read target service code set which is depended on by the target sub-APP to be generated comprises the following steps:
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 base 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 middleware code sets in at least one middleware code set contained 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 contained in the base 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 on which the first middleware code set depends 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.
2. The method of claim 1, wherein the service layer is at a higher level than the middleware layer, the middleware layer being at a higher level than the base library layer;
any two business code sets in at least one business code set contained in the business layer cannot be relied on;
any two middleware code sets in at least one middleware code set contained in the middleware layer meet a unidirectional dependency criterion;
the unidirectional dependency criterion is satisfied between any two of at least one set of base code contained in the base layer.
3. The method of claim 2, wherein the target sub-APP to be generated is a target vertical service APP to be generated, wherein a main APP and a cross APP share a set of middleware codes and a set of base library codes on which the target vertical service APP to be generated depends.
4. The method of claim 3, wherein the target vertical service APP to be generated and the set of middleware codes and base library codes on which the target vertical service APP to be generated depends are not coupled to unique codes in the master APP or unique codes in the cross APP.
5. A seed application APP generating device, 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 to obtain a target service code set on which a target sub-APP to be generated depends, wherein the first Podfile is internally configured with 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 an engineering library pool;
the determining module is used for 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, 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 base library code set is at least one base library code set contained in a base library layer of the engineering library pool;
the determining module includes:
the first reading sub-module 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 base library code set on which the target service code set depends, 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 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 a second base library code set on which the first middleware code set depends according to the second reading result, 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, configured to determine the first middleware code set and the second middleware code set as the target middleware code set, and determine the first base library code set and the second base library code set as the target base library code set;
the generating module is used for generating the target sub-APP by utilizing the target service code set, the target middleware code set and the target base code set, on which the target sub-APP to be generated depends.
6. The sub-application APP generating apparatus of claim 5, wherein a level of the service layer is higher than a level of the middleware layer, the level of the middleware layer being higher than a level of the base library layer;
Any two business code sets in at least one business code set contained in the business layer cannot be relied on;
any two middleware code sets in at least one middleware code set contained in the middleware layer meet a unidirectional dependency criterion;
the unidirectional dependency criterion is satisfied between any two of at least one set of base code contained in the base layer.
7. The sub-application APP generation apparatus of claim 6, wherein the target sub-APP to be generated is a target vertical service 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 service APP to be generated depends.
8. The sub-application APP generation apparatus of claim 7, wherein the target vertical service APP to be generated and the set of middleware codes and base library codes on which the target vertical service APP to be generated depends are not coupled with unique codes in the main APP or unique codes in the cross APP.
9. An electronic device, comprising:
A memory for storing program instructions;
a processor for calling and executing program instructions in said memory to implement the sub-application APP generation method of any one of claims 1 to 4.
10. A readable storage medium, wherein a computer program is stored in the readable storage medium, and when executed by at least one processor of a sub-application APP generating device, the sub-application APP generating device performs the sub-application APP generating method of any one of claims 1 to 4.
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 CN110569063A (en) | 2019-12-13 |
CN110569063B true 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) |
Families Citing this family (4)
Publication number | Priority date | Publication date | Assignee | Title |
---|---|---|---|---|
CN111338651B (en) * | 2020-02-19 | 2023-04-21 | 北京字节跳动网络技术有限公司 | Method and device for providing download resource, and method and device for downloading resource |
CN111399864B (en) * | 2020-03-16 | 2023-07-07 | 北京五八信息技术有限公司 | Android system application program foundation package generation method and generation device |
CN111984531B (en) * | 2020-07-31 | 2022-01-28 | 五八有限公司 | Code coupling detection method and device |
CN112558944B (en) * | 2021-02-26 | 2021-05-18 | 武汉木仓信息技术有限公司 | App generation method and device, processing equipment and computer readable storage medium |
Citations (2)
Publication number | Priority date | Publication date | Assignee | Title |
---|---|---|---|---|
WO2007064799A1 (en) * | 2005-12-01 | 2007-06-07 | Cassatt Corporation | Automated deployment and configuration of applications in an autonomically controlled distributed computing system |
CN109240839A (en) * | 2018-09-26 | 2019-01-18 | 海南新软软件有限公司 | A kind of separate traffic framework |
Family Cites Families (14)
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 |
US9336060B2 (en) * | 2011-06-17 | 2016-05-10 | Microsoft Technology Licensing, Llc | Middleware services framework for on-premises and cloud deployment |
CN104572072B (en) * | 2014-12-01 | 2017-09-29 | 北京百度网讯科技有限公司 | A kind of language transfer method and equipment to the program based on MVC pattern |
CN106528071B (en) * | 2015-09-15 | 2019-08-13 | 阿里巴巴集团控股有限公司 | The choosing method and device of object code |
US9811327B2 (en) * | 2015-12-21 | 2017-11-07 | Quixey, Inc. | Dependency-aware transformation of multi-function applications for on-demand execution |
US11340893B2 (en) * | 2015-12-31 | 2022-05-24 | Kony, Inc. | Mobile application update preserving changes to the application made by a client |
US10019242B2 (en) * | 2016-04-27 | 2018-07-10 | Adp, Llc | User interface engine for Miniapp development |
CN106569794B (en) * | 2016-09-23 | 2020-03-24 | 北京五八信息技术有限公司 | Application program development device |
CN106919386B (en) * | 2017-02-15 | 2019-09-20 | 北京航空航天大学 | The method and apparatus of code is generated based on ARINC653 operating system |
CN106990960B (en) * | 2017-03-28 | 2020-10-30 | 创新先进技术有限公司 | Code deployment method and device |
CN107179923B (en) * | 2017-03-31 | 2018-12-11 | 腾讯科技(深圳)有限公司 | Applied program processing method, device and computer equipment |
CN109240666B (en) * | 2018-06-22 | 2020-08-25 | 北京大学 | Function calling code generation method and system based on call stack and dependent path |
CN109189374B (en) * | 2018-06-22 | 2020-08-28 | 北京大学 | Object structure code generation method and system based on object reference chain |
CN109614081B (en) * | 2018-11-26 | 2022-03-29 | Oppo广东移动通信有限公司 | Browser implementation method and device and mobile terminal |
-
2019
- 2019-08-30 CN CN201910814518.1A patent/CN110569063B/en active Active
Patent Citations (2)
Publication number | Priority date | Publication date | Assignee | Title |
---|---|---|---|---|
WO2007064799A1 (en) * | 2005-12-01 | 2007-06-07 | Cassatt Corporation | Automated deployment and configuration of applications in an autonomically controlled distributed computing system |
CN109240839A (en) * | 2018-09-26 | 2019-01-18 | 海南新软软件有限公司 | A kind of separate traffic framework |
Also Published As
Publication number | Publication date |
---|---|
CN110569063A (en) | 2019-12-13 |
Similar Documents
Publication | Publication Date | Title |
---|---|---|
CN110569063B (en) | Sub-application APP generation method and generation device | |
CN106990960B (en) | Code deployment method and device | |
CN113641940B (en) | Page jump method, device, system, equipment and storage medium | |
CN110825448A (en) | Method, device, electronic equipment and storage medium for realizing mutual calling of multiple service modules | |
CN110309669B (en) | Data labeling method, device and equipment | |
CN109891415B (en) | Securing a Web server for an unauthorized client application | |
CN110162344B (en) | Isolation current limiting method and device, computer equipment and readable storage medium | |
CN111523887B (en) | Authority control method and device for intelligent contract read-only method and electronic equipment | |
CN110659905A (en) | Transaction verification method, device, terminal equipment and storage medium | |
CN113079224A (en) | Account binding method and device, storage medium and electronic equipment | |
CN114925015A (en) | Data processing method, device, equipment and medium based on multi-core processor | |
CN113703996B (en) | Access control method, equipment and medium based on user and YANG model grouping | |
CN112738181B (en) | Method, device and server for cluster external IP access | |
CN115455328A (en) | Automatic generation method, device and equipment of page permission and storage medium | |
CN115225299B (en) | User authentication method, server and system | |
CN111399928A (en) | Application program starting method and device, electronic equipment and readable storage medium | |
CN111369246B (en) | Calling authentication method and device of intelligent contract, electronic equipment and storage medium | |
CN111651469B (en) | Method and device for managing blockchain system contracts | |
CN114661295A (en) | Parameter injection method and device and computer storage medium | |
CN109787945B (en) | Method and device for realizing user component in Android system | |
CN112346888A (en) | Data communication method and device based on software application and server equipment | |
CN111209593A (en) | Block chain-based distributed lock processing method, related device and electronic equipment | |
CN110648123A (en) | Digital asset construction method and device and electronic equipment | |
CN105094773A (en) | Module function reusing method and system | |
CN111045812A (en) | Block chain intelligent contract reverse calling method, equipment and medium |
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 |
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. |
|
TR01 | Transfer of patent right |