ActiveRecord + WCF Integration

8 views
Skip to first unread message

Doug Mayer

unread,
Jul 3, 2008, 12:18:33 PM7/3/08
to Castle Project Users
Since WCF doesn't allow access to the HttpContext.Current, I can't use
isWeb="true" in my AR config. Is it then recommended to use
isWeb="false", or are there other problems with AR + WCF that may not
be immediately apparent?

Thanks!
Doug

Ayende Rahien

unread,
Jul 3, 2008, 3:28:15 PM7/3/08
to castle-pro...@googlegroups.com
Use Hybrid access, or thread safe.
Or write a OperationContextScope

Doug Mayer

unread,
Jul 3, 2008, 3:35:50 PM7/3/08
to castle-pro...@googlegroups.com
I created something like an OperationContextScope for the NHibernateIntegration facility.  Would something like that be helpful to submit a patch for?  Perhaps an isWcf="true" option for ActiveRecord?

Ayende Rahien

unread,
Jul 3, 2008, 3:48:17 PM7/3/08
to castle-pro...@googlegroups.com
I think so

Ernst Naezer

unread,
Jul 3, 2008, 4:04:06 PM7/3/08
to castle-pro...@googlegroups.com
yeah that sounds very usefull

Doug Mayer

unread,
Jul 3, 2008, 4:12:04 PM7/3/08
to castle-pro...@googlegroups.com
Cool, I'll work on that this evening then.

As an aside, I'm having trouble running the Castle unit tests on my
machine. It hangs indefinitely on the NHibernateFacility tests, and
doesn't give me any suggestion on how to fix it. Do you guys have any
idea how I might at least figure out what's stopping it? Perhaps this
is a common thing with a quick fix?

Thanks!

Ernst Naezer

unread,
Jul 3, 2008, 4:19:19 PM7/3/08
to castle-pro...@googlegroups.com
hmmm... have you tried running the unit tests using a different
client? something like r# or testdriven from visual studio?

Doug Mayer

unread,
Jul 3, 2008, 4:23:25 PM7/3/08
to castle-pro...@googlegroups.com
Yes, but I've never been able to get those to work. I've had the
tests working before through NAnt on this machine. :-/

Ernst Naezer

unread,
Jul 3, 2008, 4:29:30 PM7/3/08
to castle-pro...@googlegroups.com
sounds like weird stuff... what database engine / os are you using?

Doug Mayer

unread,
Jul 3, 2008, 4:35:37 PM7/3/08
to castle-pro...@googlegroups.com
Local SQL Server 05 instance with the default connection strings (test/
test2 databases with integrated security). All of the AR tests work
perfectly, it just doesn't like the NHibernateIntegration facility.
Reply all
Reply to author
Forward
0 new messages