google / google/google-java-format
Found worker thread-leak
Đang mở
- Ngôn ngữ chính
- Java
- Star
- 6.2k
- Fork
- 937
- Merge trung bình
- 6 phút
- Pull request đã merge (30 ngày)
- 3
Mô tả
The formatter assumes that it is executed as a CLI, but it actually has a resource leak. I was trying to use it in a service, and the resource leak became apparent with more use. The issue is that Main.formatFiles creates an ExecutorService, but it doesn't shut it down. In addition it would be nice if a user could pass in their own ExecutorService whose lifecycle the user manages. That way, for every invocation of the formatter in a service context, a new ExecutorService need not be created/shutdown.
Hướng dẫn đóng góp
Đánh giá
Issue này chưa được đánh giá.