Nexus和Maven有什么区别? [英] What is the difference between Nexus and Maven?

查看:513
本文介绍了Nexus和Maven有什么区别?的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

Nexus Maven 有什么区别?

Maven 的基本使用情况是什么?仅考虑 Nexus 的方案怎么样?以及当我想同时使用两者时的外观?

What is a basic scenario of usage only Maven? What about a scenario considering only Nexus? And how it looks when I want to use both?

推荐答案

Sonatype Nexus Apache Maven 是两个软件,它们通常可以一起工作,但是它们执行的工作却截然不同. Nexus提供了一个存储库,而Maven使用了一个存储库来构建软件.

Sonatype Nexus and Apache Maven are two pieces of software that often work together but they do very different parts of the job. Nexus provides a repository while Maven uses a repository to build software.

以下引述来自"什么是Nexus? ":

Nexus管理开发所需的软件工件".如果您开发软件,则您的内部版本可以从Nexus下载依赖项,并且可以将工件发布到Nexus,从而创建一种在组织内共享工件的新方法.尽管Central仓库一直为开发人员提供了极大的便利,但是您不应该直接使用它.您应该使用Nexus代理Central并维护自己的存储库,以确保组织内部的稳定性. 使用Nexus,您可以从一个位置完全控制对组织中每个工件的访问和部署.

Nexus manages software "artifacts" required for development. If you develop software, your builds can download dependencies from Nexus and can publish artifacts to Nexus creating a new way to share artifacts within an organization. While Central repository has always served as a great convenience for developers you shouldn't be hitting it directly. You should be proxying Central with Nexus and maintaining your own repositories to ensure stability within your organization. With Nexus you can completely control access to, and deployment of, every artifact in your organization from a single location.

这是" Maven和Nexus Pro的相互引用"说明Maven如何使用存储库:

And here is a quote from "Maven and Nexus Pro, Made for Each Other" explaining how Maven uses repositories:

Maven通过检索构建应用程序所需的工件并将构建过程的结果部署到存储库中来利用存储库的概念. Maven使用结构化存储库的概念,因此可以检索组件以支持构建.这些组件或依赖项包括库,框架,容器等.Maven可以识别存储库中的组件,了解它们的依赖关系,检索成功构建所需的所有组件,并在构建完成后将其输出部署回存储库中.

Maven leverages the concept of a repository by retrieving the artifacts necessary to build an application and deploying the result of the build process into a repository. Maven uses the concept of structured repositories so components can be retrieved to support the build. These components or dependencies include libraries, frameworks, containers, etc. Maven can identify components in repositories, understand their dependencies, retrieve all that are needed for a successful build, and deploy its output back to repositories when the build is complete.

因此,当您要同时使用两者时,您将拥有一个由Nexus管理的存储库,而Maven将访问该存储库.

So, when you want to use both you will have a repository managed by Nexus and Maven will access this repository.

这篇关于Nexus和Maven有什么区别?的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

查看全文
登录 关闭
扫码关注1秒登录
发送“验证码”获取 | 15天全站免登陆