apache/maven · warning

Transport name '{}' is DEPRECATED/RENAMED, use '{}' instead

Error message

Transport name '{}' is DEPRECATED/RENAMED, use '{}' instead

What it means

-Dmaven.resolver.transport selects the transport Resolver uses (file/jdk/apache/wagon/auto). The value 'native' was renamed to 'apache' (Apache HttpClient transporters). Maven still accepts 'native', forces the file+apache transporter priorities exactly as 'apache' would, and warns that the name is deprecated.

Source

Thrown at impl/maven-core/src/main/java/org/apache/maven/internal/aether/DefaultRepositorySystemSessionFactory.java:323

            }

            configProps.put("aether.transport.wagon.perms.fileMode." + server.getId(), server.getFilePermissions());
            configProps.put("aether.transport.wagon.perms.dirMode." + server.getId(), server.getDirectoryPermissions());
        }
        sessionBuilder.setAuthenticationSelector(authSelector);

        Object transport =
                mergedProps.getOrDefault(Constants.MAVEN_RESOLVER_TRANSPORT, MAVEN_RESOLVER_TRANSPORT_DEFAULT);
        if (MAVEN_RESOLVER_TRANSPORT_DEFAULT.equals(transport)) {
            // The "default" mode (user did not set anything) from now on defaults to AUTO
        } else if (MAVEN_RESOLVER_TRANSPORT_JDK.equals(transport)) {
            // Make sure (whatever extra priority is set) that resolver file/jdk is selected
            configProps.put(FILE_TRANSPORTER_PRIORITY_KEY, RESOLVER_MAX_PRIORITY);
            configProps.put(JDK_HTTP_TRANSPORTER_PRIORITY_KEY, RESOLVER_MAX_PRIORITY);
        } else if (MAVEN_RESOLVER_TRANSPORT_APACHE.equals(transport)
                || MAVEN_RESOLVER_TRANSPORT_NATIVE.equals(transport)) {
            if (MAVEN_RESOLVER_TRANSPORT_NATIVE.equals(transport)) {
                logger.warn(
                        "Transport name '{}' is DEPRECATED/RENAMED, use '{}' instead",
                        MAVEN_RESOLVER_TRANSPORT_NATIVE,
                        MAVEN_RESOLVER_TRANSPORT_APACHE);
            }
            // Make sure (whatever extra priority is set) that resolver file/apache is selected
            configProps.put(FILE_TRANSPORTER_PRIORITY_KEY, RESOLVER_MAX_PRIORITY);
            configProps.put(APACHE_HTTP_TRANSPORTER_PRIORITY_KEY, RESOLVER_MAX_PRIORITY);
        } else if (MAVEN_RESOLVER_TRANSPORT_WAGON.equals(transport)) {
            // Make sure (whatever extra priority is set) that wagon is selected
            configProps.put(WAGON_TRANSPORTER_PRIORITY_KEY, RESOLVER_MAX_PRIORITY);
        } else if (!MAVEN_RESOLVER_TRANSPORT_AUTO.equals(transport)) {
            throw new IllegalArgumentException("Unknown resolver transport '" + transport
                    + "'. Supported transports are: " + MAVEN_RESOLVER_TRANSPORT_WAGON + ", "
                    + MAVEN_RESOLVER_TRANSPORT_APACHE + ", " + MAVEN_RESOLVER_TRANSPORT_JDK + ", "
                    + MAVEN_RESOLVER_TRANSPORT_AUTO);
        }

        sessionBuilder.setIgnoreArtifactDescriptorRepositories(request.isIgnoreTransitiveRepositories());

View on GitHub (pinned to e4093d4e12)

Solutions

  1. Change the property value from 'native' to 'apache': -Dmaven.resolver.transport=apache
  2. Search .mvn/maven.config, MAVEN_OPTS and CI variables for the stale value and update all occurrences
  3. Consider dropping the property entirely - 'auto' (the default) picks the best available transport

Example fix

# before
mvn -Dmaven.resolver.transport=native clean install
# after
mvn -Dmaven.resolver.transport=apache clean install
Defensive patterns

Strategy: validation

Validate before calling

# accept only current transport names in build scripts
TRANSPORT="${MAVEN_RESOLVER_TRANSPORT:-auto}"
case "$TRANSPORT" in auto|jdk|apache|wagon) ;; native) TRANSPORT=apache ;; *) TRANSPORT=auto ;; esac
mvn -Dmaven.resolver.transport="$TRANSPORT" clean install

Prevention

When it happens

Trigger: Starting Maven with -Dmaven.resolver.transport=native on the CLI, in .mvn/maven.config, MAVEN_OPTS, or CI pipeline environment; value propagated from old tuning guides.

Common situations: Build scripts written when the Apache transport was called 'native' (Maven 3.9-era resolver tuning); CI templates copied between projects.

Related errors


AI-assisted analysis of apache/maven@e4093d4e12 (2026-08-21). Data as JSON: /api/errors/fee9186c9cfb4c40. Report an issue: GitHub.