diff options
author | Alexander Kurtakov | 2020-04-06 19:59:10 +0000 |
---|---|---|
committer | Alexander Kurtakov | 2020-04-06 20:25:02 +0000 |
commit | 010ec318bdf1484d2e3967558eef188877f48fcb (patch) | |
tree | 0c7135b09ec5ec4a2efe15632cd718103e4133d5 /bundles/org.eclipse.equinox.p2.artifact.repository | |
parent | a2c5904abc2b7b414da76814ca2d5c384603ad34 (diff) | |
download | rt.equinox.p2-010ec318bdf1484d2e3967558eef188877f48fcb.tar.gz rt.equinox.p2-010ec318bdf1484d2e3967558eef188877f48fcb.tar.xz rt.equinox.p2-010ec318bdf1484d2e3967558eef188877f48fcb.zip |
Bug 536106 - pack200 is being deprecated in java 11 and removed fromI20200408-0600I20200407-1800I20200407-1210I20200407-0120I20200406-1800
java 14
Fix Pack200ProcessorStep to still return OK if it's not enabled due to
missing pack200 utilities.
Disable some tests that rely on packed content.
Adjust others as on Java 14 packed content is not downloaded thus
results differ.
Change-Id: I65f16d4ebbc41e20ed7d2486ea9109fffa439779
Signed-off-by: Alexander Kurtakov <akurtako@redhat.com>
Diffstat (limited to 'bundles/org.eclipse.equinox.p2.artifact.repository')
3 files changed, 14 insertions, 4 deletions
diff --git a/bundles/org.eclipse.equinox.p2.artifact.repository/META-INF/MANIFEST.MF b/bundles/org.eclipse.equinox.p2.artifact.repository/META-INF/MANIFEST.MF index c0369a2ab..a0243631d 100644 --- a/bundles/org.eclipse.equinox.p2.artifact.repository/META-INF/MANIFEST.MF +++ b/bundles/org.eclipse.equinox.p2.artifact.repository/META-INF/MANIFEST.MF @@ -2,7 +2,7 @@ Manifest-Version: 1.0 Bundle-ManifestVersion: 2 Bundle-Name: %pluginName Bundle-SymbolicName: org.eclipse.equinox.p2.artifact.repository;singleton:=true -Bundle-Version: 1.3.400.qualifier +Bundle-Version: 1.3.500.qualifier Bundle-Activator: org.eclipse.equinox.internal.p2.artifact.repository.Activator Bundle-Vendor: %providerName Bundle-Localization: plugin diff --git a/bundles/org.eclipse.equinox.p2.artifact.repository/pom.xml b/bundles/org.eclipse.equinox.p2.artifact.repository/pom.xml index 49b7a10a8..df666e639 100644 --- a/bundles/org.eclipse.equinox.p2.artifact.repository/pom.xml +++ b/bundles/org.eclipse.equinox.p2.artifact.repository/pom.xml @@ -9,7 +9,7 @@ </parent> <groupId>org.eclipse.equinox</groupId> <artifactId>org.eclipse.equinox.p2.artifact.repository</artifactId> - <version>1.3.400-SNAPSHOT</version> + <version>1.3.500-SNAPSHOT</version> <packaging>eclipse-plugin</packaging> <profiles> <profile> diff --git a/bundles/org.eclipse.equinox.p2.artifact.repository/src/org/eclipse/equinox/internal/p2/artifact/processors/pack200/Pack200ProcessorStep.java b/bundles/org.eclipse.equinox.p2.artifact.repository/src/org/eclipse/equinox/internal/p2/artifact/processors/pack200/Pack200ProcessorStep.java index 9d4fd8580..9d85ac7ac 100644 --- a/bundles/org.eclipse.equinox.p2.artifact.repository/src/org/eclipse/equinox/internal/p2/artifact/processors/pack200/Pack200ProcessorStep.java +++ b/bundles/org.eclipse.equinox.p2.artifact.repository/src/org/eclipse/equinox/internal/p2/artifact/processors/pack200/Pack200ProcessorStep.java @@ -48,10 +48,18 @@ public class Pack200ProcessorStep extends AbstractBufferingStep { @Override public void initialize(IProvisioningAgent agent, IProcessingStepDescriptor descriptor, IArtifactDescriptor context) { super.initialize(agent, descriptor, context); + boolean isJava14 = false; + if (System.getProperty("java.specification.version").compareTo("14") >= 0) { //$NON-NLS-1$ //$NON-NLS-2$ + isJava14 = true; + } + if (!isEnabled()) { IStatus status = null; + // Missing pack200 executable is fine on Java 14+ + int statusCode = isJava14 ? IStatus.OK : IStatus.ERROR; if (detailedResult) { - status = new Status(IStatus.ERROR, Activator.ID, MirrorRequest.ARTIFACT_PROCESSING_ERROR, "Unpack facility not configured.", null); //$NON-NLS-1$ + status = new Status(statusCode, Activator.ID, MirrorRequest.ARTIFACT_PROCESSING_ERROR, + "Unpack facility not configured.", null); //$NON-NLS-1$ detailedResult = true; } else { String[] locations = Utils.getPack200Commands("unpack200"); //$NON-NLS-1$ @@ -59,7 +67,9 @@ public class Pack200ProcessorStep extends AbstractBufferingStep { for (String location : locations) { locationTried.append(location).append(", "); //$NON-NLS-1$ } - status = new Status(IStatus.ERROR, Activator.ID, MirrorRequest.ARTIFACT_PROCESSING_ERROR, "Unpack facility not configured. The locations searched for unpack200 are: " + locationTried, null); //$NON-NLS-1$ + status = new Status(statusCode, Activator.ID, MirrorRequest.ARTIFACT_PROCESSING_ERROR, + "Unpack facility not configured. The locations searched for unpack200 are: " + locationTried, //$NON-NLS-1$ + null); } setStatus(status); } |