Replies: 3 comments 5 replies
-
I think it would add a certain degree of complexity but not a lot of real benefits. After all, the end users should not have to deal with those things. The only persons that may be interested to the exceptions would be the developers and we already have the command line and the console. In my experience, most of the problems I had to solve remotely were issues with Java versions. A nasty bug with Linux graphic subsystem was probably due to graphic drivers and not to FidoCadJ itself. Communicating with an external server introduces a huge number of issues: where to put the server, who maintains and pays for it, who reads the logs. More importantly it may open the door towards security problems that I do not want to be involved with. In my opinion, the game is not worth the candle. |
Beta Was this translation helpful? Give feedback.
-
Maybe showing them with a message box or something similar would be reasonable and more than enough (the user should be able to copy the text of the exception). |
Beta Was this translation helpful? Give feedback.
-
Hi,
I think it prevents to run FidoCadJ in the headless mode. I moved it in a section where it is executed only the program should not run on the command line only: Can you check if it is ok? |
Beta Was this translation helpful? Give feedback.
-
I would like to propose an improvement in our exception handling to ensure that all exceptions, both handled and unhandled, are properly captured and logged. Here’s the idea:
Currently, unhandled exceptions can go unnoticed, especially if they occur in non-EDT (non-Event Dispatch Thread) threads or if they are caught but not logged. This can make debugging and diagnosing issues.
Global Exception Handler:
Thread.setDefaultUncaughtExceptionHandler
: Configure this handler to capture all unhandled exceptions in non-EDT threads. This will allow us to log any exception that escapes standard checks in these threads.Swing EventQueue Management: Set up a specific handler for the EDT, which is the main thread where UI operations occur. This way, we can intercept all unhandled exceptions that occur during user interface interactions.
Custom Exception Class for Logging:
Create a custom exception class that automatically logs every exception at the time of its creation. This ensures that even exceptions caught in try-catch blocks will be automatically recorded in a log file without needing to manually add logging code in each block.
This centralized approach will provide a comprehensive view of all exceptions occurring, making it easier to debug and monitor the application.
We could also consider implementing log submission to a server with a custom PHP page, of course, only if the user chooses to send it.
Beta Was this translation helpful? Give feedback.
All reactions