设置本地Nexus存储库并从Maven部署WAR文件

Maven Central充当中央存储库管理器,其中二进制工件由不同的团队/公司/个人上载并与世界其他地方共享。 就像github和其他对源代码控制非常有效的源代码存储库一样,这些存储库管理器还充当您自己生成的二进制工件的部署目标。

设置本地存储库管理器具有多个优点。 最主要的是,它们充当Maven Central之间的高度可配置代理,因此每个人都不必从中央存储库下载所有依赖项。 另一个主要原因是要控制团队内部临时生成的工件。 使用存储库管理器的原因详细说明了完整的好处。

本技术提示将展示如何设置本地Nexus信息库管理器,以及将工件(快照和发行版)推送到其中。

让我们开始吧!

安装和配置本地Nexus存储库

  1. 下载并解压缩最新的Nexus OSS 。 默认管理员的登录名/密码是admin / admin123。 默认的部署登录名/密码是Deployment / deployment123。
  2. 以以下方式启动Nexus:
    nexus-2.11.2-03> ./bin/nexus start
    Starting Nexus OSS...
    Started Nexus OSS.

    日志可以看成是:

    nexus-2.11.2-03> tail -f logs/wrapper.log

    或者,您可以从控制台本身中显示日志的位置开始:

    nexus-2.11.2-03> ./bin/nexus console
    Running Nexus OSS...
    wrapper  | --> Wrapper Started as Console
    wrapper  | Launching a JVM...
    jvm 1    | Java HotSpot(TM) 64-Bit Server VM warning: ignoring option MaxPermSize=192m; support was removed in 8.0
    jvm 1    | Wrapper (Version 3.2.3) http://wrapper.tanukisoftware.org
    jvm 1    |   Copyright 1999-2006 Tanuki Software, Inc.  All Rights Reserved.
    jvm 1    | . . .jvm 1    | 2015-02-24 00:17:28,706-0800 INFO  [jetty-main-1] *SYSTEM org.sonatype.nexus.bootstrap.jetty.JettyServer - Running
    jvm 1    | 2015-02-24 00:17:28,706-0800 INFO  [WrapperListener_start_runner] *SYSTEM org.sonatype.nexus.bootstrap.jetty.JettyServer - Started
    jvm 1    | 2015-02-24 00:17:30,713-0800 INFO  [ar-4-thread-3] *SYSTEM org.sonatype.nexus.proxy.maven.routing.internal.ManagerImpl - Updated and published prefix file of "Public Repositories" [id=public]
  3. 将Maven设置文件(〜.m2 / settings.xml)配置为包括以下默认部署用户名和密码:
    <?xml version="1.0" encoding="UTF-8" standalone="no"?>
    <settings xmlns="http://maven.apache.org/SETTINGS/1.1.0" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xsi:schemaLocation="http://maven.apache.org/SETTINGS/1.1.0 http://maven.apache.org/xsd/settings-1.1.0.xsd"><servers><server><id>deployment</id><username>deployment</username><password>deployment123</password></server></servers>
    </settings>

将快照部署到本地Nexus存储库

  1. 从github.com/javaee-samples/javaee7-simple-sample签出一个简单的Java EE示例。
  2. 通过以下方式创建WAR文件并将其部署到本地Nexus存储库中:
    javaee7-simple-sample> mvn deploy
    [INFO] Scanning for projects...
    [INFO]                                                                         
    [INFO] ------------------------------------------------------------------------
    [INFO] Building javaee7-simple-sample 1.0-SNAPSHOT
    [INFO] ------------------------------------------------------------------------
    [INFO] 
    [INFO] --- maven-resources-plugin:2.6:resources (default-resources) @ javaee7-simple-sample ---
    [INFO] Using 'UTF-8' encoding to copy filtered resources.
    [INFO] Copying 0 resource
    [INFO] 
    [INFO] --- maven-compiler-plugin:3.1:compile (default-compile) @ javaee7-simple-sample ---
    [INFO] Changes detected - recompiling the module!
    [INFO] Compiling 4 source files to /Users/arungupta/workspaces/javaee7-simple-sample/target/classes
    [INFO] 
    [INFO] --- maven-resources-plugin:2.6:testResources (default-testResources) @ javaee7-simple-sample ---
    [INFO] Using 'UTF-8' encoding to copy filtered resources.
    [INFO] skip non existing resourceDirectory /Users/arungupta/workspaces/javaee7-simple-sample/src/test/resources
    [INFO] 
    [INFO] --- maven-compiler-plugin:3.1:testCompile (default-testCompile) @ javaee7-simple-sample ---
    [INFO] No sources to compile
    [INFO] 
    [INFO] --- maven-surefire-plugin:2.12.4:test (default-test) @ javaee7-simple-sample ---
    [INFO] No tests to run.
    [INFO] 
    [INFO] --- maven-war-plugin:2.3:war (default-war) @ javaee7-simple-sample ---
    [INFO] Packaging webapp
    [INFO] Assembling webapp [javaee7-simple-sample] in [/Users/arungupta/workspaces/javaee7-simple-sample/target/javaee7-simple-sample]
    [INFO] Processing war project
    [INFO] Copying webapp resources [/Users/arungupta/workspaces/javaee7-simple-sample/src/main/webapp]
    [INFO] Webapp assembled in [33 msecs]
    [INFO] Building war: /Users/arungupta/workspaces/javaee7-simple-sample/target/javaee7-simple-sample.war
    [INFO] 
    [INFO] --- maven-install-plugin:2.4:install (default-install) @ javaee7-simple-sample ---
    [INFO] Installing /Users/arungupta/workspaces/javaee7-simple-sample/target/javaee7-simple-sample.war to /Users/arungupta/.m2/repository/org/javaee7/sample/javaee7-simple-sample/1.0-SNAPSHOT/javaee7-simple-sample-1.0-SNAPSHOT.war
    [INFO] Installing /Users/arungupta/workspaces/javaee7-simple-sample/pom.xml to /Users/arungupta/.m2/repository/org/javaee7/sample/javaee7-simple-sample/1.0-SNAPSHOT/javaee7-simple-sample-1.0-SNAPSHOT.pom
    [INFO] 
    [INFO] >>> wildfly-maven-plugin:1.0.2.Final:deploy (default) > package @ javaee7-simple-sample >>>
    [INFO] 
    [INFO] --- maven-resources-plugin:2.6:resources (default-resources) @ javaee7-simple-sample ---
    [INFO] Using 'UTF-8' encoding to copy filtered resources.
    [INFO] Copying 0 resource
    [INFO] 
    [INFO] --- maven-compiler-plugin:3.1:compile (default-compile) @ javaee7-simple-sample ---
    [INFO] Nothing to compile - all classes are up to date
    [INFO] 
    [INFO] --- maven-resources-plugin:2.6:testResources (default-testResources) @ javaee7-simple-sample ---
    [INFO] Using 'UTF-8' encoding to copy filtered resources.
    [INFO] skip non existing resourceDirectory /Users/arungupta/workspaces/javaee7-simple-sample/src/test/resources
    [INFO] 
    [INFO] --- maven-compiler-plugin:3.1:testCompile (default-testCompile) @ javaee7-simple-sample ---
    [INFO] No sources to compile
    [INFO] 
    [INFO] --- maven-surefire-plugin:2.12.4:test (default-test) @ javaee7-simple-sample ---
    [INFO] No tests to run.
    [INFO] Skipping execution of surefire because it has already been run for this configuration
    [INFO] 
    [INFO] --- maven-war-plugin:2.3:war (default-war) @ javaee7-simple-sample ---
    [INFO] Packaging webapp
    [INFO] Assembling webapp [javaee7-simple-sample] in [/Users/arungupta/workspaces/javaee7-simple-sample/target/javaee7-simple-sample]
    [INFO] Processing war project
    [INFO] Copying webapp resources [/Users/arungupta/workspaces/javaee7-simple-sample/src/main/webapp]
    [INFO] Webapp assembled in [3 msecs]
    [INFO] Building war: /Users/arungupta/workspaces/javaee7-simple-sample/target/javaee7-simple-sample.war
    [INFO] 
    [INFO] <<< wildfly-maven-plugin:1.0.2.Final:deploy (default) < package @ javaee7-simple-sample <<<
    [INFO] 
    [INFO] --- wildfly-maven-plugin:1.0.2.Final:deploy (default) @ javaee7-simple-sample ---
    Feb 24, 2015 1:02:46 AM org.xnio.Xnio <clinit>
    INFO: XNIO version 3.2.2.Final
    Feb 24, 2015 1:02:46 AM org.xnio.nio.NioXnio <clinit>
    INFO: XNIO NIO Implementation Version 3.2.2.Final
    Feb 24, 2015 1:02:46 AM org.jboss.remoting3.EndpointImpl <clinit>
    INFO: JBoss Remoting version 4.0.3.Final
    [INFO] 
    [INFO] --- maven-deploy-plugin:2.7:deploy (default-deploy) @ javaee7-simple-sample ---
    Downloading: http://localhost:8081/nexus/content/repositories/snapshots/org/javaee7/sample/javaee7-simple-sample/1.0-SNAPSHOT/maven-metadata.xml
    Downloaded: http://localhost:8081/nexus/content/repositories/snapshots/org/javaee7/sample/javaee7-simple-sample/1.0-SNAPSHOT/maven-metadata.xml (783 B at 4.0 KB/sec)
    Uploading: http://localhost:8081/nexus/content/repositories/snapshots/org/javaee7/sample/javaee7-simple-sample/1.0-SNAPSHOT/javaee7-simple-sample-1.0-20150224.090247-2.war
    Uploaded: http://localhost:8081/nexus/content/repositories/snapshots/org/javaee7/sample/javaee7-simple-sample/1.0-SNAPSHOT/javaee7-simple-sample-1.0-20150224.090247-2.war (6 KB at 90.4 KB/sec)
    Uploading: http://localhost:8081/nexus/content/repositories/snapshots/org/javaee7/sample/javaee7-simple-sample/1.0-SNAPSHOT/javaee7-simple-sample-1.0-20150224.090247-2.pom
    Uploaded: http://localhost:8081/nexus/content/repositories/snapshots/org/javaee7/sample/javaee7-simple-sample/1.0-SNAPSHOT/javaee7-simple-sample-1.0-20150224.090247-2.pom (3 KB at 53.2 KB/sec)
    Downloading: http://localhost:8081/nexus/content/repositories/snapshots/org/javaee7/sample/javaee7-simple-sample/maven-metadata.xml
    Downloaded: http://localhost:8081/nexus/content/repositories/snapshots/org/javaee7/sample/javaee7-simple-sample/maven-metadata.xml (297 B at 13.8 KB/sec)
    Uploading: http://localhost:8081/nexus/content/repositories/snapshots/org/javaee7/sample/javaee7-simple-sample/1.0-SNAPSHOT/maven-metadata.xml
    Uploaded: http://localhost:8081/nexus/content/repositories/snapshots/org/javaee7/sample/javaee7-simple-sample/1.0-SNAPSHOT/maven-metadata.xml (783 B at 20.7 KB/sec)
    Uploading: http://localhost:8081/nexus/content/repositories/snapshots/org/javaee7/sample/javaee7-simple-sample/maven-metadata.xml
    Uploaded: http://localhost:8081/nexus/content/repositories/snapshots/org/javaee7/sample/javaee7-simple-sample/maven-metadata.xml (297 B at 6.7 KB/sec)
    [INFO] ------------------------------------------------------------------------
    [INFO] BUILD SUCCESS
    [INFO] ------------------------------------------------------------------------
    [INFO] Total time: 4.398 s
    [INFO] Finished at: 2015-02-24T01:02:47-08:00
    [INFO] Final Memory: 22M/310M
    [INFO] ------------------------------------------------------------------------

    快照存储库经过几次构建后,可以在localhost:8081 / nexus /#view-repositories; snapshots〜browsestorage中看到,如下所示:

    techtip73-nexus快照存储库-1024x749

    实际的存储库存储在../sonatype-work/nexus目录中。 这是在解压缩Nexus OSS捆绑包的同时创建的。

将发行版部署到本地Nexus存储库

  1. 清除任何以前执行的发行版:
    javaee7-simple-sample> mvn release:clean -P release
    [INFO] Scanning for projects...
    [INFO]                                                                         
    [INFO] ------------------------------------------------------------------------
    [INFO] Building javaee7-simple-sample 1.1-SNAPSHOT
    [INFO] ------------------------------------------------------------------------
    [INFO] 
    [INFO] --- maven-release-plugin:2.5.1:clean (default-cli) @ javaee7-simple-sample ---
    [INFO] Cleaning up after release...
    [INFO] ------------------------------------------------------------------------
    [INFO] BUILD SUCCESS
    [INFO] ------------------------------------------------------------------------
    [INFO] Total time: 0.912 s
    [INFO] Finished at: 2015-02-24T02:18:53-08:00
    [INFO] Final Memory: 10M/245M
    [INFO] ------------------------------------------------------------------------
  2. 准备下一个版本:
    javaee7-simple-sample> mvn release:prepare -P release
    [INFO] Scanning for projects...
    [INFO]                                                                         
    [INFO] ------------------------------------------------------------------------
    [INFO] Building javaee7-simple-sample 1.3-SNAPSHOT
    [INFO] ------------------------------------------------------------------------
    [INFO] 
    [INFO] --- maven-release-plugin:2.5.1:prepare (default-cli) @ javaee7-simple-sample ---
    [INFO] Verifying that there are no local modifications...
    [INFO]   ignoring changes on: **/pom.xml.releaseBackup, **/pom.xml.next, **/pom.xml.tag, **/pom.xml.branch, **/release.properties, **/pom.xml.backup
    [INFO] Executing: /bin/sh -c cd /Users/arungupta/workspaces/javaee7-simple-sample && git rev-parse --show-toplevel
    [INFO] Working directory: /Users/arungupta/workspaces/javaee7-simple-sample
    [INFO] Executing: /bin/sh -c cd /Users/arungupta/workspaces/javaee7-simple-sample && git status --porcelain .
    [INFO] Working directory: /Users/arungupta/workspaces/javaee7-simple-sample
    [WARNING] Ignoring unrecognized line: ?? release.properties
    [INFO] Checking dependencies and plugins for snapshots ...
    What is the release version for "javaee7-simple-sample"? (org.javaee7.sample:javaee7-simple-sample) 1.3: : 
    What is SCM release tag or label for "javaee7-simple-sample"? (org.javaee7.sample:javaee7-simple-sample) v1.3: : 
    What is the new development version for "javaee7-simple-sample"? (org.javaee7.sample:javaee7-simple-sample) 1.4-SNAPSHOT: : 
    [INFO] Transforming 'javaee7-simple-sample'...
    [INFO] Not generating release POMs
    [INFO] Executing goals 'clean verify'...
    [WARNING] Maven will be executed in interactive mode, but no input stream has been configured for this MavenInvoker instance.
    [INFO] [INFO] Scanning for projects...
    [INFO] [INFO]                                                                         
    [INFO] [INFO] ------------------------------------------------------------------------
    [INFO] [INFO] Building javaee7-simple-sample 1.3
    [INFO] [INFO] ------------------------------------------------------------------------. . .[INFO] Executing: /bin/sh -c cd /Users/arungupta/workspaces/javaee7-simple-sample && git symbolic-ref HEAD
    [INFO] Working directory: /Users/arungupta/workspaces/javaee7-simple-sample
    [INFO] Executing: /bin/sh -c cd /Users/arungupta/workspaces/javaee7-simple-sample && git push https://github.com/javaee-samples/javaee7-simple-sample.git refs/heads/master:refs/heads/master
    [INFO] Working directory: /Users/arungupta/workspaces/javaee7-simple-sample
    [INFO] Release preparation complete.
    [INFO] ------------------------------------------------------------------------
    [INFO] BUILD SUCCESS
    [INFO] ------------------------------------------------------------------------
    [INFO] Total time: 01:04 min
    [INFO] Finished at: 2015-02-24T02:55:59-08:00
    [INFO] Final Memory: 11M/245M
    [INFO] ------------------------------------------------------------------------
  3. 执行发布:
    javaee7-simple-sample> mvn javadoc:jar source:jar release:perform -P release
    [INFO] Scanning for projects...
    [INFO]                                                                         
    [INFO] ------------------------------------------------------------------------
    [INFO] Building javaee7-simple-sample 1.4-SNAPSHOT
    [INFO] ------------------------------------------------------------------------
    [INFO] 
    [INFO] --- maven-javadoc-plugin:2.10.1:jar (default-cli) @ javaee7-simple-sample ---. . .[INFO] [INFO] ------------------------------------------------------------------------
    [INFO] [INFO] BUILD FAILURE
    [INFO] [INFO] ------------------------------------------------------------------------
    [INFO] [INFO] Total time: 5.820 s
    [INFO] [INFO] Finished at: 2015-02-24T02:58:16-08:00
    [INFO] [INFO] Final Memory: 31M/312M
    [INFO] [INFO] ------------------------------------------------------------------------
    [INFO] [ERROR] Failed to execute goal org.apache.maven.plugins:maven-deploy-plugin:2.7:deploy (default-deploy) on project javaee7-simple-sample: Failed to deploy artifacts: Could not transfer artifact org.javaee7.sample:javaee7-simple-sample:war:1.3 from/to deployment (http://localhost:8081/nexus/content/repositories/releases/): Failed to transfer file: http://localhost:8081/nexus/content/repositories/releases/org/javaee7/sample/javaee7-simple-sample/1.3/javaee7-simple-sample-1.3.war. Return code is: 400, ReasonPhrase: Bad Request. -> [Help 1]

    注意,该命令以错误结尾。 这类似于此处报告的内容,但奇怪的是文件仍在Nexus上载。 这是来自localhost:8081 / nexus /#view-repositories; releases〜browsestorage的快照,同时尝试测试多个版本并想知道这些“虚假”错误消息:

    techtip73-nexus-发布库

    该错误将需要更多的调试,但现在至少可以将快照和发行版本存储在本地Nexus存储库中。

更新: Manfred Moser通过发送拉取请求帮助调试了该错误。 现在,此错误已消失,而应显示类似以下内容:

[INFO] Uploaded: http://localhost:8081/nexus/content/repositories/releases/org/javaee7/sample/javaee7-simple-sample/1.8/javaee7-simple-sample-1.8-sources.jar (3 KB at 74.7 KB/sec)
[INFO] [INFO] ------------------------------------------------------------------------
[INFO] [INFO] BUILD SUCCESS
[INFO] [INFO] ------------------------------------------------------------------------
[INFO] [INFO] Total time: 5.673 s
[INFO] [INFO] Finished at: 2015-02-26T03:50:18+05:30
[INFO] [INFO] Final Memory: 31M/320M
[INFO] [INFO] ------------------------------------------------------------------------
[INFO] Cleaning up after release...
[INFO] ------------------------------------------------------------------------
[INFO] BUILD SUCCESS
[INFO] ------------------------------------------------------------------------
[INFO] Total time: 01:10 min
[INFO] Finished at: 2015-02-26T03:50:30+05:30
[INFO] Final Memory: 13M/245M
[INFO] ------------------------------------------------------------------------

您学习了如何设置本地Nexus Repository并向其推送快照和发布版本。 随后的博客将展示如何将此存储库用于CI / CD。

请享用!

翻译自: https://www.javacodegeeks.com/2015/03/setup-local-nexus-repository-and-deploying-war-file-from-maven.html

本文来自互联网用户投稿,该文观点仅代表作者本人,不代表本站立场。本站仅提供信息存储空间服务,不拥有所有权,不承担相关法律责任。如若转载,请注明出处:http://www.mzph.cn/news/360633.shtml

如若内容造成侵权/违法违规/事实不符,请联系多彩编程网进行投诉反馈email:809451989@qq.com,一经查实,立即删除!

相关文章

mac solr mysql 配置文件_Solr配置文件浅析

接上一篇Linux下安装solr7.4&#xff0c;来谈谈solr的配置文件schema.xml和db-data-config.xml首先看schema.xml&#xff1a;idfield标签用来定义solr core中的字段。这里列出的三个字段如果没有特殊原因尽量保留。字段id被声明为uniqueKey,是让id来唯一标明一个solrdocument。…

JSF:在正确的阶段进行验证(了解生命周期)

嗨&#xff0c;大家好&#xff01; 尽管标题强调验证一词&#xff0c;但本文实际上是关于JSF生命周期的。 那是因为我相信&#xff0c;真正了解生命周期的最简单方法之一就是通过做出我们一直在做的事情&#xff1a;验证用户输入。 总的来说&#xff0c;理解所谓的JSF生命周期…

OpenShift v3:使用WildFly和MySQL的Java EE 7入门

OpenShift是Red Hat的开源PaaS平台。 OpenShift v3 &#xff08;将于今年发布&#xff09;将提供使用Docker和Kubernetes运行微服务的整体体验。 以经典的Red Hat方式&#xff0c;所有工作都在OpenShift Origin的开源中完成。 这也将推动OpenShift Online和OpenShift Enterpris…

mySQL日期函数并运行_mysql日期相关的函数

1、获取当前时间&#xff1a;/**获得当前日期时间(date time)函数&#xff1a;now(), 常用**/select now() fromdual;/**获取当前时间戳&#xff0c;current_timestamp或者current_timestamp()**/select current_timestamp, current_timestamp() fromdual;/**获得当前日期时间…

序列化对象C++对象的JSON序列化与反序列化探索

新手发帖&#xff0c;很多方面都是刚入门&#xff0c;有错误的地方请大家见谅&#xff0c;欢迎批评指正 一&#xff1a;背景 作为一名C开发人员&#xff0c;我始终很期待能够像C#与JAVA那样&#xff0c;可以省力的进行对象的序列化与反序列化&#xff0c;但到现在为止&#xff…

python socket udp并发_Python进阶----UDP协议使用socket通信,socketserver模块实现并发

Python进阶----UDP协议使用socket通信,socketserver模块实现并发一丶基于UDP协议的socket实现UDP协议传输数据代码如下:&#x1f447;### 客户端# -*-coding:utf-8-*-# Author:Dsimport socket# 实例化UDP协议的socket对象 ,配置参数, socket.SOCK_DGRAM(数据报)udp_clisocket.…

Java IO基准测试:Quasar与异步ForkJoinPool与ManagedBlock

“ Arien看到了我们运行的parallelStreams和ForkJoin基准测试的结果后&#xff0c;在Twitter上与我们联系。 这激起了他的兴趣&#xff0c;因此他进行了一些自己的测试&#xff0c;将Quasar纤维加入了混合物。 这是他的结果和结论。” –塔基皮&#xff08;Takipi&#xff09;A…

WP8开发札记(一)WP8应用生命周期管理

在介绍生命周期前&#xff0c;我们先了解两个相关的概念。 1、墓碑机制&#xff1a;WP8与Android采用的真后台机制不同&#xff0c;WP8采用的是墓碑机制。一旦从当前应用程序离开&#xff08;非退出&#xff09;&#xff0c;该应用会被墓碑化&#xff0c;这样可以更好的管理&am…

python类继承中构造方法_第8.3节 Python类的__init__方法深入剖析:构造方法与继承详解...

第8.3节Python类的__init__方法深入剖析&#xff1a;构造方法与继承详解一、 引言上两节介绍了构造方法的语法及参数&#xff0c;说明了构造方法是Python的类创建实例后首先执行的方法&#xff0c;并说明如果类没有重写构造方法&#xff0c;Python将会给出默认的__init__方法…

OpenShift DIY:使用Gradle构建Spring Boot / Undertow应用程序

由于此bug&#xff0c; Gradle 1.6是在OpenShift上运行的最后一个受支持的Gradle版本。 但是从Gradle 2.2开始&#xff0c;这不再是问题&#xff0c;因此使用自己动手做墨盒在OpenShift上运行最新的Gradle不再是问题。 DIY墨盒是一种实验性墨盒&#xff0c;它提供了一种在OpenS…

使用JAX-RS和Jetty创建Web服务和Rest Server

用Java创建WebService非常容易。 将其添加到ServletContainer并将其部署到嵌入式WebServer仅需要几行代码。 让我们创建一个具有两个函数的简单计算器&#xff0c;作为WebService的示例。 计算器将计算任何数量的squareRoot和平方。 它将返回一个简单的JSON响应&#xff0c;其…

maya 中使用节点连接来求余数:

绑个东西要用到求余&#xff0c;不喜欢用表达式&#xff0c;就想用节点连出来&#xff0c;找了下网上只有 镀金铆钉 在火星时代上的教程&#xff0c;不过不能下载了&#xff0c;就自己想了下&#xff0c;终于搞出来了&#xff0c;做下笔记&#xff0c;不要忘了。 求余的思路&a…

java web 登录界面案例_【JavaWeb】74:写一个登录案例

今天是刘小爱自学Java的第74天。感谢你的观看&#xff0c;谢谢你。话不多说&#xff0c;开始今天的学习&#xff1a;Java又常被称之为后台开发。什么叫后台呢&#xff1f;除了后台还有什么前台、前端后端……这些概念一大堆&#xff0c;还容易弄混。以一个三层架构的知识点来引…

7种JIRA集成可优化Java开发流程

有哪些最佳集成可以用来优化JIRA工作流程&#xff1f; 我喜欢寻找在工作流程中提高效率的方法。 看着那些小的自动化和流畅的流程&#xff0c;使我的脸上露出笑容。 我知道我并不孤单&#xff0c;偶尔花更多的时间来获得一点点提升以使其正常工作&#xff0c;而不是最终节省了我…

hive处理日志,自定义inputformat

开放环境&#xff0c;hadoop-0.20.2&#xff0c;hive-0.6 1.日志分隔符 Xml代码 2010-05-31 10:50:17|||61.132.4.82|||http://www.360buy.com/product/201185.html 2010-05-31 10:50:17|||61.132.4.82|||http://www.360buy.com/product/201185.html分隔符是“ ||| ”&#xf…

将ActiveMQ持久消息传递性能提高25倍

Apache ActiveMQ&#xff0c;JBoss A-MQ和Red Hat Apache ActiveMQ是一个非常受欢迎的开源消息传递代理&#xff0c;由创建&#xff08;和工作&#xff09; Apache Karaf &#xff0c; Apache Camel &#xff0c; Apache ServiceMix以及许多其他工具的人提供给您。 它拥有一个充…

ECMA学习小结(3)——constructor 和 prototype

每个函数都有一个prototype的属性&#xff0c;当我们以这个函数为构造函数创建实例时&#xff08;即用new的形式&#xff09;&#xff0c;创建出来的这个对象是没有prototype的属性的。以下代码为例&#xff1a;在console里进行调试cf 拥有一个prototype的属性&#xff0c;这个…

java什么是网络接口_java 网络编程 -- IP地址的表示与网络接口信息的获取(InetAddress和NetworkInterface)...

使用java进行网络程序的开发&#xff0c;可以说是一件令人愉悦的事情&#xff0c;对于用惯了C网络接口编程的人来说&#xff0c;当他们首次使用Java开发网络应用程序&#xff0c;会发现java开发网络应用是如此的简单&#xff0c;甚至仅用几分钟时间&#xff0c;您就可以学会这种…

如何使用悲观锁定修复乐观锁定竞争条件

概括 在我以前的文章中 &#xff0c;我解释了使用显式乐观锁定的好处。 然后我们发现&#xff0c;在很短的时间范围内&#xff0c;并发交易仍可以在我们当前交易被提交之前立即提交产品价格更改。 此问题可以描述如下&#xff1a; 爱丽丝拿产品 然后&#xff0c;她决定订购…

SWT外观:自定义FlatScrollBar颜色等

最近&#xff0c;我引入了一个自定义滑块控件 &#xff0c;该控件可用于改善SWT外观和更细微的视图布局的感觉。 令人高兴的是&#xff0c;该小部件似乎已经在Code Affine世界之外找到了较早的采用者 。 这导致了一些增强 &#xff0c;这些增强将在以下各节中介绍。 SWT滚动条…