Skip to content

Commit

Permalink
Revert "Upgrade Azure SDK and Jackson (#72833) (#72995) (#73493)" (#7…
Browse files Browse the repository at this point in the history
…3861)

The recent upgrade of the Azure SDK has caused a few test failures that
have been difficult to debug and do not yet have a fix. In particular, a
change to the netty reactor resolving
(reactor/reactor-netty#1655). We need to wait
for a fix for that issue, so this reverts commit
f454cef.

relates #73493
  • Loading branch information
rjernst authored Jun 8, 2021
1 parent 4c7c2d4 commit ddf4c69
Show file tree
Hide file tree
Showing 126 changed files with 143 additions and 139 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -88,7 +88,7 @@ if (System.getProperty('idea.active') == 'true') {
tasks.register('buildDependencyArtifacts') {
group = 'ide'
description = 'Builds artifacts needed as dependency for IDE modules'
dependsOn ':plugins:repository-hdfs:hadoop-common:shadowJar'
dependsOn ':plugins:repository-hdfs:hadoop-common:shadowJar', ':plugins:repository-azure:azure-storage-blob:shadowJar'
}

idea {
Expand Down
6 changes: 3 additions & 3 deletions build-tools-internal/version.properties
Original file line number Diff line number Diff line change
Expand Up @@ -9,8 +9,8 @@ checkstyle = 8.42
# optional dependencies
spatial4j = 0.7
jts = 1.15.0
jackson = 2.12.2
snakeyaml = 1.27
jackson = 2.10.4
snakeyaml = 1.26
icu4j = 62.1
supercsv = 2.4.0
# when updating log4j, please update also docs/java-api/index.asciidoc
Expand All @@ -20,7 +20,7 @@ slf4j = 1.6.2
# when updating the JNA version, also update the version in buildSrc/build.gradle
jna = 5.7.0-1

netty = 4.1.63.Final
netty = 4.1.49.Final
joda = 2.10.10

commons_lang3 = 3.9
Expand Down
1 change: 1 addition & 0 deletions client/sniffer/licenses/jackson-core-2.10.4.jar.sha1
Original file line number Diff line number Diff line change
@@ -0,0 +1 @@
8796585e716440d6dd5128b30359932a9eb74d0d
1 change: 0 additions & 1 deletion client/sniffer/licenses/jackson-core-2.12.2.jar.sha1

This file was deleted.

1 change: 1 addition & 0 deletions libs/x-content/licenses/jackson-core-2.10.4.jar.sha1
Original file line number Diff line number Diff line change
@@ -0,0 +1 @@
8796585e716440d6dd5128b30359932a9eb74d0d
1 change: 0 additions & 1 deletion libs/x-content/licenses/jackson-core-2.12.2.jar.sha1

This file was deleted.

Original file line number Diff line number Diff line change
@@ -0,0 +1 @@
c854bb2d46138198cb5d4aae86ef6c04b8bc1e70

This file was deleted.

Original file line number Diff line number Diff line change
@@ -0,0 +1 @@
c872c2e224cfdcc5481037d477f5890f05c001b4

This file was deleted.

Original file line number Diff line number Diff line change
@@ -0,0 +1 @@
8a7f3c6b640bd89214807af6d8160b4b3b16af93

This file was deleted.

1 change: 1 addition & 0 deletions libs/x-content/licenses/snakeyaml-1.26.jar.sha1
Original file line number Diff line number Diff line change
@@ -0,0 +1 @@
a78a8747147d2c5807683e76ec2b633e95c14fe9
1 change: 0 additions & 1 deletion libs/x-content/licenses/snakeyaml-1.27.jar.sha1

This file was deleted.

Original file line number Diff line number Diff line change
@@ -0,0 +1 @@
6ae6028aff033f194c9710ad87c224ccaadeed6c

This file was deleted.

Original file line number Diff line number Diff line change
@@ -0,0 +1 @@
76e9152e93d4cf052f93a64596f633ba5b1c8ed9

This file was deleted.

2 changes: 0 additions & 2 deletions modules/transport-netty4/build.gradle
Original file line number Diff line number Diff line change
Expand Up @@ -122,8 +122,6 @@ tasks.named("thirdPartyAudit").configure {
'io.netty.internal.tcnative.SSL',
'io.netty.internal.tcnative.SSLContext',
'io.netty.internal.tcnative.SSLPrivateKeyMethod',
'io.netty.internal.tcnative.SSLSession',
'io.netty.internal.tcnative.SSLSessionCache',

// from io.netty.handler.ssl.util.BouncyCastleSelfSignedCertGenerator (netty)
'org.bouncycastle.cert.X509v3CertificateBuilder',
Expand Down
Original file line number Diff line number Diff line change
@@ -0,0 +1 @@
8e819a81bca88d1e88137336f64531a53db0a4ad

This file was deleted.

Original file line number Diff line number Diff line change
@@ -0,0 +1 @@
20218de83c906348283f548c255650fd06030424

This file was deleted.

Original file line number Diff line number Diff line change
@@ -0,0 +1 @@
4f30dbc462b26c588dffc0eb7552caef1a0f549e

This file was deleted.

Original file line number Diff line number Diff line change
@@ -0,0 +1 @@
927c8563a1662d869b145e70ce82ad89100f2c90

This file was deleted.

Original file line number Diff line number Diff line change
@@ -0,0 +1 @@
c73443adb9d085d5dc2d5b7f3bdd91d5963976f7

This file was deleted.

Original file line number Diff line number Diff line change
@@ -0,0 +1 @@
eb81e1f0eaa99e75983bf3d28cae2b103e0f3a34

This file was deleted.

Original file line number Diff line number Diff line change
@@ -0,0 +1 @@
415ea7f326635743aec952fe2349ca45959e94a7

This file was deleted.

Original file line number Diff line number Diff line change
@@ -0,0 +1 @@
6ae6028aff033f194c9710ad87c224ccaadeed6c

This file was deleted.

Original file line number Diff line number Diff line change
@@ -0,0 +1 @@
76e9152e93d4cf052f93a64596f633ba5b1c8ed9

This file was deleted.

47 changes: 47 additions & 0 deletions plugins/repository-azure/azure-storage-blob/build.gradle
Original file line number Diff line number Diff line change
@@ -0,0 +1,47 @@
import org.elasticsearch.gradle.internal.JavaClassPublicifier;

apply plugin: 'elasticsearch.java'
apply plugin: 'com.github.johnrengelman.shadow'

configurations {
originalJar {
transitive = false
}
}

dependencies {
originalJar "com.azure:azure-storage-blob:${project.parent.versions.azure}"
implementation "com.azure:azure-storage-blob:${project.parent.versions.azure}"
}

// We have to rewrite the service classes to make them public to avoid
// granting the permission "java.lang.reflect.ReflectPermission" "newProxyInPackage"
// to this plugin.
//
// There are plans to make those public in the azure sdk side, but in the meanwhile
// we just do this workaround
// https://github.com/Azure/azure-sdk-for-java/issues/12829#issuecomment-736755543
List<String> classesToRewrite = ['com/azure/storage/blob/implementation/AppendBlobsImpl$AppendBlobsService.class',
'com/azure/storage/blob/implementation/BlobsImpl$BlobsService.class',
'com/azure/storage/blob/implementation/BlockBlobsImpl$BlockBlobsService.class',
'com/azure/storage/blob/implementation/ContainersImpl$ContainersService.class',
'com/azure/storage/blob/implementation/DirectorysImpl$DirectorysService.class',
'com/azure/storage/blob/implementation/PageBlobsImpl$PageBlobsService.class',
'com/azure/storage/blob/implementation/ServicesImpl$ServicesService.class']

tasks.register('extractClientClasses', Copy).configure {
from({ zipTree(configurations.originalJar.singleFile) }) {
include "com/azure/storage/blob/implementation/**"
}
into project.file('build/original')
}

def modifiedOutput = project.layout.buildDirectory.dir('modified')
def makePublic = tasks.register('makeClientClassesPublic', JavaClassPublicifier) {
dependsOn 'extractClientClasses'
classFiles = classesToRewrite
inputDir = project.layout.buildDirectory.dir('original')
outputDir = modifiedOutput
}

sourceSets.main.output.dir(modifiedOutput, builtBy: makePublic)
54 changes: 23 additions & 31 deletions plugins/repository-azure/build.gradle
Original file line number Diff line number Diff line change
Expand Up @@ -22,34 +22,38 @@ esplugin {
}

versions << [
'azure': '12.11.1',
'azureCore': '1.16.0',
'azureCoreHttpNetty': '1.9.1',
'azureAvro': '12.0.4',
'azure': '12.9.0',
'azureCore': '1.10.0',
'azureCoreHttpNetty': '1.6.3',

'jakartaActivation': '1.2.1',
'jakartaXMLBind': '2.3.2',
'stax2API': '4.2',
'woodstox': '6.2.4',
'woodstox': '6.0.2',

'reactorNetty': '1.0.6',
'reactorCore': '3.4.5',
'reactorNetty': '0.9.12.RELEASE',
'reactorCore': '3.3.10.RELEASE',
'reactiveStreams': '1.0.3',
]

dependencies {
api project(path: 'azure-storage-blob', configuration: 'shadow')
if (isEclipse) {
/*
* Eclipse can't pick up the shadow dependency so we point it at *something*
* so it can compile things.
*/
api project(path: 'azure-storage-blob')
}
api "com.azure:azure-storage-common:${versions.azure}"
api "com.azure:azure-storage-blob:${versions.azure}"
api "com.azure:azure-core-http-netty:${versions.azureCoreHttpNetty}"
api "com.azure:azure-core:${versions.azureCore}"
api "com.azure:azure-storage-internal-avro:${versions.azureAvro}"

// jackson
api "com.fasterxml.jackson.core:jackson-core:${versions.jackson}"
api "com.fasterxml.jackson.core:jackson-databind:${versions.jackson}"
api "com.fasterxml.jackson.core:jackson-annotations:${versions.jackson}"
api "com.fasterxml.jackson.core:jackson-databind:${versions.jackson}"
api "com.fasterxml.jackson:jackson-bom:${versions.jackson}"

// jackson xml
api "com.fasterxml.jackson.dataformat:jackson-dataformat-xml:${versions.jackson}"
Expand All @@ -60,23 +64,18 @@ dependencies {

// netty
api "io.netty:netty-buffer:${versions.netty}"
api "io.netty:netty-codec:${versions.netty}"
api "io.netty:netty-codec-dns:${versions.netty}"
api "io.netty:netty-codec-http:${versions.netty}"
api "io.netty:netty-codec-http2:${versions.netty}"
api "io.netty:netty-codec-socks:${versions.netty}"
api "io.netty:netty-codec:${versions.netty}"
api "io.netty:netty-common:${versions.netty}"
api "io.netty:netty-handler:${versions.netty}"
api "io.netty:netty-handler-proxy:${versions.netty}"
api "io.netty:netty-handler:${versions.netty}"
api "io.netty:netty-resolver:${versions.netty}"
api "io.netty:netty-resolver-dns:${versions.netty}"
api "io.netty:netty-transport:${versions.netty}"
api "io.netty:netty-transport-native-unix-common:${versions.netty}"

// reactor
api "io.projectreactor.netty:reactor-netty:${versions.reactorNetty}"
api "io.projectreactor.netty:reactor-netty-core:${versions.reactorNetty}"
api "io.projectreactor.netty:reactor-netty-http:${versions.reactorNetty}"
api "io.projectreactor:reactor-core:${versions.reactorCore}"
api "org.reactivestreams:reactive-streams:${versions.reactiveStreams}"

Expand Down Expand Up @@ -106,7 +105,6 @@ tasks.named("dependencyLicenses").configure {
mapping from: /netty-.*/, to: 'netty'
mapping from: /jaxb-.*/, to: 'jaxb'
mapping from: /stax-.*/, to: 'stax'
mapping from: /reactor-netty-.*/, to: 'reactor-netty'
mapping from: /reactive-streams.*/, to: 'reactive-streams'
}

Expand Down Expand Up @@ -240,8 +238,6 @@ tasks.named("thirdPartyAudit").configure {
'io.netty.internal.tcnative.CertificateVerifier',
'io.netty.internal.tcnative.SessionTicketKey',
'io.netty.internal.tcnative.SniHostNameMatcher',
'io.netty.internal.tcnative.SSLSession',
'io.netty.internal.tcnative.SSLSessionCache',

// from io.netty.util.internal.Hidden (netty-common optional dependency)
'reactor.blockhound.BlockHound$Builder',
Expand All @@ -250,23 +246,14 @@ tasks.named("thirdPartyAudit").configure {
// it uses NIO
'io.netty.channel.kqueue.KQueue',
'io.netty.channel.kqueue.KQueueDatagramChannel',
'io.netty.channel.kqueue.KQueueDomainSocketChannel',
'io.netty.channel.kqueue.KQueueEventLoopGroup',
'io.netty.channel.kqueue.KQueueServerDomainSocketChannel',
'io.netty.channel.kqueue.KQueueServerSocketChannel',
'io.netty.channel.kqueue.KQueueSocketChannel',
'io.netty.channel.epoll.Epoll',
'io.netty.channel.epoll.EpollDatagramChannel',
'io.netty.channel.epoll.EpollDomainSocketChannel',
'io.netty.channel.epoll.EpollEventLoopGroup',
'io.netty.channel.epoll.EpollServerDomainSocketChannel',
'io.netty.channel.epoll.EpollServerSocketChannel',
'io.netty.channel.epoll.EpollSocketChannel',
'io.netty.incubator.channel.uring.IOUring',
'io.netty.incubator.channel.uring.IOUringDatagramChannel',
'io.netty.incubator.channel.uring.IOUringEventLoopGroup',
'io.netty.incubator.channel.uring.IOUringServerSocketChannel',
'io.netty.incubator.channel.uring.IOUringSocketChannel',

// from reactor.netty.http.server.HttpServer (reactor-netty)
'io.netty.handler.codec.haproxy.HAProxyMessage',
Expand All @@ -278,8 +265,7 @@ tasks.named("thirdPartyAudit").configure {

'org.slf4j.impl.StaticLoggerBinder',
'org.slf4j.impl.StaticMDCBinder',
'org.slf4j.impl.StaticMarkerBinder',
'com.ctc.wstx.shaded.msv_core.driver.textui.Driver',
'org.slf4j.impl.StaticMarkerBinder'
)

if (BuildParams.runtimeJavaVersion <= JavaVersion.VERSION_1_8) {
Expand All @@ -295,6 +281,8 @@ tasks.named("thirdPartyAudit").configure {
)
} else {
ignoreMissingClasses(
'com.sun.org.apache.xml.internal.resolver.Catalog',
'com.sun.org.apache.xml.internal.resolver.tools.CatalogResolver',
'javax.activation.DataHandler',
'javax.activation.DataSource',
'javax.xml.bind.JAXBElement',
Expand Down Expand Up @@ -345,7 +333,11 @@ tasks.named("thirdPartyAudit").configure {
'io.netty.util.internal.shaded.org.jctools.util.UnsafeAccess',
'io.netty.util.internal.shaded.org.jctools.util.UnsafeRefArrayAccess',

'reactor.core.publisher.MultiProducerRingBuffer',
'reactor.core.publisher.RingBufferFields',
'reactor.core.publisher.Traces$SharedSecretsCallSiteSupplierFactory$TracingException',
'reactor.core.publisher.UnsafeSequence',
'reactor.core.publisher.UnsafeSupport'
)
}
boolean useFixture = false
Expand Down
Original file line number Diff line number Diff line change
@@ -0,0 +1 @@
d5e1258ba153b5e27c90b7c9cad262e6fc171d24

This file was deleted.

Original file line number Diff line number Diff line change
@@ -0,0 +1 @@
1c72bdc36faad65f53dd160becc38dd93a7356e2

This file was deleted.

This file was deleted.

This file was deleted.

Original file line number Diff line number Diff line change
@@ -0,0 +1 @@
42d0439a676e51bb1dea809c60e8a925bb07477c

This file was deleted.

Original file line number Diff line number Diff line change
@@ -0,0 +1 @@
6ae6028aff033f194c9710ad87c224ccaadeed6c

This file was deleted.

Original file line number Diff line number Diff line change
@@ -0,0 +1 @@
76e9152e93d4cf052f93a64596f633ba5b1c8ed9

This file was deleted.

Original file line number Diff line number Diff line change
@@ -0,0 +1 @@
ffd80322264922e7edb6b35139ec1f2f55824156

This file was deleted.

Original file line number Diff line number Diff line change
@@ -0,0 +1 @@
de00203e6fee3493c8978a0064a3dda2e8373545

This file was deleted.

Original file line number Diff line number Diff line change
@@ -0,0 +1 @@
68364602aed552c0dcfc5743b393bad95c85b009

This file was deleted.

Original file line number Diff line number Diff line change
@@ -0,0 +1 @@
8e819a81bca88d1e88137336f64531a53db0a4ad

This file was deleted.

Original file line number Diff line number Diff line change
@@ -0,0 +1 @@
20218de83c906348283f548c255650fd06030424
Loading

0 comments on commit ddf4c69

Please sign in to comment.