From 3c2281efd3430e7cb8231be4adb613531d55b606 Mon Sep 17 00:00:00 2001 From: Eric Barboni Date: Mon, 22 Nov 2021 17:54:18 +0100 Subject: [PATCH 1/3] Upgrade to Apache Maven 3.8.4 --- .../apache-maven-3.6.3-jsoup-license.txt | 28 -- .../apache-maven-3.6.3-jsr-250-license.txt | 390 ------------------ ...txt => apache-maven-3.8.4-bin-license.txt} | 2 +- ....txt => apache-maven-3.8.4-bin-notice.txt} | 4 +- ...txt => apache-maven-3.8.4-epl-license.txt} | 6 +- ...t => apache-maven-3.8.4-slf4j-license.txt} | 4 +- java/maven.embedder/external/binaries-list | 2 +- .../external/binariesembedded-list | 72 ++-- .../nbproject/project.properties | 2 +- java/maven.embedder/nbproject/project.xml | 78 ++-- .../netbeans/nbbuild/extlibs/ignored-overlaps | 9 +- 11 files changed, 88 insertions(+), 509 deletions(-) delete mode 100644 java/maven.embedder/external/apache-maven-3.6.3-jsoup-license.txt delete mode 100644 java/maven.embedder/external/apache-maven-3.6.3-jsr-250-license.txt rename java/maven.embedder/external/{apache-maven-3.6.3-bin-license.txt => apache-maven-3.8.4-bin-license.txt} (99%) rename java/maven.embedder/external/{apache-maven-3.6.3-bin-notice.txt => apache-maven-3.8.4-bin-notice.txt} (97%) rename java/maven.embedder/external/{apache-maven-3.6.3-epl-license.txt => apache-maven-3.8.4-epl-license.txt} (97%) rename java/maven.embedder/external/{apache-maven-3.6.3-slf4j-license.txt => apache-maven-3.8.4-slf4j-license.txt} (92%) diff --git a/java/maven.embedder/external/apache-maven-3.6.3-jsoup-license.txt b/java/maven.embedder/external/apache-maven-3.6.3-jsoup-license.txt deleted file mode 100644 index 6f969aeac89a..000000000000 --- a/java/maven.embedder/external/apache-maven-3.6.3-jsoup-license.txt +++ /dev/null @@ -1,28 +0,0 @@ -Name: jsoup -Description: Part of Apache Maven Distribution -Version: 3.6.3 -License: Maven-MIT -Origin: Apache Software Foundation -Files: apache-maven-3.6.3-bin.zip!/apache-maven-3.6.3/lib/jsoup-1.12.1.jar - -The MIT License - -Copyright (c) 2009-2019 Jonathan Hedley - -Permission is hereby granted, free of charge, to any person obtaining a copy -of this software and associated documentation files (the "Software"), to deal -in the Software without restriction, including without limitation the rights -to use, copy, modify, merge, publish, distribute, sublicense, and/or sell -copies of the Software, and to permit persons to whom the Software is -furnished to do so, subject to the following conditions: - -The above copyright notice and this permission notice shall be included in all -copies or substantial portions of the Software. - -THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR -IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, -FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE -AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER -LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, -OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE -SOFTWARE. diff --git a/java/maven.embedder/external/apache-maven-3.6.3-jsr-250-license.txt b/java/maven.embedder/external/apache-maven-3.6.3-jsr-250-license.txt deleted file mode 100644 index 373e2441c08e..000000000000 --- a/java/maven.embedder/external/apache-maven-3.6.3-jsr-250-license.txt +++ /dev/null @@ -1,390 +0,0 @@ -Name: JSR-250 Common Annotations for the JavaTM Platform -Description: Part of Apache Maven Distribution -Version: 3.6.3 -License: CDDL-1.0 -Origin: Apache Software Foundation -Files: apache-maven-3.6.3-bin.zip!/apache-maven-3.6.3/lib/jsr250-api-1.0.jar - -COMMON DEVELOPMENT AND DISTRIBUTION LICENSE (CDDL) Version 1.0 - - - 1. Definitions. - - 1.1. "Contributor" means each individual or entity that - creates or contributes to the creation of Modifications. - - 1.2. "Contributor Version" means the combination of the - Original Software, prior Modifications used by a - Contributor (if any), and the Modifications made by that - particular Contributor. - - 1.3. "Covered Software" means (a) the Original Software, or - (b) Modifications, or (c) the combination of files - containing Original Software with files containing - Modifications, in each case including portions thereof. - - 1.4. "Executable" means the Covered Software in any form - other than Source Code. - - 1.5. "Initial Developer" means the individual or entity - that first makes Original Software available under this - License. - - 1.6. "Larger Work" means a work which combines Covered - Software or portions thereof with code not governed by the - terms of this License. - - 1.7. "License" means this document. - - 1.8. "Licensable" means having the right to grant, to the - maximum extent possible, whether at the time of the initial - grant or subsequently acquired, any and all of the rights - conveyed herein. - - 1.9. "Modifications" means the Source Code and Executable - form of any of the following: - - A. Any file that results from an addition to, - deletion from or modification of the contents of a - file containing Original Software or previous - Modifications; - - B. Any new file that contains any part of the - Original Software or previous Modification; or - - C. Any new file that is contributed or otherwise made - available under the terms of this License. - - 1.10. "Original Software" means the Source Code and - Executable form of computer software code that is - originally released under this License. - - 1.11. "Patent Claims" means any patent claim(s), now owned - or hereafter acquired, including without limitation, - method, process, and apparatus claims, in any patent - Licensable by grantor. - - 1.12. "Source Code" means (a) the common form of computer - software code in which modifications are made and (b) - associated documentation included in or with such code. - - 1.13. "You" (or "Your") means an individual or a legal - entity exercising rights under, and complying with all of - the terms of, this License. For legal entities, "You" - includes any entity which controls, is controlled by, or is - under common control with You. For purposes of this - definition, "control" means (a) the power, direct or - indirect, to cause the direction or management of such - entity, whether by contract or otherwise, or (b) ownership - of more than fifty percent (50%) of the outstanding shares - or beneficial ownership of such entity. - - 2. License Grants. - - 2.1. The Initial Developer Grant. - - Conditioned upon Your compliance with Section 3.1 below and - subject to third party intellectual property claims, the - Initial Developer hereby grants You a world-wide, - royalty-free, non-exclusive license: - - (a) under intellectual property rights (other than - patent or trademark) Licensable by Initial Developer, - to use, reproduce, modify, display, perform, - sublicense and distribute the Original Software (or - portions thereof), with or without Modifications, - and/or as part of a Larger Work; and - - (b) under Patent Claims infringed by the making, - using or selling of Original Software, to make, have - made, use, practice, sell, and offer for sale, and/or - otherwise dispose of the Original Software (or - portions thereof). - - (c) The licenses granted in Sections 2.1(a) and (b) - are effective on the date Initial Developer first - distributes or otherwise makes the Original Software - available to a third party under the terms of this - License. - - (d) Notwithstanding Section 2.1(b) above, no patent - license is granted: (1) for code that You delete from - the Original Software, or (2) for infringements - caused by: (i) the modification of the Original - Software, or (ii) the combination of the Original - Software with other software or devices. - - 2.2. Contributor Grant. - - Conditioned upon Your compliance with Section 3.1 below and - subject to third party intellectual property claims, each - Contributor hereby grants You a world-wide, royalty-free, - non-exclusive license: - - (a) under intellectual property rights (other than - patent or trademark) Licensable by Contributor to - use, reproduce, modify, display, perform, sublicense - and distribute the Modifications created by such - Contributor (or portions thereof), either on an - unmodified basis, with other Modifications, as - Covered Software and/or as part of a Larger Work; and - - - (b) under Patent Claims infringed by the making, - using, or selling of Modifications made by that - Contributor either alone and/or in combination with - its Contributor Version (or portions of such - combination), to make, use, sell, offer for sale, - have made, and/or otherwise dispose of: (1) - Modifications made by that Contributor (or portions - thereof); and (2) the combination of Modifications - made by that Contributor with its Contributor Version - (or portions of such combination). - - (c) The licenses granted in Sections 2.2(a) and - 2.2(b) are effective on the date Contributor first - distributes or otherwise makes the Modifications - available to a third party. - - (d) Notwithstanding Section 2.2(b) above, no patent - license is granted: (1) for any code that Contributor - has deleted from the Contributor Version; (2) for - infringements caused by: (i) third party - modifications of Contributor Version, or (ii) the - combination of Modifications made by that Contributor - with other software (except as part of the - Contributor Version) or other devices; or (3) under - Patent Claims infringed by Covered Software in the - absence of Modifications made by that Contributor. - - 3. Distribution Obligations. - - 3.1. Availability of Source Code. - - Any Covered Software that You distribute or otherwise make - available in Executable form must also be made available in - Source Code form and that Source Code form must be - distributed only under the terms of this License. You must - include a copy of this License with every copy of the - Source Code form of the Covered Software You distribute or - otherwise make available. You must inform recipients of any - such Covered Software in Executable form as to how they can - obtain such Covered Software in Source Code form in a - reasonable manner on or through a medium customarily used - for software exchange. - - 3.2. Modifications. - - The Modifications that You create or to which You - contribute are governed by the terms of this License. You - represent that You believe Your Modifications are Your - original creation(s) and/or You have sufficient rights to - grant the rights conveyed by this License. - - 3.3. Required Notices. - - You must include a notice in each of Your Modifications - that identifies You as the Contributor of the Modification. - You may not remove or alter any copyright, patent or - trademark notices contained within the Covered Software, or - any notices of licensing or any descriptive text giving - attribution to any Contributor or the Initial Developer. - - 3.4. Application of Additional Terms. - - You may not offer or impose any terms on any Covered - Software in Source Code form that alters or restricts the - applicable version of this License or the recipients' - rights hereunder. You may choose to offer, and to charge a - fee for, warranty, support, indemnity or liability - obligations to one or more recipients of Covered Software. - However, you may do so only on Your own behalf, and not on - behalf of the Initial Developer or any Contributor. You - must make it absolutely clear that any such warranty, - support, indemnity or liability obligation is offered by - You alone, and You hereby agree to indemnify the Initial - Developer and every Contributor for any liability incurred - by the Initial Developer or such Contributor as a result of - warranty, support, indemnity or liability terms You offer. - - - 3.5. Distribution of Executable Versions. - - You may distribute the Executable form of the Covered - Software under the terms of this License or under the terms - of a license of Your choice, which may contain terms - different from this License, provided that You are in - compliance with the terms of this License and that the - license for the Executable form does not attempt to limit - or alter the recipient's rights in the Source Code form - from the rights set forth in this License. If You - distribute the Covered Software in Executable form under a - different license, You must make it absolutely clear that - any terms which differ from this License are offered by You - alone, not by the Initial Developer or Contributor. You - hereby agree to indemnify the Initial Developer and every - Contributor for any liability incurred by the Initial - Developer or such Contributor as a result of any such terms - You offer. - - 3.6. Larger Works. - - You may create a Larger Work by combining Covered Software - with other code not governed by the terms of this License - and distribute the Larger Work as a single product. In such - a case, You must make sure the requirements of this License - are fulfilled for the Covered Software. - - 4. Versions of the License. - - 4.1. New Versions. - - Sun Microsystems, Inc. is the initial license steward and - may publish revised and/or new versions of this License - from time to time. Each version will be given a - distinguishing version number. Except as provided in - Section 4.3, no one other than the license steward has the - right to modify this License. - - 4.2. Effect of New Versions. - - You may always continue to use, distribute or otherwise - make the Covered Software available under the terms of the - version of the License under which You originally received - the Covered Software. If the Initial Developer includes a - notice in the Original Software prohibiting it from being - distributed or otherwise made available under any - subsequent version of the License, You must distribute and - make the Covered Software available under the terms of the - version of the License under which You originally received - the Covered Software. Otherwise, You may also choose to - use, distribute or otherwise make the Covered Software - available under the terms of any subsequent version of the - License published by the license steward. - - 4.3. Modified Versions. - - When You are an Initial Developer and You want to create a - new license for Your Original Software, You may create and - use a modified version of this License if You: (a) rename - the license and remove any references to the name of the - license steward (except to note that the license differs - from this License); and (b) otherwise make it clear that - the license contains terms which differ from this License. - - 5. DISCLAIMER OF WARRANTY. - - COVERED SOFTWARE IS PROVIDED UNDER THIS LICENSE ON AN "AS IS" - BASIS, WITHOUT WARRANTY OF ANY KIND, EITHER EXPRESSED OR IMPLIED, - INCLUDING, WITHOUT LIMITATION, WARRANTIES THAT THE COVERED - SOFTWARE IS FREE OF DEFECTS, MERCHANTABLE, FIT FOR A PARTICULAR - PURPOSE OR NON-INFRINGING. THE ENTIRE RISK AS TO THE QUALITY AND - PERFORMANCE OF THE COVERED SOFTWARE IS WITH YOU. SHOULD ANY - COVERED SOFTWARE PROVE DEFECTIVE IN ANY RESPECT, YOU (NOT THE - INITIAL DEVELOPER OR ANY OTHER CONTRIBUTOR) ASSUME THE COST OF - ANY NECESSARY SERVICING, REPAIR OR CORRECTION. THIS DISCLAIMER OF - WARRANTY CONSTITUTES AN ESSENTIAL PART OF THIS LICENSE. NO USE OF - ANY COVERED SOFTWARE IS AUTHORIZED HEREUNDER EXCEPT UNDER THIS - DISCLAIMER. - - 6. TERMINATION. - - 6.1. This License and the rights granted hereunder will - terminate automatically if You fail to comply with terms - herein and fail to cure such breach within 30 days of - becoming aware of the breach. Provisions which, by their - nature, must remain in effect beyond the termination of - this License shall survive. - - 6.2. If You assert a patent infringement claim (excluding - declaratory judgment actions) against Initial Developer or - a Contributor (the Initial Developer or Contributor against - whom You assert such claim is referred to as "Participant") - alleging that the Participant Software (meaning the - Contributor Version where the Participant is a Contributor - or the Original Software where the Participant is the - Initial Developer) directly or indirectly infringes any - patent, then any and all rights granted directly or - indirectly to You by such Participant, the Initial - Developer (if the Initial Developer is not the Participant) - and all Contributors under Sections 2.1 and/or 2.2 of this - License shall, upon 60 days notice from Participant - terminate prospectively and automatically at the expiration - of such 60 day notice period, unless if within such 60 day - period You withdraw Your claim with respect to the - Participant Software against such Participant either - unilaterally or pursuant to a written agreement with - Participant. - - 6.3. In the event of termination under Sections 6.1 or 6.2 - above, all end user licenses that have been validly granted - by You or any distributor hereunder prior to termination - (excluding licenses granted to You by any distributor) - shall survive termination. - - 7. LIMITATION OF LIABILITY. - - UNDER NO CIRCUMSTANCES AND UNDER NO LEGAL THEORY, WHETHER TORT - (INCLUDING NEGLIGENCE), CONTRACT, OR OTHERWISE, SHALL YOU, THE - INITIAL DEVELOPER, ANY OTHER CONTRIBUTOR, OR ANY DISTRIBUTOR OF - COVERED SOFTWARE, OR ANY SUPPLIER OF ANY OF SUCH PARTIES, BE - LIABLE TO ANY PERSON FOR ANY INDIRECT, SPECIAL, INCIDENTAL, OR - CONSEQUENTIAL DAMAGES OF ANY CHARACTER INCLUDING, WITHOUT - LIMITATION, DAMAGES FOR LOST PROFITS, LOSS OF GOODWILL, WORK - STOPPAGE, COMPUTER FAILURE OR MALFUNCTION, OR ANY AND ALL OTHER - COMMERCIAL DAMAGES OR LOSSES, EVEN IF SUCH PARTY SHALL HAVE BEEN - INFORMED OF THE POSSIBILITY OF SUCH DAMAGES. THIS LIMITATION OF - LIABILITY SHALL NOT APPLY TO LIABILITY FOR DEATH OR PERSONAL - INJURY RESULTING FROM SUCH PARTY'S NEGLIGENCE TO THE EXTENT - APPLICABLE LAW PROHIBITS SUCH LIMITATION. SOME JURISDICTIONS DO - NOT ALLOW THE EXCLUSION OR LIMITATION OF INCIDENTAL OR - CONSEQUENTIAL DAMAGES, SO THIS EXCLUSION AND LIMITATION MAY NOT - APPLY TO YOU. - - 8. U.S. GOVERNMENT END USERS. - - The Covered Software is a "commercial item," as that term is - defined in 48 C.F.R. 2.101 (Oct. 1995), consisting of "commercial - computer software" (as that term is defined at 48 C.F.R. - 252.227-7014(a)(1)) and "commercial computer software - documentation" as such terms are used in 48 C.F.R. 12.212 (Sept. - 1995). Consistent with 48 C.F.R. 12.212 and 48 C.F.R. 227.7202-1 - through 227.7202-4 (June 1995), all U.S. Government End Users - acquire Covered Software with only those rights set forth herein. - This U.S. Government Rights clause is in lieu of, and supersedes, - any other FAR, DFAR, or other clause or provision that addresses - Government rights in computer software under this License. - - 9. MISCELLANEOUS. - - This License represents the complete agreement concerning subject - matter hereof. If any provision of this License is held to be - unenforceable, such provision shall be reformed only to the - extent necessary to make it enforceable. This License shall be - governed by the law of the jurisdiction specified in a notice - contained within the Original Software (except to the extent - applicable law, if any, provides otherwise), excluding such - jurisdiction's conflict-of-law provisions. Any litigation - relating to this License shall be subject to the jurisdiction of - the courts located in the jurisdiction and venue specified in a - notice contained within the Original Software, with the losing - party responsible for costs, including, without limitation, court - costs and reasonable attorneys' fees and expenses. The - application of the United Nations Convention on Contracts for the - International Sale of Goods is expressly excluded. Any law or - regulation which provides that the language of a contract shall - be construed against the drafter shall not apply to this License. - You agree that You alone are responsible for compliance with the - United States export administration regulations (and the export - control laws and regulation of any other countries) when You use, - distribute or otherwise make available any Covered Software. - - 10. RESPONSIBILITY FOR CLAIMS. - - As between Initial Developer and the Contributors, each party is - responsible for claims and damages arising, directly or - indirectly, out of its utilization of rights under this License - and You agree to work with Initial Developer and Contributors to - distribute such responsibility on an equitable basis. Nothing - herein is intended or shall be deemed to constitute any admission - of liability. diff --git a/java/maven.embedder/external/apache-maven-3.6.3-bin-license.txt b/java/maven.embedder/external/apache-maven-3.8.4-bin-license.txt similarity index 99% rename from java/maven.embedder/external/apache-maven-3.6.3-bin-license.txt rename to java/maven.embedder/external/apache-maven-3.8.4-bin-license.txt index d55749d9e565..fa260faa20a8 100644 --- a/java/maven.embedder/external/apache-maven-3.6.3-bin-license.txt +++ b/java/maven.embedder/external/apache-maven-3.8.4-bin-license.txt @@ -1,6 +1,6 @@ Name: Apache Maven Distribution Description: Apache Maven Distribution -Version: 3.6.3 +Version: 3.8.4 License: Apache-2.0 Origin: Apache Software Foundation URL: http://maven.apache.org/ diff --git a/java/maven.embedder/external/apache-maven-3.6.3-bin-notice.txt b/java/maven.embedder/external/apache-maven-3.8.4-bin-notice.txt similarity index 97% rename from java/maven.embedder/external/apache-maven-3.6.3-bin-notice.txt rename to java/maven.embedder/external/apache-maven-3.8.4-bin-notice.txt index c76d78acdde5..87b31c9b0a82 100644 --- a/java/maven.embedder/external/apache-maven-3.6.3-bin-notice.txt +++ b/java/maven.embedder/external/apache-maven-3.8.4-bin-notice.txt @@ -1,6 +1,6 @@ Apache Maven Distribution -Copyright 2001-2019 The Apache Software Foundation +Copyright 2001-2021 The Apache Software Foundation This product includes software developed at The Apache Software Foundation (http://www.apache.org/). @@ -26,7 +26,7 @@ javolution (http://javolution.org/). This product includes software developed by Rome (https://rome.dev.java.net/). -about.html in archive lib/org.eclipse.sisu.inject-0.3.4.jar +about.html in archive lib/org.eclipse.sisu.inject-0.3.5.jar diff --git a/java/maven.embedder/external/apache-maven-3.6.3-epl-license.txt b/java/maven.embedder/external/apache-maven-3.8.4-epl-license.txt similarity index 97% rename from java/maven.embedder/external/apache-maven-3.6.3-epl-license.txt rename to java/maven.embedder/external/apache-maven-3.8.4-epl-license.txt index 55a28b4d7166..e5249451a6be 100644 --- a/java/maven.embedder/external/apache-maven-3.6.3-epl-license.txt +++ b/java/maven.embedder/external/apache-maven-3.8.4-epl-license.txt @@ -1,9 +1,9 @@ Name: Apache Maven components under EPL v1.0 -Description: These Apache Maven components are under EPL v1.0: org.eclipse.sisu.inject-0.3.4.jar org.eclipse.sisu.plexus-0.3.4.jar -Version: 3.6.3 +Description: These Apache Maven components are under EPL v1.0: org.eclipse.sisu.inject-0.3.5.jar org.eclipse.sisu.plexus-0.3.5.jar +Version: 3.8.4 License: Maven-EPL-v10 Origin: Apache Software Foundation -Files: apache-maven-3.6.3-bin.zip!/apache-maven-3.6.3/lib/org.eclipse.sisu.inject-0.3.4.jar apache-maven-3.6.3-bin.zip!/apache-maven-3.6.3/lib/org.eclipse.sisu.plexus-0.3.4.jar +Files: apache-maven-3.8.4-bin.zip!/apache-maven-3.8.4/lib/org.eclipse.sisu.inject-0.3.5.jar apache-maven-3.8.4-bin.zip!/apache-maven-3.8.4/lib/org.eclipse.sisu.plexus-0.3.5.jar Eclipse Public License - v 1.0 diff --git a/java/maven.embedder/external/apache-maven-3.6.3-slf4j-license.txt b/java/maven.embedder/external/apache-maven-3.8.4-slf4j-license.txt similarity index 92% rename from java/maven.embedder/external/apache-maven-3.6.3-slf4j-license.txt rename to java/maven.embedder/external/apache-maven-3.8.4-slf4j-license.txt index f451e469c6a6..cb036615bdf2 100644 --- a/java/maven.embedder/external/apache-maven-3.6.3-slf4j-license.txt +++ b/java/maven.embedder/external/apache-maven-3.8.4-slf4j-license.txt @@ -1,9 +1,9 @@ Name: slf4j Description: Part of Apache Maven Distribution -Version: 3.6.3 +Version: 3.8.4 License: MIT-slf4j Origin: Apache Software Foundation -Files: apache-maven-3.6.3-bin.zip!/apache-maven-3.6.3/lib/slf4j-api-1.7.29.jar +Files: apache-maven-3.8.4-bin.zip!/apache-maven-3.8.4/lib/slf4j-api-1.7.32.jar Copyright (c) 2004-2017 QOS.ch All rights reserved. diff --git a/java/maven.embedder/external/binaries-list b/java/maven.embedder/external/binaries-list index 36f93a82e341..693764916631 100644 --- a/java/maven.embedder/external/binaries-list +++ b/java/maven.embedder/external/binaries-list @@ -16,4 +16,4 @@ # under the License. A2AC1CD690AB4C80DEFE7F9BCE14D35934C35CEC jdom:jdom:1.0 5D9CE6ADD7B714B8095F0E3E396C5E9F8C5DCFEF org.apache.maven.shared:maven-dependency-tree:2.2 -B36434A3A5C7A6B75AC955DF152E4325765D0804 org.apache.maven:apache-maven:3.6.3:bin@zip +765515B57D2F525BCB682DE9EC702F1D8703E9B9 org.apache.maven:apache-maven:3.8.4:bin@zip diff --git a/java/maven.embedder/external/binariesembedded-list b/java/maven.embedder/external/binariesembedded-list index 943fd47ba00a..054ff74d0f0b 100644 --- a/java/maven.embedder/external/binariesembedded-list +++ b/java/maven.embedder/external/binariesembedded-list @@ -15,46 +15,44 @@ # specific language governing permissions and limitations # under the License. -44C453F60909DFC223552ACE63E05C694215156B;javax.enterprise:cdi-api:1.0 C51C00206BB913CD8612B24ABD9FA98AE89719B1;commons-cli:commons-cli:1.4 -2852E6E05FBB95076FC091F6D1780F1F8FE35E0F;commons-io:commons-io:2.5 +815893DF5F31DA2ECE4040FE0A12FD44B577AFAF;commons-io:commons-io:2.6 6505A72A097D9270F7A9E7BF42C4238283247755;org.apache.commons:commons-lang3:3.8.1 BDAAB946CA5AD20253502D873BA0C3313D141036;com.google.guava:guava:25.1-android -41E5AB52EC65E60B6C0CED947BECF7BA96402645;com.google.inject:guice:4.2.1:no_aop -E90CAA31C9B8D748359450D7487F76B05549AE65;org.fusesource.jansi:jansi:1.17.1 +FA13659F9128F4C011C8E1D06F137083B4876377;com.google.inject:guice:4.2.2:no_aop +321C614F85F1DEA6BB08C1817C60D53B7F3552FD;org.fusesource.jansi:jansi:2.4.0 6975DA39A7040257BD51D21A231B76C915872D38;javax.inject:javax.inject:1 -D6DCA1EC36F28ECF286241DEADC790C2D4C8EAA0;org.slf4j:jcl-over-slf4j:1.7.29 -55819A28FC834C2F2BCF4DCDB278524DC3CF088F;org.jsoup:jsoup:1.12.1 -5025422767732A1AB45D93ABFEA846513D742DCF;javax.annotation:jsr250-api:1.0 -F8FF8032903882376E8D000C51E3E16D20FC7DF7;org.apache.maven:maven-artifact:3.6.3 -E9A37AF390009A525D8FAA6B18BD682123F85F9E;org.apache.maven:maven-builder-support:3.6.3 -2A8242398EFBFD533FFE36147864C34A326666DA;org.apache.maven:maven-compat:3.6.3 -ECA800AA73E750EC9A880EB224F0BB68F5B7873B;org.apache.maven:maven-core:3.6.3 -CC8DF86676BCB37F68D2CEAF05DF8EF6FB11D873;org.apache.maven:maven-embedder:3.6.3 -61C7848DCE2FBF7F7AB0FDC8E8A7CC9DA5DD7827;org.apache.maven:maven-model:3.6.3 -4EF1D56F53D3E0A9003B7CC82C89AF9878321E82;org.apache.maven:maven-model-builder:3.6.3 -063FE5967B9C4C1B6FA6004BE76E1C939E8BD1D6;org.apache.maven:maven-plugin-api:3.6.3 -14D28071C85E76B656C46C465DB91D394D6F48F0;org.apache.maven:maven-repository-metadata:3.6.3 -CEEE6B7EA1BC252AFA585FA32F76C2CDA206BDCD;org.apache.maven.resolver:maven-resolver-api:1.4.1 -C213352D609D576641AED35172157D46CD2003D4;org.apache.maven.resolver:maven-resolver-connector-basic:1.4.1 -1658CFA27978C5949C3A92086514A22CA85394E4;org.apache.maven.resolver:maven-resolver-impl:1.4.1 -115240B65C1D0E9745CB2012B977AFC3D1795F94;org.apache.maven:maven-resolver-provider:3.6.3 -905A024FF050E804A8A4DF53EEEE63CC7D153438;org.apache.maven.resolver:maven-resolver-spi:1.4.1 -F3268F4EE92227AB98B7BE0AC5122DAA2ED97E35;org.apache.maven.resolver:maven-resolver-transport-wagon:1.4.1 -3F6D4F4BC3E24B46A776B47CCFEAED9D2ED01549;org.apache.maven.resolver:maven-resolver-util:1.4.1 -BBF4E06DCDB0BB33D1546C080DF5C8D92B535D30;org.apache.maven:maven-settings:3.6.3 -756D46810B8CC7B2B98585CCC787854CDFDE7FD9;org.apache.maven:maven-settings-builder:3.6.3 -08DD4DFB1D2D8B6969F6462790F82670BCD35CE2;org.apache.maven.shared:maven-shared-utils:3.2.1 -DE3B6CF15C2974250AE88820AB6C210FD8F38ED3;org.apache.maven:maven-slf4j-provider:3.6.3 -FC3BE144183F54DC6F5C55E34462C1C2D89D7D96;org.eclipse.sisu:org.eclipse.sisu.inject:0.3.4 -F1335A3B7BC3FD23F67DA88BD60CD5D4C3304EF3;org.eclipse.sisu:org.eclipse.sisu.plexus:0.3.4 -51460409B6CDC2B828540C19C05691F89141EDC2;org.sonatype.plexus:plexus-cipher:1.7 +32C060250BCC5282CDBC1FD7008C12EB4EBAD00E;org.slf4j:jcl-over-slf4j:1.7.32 +479C1E06DB31C432330183F5CAE684163F186146;javax.annotation:javax.annotation.api:1.2 +6DBA6D03AC7ABD8B895595B0EE7000CE35C3D421;org.apache.maven:maven-artifact:3.8.4 +19E7C1DD9AB8C3266DB19E067E2B7B8764F0FA6A;org.apache.maven:maven-builder-support:3.8.4 +B084A01A5E6D92AC83E64C1FEA25FC019E9EE125;org.apache.maven:maven-compat:3.8.4 +CB11BAC5ED848B900C2533D42AE8F23A73E6A015;org.apache.maven:maven-core:3.8.4 +5159D6F217F646FEF15648EAD95B536337F04CDB;org.apache.maven:maven-embedder:3.8.4 +71057054EA1E5E341B2196804A426E3243F6CB2E;org.apache.maven:maven-model:3.8.4 +8E039DB854CEE3DDBCA932B90C0C06CDCB9DC640;org.apache.maven:maven-model-builder:3.8.4 +699BF28A990398CAA3C7DC860476C409FE538036;org.apache.maven:maven-plugin-api:3.8.4 +C62113372F740797767D520F604D0543DCDFC92F;org.apache.maven:maven-repository-metadata:3.8.4 +5EE235AA5AC5994B5DC847F8E78FFE9D77DD55D7;org.apache.maven.resolver:maven-resolver-api:1.6.3 +D1C8F8E30C2AAE85330E21329D42D7E7F12A7CC3;org.apache.maven.resolver:maven-resolver-connector-basic:1.6.3 +2714FFE60BD71259A41B3E4816122504B5F2DB93;org.apache.maven.resolver:maven-resolver-impl:1.6.3 +2CCBD1E2C713922353CCD779E56AEEFC7A9FA56F;org.apache.maven:maven-resolver-provider:3.8.4 +176425F73FE768BF9CDB8B5A742E7A00C1D8D178;org.apache.maven.resolver:maven-resolver-spi:1.6.3 +7BEC7BC7F6C71A0A793EF355CC908BFAA3DD5F6D;org.apache.maven.resolver:maven-resolver-transport-wagon:1.6.3 +07D5A6879037B34C61C2F527DFCFB59084E86ED0;org.apache.maven.resolver:maven-resolver-util:1.6.3 +ECE24EC40B7D73E755F2EBD22BF8471B6C0B8FBD;org.apache.maven:maven-settings:3.8.4 +50BF143B0E338A26651970860E3067DD94CF31AA;org.apache.maven:maven-settings-builder:3.8.4 +F87A61ADB1E12A00DCC6CC6005A51E693AA7C4AC;org.apache.maven.shared:maven-shared-utils:3.3.4 +5B4DBD3CF0B14038766A6E915D75646C6D396E5B;org.apache.maven:maven-slf4j-provider:3.8.4 +D4265DD4F0F1D7A06D80DF5A5F475D5FF9C17140;org.eclipse.sisu:org.eclipse.sisu.inject:0.3.5 +D71996BB2E536F966B3B70E647067FFF3B73D32F;org.eclipse.sisu:org.eclipse.sisu.plexus:0.3.5 +425EA8E534716B4BFF1EA90F39BD76BE951D651B;org.sonatype.plexus:plexus-cipher:2.0 8587E80FCB38E70B70FAE8D5914B6376BFAD6259;org.codehaus.plexus:plexus-classworlds:2.6.0 2F2147A6CC6A119A1B51A96F31D45C557F6244B9;org.codehaus.plexus:plexus-component-annotations:2.1.0 -3B37B3335E6A97E11E690BBDC22ADE1A5DEB74D6;org.codehaus.plexus:plexus-interpolation:1.25 -43FDE524E9B94C883727A9FDDB8669181B890EA7;org.sonatype.plexus:plexus-sec-dispatcher:1.4 -13B015768E0D04849D2794E4C47EB02D01A0DE32;org.codehaus.plexus:plexus-utils:3.2.1 -E56BF4473A4C6B71C7DD397A833DCE86D1993D9D;org.slf4j:slf4j-api:1.7.29 -9F4E71EFC815C087E32C2C80341C1ED5D9CBEDD6;org.apache.maven.wagon:wagon-file:3.3.4 -8152D42E1C416AF9B4B146FB1AA082BBCC55C557;org.apache.maven.wagon:wagon-http:3.3.4:shaded -7A99FDAA534AA8C01F01A447FE1C7AF5CFC7B0D5;org.apache.maven.wagon:wagon-provider-api:3.3.4 \ No newline at end of file +25B919C664B79795CCDE0EDE5CEE0FD68B544197;org.codehaus.plexus:plexus-interpolation:1.26 +F89C5080614FFD0764E49861895DBEDDE1B47237;org.sonatype.plexus:plexus-sec-dispatcher:2.0 +CF43B5391DE623B36FE066A21127BAEF82C64022;org.codehaus.plexus:plexus-utils:3.3.0 +CDCFF33940D9F2DE763BC41EA05A0BE5941176C3;org.slf4j:slf4j-api:1.7.32 +85876A5672B78AA2E817EEE495239CDDD7B598E7;org.apache.maven.wagon:wagon-file:3.4.3 +FAF4DE1C28C670B22F25705A20DB3E8EE323FB04;org.apache.maven.wagon:wagon-http:3.4.3:shaded +35AEA87712379DB1844B2001AA644D709EA46877;org.apache.maven.wagon:wagon-provider-api:3.4.3 diff --git a/java/maven.embedder/nbproject/project.properties b/java/maven.embedder/nbproject/project.properties index a61eb1062587..aaeca8f28b04 100644 --- a/java/maven.embedder/nbproject/project.properties +++ b/java/maven.embedder/nbproject/project.properties @@ -20,7 +20,7 @@ javac.source=1.8 javac.compilerargs=-Xlint -Xlint:-serial release.external/jdom-1.0.jar=modules/ext/maven/jdom-1.0.jar release.external/maven-dependency-tree-2.2.jar=modules/ext/maven/maven-dependency-tree-2.2.jar -bundled.maven=apache-maven-3.6.3 +bundled.maven=apache-maven-3.8.4 extra.module.files=maven/ nbm.executable.files=maven/bin/mvn,maven/bin/mvnDebug,maven/bin/mvnyjp extra.license.files=${cluster}/maven/LICENSE.txt,${cluster}/maven/NOTICE.txt diff --git a/java/maven.embedder/nbproject/project.xml b/java/maven.embedder/nbproject/project.xml index ff4513c3c521..4cdbc3010cc3 100644 --- a/java/maven.embedder/nbproject/project.xml +++ b/java/maven.embedder/nbproject/project.xml @@ -284,14 +284,11 @@ ../maven/boot/plexus-classworlds-2.6.0.jar - - ../maven/lib/cdi-api-1.0.jar - ../maven/lib/commons-cli-1.4.jar - ../maven/lib/commons-io-2.5.jar + ../maven/lib/commons-io-2.6.jar ../maven/lib/commons-lang3-3.8.1.jar @@ -300,115 +297,112 @@ ../maven/lib/guava-25.1-android.jar - ../maven/lib/guice-4.2.1-no_aop.jar - - - ../maven/lib/jansi-1.17.1.jar + ../maven/lib/guice-4.2.2-no_aop.jar - ../maven/lib/javax.inject-1.jar + ../maven/lib/jansi-2.4.0.jar - ../maven/lib/jcl-over-slf4j-1.7.29.jar + ../maven/lib/javax.annotation-api-1.2.jar - ../maven/lib/jsoup-1.12.1.jar + ../maven/lib/javax.inject-1.jar - ../maven/lib/jsr250-api-1.0.jar + ../maven/lib/jcl-over-slf4j-1.7.32.jar - ../maven/lib/maven-artifact-3.6.3.jar + ../maven/lib/maven-artifact-3.8.4.jar - ../maven/lib/maven-builder-support-3.6.3.jar + ../maven/lib/maven-builder-support-3.8.4.jar - ../maven/lib/maven-compat-3.6.3.jar + ../maven/lib/maven-compat-3.8.4.jar - ../maven/lib/maven-core-3.6.3.jar + ../maven/lib/maven-core-3.8.4.jar - ../maven/lib/maven-embedder-3.6.3.jar + ../maven/lib/maven-embedder-3.8.4.jar - ../maven/lib/maven-model-3.6.3.jar + ../maven/lib/maven-model-3.8.4.jar - ../maven/lib/maven-model-builder-3.6.3.jar + ../maven/lib/maven-model-builder-3.8.4.jar - ../maven/lib/maven-plugin-api-3.6.3.jar + ../maven/lib/maven-plugin-api-3.8.4.jar - ../maven/lib/maven-repository-metadata-3.6.3.jar + ../maven/lib/maven-repository-metadata-3.8.4.jar - ../maven/lib/maven-resolver-api-1.4.1.jar + ../maven/lib/maven-resolver-api-1.6.3.jar - ../maven/lib/maven-resolver-connector-basic-1.4.1.jar + ../maven/lib/maven-resolver-connector-basic-1.6.3.jar - ../maven/lib/maven-resolver-impl-1.4.1.jar + ../maven/lib/maven-resolver-impl-1.6.3.jar - ../maven/lib/maven-resolver-provider-3.6.3.jar + ../maven/lib/maven-resolver-provider-3.8.4.jar - ../maven/lib/maven-resolver-spi-1.4.1.jar + ../maven/lib/maven-resolver-spi-1.6.3.jar - ../maven/lib/maven-resolver-transport-wagon-1.4.1.jar + ../maven/lib/maven-resolver-transport-wagon-1.6.3.jar - ../maven/lib/maven-resolver-util-1.4.1.jar + ../maven/lib/maven-resolver-util-1.6.3.jar - ../maven/lib/maven-settings-3.6.3.jar + ../maven/lib/maven-settings-3.8.4.jar - ../maven/lib/maven-settings-builder-3.6.3.jar + ../maven/lib/maven-settings-builder-3.8.4.jar - ../maven/lib/maven-shared-utils-3.2.1.jar + ../maven/lib/maven-shared-utils-3.3.4.jar - ../maven/lib/maven-slf4j-provider-3.6.3.jar + ../maven/lib/maven-slf4j-provider-3.8.4.jar - ../maven/lib/org.eclipse.sisu.inject-0.3.4.jar + ../maven/lib/org.eclipse.sisu.inject-0.3.5.jar - ../maven/lib/org.eclipse.sisu.plexus-0.3.4.jar + ../maven/lib/org.eclipse.sisu.plexus-0.3.5.jar - ../maven/lib/plexus-cipher-1.7.jar + ../maven/lib/plexus-cipher-2.0.jar ../maven/lib/plexus-component-annotations-2.1.0.jar - ../maven/lib/plexus-interpolation-1.25.jar + ../maven/lib/plexus-interpolation-1.26.jar - ../maven/lib/plexus-sec-dispatcher-1.4.jar + ../maven/lib/plexus-sec-dispatcher-2.0.jar - ../maven/lib/plexus-utils-3.2.1.jar + ../maven/lib/plexus-utils-3.3.0.jar - ../maven/lib/slf4j-api-1.7.29.jar + ../maven/lib/slf4j-api-1.7.32.jar - ../maven/lib/wagon-file-3.3.4.jar + ../maven/lib/wagon-file-3.4.3.jar - ../maven/lib/wagon-http-3.3.4-shaded.jar + ../maven/lib/wagon-http-3.4.3-shaded.jar - ../maven/lib/wagon-provider-api-3.3.4.jar + ../maven/lib/wagon-provider-api-3.4.3.jar diff --git a/nbbuild/antsrc/org/netbeans/nbbuild/extlibs/ignored-overlaps b/nbbuild/antsrc/org/netbeans/nbbuild/extlibs/ignored-overlaps index 0ae8845b56e1..07e96eb3d194 100644 --- a/nbbuild/antsrc/org/netbeans/nbbuild/extlibs/ignored-overlaps +++ b/nbbuild/antsrc/org/netbeans/nbbuild/extlibs/ignored-overlaps @@ -32,7 +32,8 @@ ide/db.dataview/external/commons-compress-1.20.jar java/java.disco/external/comm # It happens that maven 3.3.9 uses commons-lang-2.6.jar, same as o.apache.commons.lang # and commons-io-2.5.jar, same as java.lsp.server # These are used independently, different functional goals -java/java.lsp.server/external/commons-io-2.5.jar java/maven.embedder/external/apache-maven-3.6.3-bin.zip +# maven 3.8.4 use common-io-2.6 java/java.lsp.server/external/commons-io-2.5.jar java/maven.embedder/external/apache-maven-3.6.3-bin.zip +platform/o.apache.commons.io/external/commons-io-2.6.jar java/maven.embedder/external/apache-maven-3.8.4-bin.zip # Contains test data (badPackageFileInJar.jar is packaged twice) - this is an # upstream problem @@ -48,6 +49,10 @@ webcommon/javascript2.jade/external/jflex-1.4.3.jar webcommon/javascript2.lexer/ enterprise/javaee.api/external/javax.annotation-api-1.2.jar java/maven.indexer/external/javax.annotation-api-1.2.jar enterprise/javaee7.api/external/javax.annotation-api-1.2.jar enterprise/javaee8.api/external/javax.annotation-api-1.2.jar enterprise/javaee8.api/external/javax.annotation-api-1.2.jar java/maven.indexer/external/javax.annotation-api-1.2.jar +enterprise/javaee8.api/external/javax.annotation-api-1.2.jar java/maven.embedder/external/apache-maven-3.8.4-bin.zip +enterprise/javaee7.api/external/javax.annotation-api-1.2.jar java/maven.embedder/external/apache-maven-3.8.4-bin.zip +java/maven.indexer/external/javax.annotation-api-1.2.jar java/maven.embedder/external/apache-maven-3.8.4-bin.zip + # jaxb-api-osgi is used by multiple modules. enterprise/javaee.api/external/jaxb-api-osgi-2.2.7.jar enterprise/javaee7.api/external/jaxb-api-osgi-2.2.7.jar @@ -71,7 +76,7 @@ extide/gradle/external/gradle-7.3-bin.zip ide/c.jcraft.jzlib/external/jzlib-1.1. extide/gradle/external/gradle-7.3-bin.zip ide/libs.antlr4.runtime/external/antlr4-runtime-4.7.2.jar extide/gradle/external/gradle-7.3-bin.zip ide/o.apache.commons.lang/external/commons-lang-2.6.jar extide/gradle/external/gradle-7.3-bin.zip ide/o.eclipse.jgit/external/org.eclipse.jgit-5.7.0.202003110725-r.jar -extide/gradle/external/gradle-7.3-bin.zip java/maven.embedder/external/apache-maven-3.6.3-bin.zip +extide/gradle/external/gradle-7.3-bin.zip java/maven.embedder/external/apache-maven-3.8.4-bin.zip extide/gradle/external/gradle-7.3-bin.zip platform/libs.junit4/external/hamcrest-core-1.3.jar extide/gradle/external/gradle-7.3-bin.zip platform/libs.junit4/external/junit-4.13.2.jar extide/gradle/external/gradle-7.3-bin.zip platform/libs.testng/external/jcommander-1.78.jar From b5b45e31e5cc550e0957151ac65cb84a1581fe52 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Matthias=20Bl=C3=A4sing?= Date: Fri, 10 Dec 2021 22:22:34 +0100 Subject: [PATCH 2/3] Upgrade to Apache Maven 3.8.4: Adjust to DefaultModelBuilder changes In maven 3.6 the method ModelBuilder#build(ModelBuildingRequest, ModelBuildingResult) at the end of the call to ModelBuilder#build(ModelBuildingRequest) In 3.8.X the call chain was modified, so a private method of DefaultModelBuilder is called instead of the two parameter public method. The implementation in NBModelBuilder called first the super implementation. So in essence the sequence in the past was: - NBModelBuilder#build(ModelBuildingRequest) - DefaultModelBuilder#build(ModelBuildingRequest) - NBModelBuilder#build(ModelBuildingRequest, ModelBuildingResult) - DefaultModelBuilder#build(ModelBuildingRequest, ModelBuildingResult) - [NB Extensions] - [NB Extensions] The modified implementation ensures, that the post processing happens independend from the call chain. --- .../maven/embedder/impl/NBModelBuilder.java | 34 +++++++++++-------- 1 file changed, 19 insertions(+), 15 deletions(-) diff --git a/java/maven.embedder/src/org/netbeans/modules/maven/embedder/impl/NBModelBuilder.java b/java/maven.embedder/src/org/netbeans/modules/maven/embedder/impl/NBModelBuilder.java index 0b2f7103798a..8ed0fbc4230c 100644 --- a/java/maven.embedder/src/org/netbeans/modules/maven/embedder/impl/NBModelBuilder.java +++ b/java/maven.embedder/src/org/netbeans/modules/maven/embedder/impl/NBModelBuilder.java @@ -47,10 +47,11 @@ public class NBModelBuilder extends DefaultModelBuilder { private static final String NETBEANS_PROFILES = "____netbeans.profiles"; private static final String NETBEANS_MODELDESCS = "____netbeans.model.descriptions"; - + @Override public ModelBuildingResult build(ModelBuildingRequest request) throws ModelBuildingException { ModelBuildingResult toRet = super.build(request); + postProcessResult(request, toRet); Model eff = toRet.getEffectiveModel(); InputSource source = new InputSource(); source.setLocation(""); @@ -64,7 +65,14 @@ public ModelBuildingResult build(ModelBuildingRequest request) throws ModelBuild } return toRet; } - + + @Override + public ModelBuildingResult build(ModelBuildingRequest request, ModelBuildingResult result) throws ModelBuildingException { + ModelBuildingResult mbr = super.build(request, result); + postProcessResult(request, result); + return mbr; + } + private static class ModelInputSource extends InputSource { final List rawModels; @@ -75,21 +83,19 @@ public ModelInputSource(List rawModels) { } } - @Override - public ModelBuildingResult build(ModelBuildingRequest request, ModelBuildingResult result) throws ModelBuildingException { - ModelBuildingResult toRet = super.build(request, result); - if (request.getPomFile() != null) { - List rawModels = new ArrayList(); - for (String id : toRet.getModelIds()) { + private void postProcessResult(ModelBuildingRequest request, ModelBuildingResult result) throws ModelBuildingException { + if (request.getPomFile() != null && result.getEffectiveModel().getLocation(NETBEANS_MODELDESCS) == null) { + List rawModels = new ArrayList<>(); + for (String id : result.getModelIds()) { if (id != null && id.trim().length() > 0) { //skip the default super pom - Model m = toRet.getRawModel(id); - List modules = new ArrayList(); + Model m = result.getRawModel(id); + List modules = new ArrayList<>(); for (String module : m.getModules()) { modules.add(module); } String name = m.getName(); - List profiles = new ArrayList(); + List profiles = new ArrayList<>(); for (Profile p : m.getProfiles()) { profiles.add(p.getId()); //TODO for activated profiles, not entirely correct. @@ -106,15 +112,13 @@ public ModelBuildingResult build(ModelBuildingRequest request, ModelBuildingResu rawModels.add(new ModelDescImpl(id, loc, name, profiles, modules)); } } - toRet.getEffectiveModel().setLocation(NETBEANS_MODELDESCS, new InputLocation(-1, -1, new ModelInputSource(rawModels))); + result.getEffectiveModel().setLocation(NETBEANS_MODELDESCS, new InputLocation(-1, -1, new ModelInputSource(rawModels))); } - return toRet; } - public static Set getAllProfiles(Model mdl) { InputLocation location = mdl.getLocation(NETBEANS_PROFILES); - HashSet toRet = new HashSet(); + HashSet toRet = new HashSet<>(); if (location != null) { String s = location.getSource().getLocation(); if (!s.isEmpty()) { From d4b4f5faf226d2dce832bc67f2144c9528d83547 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Matthias=20Bl=C3=A4sing?= Date: Thu, 16 Dec 2021 19:57:26 +0100 Subject: [PATCH 3/3] Stabilize ShellConstructorTest and RunJarStartupArgsTest on JDK 9+ ---------- RunJarStartupArgsTest ---------- Without maven.compiler.source and maven.compiler.target set, they are defaulted to 1.5. This will fail on recent JDKs. Instead use the java version from the running JDK, which can be assumed to be a save default. ---------- ShellConstructorTest --------- The test is flaky and it was found, that sometimes the maven CLI version is reported to be NULL. Closed analysis showed, that this is caused by a IOException, referencing to an unexpected end of zlib input stream. The issue seems to be, that the ArchiveURLMapper caches jars and the test in rapid succession deletes jars and recreates them. This change moves dummy JAR creation from per Test to per Testcase. This shoud stabilize the test. --- .../execute/cmd/ShellConstructorTest.java | 89 ++++++++++--------- .../maven/runjar/RunJarStartupArgsTest.java | 4 +- 2 files changed, 51 insertions(+), 42 deletions(-) diff --git a/java/maven/test/unit/src/org/netbeans/modules/maven/execute/cmd/ShellConstructorTest.java b/java/maven/test/unit/src/org/netbeans/modules/maven/execute/cmd/ShellConstructorTest.java index c720aee208f5..dd179512fdbd 100644 --- a/java/maven/test/unit/src/org/netbeans/modules/maven/execute/cmd/ShellConstructorTest.java +++ b/java/maven/test/unit/src/org/netbeans/modules/maven/execute/cmd/ShellConstructorTest.java @@ -19,7 +19,6 @@ package org.netbeans.modules.maven.execute.cmd; import java.io.File; -import java.io.FileNotFoundException; import java.io.FileOutputStream; import java.io.IOException; import java.lang.reflect.Method; @@ -34,54 +33,25 @@ import java.util.jar.JarEntry; import java.util.jar.JarOutputStream; import java.util.jar.Manifest; +import org.junit.After; +import org.junit.AfterClass; +import org.junit.Before; +import org.junit.BeforeClass; import org.junit.Test; -import org.netbeans.junit.NbTestCase; import org.netbeans.modules.maven.options.MavenSettings; import org.openide.util.Utilities; +import static org.junit.Assert.*; /** * * */ -public class ShellConstructorTest extends NbTestCase { +public class ShellConstructorTest { - private final File MAVENMOCK_DIR = new File(this.getDataDir(), "mavenmock"); - - public ShellConstructorTest(String name) throws FileNotFoundException, IOException { - super(name); - } - - @Override - protected void tearDown() throws Exception { -// Files.walkFileTree(MAVENMOCK_DIR.toPath(), new FileVisitor() { -// @Override -// public FileVisitResult preVisitDirectory(Path t, BasicFileAttributes bfa) throws IOException { -// return FileVisitResult.CONTINUE; -// } -// -// @Override -// public FileVisitResult visitFile(Path t, BasicFileAttributes bfa) throws IOException { -// Files.delete(t); -// return FileVisitResult.CONTINUE; -// } -// -// @Override -// public FileVisitResult visitFileFailed(Path t, IOException ioe) throws IOException { -// throw ioe; -// } -// -// @Override -// public FileVisitResult postVisitDirectory(Path t, IOException ioe) throws IOException { -// Files.delete(t); -// return FileVisitResult.CONTINUE; -// } -// }); - resetOs(); - } + private static final File MAVENMOCK_DIR = new File(System.getProperty("xtest.data"), "mavenmock"); - @Override - protected void setUp() throws Exception { - resetOs(); + @BeforeClass + public static void setUpBeforeClass() throws Exception { // Prepare mock maven directories createMock("2.2", "2.2.1"); createMock("3.0.5", "3.0.5"); @@ -89,7 +59,44 @@ protected void setUp() throws Exception { createMock("4.0.0", "4.0.0"); } - private void createMock(String dirName, String version) throws IOException { + @AfterClass + public static void tearDownAfterClass() throws Exception { + Files.walkFileTree(MAVENMOCK_DIR.toPath(), new FileVisitor() { + @Override + public FileVisitResult preVisitDirectory(Path t, BasicFileAttributes bfa) throws IOException { + return FileVisitResult.CONTINUE; + } + + @Override + public FileVisitResult visitFile(Path t, BasicFileAttributes bfa) throws IOException { + Files.delete(t); + return FileVisitResult.CONTINUE; + } + + @Override + public FileVisitResult visitFileFailed(Path t, IOException ioe) throws IOException { + throw ioe; + } + + @Override + public FileVisitResult postVisitDirectory(Path t, IOException ioe) throws IOException { + Files.delete(t); + return FileVisitResult.CONTINUE; + } + }); + } + + @After + public void tearDown() throws Exception { + resetOs(); + } + + @Before + public void setUp() throws Exception { + resetOs(); + } + + private static void createMock(String dirName, String version) throws IOException { File mockDir = new File(new File(MAVENMOCK_DIR, dirName), "lib"); mockDir.mkdirs(); Properties properties = new Properties(); @@ -149,7 +156,7 @@ public void testShellconstructoronWindows() throws Exception { } private boolean getCLI(String folder, String requestedversion, String mvn) { - File sourceJar = new File(this.getDataDir(), "mavenmock/" + folder + "/"); + File sourceJar = new File(MAVENMOCK_DIR, folder + "/"); String version = MavenSettings.getCommandLineMavenVersion(sourceJar); assertEquals(requestedversion, version); ShellConstructor shellConstructor = new ShellConstructor(sourceJar); diff --git a/java/maven/test/unit/src/org/netbeans/modules/maven/runjar/RunJarStartupArgsTest.java b/java/maven/test/unit/src/org/netbeans/modules/maven/runjar/RunJarStartupArgsTest.java index 5d8914f4e38a..7ef761a3cb8c 100644 --- a/java/maven/test/unit/src/org/netbeans/modules/maven/runjar/RunJarStartupArgsTest.java +++ b/java/maven/test/unit/src/org/netbeans/modules/maven/runjar/RunJarStartupArgsTest.java @@ -109,9 +109,11 @@ private Properties doTestSpacedExtender() throws Exception { " \n" + " test.PrintCommandLine\n" + " ${java.home}/bin/java\n" + + " " + System.getProperty("java.specification.version") + "\n" + + " " + System.getProperty("java.specification.version") + "\n" + " \n" + "\n"); - + FileObject f = FileUtil.createFolder(d, "src/main/java/test"); FileObject source = FileUtil.toFileObject(getDataDir()).getFileObject("exec/PrintCommandLine.java"); FileObject result = FileUtil.copyFile(source, f, source.getName());