c# - WSTrustChannelFactory as a singleton. Is it the best practice? -


i'm working application uses wstrustchannelfactory create trust channels, noticed code creating new wstrustchannelfactory everytime new channel needed.

i've never worked before since factory suppose can implemented singleton.

am right? if so, there additional consideration take (will factory "usable" or there scenarios/exceptions should replaced new instance)?. also, factory creation expensive operation, such wcf channelfactory creation?

am right?

yes, think are. i've worked on several projects used channel factory , each time singleton. has limits , can become bottleneck under high load, lot implementations think fine.


Comments

Popular posts from this blog

linux - xterm copying to CLIPBOARD using copy-selection causes automatic updating of CLIPBOARD upon mouse selection -

c++ - qgraphicsview horizontal scrolling always has a vertical delta -