SpiceIt Maven Plugin

SpiceIt Maven Plugin: the easy way to use SpiceIt in your Maven project.

License

License

Categories

Categories

Maven Build Tools
GroupId

GroupId

gg.neko.spiceit
ArtifactId

ArtifactId

spiceit-maven-plugin
Last Version

Last Version

0.1
Release Date

Release Date

Type

Type

maven-plugin
Description

Description

SpiceIt Maven Plugin
SpiceIt Maven Plugin: the easy way to use SpiceIt in your Maven project.

Download spiceit-maven-plugin

How to add to project

<plugin>
    <groupId>gg.neko.spiceit</groupId>
    <artifactId>spiceit-maven-plugin</artifactId>
    <version>0.1</version>
</plugin>

Dependencies

compile (4)

Group / Artifact Type Version
gg.neko.spiceit : spiceit-injector jar 0.1
org.apache.maven : maven-plugin-api jar 3.6.2
org.apache.maven : maven-project jar 2.2.1
org.apache.maven.plugin-tools : maven-plugin-annotations jar 3.6.0

test (4)

Group / Artifact Type Version
ch.qos.logback : logback-classic jar 1.2.3
org.junit.jupiter : junit-jupiter-api jar 5.5.2
org.junit.jupiter : junit-jupiter-engine jar 5.5.2
org.mockito : mockito-junit-jupiter jar 3.1.0

Project Modules

There are no modules declared in this project.

SpiceIt

A collection of nice, easy to use features to make your code spicier.

Build Status Coveralls github branch LGTM Grade GitHub nyan

With SpiceIt, this class: example class

produces this output: example output

Getting started

SpiceIt features are exposed by the API module: go on and import it as a Maven dependency:

<dependency>
    <groupId>gg.neko.spiceit</groupId>
    <artifactId>spiceit-api</artifactId>
    <version>0.1</version>
</dependency>

Making it work

SpiceIt needs to inject its magic into your bytecode.
It can do so with either its Maven plugin or its Java agent.

  • Maven plugin
    add this plugin to your pom.xml plugins section:
    <plugin>
        <groupId>gg.neko.spiceit</groupId>
        <artifactId>spiceit-maven-plugin</artifactId>
        <version>0.1</version>
        <executions>
            <execution>
                <goals>
                    <goal>spiceit</goal>
                </goals>
            </execution>
        </executions>
    </plugin>
  • Java agent
    download the agent from Maven Central Repository (or compile it from source, if that's your thing) and launch your application with this option:
    -javaagent:spiceit-agent-0.1-jar-with-dependencies.jar

Check out the example projects making use of Maven plugin and Java agent.

Available features

Here are the spicy features!

  • LogIt logs methods entry, exit and error
  • TimeIt logs methods execution time

More coming soon™ 😎

Transitive dependencies

Just SLF4J for logging, already provided by SpiceIt API module.
Since it's a simple façade for various logging framework, you can choose your favorite implementation, e.g. logback or log4j.

License

Licensed under the MIT License.

Versions

Version
0.1