The tool is implemented as an Java agent and therefore it can be started with or connected on runtime with the application. During execution the agent collects and sends the encrypted data via REST api to a second system which holds the data. It provides a GUI to explore and visualize those for the developer.
The agent itself is implemented in Java 8.
java -jar explorer-1.0-SNAPSHOT.jar.java -javaagent:agent-1.0-SNAPSHOT.jar -jar my-application-to-observe.jar.
$ jps
1234 my-application-to-observe.jar
23456 jps
Start the agentloader and provide agant and pid, here 1234:java -jar agentloader-1.0-SNAPSHOT.jar agent-1.0-SNAPSHOT.jar 1234
The only configuration option which must be defined is the web consumer to let agent know tho whom the data should be sent.
Furthermore we suggest to set the application name. The minimum configuration file looks like this:
consumer:
connectionUri: http://localhost:8080
versionapplicationNameinstrumentationTypeloggerLeveladapterfileNameconfigurations with following
packageFormatclassFormatmethodFormatstaticspreserveHistoryobjectStateDetailLevelparameterDetailLevelresultDetailLevelconnectionUri (required)userpasswordheaderstypeconnectionUri: https://localhost:8080/api/v1connectionUri: https://localhost:9200/{index}/_bulkconnectionUri: https://localhost:27017/app/{Mongo DB API key}/endpoint/data/beta/action/insertMany
consumer:
connectionUri: https://localhost:27017/app/{Mongo DB API key}/endpoint/data/beta/action/insertMany
type: MONGO_DB
mongoDb:
dataSource: "i.e. cluster id"
database: "database name"
collection: "collection name"
apiKey: "Mongo DB API key"
FILE_SYSTEM: only connectionUri is used to specifile file to write into in 'append' mode.
If one adapter is of type FILE it represents the file name where it is logged to. Default is 'agent.log'dateTimedateTime is reached. The format is YYYY-mm-dd hh:ss.stopWatchTimeInSecondstimeInSeconds is reached.
methodoccurrences tells how often a method was called.packageRegex defines the matching packages containing the methods. Classes might be included in this definition.methodRegex defines the matching method names.parameterCount the amount of parameter the method has.resultRegex defines the matching classes the method returns as a result.exceptionoccurrences tells how often an exception was thrown.packageRegex defines the matching packages. Exception as a class might be included in this definition.messageRegex defines the matching message given by exception.
version: 1.0
applicationName: ""
instrumentationType: DEBUG
logging:
loggerLevel: ERROR
adapter:
- CONSOLE
fileName: agent.log
instrumentation:
configurations:
- packageFormat: de.seospice.*.app.**
classFormat: My*Class
methodFormat: method*
statics: false
behavior:
preserveHistory: false
objectStateDetailLevel: NONE
parameterDetailLevel: INDICATION
resultDetailLevel: INDICATION
consumer:
connectionUri: http://localhost:8080
user: user
password: password
headers:
- "X-Forwarded-For: 127.0.0.1"
type = EXPLORER;
condition:
exitOnCondition: true
dateTime: "2022-12-24 18:00"
stopWatchTimeInSeconds: 5
method:
occurrences: 10
packageRegex: (com|de)\\.seospice\\.app
methodRegex: ^create
parameterCount: 1
resultRegex: Class$
exception:
occurrences: 10
packageRegex: (com|de)\\.seospice\\.app
messageRegex: ^Error during
We only tested Java.
Does the Explorer persist the received data?Currently not. When you exit the Explorer the date are lost. If you need persistence let us know.
Will there be support for Java 18?Yes!
Is it planned to have a special support for Spring Boot?We are on it!
Is it planned adding support finding unused classes, uncalled methods or non thrown exceptions more easily?
We are on it!
Is it planned giving an overview about the time used by methods like in NewRelic?Yes!