CN101957794B - Deployment constraint automatic detection method for Web application - Google Patents

Deployment constraint automatic detection method for Web application Download PDF

Info

Publication number
CN101957794B
CN101957794B CN2010102893648A CN201010289364A CN101957794B CN 101957794 B CN101957794 B CN 101957794B CN 2010102893648 A CN2010102893648 A CN 2010102893648A CN 201010289364 A CN201010289364 A CN 201010289364A CN 101957794 B CN101957794 B CN 101957794B
Authority
CN
China
Prior art keywords
constraint
deployment
web application
entity
configuration
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.)
Expired - Fee Related
Application number
CN2010102893648A
Other languages
Chinese (zh)
Other versions
CN101957794A (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.)
Institute of Software of CAS
Original Assignee
Institute of Software of CAS
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 Institute of Software of CAS filed Critical Institute of Software of CAS
Priority to CN2010102893648A priority Critical patent/CN101957794B/en
Publication of CN101957794A publication Critical patent/CN101957794A/en
Application granted granted Critical
Publication of CN101957794B publication Critical patent/CN101957794B/en
Expired - Fee Related legal-status Critical Current
Anticipated expiration legal-status Critical

Links

Images

Landscapes

  • Information Retrieval, Db Structures And Fs Structures Therefor (AREA)
  • Stored Programmes (AREA)

Abstract

The invention discloses a deployment constraint automatic detection method for Web application which comprises the following steps of: (1) establishing a deployment scheme model of the Web application of D(omega)=(U, R), wherein omega is the Web application, U is the entity set of the deployment scheme and R is the relation set among the entities; and (2) detecting the deployment constraint of the application according to the deployment scheme model. The invention can ensure that the method can automatically detect the deployment constraint of various types and in various planes after finishing the design of the deployment scheme model of the Web application; the method can automatically position and prompts users to modify the deployment scheme of the Web application to guarantee the satisfaction of the deployment constraint after detecting the current Web application to violate the deployment constraint; the success for carrying out the deployment operation according to the deployment scheme can be ensured; and the deployment efficiency and the accuracy of the Web application can be greatly enhanced.

Description

Web application deployment constraint automatic testing method
Technical field
The present invention relates to a kind of method that constraint detects of disposing, relate in particular to a kind of deployment constraint automatic testing method of using towards Web, belong to computer software technical field.
Background technology
Disposing (Deployment) is an important stage of computer software life cycle, accomplishes and is delivered between the software systems successful operation between software development, mainly bears the preceding preliminary work of software systems operation.The direct target of disposing is to ensure correctly installation and operation of software systems, satisfies user's related needs simultaneously.Along with the development of software engineering, software forms and software size, become one of main method of Software deployment based on the dispositions method of model.
Software deployment relates to the design of deployment scheme and disposes the inspection of constraint.Wherein, The configuration information of the installation site of the assembly of the physical topological structure when deployment scheme has been portrayed Software deployment, formation software application system and incidence relation, running environment etc.; Being the desired target that reaches of Software deployment, is the actual reference frame of carrying out various operations in the deployment; The disposed constraint definition restriction that must satisfy of deployment and deployment scheme and the rule of following, aspects such as the dependence of the resource that need consider when relating generally to Software deployment, function/nonfunction requirement and best practices.In the design and planning process of deployment scheme, possibly exist stating the situation of running counter to of constraint, as: do not satisfy the defined resource requirement of constraint, parameter value coupling.Whether dispose constraint and detect restriction and the rule needs followed in order to the check deployment scheme and runs counter to, discovery that can be is as early as possible also located the problem that exists in the deployment scheme, helps to improve the correctness of deployment scheme.
The Web of multi-layer framework uses the network application software that has become current main-stream, and Web uses has characteristics open, dynamic and that distribute, and the scale of system and complexity also constantly increase.Web uses and the isomerism of running environment makes constrained type more complicated various, and the expansion of system scale and dispersion cause amount of constraint to increase greatly, and this all is to dispose the constraint detection to have brought more difficulty.
Current existing patent of invention has given a lot of concerns and has formed relevant achievement the software systems deployment issue with academic research.
Some patents of invention have proposed the software dispositions method relevant with application system; 200810143799.4), design, deployment and the management of Distributed Computer System framework and Distributed Application (application number: 200410033027.7), the dispositions method of distributed software system (application number: 200610099028.0), have a deployment relation and method (application number: of dependence assembly 200610138332.1) and Software deployment method and system and software deployment service device and client server (application number: 200710195500.5) etc. representative comprises: a kind of general calculation entironment is disposed down and collocation method (application number:; The foregoing invention patent is primarily aimed at varying environment and dissimilar software systems propose corresponding dispositions method or system realizes; Mainly, improve the automaticity and the extensibility of deployment in order to solve problems such as deployment is difficult, version is inconsistent.But existing patent of invention does not propose special automated detection method to the constraint that relates in the Web application system deployment, is difficult to guarantee the correctness of deployment scheme.
Aspect academic research; Towards the statement formula restraint frame of SOA application deployment and configuration (referring to document: Luo J; Li Y; Qiu J, Chen Y.Declarative Constraint Framework for SOA Deployment and Configuration.In ICWS ' 08, pages 637-644; 2008) with application and the identifying object of the described deployment scheme of deployment model as constraint, the constraint of accomplishing the described deployment scheme of model through constraint template and several committed steps such as retraining checking generates and checking.This method will retrain template and convert OCL object constraint language into (referring to document: http://www.omg.org/spec/OCL/2.0/PDF) the formalization constraint specification of expression is also resolved and verified; But the constraint generation and the instantiation process that are based on the constraint template still need artificial the participation; Automaticity a little less than, the constrained type that can verify simultaneously is also comparatively limited.The constraint verification method that has proposed resource and parameter configuration aspect in the deployment configuration process based on the constraint of software resource allocation models checking is (referring to document: Li Y; Qiu J; Sun KW; Chen Y.Modeling and VerifyingConfiguration in Service Deployment.In SCC ' 06; Pages 238-248,2006) utilize parameter configuration and the incidence relation represented based on the software resource allocation models to retrain checking, but only pay close attention to the constraint detection of resource and parameter configuration in the deployment configuration process.Therefore, current deployment constraint checking to the Web application system is operated in the automaticity aspect that constraint generates and detect and is still waiting to improve, and is difficult to support the automatic generation that retrains, and the constrained type that is covered simultaneously is also comparatively limited.
Summary of the invention
The objective of the invention is to overcome the more weak shortcoming of constraint checking detection automaticity in the above-mentioned prior art; The automatic testing method that retrains in a kind of new Web application deployment is proposed; Can implement deployment constraint comparatively comprehensive, robotization to the deployment scheme model that Web uses detects; Improve the correctness of the deployment scheme of design phase, thus when avoiding actual executions Web application deployment operation since the deployment that causes of running counter to that deployment is retrained fail.
Technical scheme of the present invention is as shown in Figure 1, and Web application deployment constraint automatic testing method comprises following step:
1) set up the deployment scheme model D (Ω) that Web uses=<u, R>, Ω representes that Web uses, and D (Ω) is a doublet, and wherein U is expressed as entity sets { u related in the deployment scheme model 1..., u n, R is expressed as the set of relationship { r between the entity in the deployment scheme model 1..., r m.Said entity sets { u 1..., u nElement u i=<iD, Name, Type, Protocol, InterfaceSet, CapabilitySet, RequirementSet, StateSet, AttrSet>, u i∈ { u 1..., u n, expression Web uses the deployment entity that Ω relates to, and first group component that wherein deployment scheme model entity element is corresponding is sign, title, agreement, interface, the ability of presentation-entity respectively, demand, state and attribute.The element r of said set of relationship j=<iD, Name, Type, SourceID, TargetID, Volume>, r j∈ { r 1..., r m; The relation of inter-entity when representing that with directed edge Web uses Ω and disposes, the quantity that wherein the corresponding first group component of deployment scheme model entity relation sign, title, type, source end entity, destination entity and the type relation representing respectively to concern can instantiation.
The deployment scheme model has been portrayed the final deployable state that desired Web uses, and comprising: the incidence relation of the installation site of assembly, the configuring condition of parameter, inter-entity etc.The deployment scheme model has been confirmed to constitute assembly (as: EJB, WebService), application runtime environment (as: computing machine, Java Virtual Machine, Web container), resource (as: data source, internal memory, thread) and the service entities such as (as: log services, affairs service, monitor service) that Web uses, and model is also confirmed the incidence relation that each entity exists when disposing simultaneously.
2) the deployment scheme model D (Ω) that uses according to Web detects the constraint of Web application deployment, and the constraint of Web application deployment is that the constraint of Web application configuration, application component rely on constraint and Web application component and dispose the combination of describing intrafascicular approximately one or more.Three major types constraint relates to the different levels of deployment scheme in fact; Dispose and describe constraint and dependence constraint and application configuration constraint respectively from the architecture to the parameter configuration; The many aspects that covered the deployment scheme model according to the level and the granularity of " by height on earth, from coarse to fine ".
Detect Web application configuration constraint (Configuration Constraint); Application configuration constraint is more and the most complicated one type of type in the deployment, and major limitation and standard are applied in that the resource that must satisfy when disposing relies on, function/nonfunction requirement and strategy and the best realization considered when disposing.
At first confirm the configuration constraint template,
Second goes on foot the mapping mapping that sets up inter-entity incidence relation in configuration constraint template and the deployment scheme, and (α), CP is the configuration constraint template for R, CP, and R is an incidence relation, and α is a map operation;
The 3rd step traversal deployment scheme model D (Ω); Obtain incidence relation set R and R related entity sets U; (R, CP α) bind corresponding constraint template according to mapping; Each constraint template of deployment scheme instance substitution with traversal obtains obtains the required satisfied configuration constraint set of current Web application deployment.
During the instantiation of configuration constraint template, traversal deployment scheme model obtains incidence relation set R={R Hos, R Dep, R Loc, be subdivided into the relator set of a plurality of types according to the type of R, obtain simultaneously R the information of related entity sets U.
The 4th step converted the configuration constraint set into the OCL linguistic form, adopted the OCL resolver to automatically perform checking one by one.The OCL resolver can provide true or false as a result, representes to satisfy or run counter to corresponding configuration constraint respectively.
The type of said entity comprises application component, running environment, resource and service, i.e. Type ∈ { App, Env, Res, Ser}.
The type of said entity relationship comprises that the position of host's relation (Hosting), entity and inter-entity between dependence (Dependency), Web application component and the running environment of inter-entity concerns the relation of inclusion (Containning) of (Location) and inter-entity.Be Type ∈ { Dep, Hos, Loc, Con}.
Concern that source/purpose sign is corresponding with the entity that current relation is acted in the relationship elements, i.e. SourceID/TargetID=u i.ID, u i∈ { u 1..., u n.
Said configuration constraint comprises unique constraints (Unique Constraint), equivalence constraint (EqualityConstraint), compatible constraint (Compability Constraint), resource constraint (Resource Constraint) and position constraint (Location Constraint).
During the mapping of inter-entity incidence relation, said mapping mode is in setting up configuration constraint template and deployment scheme:
Mapping relations are set up in host's relation in the deployment scheme model and unique constraints or compatible constraint;
Mapping relations are set up in dependence and resource constraint or equivalence constraint;
The position relation is set up mapping relations with position constraint.
Unique constraints has limited disposes the nonrepeatability of entity in specified scope, expression in the deployment scheme model at the deployment entity of same environment/container contents, its sign must be unique, as: the IP address of physical node must be unique in the deployed environment; In the same Enterprise Java Bean container environment, the JNDI of EJB assembly sign is unique etc.The configuration constraint template of said unique constraints is: CP Unique<iD 1..., ID k, Scope>, wherein, ID 1..., ID kFor disposing the uniqueness sign set of entity, Scope=u m∈ U, and common u m.Type=Env.
The configuration constraint template of said equivalence constraint is CP Equal<capability, Requirement>, be meant that two are disposed between the entity, in service and the demand side that entity provides, the corresponding parameters configuration must be consistent.Wherein, Capability refers to that service provides entity that the function corresponding parameters is provided, and Requirement is then corresponding to the configuration parameter of functional requirement side
The configuration constraint template of said resource constraint is CP Resource<capability, ReqSet>, be that finger assembly should be less than the resource quantity that is provided to the demand summation of resource.Wherein, Capability refers to that resource provides total resources that entity provides, and ReqSet is then corresponding to the resource requirement total amount of resource requirement side
Said compatible constraint template is CP Compatible<interfaceSet 1, InterfaceSet 2>, be meant in Web uses the assembly that will dispose and running environment, to have the identical but version of assembly not simultaneously, carry out the replacement of assembly and the stylish assembly of upgrading needs compatibility to be replaced assembly.Wherein, InterfaceSet 1Be the set of interfaces of lowest version assembly, InterfaceSet 2Set of interfaces for the redaction assembly
Said position constraint template is CP Location<u 1, u 2, target, locType>, be meant by the position relation constraint must two application components to be deployed in the same container or must not to be in the same container.Wherein, u 1, u 2∈ U is application component; Target ∈ U is assembly container; LocType is the position relationship type, and { i.e. coexistence maybe can not coexist locType ∈ for Co-Location, anti-location}.
The template definition of above-mentioned each configuration constraint can be referring to table 1
Table 1 configuration constraint template definition table
Figure BSA00000281362300041
Figure BSA00000281362300051
For the mapping relations that have " one-to-many ", the constrained type of then assisting segmentation specifically to be mapped to through the entity type and the property value type at incidence relation two ends.Be mapped as example, mapping (R with host relation and unique constraints Hos, CP Unique, α): R Hos<r 1..., r k>->α CP Unique<iD 1..., ID k, Scope>, R wherein HosHost's set of relationship in the deployment model of expression Web application Ω, CP UniqueExpression unique constraints template, α is the operation of mapping relations.In precondition: 1) R HosIn relation be host type; 2) R HosIn the targetID of all hosts relation identical, promptly all belong to R HosThe host of set concerns that institute's application associated assembly all is deployed in the same targeted environment.Carry out the map operation that α representes: 1) obtain set R HosIn all concern the sign of the source application component of r, set up ID 1..., ID k2) obtain the running environment entity information based on r.targetID, set up mapping with Scope.About the mapping of other types configuration constraint template and incidence relation referring to table 2.
The mapping table of table 2 configuration constraint template and incidence relation
Can also detect application component and rely on constraint according to the deployment scheme model D (Ω) of Web application:
At first with deployment scheme D (Ω) abstract be digraph G, the node of digraph G is represented entity, directed edge is represented the dependence of inter-entity, whether traversal digraph G detects G satisfies and relies on constraint.
The Web application component relies on constraint and constitutes the dependence between application component in order to standard, avoids occurring relying on conflict.Rely on conflict and refer to constitute the call relation of interdependence or the circulation dependence that cause exist assembly of a plurality of assemblies of Web application owing to function and interface.That is, use Ω, r for Web i, r j∈ R, { r i, r j| r i.Type=r j.Type=Dep ∧ r i.SourceID=r j.TargetID ∧ r j.SourceID=r i.TargetID, i ≠ j}; Or r 1..., r k∈ R, k>2, { r 1..., r k| r i.TargetID=r I+1.SourceID ∧ r k.TargetID=r 1.SourceID, i=1..k-1}.Dependence conflict for above-mentioned definition; Web is used the abstract digraph G of deployment scheme model of Ω for forming by node (entity is disposed in expression) and directed edge (expression dependence Dep); Detect G based on the figure ergodic algorithm and whether have loop P; If there is loop, then think to exist dependence to conflict and run counter to dependence to retrain.
Detect method that application component relies on constraint and be at first and to be digraph G with deployment scheme D (Ω) is abstract, the node of digraph G represent entity, and directed edge represent the dependence of inter-entity, and whether traversal digraph G detects G satisfies dependence and retrain.
The method that detects Web application component dependence constraint is:
It is 0 node set Set (a) that A, traversal G find out-degree;
B, judgement Set (a) are not empty, from Set (a), take out a node u arbitrarily;
C, node u is deleted from G;
D, find among the G all nodes that rely on u, the out-degree of these nodes is subtracted 1;
E, the newly-generated G of continuation traversal are empty until Set (a), whether judge G also for empty, for sky shows the satisfied constraint that relies on, otherwise, show to exist to rely on and conflict.
Can also detect the Web application component and dispose the description constraint: the content of deployment descriptor file and deployment of components bag is compared according to the deployment scheme model D (Ω) of Web application.Dispose and describe institutional framework and the content that constraint is disposed bag in order to various components in the standard Web application; Detection for this type of constraint serves as to detect foundation with the deployment descriptor file of Web application component mainly; Through carrying out the comparison of deployment of components bag content and deployment descriptor file, to disposing running counter to of constraint described from institutional framework and the content integrity aspect discovery deployment of components bag of disposing bag.
Good effect of the present invention is:
Adopt method of the present invention; Can be after accomplishing Web application deployment scheme Model Design; Based on the deployment scheme model deployment constraint of polytype, a plurality of aspects is implemented to detect automatically; Use for after the running counter to of the deployment constraint that is comprised detecting current Web, the modification that can locate and point out the user to carry out Web application deployment scheme automatically guarantees disposing satisfying of constraint, thereby guarantees follow-uply to carry out the success that deployment operation is carried out according to deployment scheme.Because the present invention can realize the detection of automatic, eurypalynous deployment constraint, therefore can improve deployment efficient and the correctness that Web uses greatly.
Description of drawings
Fig. 1 is the schematic flow sheet of Web application deployment constraint automatic testing method of the present invention.
Fig. 2 is the use schematic flow sheet of the travelling custom-built system that uses among the embodiment.
Fig. 3 is the structural representation of the travelling custom-built system that uses among the embodiment.
Fig. 4 is the deployment model figure of the travelling custom-built system that uses among the embodiment.
Fig. 5 is the deployment pack arrangement synoptic diagram of the WS-BPEL assembly in the travelling custom-built system that uses among the embodiment.
Fig. 6 is the component dependencies figure of the travelling custom-built system that uses among the embodiment.
Fig. 7 is that the Web application deployment relies on constraint testing process synoptic diagram
Embodiment
Below in conjunction with accompanying drawing and embodiment the present invention is further specified.
It is an online travelling custom-built system TravelPlan that the Web that present embodiment detects uses Ω; This system comprises multiple services such as login authentication, movable selection, hotel reservation, flight reservation, acknowledgement of orders and on-line payment; For the user provides online itinerary customize services one-stop, procedure, be that the complicated Web of a typical distributed uses.Fig. 2 is the concise and to the point use schematic flow sheet of TravelPlan system; The user is at first through the authentication login system; Then can select to climb the mountain or the tour itineraries of island trip; In selected tour itineraries laggard serve a round of liquor to the guests shop and plane ticket booking, calculate required cost and online completion payment according to whole itinerary at last.
Online travelling custom-built system TravelPlan is made up of the polytype a plurality of assemblies of EJB, Web Service, WS-BPEL and Web Module, and structure is as shown in Figure 3.The function of the component list and correspondence is as shown in the table.
The online travelling custom-built system of table 3 TravelPlan module information
Figure BSA00000281362300081
The deployed environment of online travelling custom-built system TravelPlan is made up of 3 station servers and through the network interconnection, the deployment scheme model synoptic diagram of system is referring to Fig. 4, and the deployed environment configuration is as shown in the table.
The online travelling custom-built system of table 4 deployed environment information
Figure BSA00000281362300091
For this embodiment; We expect based on the deployment scheme model; Obtain Web and use the correct deployment scheme that various deployment constraints are satisfied in travelling customization plan; The application configuration constraint that when disposing, need satisfy, dependence constraint and application component are disposed and are described constraint, can use method of the present invention to detect the deployment scheme model and whether satisfy above-mentioned constraint.
Concrete steps are following:
1, sets up Web application deployment scheme model
The deployment scheme model is mainly described Web and is applied in parameter configuration and the interconnection structure of carrying out deployment back application component, running environment and physical resource.Adopt for this embodiment that the defined model of step 1 carries out the modeling of deployment scheme in the content of the present invention.In practical implementation, we adopt the method for model-driven to set up the deployment scheme model of this deployment embodiment, the model definition in the strict follow procedures 1 of the data message that model is portrayed, and Ω (D)=<{ u 1, u 2..., u 17, { r 1, r 2..., r 26}>, wherein entity is represented physical node, flow process container, service container and web container respectively, corresponding flow process, service, EJB assembly, and the relation of assembly.The illustrated mode of direct usefulness that comprises of node and container has represented that the host between the entity concerns r among Fig. 4 1-r 14, r for example 1Expression u 1Comprise u 2, i.e. u 1Run on u 2On, u 1And u 2Between exist the host to concern r 1, r 2-r 14By that analogy, so r 1-r 14No longer represent with line; And r 15-r 24Then represented the dependence that produces owing to interface interchange between the assembly, in Fig. 4, represented r with dotted line with single arrow 25And r 26The position relation of expression inter-module, promptly whether the related both sides' entity of relation satisfies r on the position 25And r 26The status requirement of expression is represented with the solid line of double-head arrow.
2, carry out the automatic detection of Web application deployment constraint
For the deployment scheme model of embodiment, according to the present invention in to disposing the classification of constraint, describe constraint from disposing respectively, rely on constraint and application configuration and retrain several aspects and detect.Can be according to circumstances, detect one or more combination wherein, present embodiment is disposed to retrain to three kinds with granularity according to the level of " by height on earth, from coarse to fine " and is detected.
2.1 the Web application component is disposed the description constraint to be detected; Because embodiment TravelPlan is made up of a plurality of assemblies; And but each assembly all is an independently deployment unit; Therefore detecting actual for the deployment description constraint of using is each assembly to be disposed respectively describe the constraint detection, when all application components all satisfy deployment metadata description separately, then uses to satisfy and dispose constraint specification.
Is that example is disposed description constraint detection for present embodiment with WS-BPEL assembly travelplan.zip, and the deployment pack arrangement of WS-BPEL assembly is as shown in Figure 5, and oncebpel-dd.xml is a deployment descriptor file, and its content is as shown in table 5.According to the method for the invention; With oncebpel-dd.xml is foundation; Detect disposing bag travelplan.zip; The content of deployment descriptor file and deployment of components bag is compared, mainly from the institutional framework of disposing bag with dispose bag the content that comprises whether with deployment descriptor file in content whether consistent several aspect detects, can find that through detecting travelplan.zip satisfies it and disposes to describe and retrain.The detection method of other assemblies is similar with it.
Table 5 oncebpel-dd.xml file content table
Figure BSA00000281362300101
Detect 2.2 the Web application component is relied on constraint, according to method of the present invention, according to the deployment scheme model of Web application TravelPlan, foundation is the dependence between application component wherein, sets up corresponding digraph G=({ 1,2,3; 4,5,6,7,8,9,10; 11}, { a, b, c, d, e; F, g, h, i, j}), as shown in Figure 6.Wherein, 1-11 is a node, and each node serial number is corresponding with the numbering of assembly in the table 3, and a-j is the directed edge between the node, the dependence that exists between the expression assembly.Use the represented concrete testing process of Fig. 7 to carry out the dependence collision detection of Web application component to digraph G:
1) traversal G find out-degree be 0 node set Set (a)=7,8,9,10,11}; Out-degree is defined as the number on the limit of being sent by current specified node.
2) because Set (a) is not empty, from Set (a), take out node u=7;
4) node 7 is deleted from G;
5) finding among the G and to rely on 7 node, be node 5 among the embodiment, and the limit of deletion of node 5 to 7 simultaneously subtracts 1 with 5 out-degree simultaneously, and 5 out-degree is 0 at this moment;
6) through step 1, after 2,3,4,5, G=(1,2,3,4,5,6,8,9,10,11}, a, b, c, d, e, f, g, h, j}), Set (a)=and 8,9,10,11};
7) above-mentioned steps is carried out in circulation, and final Set (a) is empty.
8) judge whether current G is empty, because the G while also is empty, testing process finishes this moment, and judge that embodiment satisfies the dependence constraint, do not exist to rely on conflict.
2.3 constraint detects to the Web application configuration, according to method of the present invention, implementation step is:
1) at first sets up Web application configuration constraint ATL,, then set up the mapping mapping (R of inter-entity incidence relation in configuration constraint template and the deployment scheme in order to storage and management Web application configuration constraint template; CP, α), CP is the configuration constraint template; R is an incidence relation, and α is a map operation; Mapping mode is:
Mapping relations are set up in host's relation in the deployment scheme model and unique constraints or compatible constraint;
Mapping relations are set up in dependence and resource constraint or equivalence constraint;
The position relation is set up mapping relations with position constraint.
2) the deployment model D (Ω) of traversal embodiment TravelPlan obtains set of relationship R={R Hos, R Dep, R Loc, U={u 1, u 2..., u 17.Wherein, R Hos=<r 1, r 2, r 3..., r 14>, be expressed as the host's set of relationship among the TravelPlan, R Dep={ r 15, r 16..., r 24, R Loc=<r 25, r 26>, r 1-r 26Be the relationship example in the TravelPlan deployment model, u 1-u 17Be the deployment entity in the TravelPlan deployment model.
3) with r 1, r 2, r 3, r 4, r 5Be example, it concerns that destination node is entity u 4(that is, Web Service container OnceSE2.0), and relationship type is the host and concerns Hosting, r 1-r 5Source node be u 6, u 7, u 8, u 9, u 10, type is web Service.Therefore, can see Web Service assembly (u according to the analyze relationship of model information 6-u 10) be deployed in the same Web Service container OnceSE2.0 (u under the same physical node (IP:133.133.133.40) 4) in, it is designated IP+port=133.133.133.40:8080, and specifying information is as shown in the table.
Host's relation that table 6 Web Service assembly is relevant
Figure BSA00000281362300111
Figure BSA00000281362300121
4), adopt mapping (R according to configuration constraint template of having set up and the mapping between the relationship type Hos,CP Unique, α) defined mapping relations obtain among the embodiment based on constraint template CP Unique<iD 1..., ID k, Scope>Web Serviceu 6-u 10Relevant unique constraints instance:
CP unique<r 1.SourceID,r 2.SourceID,r 3.SourceID,r 4.SourceID,r 5.SourceID,r.TargetID>
Because the target identification of all host's relations is consistent, promptly be deployed in the same targeted environment container, so r.TargetID representes r 1-r 5The object representation of any host relation.This unique constraints case representation: use TravelPlan for Web, be deployed in 5 Web Service assemblies among the OnceSE2.0, its sign must be unique.
5) unique constraints of following instantiation converts the formalization constraint specification with the OCL language representation into; Adopt the OCL resolver to verify; And return the checking result of True or False; Return True and represent that deployment scheme satisfies current constraint, False representes that then running counter to current constraint appears in deployment scheme.For present embodiment, the OCL that above-mentioned unique constraints is converted to is described as as shown in table 7:
Table 7 OCL code table
Figure BSA00000281362300122
Adopt in the present embodiment the OCL resolver Dresden OCL2 that increases income (referring to: http://dresden-ocl.sourceforge.net) unique constraints of describing based on OCL is verified and obtains accordingly result to be True; When promptly 5 Web Service were deployed in the same running environment in the present embodiment, its sign satisfied unique constraints.
Similar with unique constraints, the constraint that can carry out other types such as equivalence constraint, position constraint for embodiment TravelPlan equally generates and checking.In Fig. 4, concern r 20Be example, because r 20Be dependence, and r 20Related source node (u 6) and destination node (u 13) service that provides and the type of demand are character string, so r 20Corresponding constraint template is mapped as equivalence constraint CP Equal<capability, Requirement>, will retrain template and r through the operation of correspondence 20, u 6And u 13Information combine, obtain corresponding examples of constraints CP Equal<' LoginService ', ' LoginService ’>For the r that concerns among Fig. 4 26, because r 26Be the position relation, so r 26Corresponding constraint template is mapped as position constraint CP Location<u 1, u 2, target, locType>, the operation through correspondence combines the position constraint template with information in the deployment scheme model, obtain corresponding examples of constraints CP Location<u 16, u 17, u 12, ' Co-Location ’>Convert all types of constraints of above-mentioned instantiation into formalization constraint specification, adopt the OCL resolver to verify,, can confirm whether deployment scheme satisfies current constraint according to the checking result of True that returns or False with the OCL language representation.
Although do not have compatible constraint and resource constraint in the present embodiment; Whether but those skilled in the art are according to the method for the invention between the host in deployment scheme model relation and the compatible constraint and set up mapping relations between dependence and the resource constraint, satisfy and retrain thereby detect the assembly that will dispose.

Claims (13)

1.Web application deployment constraint automatic testing method may further comprise the steps;
1) set up the deployment scheme model D (Ω) that Web uses=<u, R>, wherein Ω is that Web uses, U is entity sets { u 1..., u n, the type of said entity comprises application component, running environment, resource and service; R is the incidence relation set { r between the entity 1..., r m;
2) the deployment scheme model of using according to Web, detect the constraint of Web application configuration:
At first confirm the configuration constraint template,
Second goes on foot the mapping mapping that sets up inter-entity incidence relation in configuration constraint template and the deployment scheme, and (α), CP is the configuration constraint template for R, CP, and R is the incidence relation set, and α is a map operation;
The 3rd step traversal deployment scheme model D (Ω); Obtain incidence relation set R and R related entity sets U; (R, CP α) bind corresponding constraint template based on mapping mapping; Each constraint template of deployment scheme instance substitution with traversal obtains obtains the required satisfied configuration constraint set of current Web application deployment;
The 4th step converted the configuration constraint set into the OCL linguistic form, adopted the OCL resolver to automatically perform checking one by one.
2. Web application deployment constraint automatic testing method according to claim 1 is characterized in that step 2) also comprise according to the deployment scheme model, detect the Web application component and rely on constraint:
With deployment scheme model D (Ω) abstract be digraph G, the node of digraph G is represented entity, directed edge is represented the dependence of inter-entity;
Traversal digraph G detects G and whether satisfies the dependence constraint.
3. Web application deployment constraint automatic testing method according to claim 1 and 2 is characterized in that step 2) also comprise according to the deployment scheme model, detect the Web application component and dispose the description constraint:
The content of deployment descriptor file and deployment of components bag is compared.
4. Web application deployment constraint automatic testing method according to claim 1 is characterized in that the type of said entity comprises application component, running environment, resource and service.
5. Web application deployment according to claim 1 constraint automatic testing method, the type that it is characterized in that said entity associated relation comprise that the position of host's relation, entity and inter-entity between dependence, Web application component and the running environment of inter-entity concerns and the relation of inclusion of inter-entity.
6. Web application deployment constraint automatic testing method according to claim 5 is characterized in that said configuration constraint comprises unique constraints, equivalence constraint, compatible constraint, resource constraint and position constraint.
7. Web application deployment constraint automatic testing method according to claim 6 is characterized in that said mapping mode is:
Mapping relations are set up in host's relation in the deployment scheme model and unique constraints or compatible constraint;
Mapping relations are set up in dependence and resource constraint or equivalence constraint;
The position relation is set up mapping relations with position constraint.
8. Web application deployment constraint automatic testing method according to claim 7 is characterized in that the configuration constraint template of said unique constraints does; CP Unique<iD 1..., ID k, Scope>, wherein, ID 1..., ID kBe the uniqueness sign set of entity, Scope=u m∈ U.
9. Web application deployment constraint automatic testing method according to claim 7 is characterized in that the configuration constraint template of said equivalence constraint is CP Equal<capability 1, Requirement>, Capability 1Refer to that service provides the parameter of function that entity provides, Requirement is then corresponding to the configuration parameter of functional requirement entity.
10. Web application deployment constraint automatic testing method according to claim 7, the configuration constraint template that it is characterized in that said resource constraint is CP Resource<capability 2, ReqSet>, Capability 2Refer to the total resources that resource provides entity to provide, ReqSet is the resource requirement total amount of resource requirement entity.
11. Web application deployment constraint automatic testing method according to claim 7 is characterized in that said compatible constraint template is CP Compatible<interfaceSet 1, InterfaceSet 2>, InterfaceSet 1Be the set of interfaces of lowest version assembly, InterfaceSet 2Set of interfaces for the redaction assembly.
12. Web application deployment constraint automatic testing method according to claim 7 is characterized in that said position constraint template is CP Location<u 1, u 2, target, locType>, u 1, u 2Be application component; Target is an assembly container; LocType is the position relationship type.
13. Web application deployment constraint automatic testing method according to claim 2, whether the satisfied method that relies on constraint does to it is characterized in that detecting G;
It is 0 node set Set (a) that A, traversal G find out-degree;
B, judgement Set (a) are not empty, from Set (a), take out a node u arbitrarily;
C, node u is deleted from G;
D, find among the G all nodes that rely on u, the out-degree of these nodes is subtracted 1;
E, the newly-generated G of continuation traversal are empty until Set (a), whether judge G also for empty, for sky shows the satisfied constraint that relies on, otherwise, show to exist to rely on and conflict.
CN2010102893648A 2010-09-21 2010-09-21 Deployment constraint automatic detection method for Web application Expired - Fee Related CN101957794B (en)

Priority Applications (1)

Application Number Priority Date Filing Date Title
CN2010102893648A CN101957794B (en) 2010-09-21 2010-09-21 Deployment constraint automatic detection method for Web application

Applications Claiming Priority (1)

Application Number Priority Date Filing Date Title
CN2010102893648A CN101957794B (en) 2010-09-21 2010-09-21 Deployment constraint automatic detection method for Web application

Publications (2)

Publication Number Publication Date
CN101957794A CN101957794A (en) 2011-01-26
CN101957794B true CN101957794B (en) 2012-05-23

Family

ID=43485132

Family Applications (1)

Application Number Title Priority Date Filing Date
CN2010102893648A Expired - Fee Related CN101957794B (en) 2010-09-21 2010-09-21 Deployment constraint automatic detection method for Web application

Country Status (1)

Country Link
CN (1) CN101957794B (en)

Families Citing this family (10)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN104915238B (en) * 2015-06-29 2018-03-30 中国科学院软件研究所 A kind of configuration parameter association determination method of Web applications
CN108287997B (en) * 2018-01-10 2020-07-31 武汉斗鱼网络科技有限公司 Host environment identification method, device, medium and equipment of target application program
CN108429787B (en) * 2018-01-30 2021-06-08 中经社控股有限公司 Container deployment method and device, computer storage medium and terminal
CN109471624B (en) * 2018-11-21 2021-12-24 中国航空无线电电子研究所 Shared data model control system based on GOSAA and data architecture generation method
CN109783870B (en) * 2018-12-18 2020-12-29 北京航空航天大学 Human-computer interaction risk scene identification method based on formal verification
CN111400073B (en) * 2020-03-10 2021-08-20 中国科学院软件研究所 Formalized system model conversion and reliability analysis method from automobile open architecture system to unified software and hardware representation
CN111782523B (en) * 2020-06-29 2024-06-04 深圳赛安特技术服务有限公司 Cloud service deployment testing method and device, electronic equipment and storage medium
CN113504972A (en) * 2021-07-26 2021-10-15 京东科技控股股份有限公司 Service deployment method and device, electronic equipment and storage medium
CN114328270B (en) * 2022-01-20 2024-05-03 重庆长安汽车股份有限公司 OTA upgrade detection method based on SOA service and readable storage medium
CN116225464B (en) * 2023-05-09 2023-07-11 霖济智云科技(苏州)有限公司 Rapid deployment method of platform

Family Cites Families (4)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
US6912710B2 (en) * 2002-01-31 2005-06-28 International Business Machines Corporation Round-trip maintenance of software configuration
CN1928814A (en) * 2006-07-28 2007-03-14 中国科学院软件研究所 Organization entity capacity based software process mode construction method and system
CN101453367B (en) * 2007-11-30 2011-12-28 华为技术有限公司 Software deployment method and system, software deployment server and user server
CN101425010B (en) * 2008-12-03 2011-01-12 中国人民解放军国防科学技术大学 Deploy and collocation method under general computation surroundings

Also Published As

Publication number Publication date
CN101957794A (en) 2011-01-26

Similar Documents

Publication Publication Date Title
CN101957794B (en) Deployment constraint automatic detection method for Web application
US8677317B2 (en) Simplified deployment modeling
US8959481B2 (en) Determining system level dependencies
JP5982366B2 (en) Systems and methods for private cloud computing
CN109710243B (en) Block chain development method, device, server and medium based on visual platform
US8037471B2 (en) Systems and methods for constructing relationship specifications from component interactions
US7684964B2 (en) Model and system state synchronization
CN105793820A (en) Methods and apparatus to manage virtual machines
CN109240900A (en) Block chain network service platform and its intelligent contract detection method, storage medium
US11226813B2 (en) System and method for automated source code generation to provide service layer functionality for legacy computing systems in a service-oriented architecture
Quinton et al. SALOON: a platform for selecting and configuring cloud environments
US8463634B2 (en) Efficient system for realizing business process families using model-driven techniques
JP6673359B2 (en) System construction support system, method and program
CN107885551A (en) A kind of service arrangement method, apparatus, computer-readable recording medium and storage control
US20140250306A1 (en) Decision service manager
CN102007756A (en) Method and apparatus for dynamic provisioning in data processing environment
TW201913374A (en) Automated continuous integration system and method under microservice software development infrastructure including a code review system, a code security check module, an automatic test component, and a deployment function module
CN117311718A (en) Domestic GIS application development method and system
da Costa Cordeiro et al. ChangeLedge: Change design and planning in networked systems based on reuse of knowledge and automation
US20130024834A1 (en) Managing an application development environment
Singh et al. An architecture for developing aspect-oriented web services
Sferruzza et al. A model-driven method for fast building consistent web services in practice
Becha et al. Consumer-centric non-functional properties of soa-based services
Glöckner et al. Privacy preserving BPMS for collaborative BPaaS
Wang et al. An aspect-oriented UML tool for software development with early aspects

Legal Events

Date Code Title Description
C06 Publication
PB01 Publication
C10 Entry into substantive examination
SE01 Entry into force of request for substantive examination
C14 Grant of patent or utility model
GR01 Patent grant
CF01 Termination of patent right due to non-payment of annual fee

Granted publication date: 20120523