Unity Lifetime Mangers for OWIN self hosted Web APIEntity Framework Core: A second operation started on this context before a previous operation completedPass a parameter to OWIN hostGet Remote Host IP in Web API Self-Hosted Using OwinWhat is the right way to self-host a Web API?Running self-hosted OWIN Web API under non-admin accountDependency injection not working with Owin self-hosted Web Api 2 and AutofacGet current owin context in self host modeHost Web API as Windows Service using OWINIs it possible to run a self hosting OWIN web api inside WinForms (C#)?PerHttpRequestLifeTimeManager for Unity with Web API and OWINHow to provide a Service object to OWIN and access from Api controller

Responsibility for visa checking

Can you please explain this joke: "I'm going bananas is what I tell my bananas before I leave the house"?

What's the correct term for a waitress in the Middle Ages?

Riley's, assemble!

Pronoun introduced before its antecedent

How could a possessed body begin to rot and decay while it is still alive?

Is it possible for people to live in the eye of a permanent hypercane?

What is the advantage of carrying a tripod and ND-filters when you could use image stacking instead?

Applicants clearly not having the skills they advertise

What's the logic behind the the organization of Hamburg's bus transport into "rings"?

In this example, which path would a monster affected by the Dissonant Whispers spell take?

Is it a problem that pull requests are approved without any comments

Could the Missouri River be running while Lake Michigan was frozen several meters deep?

How to make thick Asian sauces?

Did Darth Vader wear the same suit for 20+ years?

Why is the relationship between frequency and pitch exponential?

correct term describing the action of sending a brand-new ship out into its first seafaring trip

Diet Coke or water?

Why is c4 bad when playing the London against a King's Indian?

I wrote a scene that the majority of my readers loved. How do I get back to that place while writing my new book?

Accidentally cashed a check twice

Metal bar on DMM PCB

Accidentally renamed tar.gz file to a non tar.gz file, will my file be messed up

Prove that a function is indefinitely differentiable



Unity Lifetime Mangers for OWIN self hosted Web API


Entity Framework Core: A second operation started on this context before a previous operation completedPass a parameter to OWIN hostGet Remote Host IP in Web API Self-Hosted Using OwinWhat is the right way to self-host a Web API?Running self-hosted OWIN Web API under non-admin accountDependency injection not working with Owin self-hosted Web Api 2 and AutofacGet current owin context in self host modeHost Web API as Windows Service using OWINIs it possible to run a self hosting OWIN web api inside WinForms (C#)?PerHttpRequestLifeTimeManager for Unity with Web API and OWINHow to provide a Service object to OWIN and access from Api controller






.everyoneloves__top-leaderboard:empty,.everyoneloves__mid-leaderboard:empty,.everyoneloves__bot-mid-leaderboard:empty height:90px;width:728px;box-sizing:border-box;








1















Im migrating a Web API from IIS to self hosting with OWIN and The UNITY lifetime managers are giving me problems. I keep getting "A second operation started on this context before a previous operation completed". We were using PerRequestLifetimeManager but that only works on IIS.



This is an existing system that has alot of code depending on each other so moving it to dotnet core is not an option at the moment. I have tryed using all the unity lifetime managers under microsoft.practices.unity and none of them worked. I tryed to implement my own lifetime manager and that gave me the same result. I tried to upgrade to the latest unity container and that caused problems with rhino service bus. The only code I added or changed was the code to self hos which was a few lines that to start the server and to change the api controllers to work with the self hosting



Before I change service buses I need to know if any of the new updates to unity will fix my problem or is there something else I can do to get it to work. I just need it to stop throwing a "A second operation started on this context before a previous operation completed" error. Any thing and everything that would help is welcomed.










share|improve this question






















  • stackoverflow.com/a/48768221/1169180. If this doesn't work, could you post some code to replicate this issue?

    – Shaggy
    Mar 24 at 21:59











  • That didn't work but thanks for the input. I was moved to a different project so I its someone else's problem now ;)

    – Black Cupid
    Apr 3 at 13:03

















1















Im migrating a Web API from IIS to self hosting with OWIN and The UNITY lifetime managers are giving me problems. I keep getting "A second operation started on this context before a previous operation completed". We were using PerRequestLifetimeManager but that only works on IIS.



This is an existing system that has alot of code depending on each other so moving it to dotnet core is not an option at the moment. I have tryed using all the unity lifetime managers under microsoft.practices.unity and none of them worked. I tryed to implement my own lifetime manager and that gave me the same result. I tried to upgrade to the latest unity container and that caused problems with rhino service bus. The only code I added or changed was the code to self hos which was a few lines that to start the server and to change the api controllers to work with the self hosting



Before I change service buses I need to know if any of the new updates to unity will fix my problem or is there something else I can do to get it to work. I just need it to stop throwing a "A second operation started on this context before a previous operation completed" error. Any thing and everything that would help is welcomed.










share|improve this question






















  • stackoverflow.com/a/48768221/1169180. If this doesn't work, could you post some code to replicate this issue?

    – Shaggy
    Mar 24 at 21:59











  • That didn't work but thanks for the input. I was moved to a different project so I its someone else's problem now ;)

    – Black Cupid
    Apr 3 at 13:03













1












1








1








Im migrating a Web API from IIS to self hosting with OWIN and The UNITY lifetime managers are giving me problems. I keep getting "A second operation started on this context before a previous operation completed". We were using PerRequestLifetimeManager but that only works on IIS.



This is an existing system that has alot of code depending on each other so moving it to dotnet core is not an option at the moment. I have tryed using all the unity lifetime managers under microsoft.practices.unity and none of them worked. I tryed to implement my own lifetime manager and that gave me the same result. I tried to upgrade to the latest unity container and that caused problems with rhino service bus. The only code I added or changed was the code to self hos which was a few lines that to start the server and to change the api controllers to work with the self hosting



Before I change service buses I need to know if any of the new updates to unity will fix my problem or is there something else I can do to get it to work. I just need it to stop throwing a "A second operation started on this context before a previous operation completed" error. Any thing and everything that would help is welcomed.










share|improve this question














Im migrating a Web API from IIS to self hosting with OWIN and The UNITY lifetime managers are giving me problems. I keep getting "A second operation started on this context before a previous operation completed". We were using PerRequestLifetimeManager but that only works on IIS.



This is an existing system that has alot of code depending on each other so moving it to dotnet core is not an option at the moment. I have tryed using all the unity lifetime managers under microsoft.practices.unity and none of them worked. I tryed to implement my own lifetime manager and that gave me the same result. I tried to upgrade to the latest unity container and that caused problems with rhino service bus. The only code I added or changed was the code to self hos which was a few lines that to start the server and to change the api controllers to work with the self hosting



Before I change service buses I need to know if any of the new updates to unity will fix my problem or is there something else I can do to get it to work. I just need it to stop throwing a "A second operation started on this context before a previous operation completed" error. Any thing and everything that would help is welcomed.







c# asp.net owin unity-container rhino-servicebus






share|improve this question













share|improve this question











share|improve this question




share|improve this question










asked Mar 24 at 13:39









Black CupidBlack Cupid

111




111












  • stackoverflow.com/a/48768221/1169180. If this doesn't work, could you post some code to replicate this issue?

    – Shaggy
    Mar 24 at 21:59











  • That didn't work but thanks for the input. I was moved to a different project so I its someone else's problem now ;)

    – Black Cupid
    Apr 3 at 13:03

















  • stackoverflow.com/a/48768221/1169180. If this doesn't work, could you post some code to replicate this issue?

    – Shaggy
    Mar 24 at 21:59











  • That didn't work but thanks for the input. I was moved to a different project so I its someone else's problem now ;)

    – Black Cupid
    Apr 3 at 13:03
















stackoverflow.com/a/48768221/1169180. If this doesn't work, could you post some code to replicate this issue?

– Shaggy
Mar 24 at 21:59





stackoverflow.com/a/48768221/1169180. If this doesn't work, could you post some code to replicate this issue?

– Shaggy
Mar 24 at 21:59













That didn't work but thanks for the input. I was moved to a different project so I its someone else's problem now ;)

– Black Cupid
Apr 3 at 13:03





That didn't work but thanks for the input. I was moved to a different project so I its someone else's problem now ;)

– Black Cupid
Apr 3 at 13:03












0






active

oldest

votes












Your Answer






StackExchange.ifUsing("editor", function ()
StackExchange.using("externalEditor", function ()
StackExchange.using("snippets", function ()
StackExchange.snippets.init();
);
);
, "code-snippets");

StackExchange.ready(function()
var channelOptions =
tags: "".split(" "),
id: "1"
;
initTagRenderer("".split(" "), "".split(" "), channelOptions);

StackExchange.using("externalEditor", function()
// Have to fire editor after snippets, if snippets enabled
if (StackExchange.settings.snippets.snippetsEnabled)
StackExchange.using("snippets", function()
createEditor();
);

else
createEditor();

);

function createEditor()
StackExchange.prepareEditor(
heartbeatType: 'answer',
autoActivateHeartbeat: false,
convertImagesToLinks: true,
noModals: true,
showLowRepImageUploadWarning: true,
reputationToPostImages: 10,
bindNavPrevention: true,
postfix: "",
imageUploader:
brandingHtml: "Powered by u003ca class="icon-imgur-white" href="https://imgur.com/"u003eu003c/au003e",
contentPolicyHtml: "User contributions licensed under u003ca href="https://creativecommons.org/licenses/by-sa/3.0/"u003ecc by-sa 3.0 with attribution requiredu003c/au003e u003ca href="https://stackoverflow.com/legal/content-policy"u003e(content policy)u003c/au003e",
allowUrls: true
,
onDemand: true,
discardSelector: ".discard-answer"
,immediatelyShowMarkdownHelp:true
);



);













draft saved

draft discarded


















StackExchange.ready(
function ()
StackExchange.openid.initPostLogin('.new-post-login', 'https%3a%2f%2fstackoverflow.com%2fquestions%2f55324390%2funity-lifetime-mangers-for-owin-self-hosted-web-api%23new-answer', 'question_page');

);

Post as a guest















Required, but never shown

























0






active

oldest

votes








0






active

oldest

votes









active

oldest

votes






active

oldest

votes















draft saved

draft discarded
















































Thanks for contributing an answer to Stack Overflow!


  • Please be sure to answer the question. Provide details and share your research!

But avoid


  • Asking for help, clarification, or responding to other answers.

  • Making statements based on opinion; back them up with references or personal experience.

To learn more, see our tips on writing great answers.




draft saved


draft discarded














StackExchange.ready(
function ()
StackExchange.openid.initPostLogin('.new-post-login', 'https%3a%2f%2fstackoverflow.com%2fquestions%2f55324390%2funity-lifetime-mangers-for-owin-self-hosted-web-api%23new-answer', 'question_page');

);

Post as a guest















Required, but never shown





















































Required, but never shown














Required, but never shown












Required, but never shown







Required, but never shown

































Required, but never shown














Required, but never shown












Required, but never shown







Required, but never shown







Popular posts from this blog

Kamusi Yaliyomo Aina za kamusi | Muundo wa kamusi | Faida za kamusi | Dhima ya picha katika kamusi | Marejeo | Tazama pia | Viungo vya nje | UrambazajiKuhusu kamusiGo-SwahiliWiki-KamusiKamusi ya Kiswahili na Kiingerezakuihariri na kuongeza habari

Swift 4 - func physicsWorld not invoked on collision? The Next CEO of Stack OverflowHow to call Objective-C code from Swift#ifdef replacement in the Swift language@selector() in Swift?#pragma mark in Swift?Swift for loop: for index, element in array?dispatch_after - GCD in Swift?Swift Beta performance: sorting arraysSplit a String into an array in Swift?The use of Swift 3 @objc inference in Swift 4 mode is deprecated?How to optimize UITableViewCell, because my UITableView lags

Access current req object everywhere in Node.js ExpressWhy are global variables considered bad practice? (node.js)Using req & res across functionsHow do I get the path to the current script with Node.js?What is Node.js' Connect, Express and “middleware”?Node.js w/ express error handling in callbackHow to access the GET parameters after “?” in Express?Modify Node.js req object parametersAccess “app” variable inside of ExpressJS/ConnectJS middleware?Node.js Express app - request objectAngular Http Module considered middleware?Session variables in ExpressJSAdd properties to the req object in expressjs with Typescript