|
dev
newsgroups
|
|||||||||||||||||||||||
|
|||||||||||||||||||||||
Exception ManagementThe .NET architecture guide says that "Exceptions need to be serializble in
order to flow upstream accross tiers". Why? Cant we simply throw excpetions to the calling code even if it is in a diffent component in a differnt layer in a differnt machine on the newtork? I think it is basiccly passing exceptions. -- Regards Ginny That's exactly what that sentence means. You CAN just pass an exception
between layers without having to serialize it. However, if you wanted to pass an exception through a web service, you'd need to serialzie it. Show quote "Ginny" <techni***@peoplewareindia.com> wrote in message news:e6MaDtavGHA.2260@TK2MSFTNGP03.phx.gbl... > The .NET architecture guide says that "Exceptions need to be serializble > in > order to flow upstream accross tiers". Why? Cant we simply throw > excpetions > to the calling code even if it is in a diffent component in a differnt > layer > in a differnt machine on the newtork? I think it is basiccly passing > exceptions. > > -- > Regards > Ginny > > I think that term that gave you trouble was "upstream". In this context,
upstream means via http. Show quote "Scott M." <s-mar@nospam.nospam> wrote in message news:%23YEMRbbvGHA.4444@TK2MSFTNGP05.phx.gbl... > That's exactly what that sentence means. You CAN just pass an exception > between layers without having to serialize it. However, if you wanted to > pass an exception through a web service, you'd need to serialzie it. > > > "Ginny" <techni***@peoplewareindia.com> wrote in message > news:e6MaDtavGHA.2260@TK2MSFTNGP03.phx.gbl... >> The .NET architecture guide says that "Exceptions need to be serializble >> in >> order to flow upstream accross tiers". Why? Cant we simply throw >> excpetions >> to the calling code even if it is in a diffent component in a differnt >> layer >> in a differnt machine on the newtork? I think it is basiccly passing >> exceptions. >> >> -- >> Regards >> Ginny >> >> > > The main reason is to allow serialization of exceptions across a web service
boundary. If you are not doing SOA, you can, technically speaking, drop this requirement. Unless you have greatly altered the exception implementation, it is not a lot of work to make it serializable (add an attribute). -- Show quoteGregory A. Beamer MVP; MCP: +I, SE, SD, DBA ************************************************* Think outside of the box! ************************************************* "Ginny" <techni***@peoplewareindia.com> wrote in message news:e6MaDtavGHA.2260@TK2MSFTNGP03.phx.gbl... > The .NET architecture guide says that "Exceptions need to be serializble > in > order to flow upstream accross tiers". Why? Cant we simply throw > excpetions > to the calling code even if it is in a diffent component in a differnt > layer > in a differnt machine on the newtork? I think it is basiccly passing > exceptions. > > -- > Regards > Ginny > > minor point: it also allows serialization of exceptions across appdomain and
remoting (process) boundaries. Show quote "Cowboy (Gregory A. Beamer)" <NoSpamMgbworld@comcast.netNoSpamM> wrote in message news:OjwnjV8vGHA.2436@TK2MSFTNGP06.phx.gbl... > The main reason is to allow serialization of exceptions across a web > service boundary. If you are not doing SOA, you can, technically speaking, > drop this requirement. Unless you have greatly altered the exception > implementation, it is not a lot of work to make it serializable (add an > attribute). > > -- > Gregory A. Beamer > MVP; MCP: +I, SE, SD, DBA > > ************************************************* > Think outside of the box! > ************************************************* > "Ginny" <techni***@peoplewareindia.com> wrote in message > news:e6MaDtavGHA.2260@TK2MSFTNGP03.phx.gbl... >> The .NET architecture guide says that "Exceptions need to be serializble >> in >> order to flow upstream accross tiers". Why? Cant we simply throw >> excpetions >> to the calling code even if it is in a diffent component in a differnt >> layer >> in a differnt machine on the newtork? I think it is basiccly passing >> exceptions. >> >> -- >> Regards >> Ginny >> >> > > |
|||||||||||||||||||||||