This is a migrated thread and some comments may be shown as answers.

Error on IntelliTrace

8 Answers 62 Views
Data Access Free Edition
This is a migrated thread and some comments may be shown as answers.
This question is locked. New answers and comments are not allowed.
Nelson
Top achievements
Rank 1
Nelson asked on 27 Dec 2013, 05:46 PM
Hi ..

Searched the forum, however I found nothing about my problem.

When trying to run a web service on my local machine, the problem does not happen. When you run the deploy server the following error occurs:
Telerik.OpenAccess.Runtime --> System.TypeInitializationException: The type initializer for 'OpenAccessRuntime.Intellitrace' threw an exception. ---> System.Security.SecurityException: Request failed.
   at OpenAccessRuntime.Intellitrace..cctor()
   --- End of inner exception stack trace ---
   at OpenAccessRuntime.Intellitrace.OpenDatabase(String url, Boolean metaDataOnly)
   at OpenAccessRuntime.Relational.RelationalStorageManagerFactory..ctor(StorageManagerFactoryBuilder b)
   at OpenAccessRuntime.storagemanager.StorageManagerFactoryBuilder.createSmfForURL()em:
   at OpenAccessRuntime.ExceptionWrapper.Throw()
   at OpenAccessRuntime.storagemanager.StorageManagerFactoryBuilder.createSmfForURL()
   at OpenAccessRuntime.storagemanager.StorageManagerFactoryBuilder.createStorageManagerFactory()
   at OpenAccessRuntime.DataObjects.PersistenceManagerFactoryImp.createStorageManagerFactory()
   at OpenAccessRuntime.DataObjects.PersistenceManagerFactoryBase.init()
   at OpenAccessRuntime.DataObjects.PersistenceManagerFactoryImp.init()
   at OpenAccessRuntime.DataObjects.BootstrapPMF.getPersistenceManagerFactory(PropertySet props)
   at OpenAccessRuntime.Helper.getPersistenceManagerFactory(PropertySet props)
   at OpenAccessRuntime.DatabaseAdapter.AssertPersistenceManagerFactory(String usr, String password, Boolean open)
   at OpenAccessRuntime.DatabaseAdapter.GetObjectScope(TransactionProvider provider)
   at Telerik.OpenAccess.Database.GetObjectScope(TransactionProvider provider)
   at Telerik.OpenAccess.OpenAccessContextBase.GetScope()
   at Telerik.OpenAccess.OpenAccessContext.GetAllCore[T]()
   at Telerik.OpenAccess.OpenAccessContext.GetAll[T]()
   at RepresDAO.Repres.get_Clientes() in d:\sistemas\fontes\Repres\RepresMobileSolution\RepresObjects\DatabaseObjects\Repres.cs:line 250
   at RepresDataObjects.webservices.servicos_v2.RetornaClientes(Int32 Start, Int32 Lenght) in d:\sistemas\fontes\Repres\RepresMobileSolution\RepresDataObjects\webservices\servicos_v2.asmx.cs:line 687
Telerik.OpenAccess.Runtime --> The type initializer for 'OpenAccessRuntime.Intellitrace' threw an exception.em:
   at OpenAccessRuntime.Intellitrace.OpenDatabase(String url, Boolean metaDataOnly)
   at OpenAccessRuntime.Relational.RelationalStorageManagerFactory..ctor(StorageManagerFactoryBuilder b)
   at OpenAccessRuntime.storagemanager.StorageManagerFactoryBuilder.createSmfForURL()
Telerik.OpenAccess.Runtime --> Request failed.em:
   at OpenAccessRuntime.Intellitrace..cctor()

I tried to look for something that disable IntelliTrace, but as far as I saw it only runs within visual studio (2010 or 2012).

As far as I know my ISP's server runs on medium trust.

Does someone could help me?

Regards.

Nelson Santos

8 Answers, 1 is accepted

Sort by
0
Dimitar Tachev
Telerik team
answered on 31 Dec 2013, 09:54 AM
Hello Nelson,

In order for Telerik OpenAccess ORM to work properly we need at least a Medium Trust and in general security exceptions like this one are thrown if we do not have the required trust level. In order to configure OpenAccess ORM to work on medium trust you could follow this article for our domain model approach or this one for the code only scenario.

However please bear in mind that if you are not using the latest official version of OpenAccess ORM - Q3 2013 SP1 (version 2013.3 1211) you could get the security exception even in medium trust because of an issue which is already fixed in this version.

Could you please confirm that you are using the latest available OpenAccess ORM version and have both your model and server are configured for a medium trust?

I am looking forward to your feedback.

Regards,
Dimitar Tachev
Telerik
OpenAccess ORM Q3 2013 simplifies your model operations even further providing you with greater flexibility. Check out the list of new features shipped with our latest release!
0
Nelson
Top achievements
Rank 1
answered on 02 Jan 2014, 04:22 PM
Hi Dimitar

I checked the version I had and was not really updated. I was a previous version of the one you entered.

Seems to have solved the problem. But now I have another related to MySql.Data.

Because my ISP using the "Medium Trust" seems to lack an allowable use in class System.Net.Socket configured within web_mediumtrust.config for it to work.

But that's their problem. I'll check with them and if I have anything else related to this issue I will contact you again.

Anyway thanks for the help.

And congratulations for the work with OpenAccess. It's a great tool!

Regards...

Nelson Santos
0
Nelson
Top achievements
Rank 1
answered on 02 Jan 2014, 08:44 PM
Hi Dimitar ...

I talked to my ISP and they told me it is not a common problem.

If we direct access to MySql without the OpenAccess works normally.

Follows the error that occurs this time.

Telerik.OpenAccess.Runtime --> Cannot perform CAS Asserts in Security Transparent methods in:
   at OpenAccessRuntime.ExceptionWrapper.Throw()
   at OpenAccessRuntime.Helper.getPersistenceManagerFactory(PropertySet props)
   at OpenAccessRuntime.DatabaseAdapter.AssertPersistenceManagerFactory(String usr, String password, Boolean open)
   at OpenAccessRuntime.DatabaseAdapter.GetObjectScope(TransactionProvider provider)
   at Telerik.OpenAccess.Database.GetObjectScope(TransactionProvider provider)
   at Telerik.OpenAccess.OpenAccessContextBase.GetScope()
   at Telerik.OpenAccess.OpenAccessContext.GetAllCore[T]()
   at Telerik.OpenAccess.OpenAccessContext.GetAll[T]()
   at RepresDAO.Repres.get_Clientes() in d:\sistemas\fontes\Repres\RepresMobileSolution\RepresObjects\DatabaseObjects\Repres.cs:line 250
   at RepresDataObjects.webservices.servicos_v2.RetornaClientes(Int32 Start, Int32 Lenght) in d:\sistemas\fontes\Repres\RepresMobileSolution\RepresDataObjects\webservices\servicos_v2.asmx.cs:line 687
MySql.Data --> Cannot perform CAS Asserts in Security Transparent methods in:
   at MySql.Data.MySqlClient.MySqlClientFactory..cctor()


Can you help me again?

Regards...

Nelson
0
Ady
Telerik team
answered on 07 Jan 2014, 10:00 AM
Hello Nelson,

 Can you provide the inner exception of this exception?  That would provide more information on the exact call that causes the exception.

Regards,
Ady
Telerik
OpenAccess ORM Q3 2013 simplifies your model operations even further providing you with greater flexibility. Check out the list of new features shipped with our latest release!
0
Nelson
Top achievements
Rank 1
answered on 07 Jan 2014, 12:49 PM
Hi Ady ...

As the problem occurs on my ISP, I can not pass the actual Exception that occurs. What I have is the stack trace of the problem:

Telerik.OpenAccess.Runtime --> Cannot perform CAS Asserts in Security Transparent methodsem:
   at OpenAccessRuntime.ExceptionWrapper.Throw()
   at OpenAccessRuntime.Helper.getPersistenceManagerFactory(PropertySet props)
   at OpenAccessRuntime.DatabaseAdapter.AssertPersistenceManagerFactory(String usr, String password, Boolean open)
   at OpenAccessRuntime.DatabaseAdapter.GetObjectScope(TransactionProvider provider)
   at Telerik.OpenAccess.Database.GetObjectScope(TransactionProvider provider)
   at Telerik.OpenAccess.OpenAccessContextBase.GetScope()
   at Telerik.OpenAccess.OpenAccessContext.GetAllCore[T]()
   at Telerik.OpenAccess.OpenAccessContext.GetAll[T]()
   at RepresDAO.Repres.get_Clientes() in d:\sistemas\fontes\Repres\RepresMobileSolution\RepresObjects\DatabaseObjects\Repres.cs:line 250
   at RepresDataObjects.webservices.servicos_v2.RetornaClientes(Int32 Start, Int32 Lenght) in d:\sistemas\fontes\Repres\RepresMobileSolution\RepresDataObjects\webservices\servicos_v2.asmx.cs:line 687
MySql.Data --> Cannot perform CAS Asserts in Security Transparent methodsem:
   at MySql.Data.MySqlClient.MySqlClientFactory..cctor()


The all indications, it looks like something is when I try to call the following method of the class that represents the object context:

public IQueryable<Clientes> Clientes
{
    get
    {
        return this.GetAll<Clientes>();
    }
}


Thanks for your attention.

Regrads...

Nelson
0
Ady
Telerik team
answered on 09 Jan 2014, 04:36 PM
Hello Nelson,

 This seems to be the same problem which you mentioned in the ticket - 706893.
Can you try to install a version lower than 6.6.5 and try again?

Regards,
Ady
Telerik
OpenAccess ORM Q3 2013 simplifies your model operations even further providing you with greater flexibility. Check out the list of new features shipped with our latest release!
0
Nelson
Top achievements
Rank 1
answered on 31 Jan 2014, 04:44 PM
Hi Ady...

Sorry for long delay in answer, but I having to working out these days and dont have time to do the adjustments.

Really the change for a old version solve the problem. I have used the version 6.3.5 that is provided by my ISP.

For that someone have the same problem, the solution work perfectly!

On my opinion the unique problem is that he have do use a version that is old and can be have bugs on it.

Is there any plan to update de OpenAccess to use a new version of mysql connector without the problem of medium trust?

Thanks.

Nelson Santos
0
Ady
Telerik team
answered on 05 Feb 2014, 10:21 AM
Hello Nelson,

 As mentioned in ticket 706893 there are no immediate plans to upgrade OpenAccess to the latest MySql connector. Maybe you can close this ticket so that we maintain a single thread for communicating on this subject.
 
Regards,
Ady
Telerik
OpenAccess ORM is now Telerik Data Access. For more information on the new names, please, check out the Telerik Product Map.
Tags
Data Access Free Edition
Asked by
Nelson
Top achievements
Rank 1
Answers by
Dimitar Tachev
Telerik team
Nelson
Top achievements
Rank 1
Ady
Telerik team
Share this question
or