Ecosyste.ms: Awesome
An open API service indexing awesome lists of open source software.
https://github.com/nettyplus/netty-leak-detector-junit-extension
Netty leak detection ⭐️
https://github.com/nettyplus/netty-leak-detector-junit-extension
java junit junit-extension junit5 netty
Last synced: 22 days ago
JSON representation
Netty leak detection ⭐️
- Host: GitHub
- URL: https://github.com/nettyplus/netty-leak-detector-junit-extension
- Owner: nettyplus
- License: apache-2.0
- Created: 2024-02-17T17:30:07.000Z (9 months ago)
- Default Branch: main
- Last Pushed: 2024-09-30T05:08:37.000Z (about 1 month ago)
- Last Synced: 2024-10-01T07:42:54.706Z (about 1 month ago)
- Topics: java, junit, junit-extension, junit5, netty
- Language: Java
- Homepage:
- Size: 166 KB
- Stars: 3
- Watchers: 1
- Forks: 0
- Open Issues: 0
-
Metadata Files:
- Readme: README.md
- License: LICENSE
Awesome Lists containing this project
README
# netty-leak-detector-junit-extension [![Maven Central](https://img.shields.io/maven-central/v/io.github.nettyplus/netty-leak-detector-junit-extension.svg)](https://search.maven.org/artifact/io.github.nettyplus/netty-leak-detector-junit-extension)
# About this library
This JUnit 5 [extension](https://junit.org/junit5/docs/current/user-guide/#extensions) detects resource leaks by registering a Netty [LeakListener](https://netty.io/4.1/api/io/netty/util/ResourceLeakDetector.LeakListener.html)
# Example: Java unit test
```java
import io.github.nettyplus.leakdetector.junit.NettyLeakDetectorExtension;
import org.junit.jupiter.api.Test;
import org.junit.jupiter.api.extension.ExtendWith;@ExtendWith(NettyLeakDetectorExtension.class)
class FooTest {
@Test
void testSomething() {
// ...
}
}```
# Example: Maven pom.xml
```
io.github.nettyplus
netty-leak-detector-junit-extension
0.0.5
test```
# Projects that use this library
- [async-http-client](https://github.com/AsyncHttpClient/async-http-client)
- [kroxylicious](https://github.com/kroxylicious/kroxylicious)# Presentations
This library was discussed in a [Netty presentation](https://speakerdeck.com/sullis/netty-chicago-java-user-group-2024-04-17) at the Chicago Java User Group.
## How to release a new version?
1. Every change on the main development branch is released as `-SNAPSHOT` version to Sonatype snapshot repo
at https://oss.sonatype.org/content/repositories/snapshots/io/github/nettyplus/netty-leak-detector-junit-extension/
2. In order to release a non-snapshot version to Maven Central push an annotated tag, for example:```
git tag -a -m "Release 0.x.y" v0.x.y
git push origin v0.x.y
```3. At the moment, you **may not create releases from GitHub Web UI**. Doing so will make the CI build fail because the
CI creates the changelog and posts to GitHub releases. We'll support this in the future.