Supporting for Software Engineering Environment
Reprinted by the author:
By: 88250
Blog: http:/blog.csdn.net/dl88250
MSN & Gmail & QQ: DL88250@gmail.com
Int
Roduction
- Introduction
- Abstract
- Construction
- Project Management
- Dependencies management
- SCM
- Helpful practices
- Continuous Integration
Abstract
Software Engineering Environment involves the processes, approaches
And tools of a software project life cycle with human-centric. This
Article introduces the advantages of two open source and stable tools,
And reflects the basic, simple and critical factors that affects on
Development of a software project.
Construction
Maven2
Is
Project management and comprehension Tool Based on Ant. Generally
Speaking, by using maven2 (Maven for short) takes the following
Advantages:
IDE independent debugging, testing, building and deployment.
It
Means developers can code using the best suitable development
Environments. For example, Java programmer can use eclipse, jdeveloper,
Or netbeans to write codes, and HTML/CSS/JavaScript programmers can
Use other development tools for convenience. The project building is
Only relies on Maven's build configuration and independent of IDE.
Makes the continuous integration easily.
A
Maven project can configures the source repository and integration tool
Easily. For example, when an artifact Code completed, we can publish
The artifact into a integration tool (such as Hudson) to build and
Finally put the artifact into test server or put it into Maven
Repository as other project dependency.
Simplicity of extension for different type projects.
Maven
Can mizmizes plugins for the specified project on demand. Some
Specified projects need to append process in the specified construct
Phase, such as when compiling source codes, may need to check
Quality of source codes by using some static or dynamic analysis tools;
After compilation, may need to append the project license on the source
Files; and after the whole construction, project manager may want
Take a glance at a project report for getting how many tests fail/
Succeed, how many source codes are below standard.
Project Management
Maven depicts projects using the object-oriented approach. A project has its ownPom. xml
For representing the project's structure, sub-projects, referenced
Projects (as dependencies) for instance. The relation between these
Projects are equivalent to the object-oriented approach's basically.
So, it takes some advantages of object model, such as inheritance and
Polymorphism.
The Project Management of Maven can not reach some
Factors (Plan, cost, risk, time, etc) of project management theories.
In other words, Maven's project management focus on the structure and
Construction behaviors of a software project.
Dependencies management
In modern software development, the Dependencies
Management is very significant and very difficult. For example, our
Current projects depend on some third-part libraries, and each
Dependency has its ownVersion
AndRuntime Dependencies
.
Maven can automatically downloads these libraries, resolves and
Downloads their runtime dependencies respectively. It takes
Following advantages:
Make the automatic project building and integration simplest.
Obviusly,
Resolving the runtime dependencies are very dull and complicated.
Fortunately, the most dependencies currently in the world have Maven
Packages, then Maven cocould decide the Library's dependency which is
Made by the Library's authors or packager.
MakeControl
Of dependencies change easy.
Frequently
The Libraries project depends on need to be upgraded. The upgrade is
From an older version to a newer version. According to the above
Advantage, the operation is very simple, just need to modify
Version number of the dependencies.
Scoping for every dependency becomes more easier.
This
Is a very typical case in test libraries. Commonly, we do not Package
JUnit. jar into production. So, scoping the dependencies will help
Project Building and release. In practice, scoping dependencies can
Keep the consistence of software impact ect. For example, we selected
Eclipse as the project IDE and using JPA for persistence and Hibernate
As the JPA implementation. After the phase effecect verification,
Proved JPA is enough to use and never need to use its delegation.
Someone use hibernate annotations to annotated entities and others use
JPA annotations to do that in deed. It breaks the consistence
Design, make the maintainers drop into mud. By using Maven Dependencies
Management, it never be happen, just identifies the scope
Hibernate-annotation.jar to runtime.
SCM
Software
Configuration Management (SCM) is focus on the management of changes
Software. Commonly, we use source version control system to track
Changes.
Helpful practices
Basically, a software project source repository shocould has three folders:Trunk
,Branch
AndTag
.
Trunk tracks the sources of current project's version. Branch tracks
The sources of current project's branches, a fully-reimplementation
Version, a upgrade version, etc, for instance. Tag Save the released
Sources of the project's several versions.
TheSource
We
Define that is source code commonly. Strictly speaking, a source
Repository shocould not include any hard modified binary data, the reason
Is that different binary data can not compare the differences easily,
It can only compare manually by human. But so far developers commit
The project's binary dependencies into source repository just
Convenience. The dependencies shoshould be resolved out side source
Repository. This point is very important to the automationFurther
Development and maintenance, otherwise the binary dependencies is managed by another tools, Maven for instance.
Another problem in multiple humans development collaboratively isConflict
.
To resolve conflicts, so far developers just to delete the conflicted
Source file and commit his/her own version. This is not the problem
That whether the usage of the source version control client developers
Got familiar or not, rather than the philosophy of why and how
Identify the configuration item. The configuration items areCore Source
Of software process management and improvement.
Continuous Integration
Hudson
Is an extensible
Continuous integration engine like cruisecontrol. But it more easily
Configure and extend. It can configures some build strategies, such
Build condition (sources commit, time step, etc). And a friendly
Integration status reporting by using dashboard.
See the following continuous integration status come from JBoss.
The continuous integration has the following advantages:
- Exposes the problems of the project as soon as possible.
Each
Integration has it own 'health' or/'weate' which quantifies
Producticategory of the team. Once encounters an integration fail, every
Member in the team will receive a mail that notifies the Member what,
When, where is it happen. Helps the team to fix the issue ASAP.
- Combines team members together into a more efficient team.
Here
Is a case: a programmers finished the development of a module, and then
Commit the codes into source repository. The CI tool will get Source
From source repository and get start a build. Once the build passed
Tester will receive a mail from CI tool that tells the tester it is
Time to test this build.
Conclusion
This article introduced some philosophies
Software Engineering with maven2 and Hudson. Some of these practices
And principles are such simple, but it is efficient if combined them on
A organized way. To build a helpful Software Engineering supporting
Environment is very sophisticated and constructive, and not only relies
On tools but also depends on human collaboration. I always trust that
Is a team shoshould to select and adapt the environment rather then do
Nothing.
Todo: issue tracking, Software Process Management
Edit this page (if you have permission)
|
Google Docs -- web word processing, presentations and spreadsheets.