-
Notifications
You must be signed in to change notification settings - Fork 138
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
[BUG] Unable to find a model due to decryption error #1287
Comments
Its the same bouncycastle NoClassDefFound, looks like a linker error. |
Checking out 2.x and running integration tests are failing with:
|
I am using the 2.x branch. |
This - opensearch-project/OpenSearch#9833 - seems to have fixed this issue. |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
What is the bug?
Read operations on registered models are failing with the following stack trace:
{"type": "server", "timestamp": "2023-09-06T01:11:51,908Z", "level": "ERROR", "component": "o.o.m.e.a.r.RemoteModel", "cluster.name": "opensearch-cluster", "node.name": "os-conversation-node2", "message": "Failed to init remote model", "cluster.uuid": "1mwDvBpJQiOUte6CMfwMMQ", "node.id": "JhN1kctFS-qyiXZJxEwUJw" ,
| "stacktrace": ["java.lang.NoClassDefFoundError: org/bouncycastle/util/encoders/Base64",
| "at com.amazonaws.encryptionsdk.internal.Utils.decodeBase64String(Utils.java:261) ~[aws-encryption-sdk-java-2.4.0.jar:?]",
| "at com.amazonaws.encryptionsdk.internal.TrailingSignatureAlgorithm$ECDSASignatureAlgorithm.deserializePublicKey(TrailingSignatureAlgorithm.java:117) ~[aws- encryption-sdk-java-2.4.0.jar:?]",
| "at com.amazonaws.encryptionsdk.DefaultCryptoMaterialsManager.deserializeTrailingKeyFromEc(DefaultCryptoMaterialsManager.java:149) ~[aws-encryption-sdk-java-2.4.0. jar:?]",
| "at com.amazonaws.encryptionsdk.DefaultCryptoMaterialsManager.decryptMaterials(DefaultCryptoMaterialsManager.java:134) ~[aws-encryption-sdk-java-2.4.0.jar:?]",
| "at com.amazonaws.encryptionsdk.internal.DecryptionHandler.readHeaderFields(DecryptionHandler.java:621) ~[aws-encryption-sdk-java-2.4.0.jar:?]",
| "at com.amazonaws.encryptionsdk.internal.DecryptionHandler.(DecryptionHandler.java:111) ~[aws-encryption-sdk-java-2.4.0.jar:?]",
| "at com.amazonaws.encryptionsdk.internal.DecryptionHandler.create(DecryptionHandler.java:302) ~[aws-encryption-sdk-java-2.4.0.jar:?]",
| "at com.amazonaws.encryptionsdk.AwsCrypto.decryptData(AwsCrypto.java:511) ~[aws-encryption-sdk-java-2.4.0.jar:?]",
| "at com.amazonaws.encryptionsdk.AwsCrypto.decryptData(AwsCrypto.java:502) ~[aws-encryption-sdk-java-2.4.0.jar:?]",
| "at com.amazonaws.encryptionsdk.AwsCrypto.decryptData(AwsCrypto.java:476) ~[aws-encryption-sdk-java-2.4.0.jar:?]",
| "at org.opensearch.ml.engine.encryptor.EncryptorImpl.decrypt(EncryptorImpl.java:90) ~[opensearch-ml-algorithms-2.10.0.0-SNAPSHOT.jar:?]",
| "at org.opensearch.ml.engine.algorithms.remote.RemoteModel.lambda$initModel$0(RemoteModel.java:80) ~[opensearch-ml-algorithms-2.10.0.0-SNAPSHOT.jar:?]",
| "at org.opensearch.ml.common.connector.HttpConnector.decrypt(HttpConnector.java:268) ~[opensearch-ml-common-2.10.0.0-SNAPSHOT.jar:?]",
| "at org.opensearch.ml.engine.algorithms.remote.RemoteModel.initModel(RemoteModel.java:80) [opensearch-ml-algorithms-2.10.0.0-SNAPSHOT.jar:?]",
| "at org.opensearch.ml.engine.MLEngine.deploy(MLEngine.java:125) [opensearch-ml-algorithms-2.10.0.0-SNAPSHOT.jar:?]",
| "at org.opensearch.ml.model.MLModelManager.setupPredictable(MLModelManager.java:844) [opensearch-ml-2.10.0.0-SNAPSHOT.jar:2.10.0.0-SNAPSHOT]",
| "at org.opensearch.ml.model.MLModelManager.lambda$deployModel$33(MLModelManager.java:771) [opensearch-ml-2.10.0.0-SNAPSHOT.jar:2.10.0.0-SNAPSHOT]",
| "at org.opensearch.core.action.ActionListener$1.onResponse(ActionListener.java:82) [opensearch-core-2.10.0-SNAPSHOT.jar:2.10.0-SNAPSHOT]",
| "at org.opensearch.action.support.TransportAction$1.onResponse(TransportAction.java:113) [opensearch-2.10.0-SNAPSHOT.jar:2.10.0-SNAPSHOT]",
| "at org.opensearch.action.support.TransportAction$1.onResponse(TransportAction.java:107) [opensearch-2.10.0-SNAPSHOT.jar:2.10.0-SNAPSHOT]",
| "at org.opensearch.action.support.single.shard.TransportSingleShardAction$AsyncSingleAction$2.handleResponse(TransportSingleShardAction.java:298) [opensearch-2.10.0- SNAPSHOT.jar:2.10.0-SNAPSHOT]",
| "at org.opensearch.action.support.single.shard.TransportSingleShardAction$AsyncSingleAction$2.handleResponse(TransportSingleShardAction.java:284) [opensearch-2.10.0- SNAPSHOT.jar:2.10.0-SNAPSHOT]",
| "at org.opensearch.transport.TransportService$ContextRestoreResponseHandler.handleResponse(TransportService.java:1496) [opensearch-2.10.0-SNAPSHOT.jar:2.10.0- SNAPSHOT]",
| "at org.opensearch.transport.InboundHandler.doHandleResponse(InboundHandler.java:394) [opensearch-2.10.0-SNAPSHOT.jar:2.10.0-SNAPSHOT]",
| "at org.opensearch.transport.InboundHandler.handleResponse(InboundHandler.java:386) [opensearch-2.10.0-SNAPSHOT.jar:2.10.0-SNAPSHOT]",
| "at org.opensearch.transport.InboundHandler.messageReceived(InboundHandler.java:161) [opensearch-2.10.0-SNAPSHOT.jar:2.10.0-SNAPSHOT]",
| "at org.opensearch.transport.InboundHandler.inboundMessage(InboundHandler.java:115) [opensearch-2.10.0-SNAPSHOT.jar:2.10.0-SNAPSHOT]",
| "at org.opensearch.transport.TcpTransport.inboundMessage(TcpTransport.java:767) [opensearch-2.10.0-SNAPSHOT.jar:2.10.0-SNAPSHOT]",
| "at org.opensearch.transport.InboundPipeline.forwardFragments(InboundPipeline.java:175) [opensearch-2.10.0-SNAPSHOT.jar:2.10.0-SNAPSHOT]",
| "at org.opensearch.transport.InboundPipeline.doHandleBytes(InboundPipeline.java:150) [opensearch-2.10.0-SNAPSHOT.jar:2.10.0-SNAPSHOT]",
| "at org.opensearch.transport.InboundPipeline.handleBytes(InboundPipeline.java:115) [opensearch-2.10.0-SNAPSHOT.jar:2.10.0-SNAPSHOT]",
| "at org.opensearch.transport.netty4.Netty4MessageChannelHandler.channelRead(Netty4MessageChannelHandler.java:95) [transport-netty4-client-2.10.0-SNAPSHOT.jar:2.10.0- SNAPSHOT]",
| "at io.netty.channel.AbstractChannelHandlerContext.invokeChannelRead(AbstractChannelHandlerContext.java:442) [netty-transport-4.1.97.Final.jar:4.1.97.Final]",
| "at io.netty.channel.AbstractChannelHandlerContext.invokeChannelRead(AbstractChannelHandlerContext.java:420) [netty-transport-4.1.97.Final.jar:4.1.97.Final]",
| "at io.netty.channel.AbstractChannelHandlerContext.fireChannelRead(AbstractChannelHandlerContext.java:412) [netty-transport-4.1.97.Final.jar:4.1.97.Final]",
| "at io.netty.handler.logging.LoggingHandler.channelRead(LoggingHandler.java:280) [netty-handler-4.1.97.Final.jar:4.1.97.Final]",
| "at io.netty.channel.AbstractChannelHandlerContext.invokeChannelRead(AbstractChannelHandlerContext.java:442) [netty-transport-4.1.97.Final.jar:4.1.97.Final]",
| "at io.netty.channel.AbstractChannelHandlerContext.invokeChannelRead(AbstractChannelHandlerContext.java:420) [netty-transport-4.1.97.Final.jar:4.1.97.Final]",
| "at io.netty.channel.AbstractChannelHandlerContext.fireChannelRead(AbstractChannelHandlerContext.java:412) [netty-transport-4.1.97.Final.jar:4.1.97.Final]",
| "at io.netty.channel.DefaultChannelPipeline$HeadContext.channelRead(DefaultChannelPipeline.java:1410) [netty-transport-4.1.97.Final.jar:4.1.97.Final]",
| "at io.netty.channel.AbstractChannelHandlerContext.invokeChannelRead(AbstractChannelHandlerContext.java:440) [netty-transport-4.1.97.Final.jar:4.1.97.Final]",
| "at io.netty.channel.AbstractChannelHandlerContext.invokeChannelRead(AbstractChannelHandlerContext.java:420) [netty-transport-4.1.97.Final.jar:4.1.97.Final]",
| "at io.netty.channel.DefaultChannelPipeline.fireChannelRead(DefaultChannelPipeline.java:919) [netty-transport-4.1.97.Final.jar:4.1.97.Final]",
| "at io.netty.channel.nio.AbstractNioByteChannel$NioByteUnsafe.read(AbstractNioByteChannel.java:166) [netty-transport-4.1.97.Final.jar:4.1.97.Final]",
| "at io.netty.channel.nio.NioEventLoop.processSelectedKey(NioEventLoop.java:788) [netty-transport-4.1.97.Final.jar:4.1.97.Final]",
| "at io.netty.channel.nio.NioEventLoop.processSelectedKeysPlain(NioEventLoop.java:689) [netty-transport-4.1.97.Final.jar:4.1.97.Final]",
| "at io.netty.channel.nio.NioEventLoop.processSelectedKeys(NioEventLoop.java:652) [netty-transport-4.1.97.Final.jar:4.1.97.Final]",
| "at io.netty.channel.nio.NioEventLoop.run(NioEventLoop.java:562) [netty-transport-4.1.97.Final.jar:4.1.97.Final]",
| "at io.netty.util.concurrent.SingleThreadEventExecutor$4.run(SingleThreadEventExecutor.java:997) [netty-common-4.1.97.Final.jar:4.1.97.Final]",
| "at io.netty.util.internal.ThreadExecutorMap$2.run(ThreadExecutorMap.java:74) [netty-common-4.1.97.Final.jar:4.1.97.Final]",
| "at java.lang.Thread.run(Thread.java:833) [?:?]",
| "Caused by: java.lang.ClassNotFoundException: org.bouncycastle.util.encoders.Base64",
| "at jdk.internal.loader.BuiltinClassLoader.loadClass(BuiltinClassLoader.java:641) ~[?:?]",
| "at jdk.internal.loader.ClassLoaders$AppClassLoader.loadClass(ClassLoaders.java:188) ~[?:?]",
| "at java.lang.ClassLoader.loadClass(ClassLoader.java:525) ~[?:?]",
| "... 51 more"] }
How can one reproduce the bug?
Register a model.
Deploy the model.
What is the expected behavior?
Deploy should succeed.
What is your host/environment?
Do you have any screenshots?
If applicable, add screenshots to help explain your problem.
Do you have any additional context?
Add any other context about the problem.
The text was updated successfully, but these errors were encountered: