0

I have loaded a sample application for SCP / S/4HANA Business Partner integration, did changes as documented in read.me, I also have comm. user/arrangement in S/4HANA for 0008. When I try to build it,

I get error during integration test, the content of file com.sap.cloud.s4hana.examples.addressmgr.BusinessPartnerServletTest is:

    <<< ERROR!    org.jboss.arquillian.container.spi.client.container.DeploymentException: Unable to deploy
    Caused by: org.apache.openejb.OpenEJBRuntimeException: org.apache.openejb.OpenEJBException: Creating application failed: /Users/d036682/Downloads/cloud_app/integration-tests/target/surefire-fork/1/arquillian-tomee-working-dir/0/292d95a8-4414-4535-846f-c8fae7dcd7e9: Cannot get Unsafe.defineClass
    Caused by: org.apache.openejb.OpenEJBException: Creating application failed: /Users/d036682/Downloads/cloud_app/integration-tests/target/surefire-fork/1/arquillian-tomee-working-dir/0/292d95a8-4414-4535-846f-c8fae7dcd7e9: Cannot get Unsafe.defineClass
    Caused by: java.lang.IllegalStateException: Cannot get Unsafe.defineClass
    Caused by: java.lang.NoSuchMethodException: sun.misc.Unsafe.defineClass(java.lang.String,[B,int,int,java.lang.ClassLoader,java.security.ProtectionDomain)

Could you please help

Thanks, Konstantin

Alexander Dümont
  • 903
  • 1
  • 5
  • 9
  • 2
    Hi Konstantin and welcome to SO. Please enhance your question with the version of the SDK you are using. Also please point us to the exact code you are using if possible, ideally in a minimal working example. The error message may indicate a mismatched dependency or jdk version, but we’ll need more information in order to tackle the issue. – Florian Wilhelm Aug 26 '19 at 08:15
  • Hi Florian, this is what I see from maven, I am not sure if this is what you are asking for: Apache Maven 3.6.1 (d66c9c0b3152b2e69ee9bac180bb8fcc8e6af555; 2019-04-04T21:00:29+02:00) Maven home: /usr/local/Cellar/maven/3.6.1/libexec Java version: 12.0.2, vendor: Oracle Corporation, runtime: /Library/Java/JavaVirtualMachines/openjdk-12.0.2.jdk/Contents/Home . In blogs it is mentioned that only jdk 8 is supported, maybe this is why it does not work for me ? - although why only at integration test ? – Konstantin Aug 27 '19 at 08:22
  • Yes, please use JDK 8. For various reasons, later versions are not supported yet. – Florian Wilhelm Aug 28 '19 at 09:56

1 Answers1

1

Please make sure to use JDK 8 as documented until further notice. Various dependencies don't work in later versions as of now.

Kind regards

Florian

Florian Wilhelm
  • 600
  • 4
  • 17