Page 1 of 1

Cant get working with ravendb

Posted: Sat 30 Mar 2013 19:57
by theperm
Can't get LinqInsight to work with a ravendb query.
here is the query in full from my function. How is able to figure out the context? get a document store (mine is a class field)? or what practice should one use to utilise LinqInsight in this regard?

Code: Select all

using (var session = documentStore.OpenAsyncSession(runDatabase))
            {
                    IQueryable<StrategyIndividual> query = session.Query<StrategyIndividual>()
                        .Skip(startIndex)
                        .Take(count)
                        .Select(x => new StrategyIndividual {
                            Id = x.Id, Parent = x.Parent, Index = x.Index,
                        });

                    var results = await query.ToListAsync();
                    return results;
                }
            }
Here is the exception
Transformation error:
Can't resolve invocation 'asyncDocumentSession.Query<StrategyIndividual> ()'.

Expression:
from x in asyncDocumentSession.Query<StrategyIndividual>().Skip(startIndex).Take(count)
select new StrategyIndividual {
Id = x.Id,
Parent = x.Parent,
Index = x.Index
}
System.InvalidOperationException
at #=qQWE6EzNwR4LVY_rIek2gwjJpCj_smFsVwYBxRPAO7DZgSKVUf2FwwM1JdiKzTbpf1JtcXaQsljCrFfwdMF0jBnBT$BqmY9b6DDnfsO1Liik=.#=qfszlRMrkx1eyzIOdXJy6Aw==(KnownLanguages #=qRq1cxE6CqjU79YP9WS6Fjg==, SyntaxTree #=qT_fyoKvHOiUUIByiLAk$JQ==, AstNode #=qJ_Yc45vTatIzuCBuL5yHng==, TypeSystem #=qVGHfK_IA8M1w7B1hcj2u$w==)
at #=qQWE6EzNwR4LVY_rIek2gwjJpCj_smFsVwYBxRPAO7DZgSKVUf2FwwM1JdiKzTbpf1JtcXaQsljCrFfwdMF0jBnBT$BqmY9b6DDnfsO1Liik=.#=qPndfse3A4SZU6iwzU8$o7A==(IDebuggerIntegration #=qCupEXxsxgbLecvL0Ym0mJQ==, KnownLanguages #=qrNX3nbj9PaJFO3G_dhUmRw==, SyntaxTree #=qqGLTmaiejYTmpiF59bQafw==, AstNode #=qFwxhGrfiKT9zaBzbECB4OA==, TypeSystem #=q_ge56BlKvuNZyof4CX97BA==, Dictionary`2 #=qUIxOW8rgNr2CbxTQ8LsJ8w==, List`1& #=qfBBIUwUr1MOwQLQa6JWYlQ==, List`1& #=q8pJshEoTZ4kHl$NApqg3pQ==)
at #=q6RwZHrTR55OU6m8f2D7i3VyRAKF_1x8GziX4pC777cEwUCq5BtOqGtGHmMlt2drGAckI8dg_BZ9bkX0GivRrmQ==.#=qMPxai69vTlFiRxFO8YcFkg==()
at #=q6RwZHrTR55OU6m8f2D7i3VyRAKF_1x8GziX4pC777cEwUCq5BtOqGtGHmMlt2drGAckI8dg_BZ9bkX0GivRrmQ==.#=qTqL1YRmVsafKJ97nxxrMpg==()
at #=q6RwZHrTR55OU6m8f2D7i3VyRAKF_1x8GziX4pC777cEwUCq5BtOqGtGHmMlt2drGAckI8dg_BZ9bkX0GivRrmQ==.#=qjfSgZOyuFmiE3bnCvKcqr4IOVoWBcV90RR9V7uS_Ywc=.#=q6NT6amo2vNsufOTptDVqyfHA4UC15BiqpkYqY0jKSI0=()

Re: Cant get working with ravendb

Posted: Mon 01 Apr 2013 09:12
by MariiaI
At the moment LINQ Insight supports regular sessions, which are returned by calling the documentStore.OpenSession method. Asynchronous sessions are not supported yet. However, we are working on it now and we will inform you about the results this week.

Re: Cant get working with ravendb

Posted: Wed 03 Apr 2013 09:06
by MariiaI
Asynchronous sessions are supported now. This feature is available in the new build of LINQ Insight 2.0.22. It can be downloaded from http://www.devart.com/linqinsight/download.html of from Registered Users' Area (provided that you have an active subscription).
For more information please refer to http://forums.devart.com/viewtopic.php?f=50&t=26295