Skip to Content
Java持续交付
book

Java持续交付

by Daniel Bryant, Abraham Marín-Pérez
November 2019
Beginner to intermediate
406 pages
9h 21m
Chinese
Publishing House of Electronics Industry
Content preview from Java持续交付
自动化构建过程
63
y
能够支持不同的配置(开发配置或者生产配置)
y
适应不断变化的产品需求
y
构建自动化
多年以来,构建工具经过不断发展,已经变得愈加复杂,功能也愈加丰富。这为开发人
员提供了一个有利的补充,例如帮助他们管理项目的依赖关系,以及将编译和打包以外
的任务自动化。通常,构建工具需要两个主要的组件 :一个构建脚本,一个能够处理构
建脚本的可执行程序。构建脚本应该是与平台无关的 :它们不需要修改内容,只需要更
换构建工具的二进制文件,就可以在
Windows
Linux
Mac
等操作系统上运行。在构
建脚本中,依赖关系的管理、相关项目的结构(模块化)和构建过程本身等概念都非常
重要。现代化的构建工具通过以下几种方式来管理这些概念
y
构建依赖
y
外部依赖
y
多模块项目
y
仓库
y
插件
y
发布和公开构件
在学习流行的构建工具之前,你首先需要掌握前面所介绍的这些概念。
构建依赖
在构建工具提供依赖管理之前,
Java
应用程序中对第三方库的使用,通常是通过手动复
制类文件和
JAR
文件来完成的。可想而知,这不仅耗时而且容易出错,关键是它让开发
人员的工作变得更加困难,因为在装配或者调试应用程序的时候,他们需要花费很多时
间和精力来熟悉代码库中所有的组件(以及组件的对应版本)。
大多数构建工具都有自己处理依赖以及依赖之间差异的方式。但是,有一点是一样的
每个依赖项或者依赖库都有一个唯一的标识,由类型、名称和版本号组成。在
Maven
Gradle
中,这通常被称为依赖项的
G AV
:组
ID
、构件
Become an O’Reilly member and get unlimited access to this title plus top books and audiobooks from O’Reilly and nearly 200 top publishers, thousands of courses curated by job role, 150+ live events each month,
and much more.

Read now

Unlock full access

More than 5,000 organizations count on O’Reilly

AirBnbBlueOriginElectronic ArtsHomeDepotNasdaqRakutenTata Consultancy Services

QuotationMarkO’Reilly covers everything we've got, with content to help us build a world-class technology community, upgrade the capabilities and competencies of our teams, and improve overall team performance as well as their engagement.
Julian F.
Head of Cybersecurity
QuotationMarkI wanted to learn C and C++, but it didn't click for me until I picked up an O'Reilly book. When I went on the O’Reilly platform, I was astonished to find all the books there, plus live events and sandboxes so you could play around with the technology.
Addison B.
Field Engineer
QuotationMarkI’ve been on the O’Reilly platform for more than eight years. I use a couple of learning platforms, but I'm on O'Reilly more than anybody else. When you're there, you start learning. I'm never disappointed.
Amir M.
Data Platform Tech Lead
QuotationMarkI'm always learning. So when I got on to O'Reilly, I was like a kid in a candy store. There are playlists. There are answers. There's on-demand training. It's worth its weight in gold, in terms of what it allows me to do.
Mark W.
Embedded Software Engineer

You might also like

Python机器学习案例精解

Python机器学习案例精解

Posts & Telecom Press, Yuxi (Hayden) Liu
Java性能优化实践:JVM调优策略、工具与技巧

Java性能优化实践:JVM调优策略、工具与技巧

Benjamin J. Evans, James Gough, Chris Newland
Python和NLTK实现自然语言处理

Python和NLTK实现自然语言处理

Posts & Telecom Press, Nitin Hardeniya
C++语言导学(原书第2版)

C++语言导学(原书第2版)

本贾尼 斯特劳斯特鲁普

Publisher Resources

ISBN: 9787121374425