Skip to content

Commit

Permalink
Version 6.0.0 compatible with Graylog 6.0.0
Browse files Browse the repository at this point in the history
  • Loading branch information
huksley committed May 10, 2024
1 parent 5f10f92 commit 4bfe6f1
Show file tree
Hide file tree
Showing 8 changed files with 705 additions and 488 deletions.
24 changes: 22 additions & 2 deletions pom.xml
Original file line number Diff line number Diff line change
Expand Up @@ -22,8 +22,9 @@
<maven.install.skip>true</maven.install.skip>
<maven.deploy.skip>true</maven.deploy.skip>
<maven.site.skip>true</maven.site.skip>
<graylog2.version>4.2.6</graylog2.version>
<graylog2.syslog4j.version>0.9.60</graylog2.syslog4j.version>
<graylog2.version>6.0.0</graylog2.version>
<graylog2.syslog4j.version>0.9.61</graylog2.syslog4j.version>
<guice.version>7.0.0</guice.version>
</properties>

<dependencies>
Expand Down Expand Up @@ -51,6 +52,25 @@
<version>1.7.21</version>
<scope>provided</scope>
</dependency>
<dependency>
<groupId>com.google.inject</groupId>
<artifactId>guice</artifactId>
<version>${guice.version}</version>
<scope>provided</scope>
</dependency>
<dependency>
<groupId>com.google.inject.extensions</groupId>
<artifactId>guice-assistedinject</artifactId>
<version>${guice.version}</version>
<scope>provided</scope>
</dependency>
<!-- FIXME: must match one used by graylog -->
<dependency>
<groupId>org.graylog2.repackaged</groupId>
<artifactId>uuid</artifactId>
<version>3.2.1</version>
<scope>provided</scope>
</dependency>
</dependencies>
<build>
<plugins>
Expand Down
8 changes: 4 additions & 4 deletions run-graylog
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
#!/bin/bash
HERE=$PWD
GL=~/Downloads/graylog-4.0.8
GL=~/Downloads/graylog-6.0.0
TT=$GL/tmp
mkdir -p $TT
sudo umount $TT
Expand All @@ -9,7 +9,7 @@ export JAVA_OPTS="-Djava.io.tmpdir=$TT"
rm -Rf $GL/data
mkdir -p $GL/data
mvn package -DskipTests
cp target/graylog-output-syslog-4.0.8.jar $GL/plugin
cp target/graylog-output-syslog-6.0.0.jar $GL/plugin
export GRAYLOG_CONF=$GL/graylog.conf
sudo sysctl -w vm.max_map_count=262144

Expand All @@ -18,12 +18,12 @@ docker run --name elastic -p 9200:9200 -e "discovery.type=single-node" \
-e "cluster.routing.allocation.disk.threshold_enabled=false" \
-d elasticsearch:7.10.1
docker rm -f mongo
docker run --name mongo -p 27017:27017 -d mongo:3.6
docker run --name mongo -p 27017:27017 -d mongo:5.0
docker start elastic
docker start mongo
sleep 10
$GL/bin/graylogctl run

## Run two consoles additionally:
## docker run -it -p 514:514/udp -p 514:514/tcp -p 601:601 --name syslog-ng balabit/syslog-ng:latest
## docker run -it -p 514:514/udp -p 514:514/tcp -p 601:601 --name syslog-ng balabit/syslog-ng:latest
## docker exec syslog-ng tail -f /var/log/messages
12 changes: 7 additions & 5 deletions run-graylog-mac
Original file line number Diff line number Diff line change
@@ -1,10 +1,12 @@
#!/bin/bash
set -e
HERE=$PWD
VER=4.2.6
if [ ! -f graylog-$VER.tgz ]; then
curl -O graylog-$VER.tgz $URL
fi
VER=6.0.0
URL=https://downloads.graylog.org/releases/graylog/graylog-$VER.tgz
if [ ! -f "graylog-$VER.tgz" ]; then
echo "Downloading $URL"
curl -L -o graylog-$VER.tgz $URL
fi
if [ ! -d graylog-$VER ]; then
tar -xzvf graylog-$VER.tgz
fi
Expand All @@ -27,7 +29,7 @@ docker run --name elastic -p 9200:9200 -e "discovery.type=single-node" \
-d elasticsearch:7.10.1

docker rm -f mongo
docker run --name mongo -p 27017:27017 -d mongo:3.6
docker run --name mongo -p 27017:27017 -d mongo:5.0
docker start elastic
docker start mongo
sleep 10
Expand Down
Loading

1 comment on commit 4bfe6f1

@kontiki99
Copy link

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

hello. I downloaded this plugin and tried to build it with maven on linux. It stops with error : T E S T S
Running com.wizecore.graylog2.plugin.test.TestFullSender
Tests run: 2, Failures: 1, Errors: 1, Skipped: 0, Time elapsed: 0.107 sec <<< FAILURE!
testMessageTruncation(com.wizecore.graylog2.plugin.test.TestFullSender) Time elapsed: 0.073 sec <<< ERROR!
java.lang.NoClassDefFoundError: com/swrve/ratelimitedlogger/RateLimitedLog
at org.graylog2.plugin.utilities.ratelimitedlog.RateLimitedLogFactory.createRateLimitedLog(RateLimitedLogFactory.java:31)
at org.graylog2.plugin.Message.(Message.java:89)´

Any hint hwo to fix that ? I am quit new to maven

Please sign in to comment.