dll - Why doesn't Azure load properly the Interop? -


i have webapp on azure uses dll. library needs interop libraries x86 , x64. sometimes, @ restart of app (i suppose), app fails due exception:

system.entrypointnotfoundexception: unable find entry point named    'sqlite3_config' in dll 'sqlite.interop.dll'. @ system.data.sqlite.unsafenativemethods.sqlite3_config_none(sqliteconfigopsenum op) @ system.data.sqlite.sqlite3.staticisinitialized() @ system.data.sqlite.sqlitelog.initialize() @ system.data.sqlite.sqliteconnection..ctor(string connectionstring, boolean parseviaframework) @ t_dox.webservice.sqlitedb.createconnection() @ webservice.cedb.connect() 

the sqlite used sqlcipher's one. missing here? don't understand why app stops working if don't make changes.


the app web service (.asmx file) uses data access layer perform business logic.

it under web site project, moved project, webapi\mvc project. routing bypasses extension, works before, simple web service call.

the called web method initializes business class loaded .net library (a vb.net library). inside, class uses wrapper sqlconnection, in case sqliteconnection. in constructor starts sqliteconnection, , works. performs crud operations ...

so can represent operation way:

[webservice(namespace = "...")] [webservicebinding(conformsto = wsiprofiles.basicprofile1_1)] public class sampleservice : system.web.services.webservice {     [webmethod]     public serverinfo test()     {          var samplebusinessclass = new samplebusinessclass();          samplebusinessclass.dosomething();            using(var connection = new sqliteconnection()) //the constructor parameterless 1                            {             //...          }               } } 

and stack (this not real one):

system.entrypointnotfoundexception: unable find entry point named 'sqlite3_config' in dll 'sqlite.interop.dll'.  @ system.data.sqlite.unsafenativemethods.sqlite3_config_none(sqliteconfigopsenum op)  @ system.data.sqlite.sqlite3.staticisinitialized()  @ system.data.sqlite.sqlitelog.initialize()  @ system.data.sqlite.sqliteconnection..ctor(string connectionstring, boolean parseviaframework)  @ xxx.webservice.sampleservice.test() 

it works, starts launch error until stop , start of web application on iss (in our case: azure).

inspecting system.data.sqlite.dll can see entry point , passes internal code (no conditions can bypass part) , works.

the system.data.sqlite.dll (1.0.96.0 version) provided sqlcypher product. think original system.data.sqlite 1 because @ first sight can see same assembly manifest , content. interop system.data.sqlite uses modified sqlcypher team give features. avoid possible issues put interop in path /bin/x64, compile our web app in x64 , runs on x64 environment.


Comments

Popular posts from this blog

Hatching array of circles in AutoCAD using c# -

ios - UITEXTFIELD InputView Uipicker not working in swift -

Python Pig Latin Translator -