best practices: nutritious information via churned web slight calls


i have web use 8 web methods. methods called synchronously, initial authenticates user, rest methods perform section work, methods called on until work done.



i need store state work (e.g. actions perform next, work finished now being performed.) i now have state vigilant contains information.



my doubt best proceed insist vigilant between any web use call? note there competence churned users job web service, any it's possess unparalleled state.



here scenarios i am thinking:



idea #1



store vigilant session.



idea #2
create an instance non-static hashmap userid particular data. something like:





[webservice(namespace = "http://developer.intuit.com/")]
[webservicebinding(conformsto = wsiprofiles.basicprofile1_1)]
public category qbwcservice : qbwebconnectorsvc {

// instance non-static reason tide event data...
private dictionary<guid,session> sessions;

open qbwcservice () {

sessions = new dictionary<guid,session>();
}
[webmethod]
open overrule string[] authenticate(string strusername, twine strpassword)
{
...
sessions.add(userid, new sessoionobject());
}
[webmethod]
open overrule string[] authenticate(guid userid)
{
sessionobject o = sessions[userid];
}
}



i am pondering thought 2 going cleanest "natural way", however i know any import implementing arrange scheme...which proceed else recommend?



Comments

Popular posts from this blog

list macos calm editors formula editors

how i practical urls indicate .aspx pages asp.net deployed an iis? (preferably but iis)

jaxb - xjc - reworking generated typesafe enum category members