Azure / azure-storage-android

Microsoft Azure Storage Library for Android
Apache License 2.0
81 stars 47 forks source link

Runtime Exception: Failed resolution of: Ljavax/xml/stream/XMLOutputFactory #63

Open AdarshanaBlr opened 6 years ago

AdarshanaBlr commented 6 years ago

Really surprised on how tricky this problem is. Unable to proceed further. I really don't know how to fix this. Tried all combinations. So basically com.microsoft.azure.storage seems like pure Java library. javax.xml.stream is missing.

Please help me here.

I'm building everything in Android Studio. So basically my Andorid App has to work. It is struggling to find the javax.xml.stream.* packages.

jofri-msft commented 6 years ago

Hi @AdarshanaBlr , what version of Android are you using? Can you verify that you have all necessary jars? http://www.findjar.com/index.x

AdarshanaBlr commented 6 years ago

Currently I'm using Android Studio 2.3.3. built June 6th 2017. JRE 1.8.0_112 android { compileSdkVersion 26 buildToolsVersion "25.0.3" ... } As you indicated, looks like the javax.xml.stream.* jar files don't exist. Thus the first call itself fails. CloudStorageAccount storageAccount = CloudStorageAccount.parse(connectionString);

Runtime error.... java.lang.NoClassDefFoundError: Failed resolution of: Ljavax/xml/stream/XMLOutputFactory; at com.microsoft.azure.storage.core.Utility.(Utility.java:120) at com.microsoft.azure.storage.core.Utility.parseAccountString(Utility.java:685) at com.microsoft.azure.storage.CloudStorageAccount.parse(CloudStorageAccount.java:239) at Caused by: java.lang.ClassNotFoundException: Didn't find class "javax.xml.stream.XMLOutputFactory" on

numankaraaslan commented 5 years ago

try importing this:

https://mvnrepository.com/artifact/javax.xml.stream/stax-api/1.0-2