Singleton or instance per request?

14 views
Skip to first unread message

Diego Mijelshon

unread,
Mar 22, 2012, 8:36:20 AM3/22/12
to dotnet...@googlegroups.com
I'm using OpenIdRelyingParty in a MVC application. It is injected into the AccountController.

What is the recommended lifestyle for this object?

Thanks!

    Diego

Andrew Arnott

unread,
Mar 22, 2012, 9:20:07 AM3/22/12
to dotnet...@googlegroups.com
It's a thread-safe object, so feel free to statically store it, or new it up with each incoming request, at your discretion.

--
Andrew Arnott
"I [may] not agree with what you have to say, but I'll defend to the death your right to say it." - S. G. Tallentyre



    Diego

--
You received this message because you are subscribed to the Google Groups "DotNetOpenAuth" group.
To view this discussion on the web visit https://groups.google.com/d/msg/dotnetopenid/-/OnNJ6EH-fYYJ.
To post to this group, send email to dotnet...@googlegroups.com.
To unsubscribe from this group, send email to dotnetopenid...@googlegroups.com.
For more options, visit this group at http://groups.google.com/group/dotnetopenid?hl=en.

Diego Mijelshon

unread,
Mar 23, 2012, 4:35:01 PM3/23/12
to dotnet...@googlegroups.com
Thanks!
That's exactly what I needed to know. I made it single instance.

    Diego


On Thursday, March 22, 2012 10:20:07 AM UTC-3, Andrew Arnott wrote:
It's a thread-safe object, so feel free to statically store it, or new it up with each incoming request, at your discretion.

--
Andrew Arnott
"I [may] not agree with what you have to say, but I'll defend to the death your right to say it." - S. G. Tallentyre


On Thu, Mar 22, 2012 at 5:36 AM, Diego Mijelshon <di...@mijelshon.com.ar> wrote:
I'm using OpenIdRelyingParty in a MVC application. It is injected into the AccountController.

What is the recommended lifestyle for this object?

Thanks!

    Diego

--
You received this message because you are subscribed to the Google Groups "DotNetOpenAuth" group.
To view this discussion on the web visit https://groups.google.com/d/​msg/dotnetopenid/-/OnNJ6EH-​fYYJ.
To post to this group, send email to dotnet...@googlegroups.com.
To unsubscribe from this group, send email to dotnetopenid+unsubscribe@​googlegroups.com.
Reply all
Reply to author
Forward
0 new messages