I have a simple question. I’m working on a Java project where some objects of the same class register their execution in MySQL. I don’t understand why but when the number of solutions in a table is a multiple of 500, the program gets stuck and no more solutions are found during a period.
I think in loggin the different objects but using log4j I only can have multiple logs with the same content. Does anybody know how to make different FileAppenders for different objects of the same class??
Thanks in advance.
First , you’ll need some way to identity the different instances of that class.
Second, log4j API shows how to create Logger’s by name. You don’t have to use the name of the class as the name of the
Logger. You can createLogger‘s with names that vary for each instance, like: