Skip to main content

All Questions

Tagged with
2 votes
2 answers
3k views

Validations and throwing exceptions in DDD?

I have a question regarding validations and exceptions in DDD. I have a ValueObject say, PasswordText which takes a string argument in it's constructor. Checks if the string matches the password ...
honey_ramgarhia's user avatar
1 vote
5 answers
2k views

What is best way to handling exceptions without users see errors for technical supports?

Assuming you have a software which you gave to clients. Now we all know that exceptions can be saved to files, databases, and so on for tracing errors by technicians. As all engineers know, no Apps ...
CowBoy's user avatar
  • 153
32 votes
7 answers
12k views

How to treat unhandled exceptions? (Terminate the application vs. Keep it alive)

What is best practice when a unhandled exceptions occurs in a desktop application? I was thinking about to show a message to the user, so that he can contact support. I would recommend to the user to ...
Jonas Benz's user avatar
1 vote
2 answers
1k views

Throw Custom Exception

First, I know - there are a lot of online resources that talk about the topic Exception handling - but yet there is still something that's unclear to me. Consider having this code in an external ...
devsmn's user avatar
  • 119
1 vote
5 answers
1k views

Limits of Defensive Programming acknowledging that Exception Handling should be avoided

I've read Defensive Programming vs Exception Handling? and if/else statements or exceptions, but none contain something relevant to what I'm searching for. Taking into account that exception handling ...
Lefteris008's user avatar
17 votes
3 answers
7k views

Should I localize exception messages?

It is probably related to "Who should read Exception.Message if at all" and similar questions asked on this site, but I don't see how it is possible to always generate a custom message while avoiding ...
username's user avatar
  • 281
-3 votes
1 answer
82 views

Convention for exception argument order [closed]

Just a quick question about a design pattern for creating custom exceptions. The question is more about the order of parameters. If you can specify more data in the exception, should the parameter for ...
Zymus's user avatar
  • 2,533
0 votes
1 answer
971 views

Include exceptions in activity diagrams? [closed]

Should I include exceptions, like a TimeOutException or just general Exceptions, to a activity diagram? For example: A activity diagram describing a client-server connection. Several exceptions can ...
Tobias H's user avatar
9 votes
3 answers
2k views

Should I make my own exceptions, or co-opt similar exceptions for slightly non-standard purposes?

This is a general design question, but I'm focusing on C# and .NET because those are the languages I'm working with right now. Should I create my own, new exception classes, or co-opt existing ...
GregRos's user avatar
  • 1,763
5 votes
2 answers
892 views

Strategies to analyze collected exceptions

We want to add error feedback to our application. I had a look at existing solutions (e.g. raygun.io), but these work "in the cloud", which is a no-go for us: most installations of our application are ...
Lukas Rieger's user avatar
0 votes
1 answer
696 views

proper exception handling (throwing/message) dll libary

I just wrote a dll library using vb.net. while testing, i got an error which i did not initially use a try-catch block. The code is Try 'The first four bytes are for the Command ...
Smith's user avatar
  • 643
6 votes
5 answers
6k views

How to handle exceptions that get absorbed by a 3rd party library?

I'm currently having an issue with a 3rd party control library provider. They have an exception occulting culture that gets in the way of my general fail-fast approach when developing software. An ...
Crono's user avatar
  • 1,657
3 votes
1 answer
1k views

How to differentiate between exceptions coming from system and business logic?

I would like to differentiate between exceptions coming from business logic like requested database record does not exist attempt to store invalid business data (validation failed) provided CSV file ...
miroxlav's user avatar
  • 672
2 votes
1 answer
113 views

Under which circumstances does it make sense to lose track of where an exception was thrown from?

Is there any valid reason why a catch block on a lower layer would throw back an exception caused by a higher, unknown layer using the following syntax: throw ex; ... rather than: throw; ... ? In ...
Crono's user avatar
  • 1,657

15 30 50 per page