Logo Questions Linux Laravel Mysql Ubuntu Git Menu
 

Maven debugging output: What does (f) mean?

Tags:

maven-2

When you run Maven 2 with the -X flag, and you watch as it configures plugins, you might see output like this:

[DEBUG] Configuring mojo 'org.apache.maven.plugins:maven-clean-plugin:2.3:clean' -->
[DEBUG]   (f) directory = e:\projects\foobar\target
[DEBUG]   (f) excludeDefaultDirectories = false
[DEBUG]   (f) failOnError = true
[DEBUG]   (s) directory = .
[DEBUG]   (s) includes = [**/*~]
[DEBUG]   (f) filesets = [file set: . (included: [**/*~], excluded: [])]
[DEBUG]   (f) followSymLinks = false
[DEBUG]   (f) outputDirectory = e:\projects\foobar\target\classes
[DEBUG]   (f) project = MavenProject: foobar:foobar:1.0-SNAPSHOT @ e:\projects\foobar\pom.xml
[DEBUG]   (f) reportDirectory = e:\projects\foobar\target\site
[DEBUG]   (f) skip = false
[DEBUG]   (f) testOutputDirectory = e:\projects\foobar\target\test-classes
[DEBUG] -- end configuration --

What is the difference between an (f) and an (s)?

like image 492
Laird Nelson Avatar asked Jan 07 '10 17:01

Laird Nelson


1 Answers

Interesting question. I never paid attention to this little detail and couldn't find any documentation on it. So I greped the sources and this is what we can see in o.a.m.p.DebugConfigurationListener (from maven-core):

public void notifyFieldChangeUsingSetter( String fieldName, Object value, Object target )
{
    if ( logger.isDebugEnabled() )
    {
        logger.debug( "  (s) " + fieldName + " = " + toString( value ) );
    }
}

public void notifyFieldChangeUsingReflection( String fieldName, Object value, Object target )
{
    if ( logger.isDebugEnabled() )
    {
        logger.debug( "  (f) " + fieldName + " = " + toString( value ) );
    }
}

And the difference between (f) and (s) should be self-explaining (sigh) now.

like image 103
Pascal Thivent Avatar answered Nov 03 '22 05:11

Pascal Thivent