Black
Black

Reputation: 5367

Could not find artifact mule-module-json

I've been happily developing my API in AnypointStudio (Eclipse) 6.2.2 until just now I added a JSON-to-Object transformer to a flow; now when I build mvn clean package -U

I get:

Downloading: https://repository.mulesoft.org/nexus/content/repositories/public/org/mule/extensions/mule-extensions/3.8.3/mule-extensions-3.8.3.pom

[INFO] BUILD FAILURE

[INFO] -----------------------------------------------------------------------

[INFO] Total time: 14.775 s

[INFO] Finished at: 2017-07-19T10:38:10+10:00

[INFO] Final Memory: 25M/644M

[INFO] ------------------------------------------------------------------------

[ERROR] Failed to execute goal on project foobar: Could not resolve dependencies for project org.foo:bar:mule:1.0.0-SNAPSHOT: Failed to collect dependencies at org.mule.modules:mule-module-json:jar:3.8.3 -> org.mule.modules:mule-module-validation:jar:3.8.3: Failed to read artifact descriptor for org.mule.modules:mule-module-validation:jar:3.8.3: Could not find artifact org.mule.extensions:mule-extensions:pom:3.8.3 in Central (http://central.maven.org/maven2/) -> [Help 1]

Can anyone suggest what's going wrong? Do I need an EE licence to use JSON-to-Object?

Upvotes: 0

Views: 2802

Answers (1)

Black
Black

Reputation: 5367

I found the answer to this. My POM was using Mule runtime 3.8.3

<mule.version>3.8.3</mule.version>

However, there is no release of the json module that corresponds to this release. The latest at Mulesoft Releases is 3.8.1:

https://repository.mulesoft.org/nexus/content/repositories/releases/org/mule/modules/mule-module-json/3.8.1/

So, manually changing the version of this dependency in my POM gets around the issue:

     <dependency>
        <groupId>org.mule.modules</groupId>
        <artifactId>mule-module-json</artifactId>
        <version>3.8.1</version>
        <scope>provided</scope>
    </dependency>

Upvotes: 2

Related Questions