Initial work in progress on plugin deps and uberjar.
This commit is contained in:
parent
0124b21692
commit
5c18eb58d7
|
@ -56,6 +56,8 @@ public class ClientRouteBuilder extends RouteBuilder {
|
||||||
.stop()
|
.stop()
|
||||||
.otherwise()
|
.otherwise()
|
||||||
.to("seda:metrics");
|
.to("seda:metrics");
|
||||||
|
} else {
|
||||||
|
log.info(">>> Skipping extension: " + ext.getDescription());
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
|
@ -15,13 +15,14 @@ subprojects {
|
||||||
testImplementation project(':shared')
|
testImplementation project(':shared')
|
||||||
|
|
||||||
implementation project(':shared')
|
implementation project(':shared')
|
||||||
|
implementation "org.slf4j:slf4j-api:${slf4jVersion}"
|
||||||
implementation(group: 'org.pf4j', name: 'pf4j', version: "${pf4jVersion}") {
|
implementation(group: 'org.pf4j', name: 'pf4j', version: "${pf4jVersion}") {
|
||||||
exclude(group: "org.slf4j")
|
exclude(group: "org.slf4j")
|
||||||
}
|
}
|
||||||
annotationProcessor(group: 'org.pf4j', name: 'pf4j', version: "${pf4jVersion}")
|
annotationProcessor(group: 'org.pf4j', name: 'pf4j', version: "${pf4jVersion}")
|
||||||
implementation "org.slf4j:slf4j-api:${slf4jVersion}"
|
|
||||||
}
|
}
|
||||||
|
|
||||||
|
/*
|
||||||
jar {
|
jar {
|
||||||
manifest {
|
manifest {
|
||||||
attributes(
|
attributes(
|
||||||
|
@ -32,14 +33,38 @@ subprojects {
|
||||||
'Plugin-Description': "${pluginDescription}"
|
'Plugin-Description': "${pluginDescription}"
|
||||||
)
|
)
|
||||||
}
|
}
|
||||||
|
|
||||||
|
}*/
|
||||||
|
|
||||||
|
task uberJar(type: Jar) {
|
||||||
|
from sourceSets.main.output
|
||||||
|
dependsOn configurations.runtimeClasspath
|
||||||
|
from {
|
||||||
|
configurations.runtimeClasspath.findAll { it.name.endsWith('jar') }.collect {
|
||||||
|
zipTree(it).matching {
|
||||||
|
exclude 'org/slf4j/**'
|
||||||
|
}
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
|
manifest {
|
||||||
|
attributes(
|
||||||
|
'Plugin-Id' : "${pluginId}",
|
||||||
|
'Plugin-Class' : "${pluginClass}",
|
||||||
|
'Plugin-Version' : "${pluginVersion}",
|
||||||
|
'Plugin-Provider' : "${pluginProvider}",
|
||||||
|
'Plugin-Description': "${pluginDescription}"
|
||||||
|
)
|
||||||
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
task copyJar(type: Copy, dependsOn:[jar]) {
|
task copyJar(type: Copy, dependsOn: ['uberJar']) {
|
||||||
from jar // here it automatically reads jar file produced from jar task
|
from jar
|
||||||
into "../output/"
|
into "../output/"
|
||||||
}
|
}
|
||||||
|
|
||||||
tasks.build.dependsOn {
|
tasks.build.dependsOn {
|
||||||
|
uberJar
|
||||||
copyJar
|
copyJar
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
|
@ -0,0 +1,2 @@
|
||||||
|
plugins {
|
||||||
|
}
|
7
plugins/os-ibmi/README.md
Normal file
7
plugins/os-ibmi/README.md
Normal file
|
@ -0,0 +1,7 @@
|
||||||
|
# IBM i Plugin
|
||||||
|
|
||||||
|
## Processor Extension
|
||||||
|
|
||||||
|
## Memory Extension
|
||||||
|
|
||||||
|
## Disk Extension
|
7
plugins/os-ibmi/build.gradle
Normal file
7
plugins/os-ibmi/build.gradle
Normal file
|
@ -0,0 +1,7 @@
|
||||||
|
plugins {
|
||||||
|
}
|
||||||
|
|
||||||
|
dependencies {
|
||||||
|
// https://mvnrepository.com/artifact/net.sf.jt400/jt400
|
||||||
|
implementation group: 'net.sf.jt400', name: 'jt400', version: '10.6'
|
||||||
|
}
|
6
plugins/os-ibmi/gradle.properties
Normal file
6
plugins/os-ibmi/gradle.properties
Normal file
|
@ -0,0 +1,6 @@
|
||||||
|
pluginId=sysmon-ibmi
|
||||||
|
pluginClass=sysmon.plugins.os_ibmi.IbmIPlugin
|
||||||
|
pluginVersion=0.0.1
|
||||||
|
pluginProvider=System Monitor
|
||||||
|
pluginDependencies=
|
||||||
|
pluginDescription=Collects IBM-i OS metrics.
|
|
@ -0,0 +1,18 @@
|
||||||
|
package sysmon.plugins.os_ibmi;
|
||||||
|
|
||||||
|
import org.slf4j.Logger;
|
||||||
|
import org.slf4j.LoggerFactory;
|
||||||
|
import org.pf4j.Plugin;
|
||||||
|
import org.pf4j.PluginWrapper;
|
||||||
|
|
||||||
|
public class IbmIPlugin extends Plugin {
|
||||||
|
|
||||||
|
private static final Logger log = LoggerFactory.getLogger(IbmIPlugin.class);
|
||||||
|
|
||||||
|
public IbmIPlugin(PluginWrapper wrapper) {
|
||||||
|
super(wrapper);
|
||||||
|
}
|
||||||
|
|
||||||
|
}
|
||||||
|
|
||||||
|
|
|
@ -0,0 +1,2 @@
|
||||||
|
plugins {
|
||||||
|
}
|
Loading…
Reference in a new issue