Closed gilbertg closed 9 years ago
@gilbertg you had several issues with the dependencies. Your build script should look like the following:
buildscript {
dependencies {
classpath group: 'org.mulesoft.build', name: 'mule-gradle-plugin', version: '1.2.0'
}
repositories {
maven { url 'http://repository.mulesoft.org/releases' }
}
}
repositories {
mavenLocal()
mavenCentral()
}
//apply plugin: 'mule' not required, applied automatically by muleStudio
apply plugin: 'mulestudio'
apply plugin: 'idea'
apply plugin: 'mmc'
//apply plugin: 'java' not required, applied automatically by muleStudio or mule
mule.version = '3.5.2'
mule.muleEnterprise = true
mule.enterpriseRepoUsername = eeRepoUser
mule.enterpriseRepoPassword = eeRepoPassword
mule.components {
module name: 'mule-module-sharepoint', version: '2.1.1', noClassifier: true, noExt: true
module name: 'mule-module-apikit-plugin', version: '1.5.2', noClassifier: true
module name: 'mule-module-objectstore', version: '1.3.1'
plugin group: 'org.mule.modules', name: 'mule-module-objectstore', version: '1.3.1'
plugin group: 'com.mulesoft.security', name: 'mule-module-security-oauth2-provider', version: '1.4.0', noClassifier: true, noExt: true
plugin group: 'com.mulesoft.security', name: 'mule-module-security-property-placeholder', version: '1.4.0', noClassifier: true, noExt: true
}
A couple of considerations:
noClassifier
and noExt
properties.noExt
is required.You had duplicated dependencies. I can acknowledge that being from the gradle studio plugin, unfortunately there is not enough information in studio to tell if the dependencies are published as a plugin or as a regular jar file. So it is doing just a best optimistic effort assuming everything is correctly packaged.
Awesome! its working now, thanks Juan. Question is - how do you know this stuff, or more importantly, how can one know this stuff? Is it possible to introspect the repo?
@gilbertg yes, you can openly browse it with your web browser, i.e. for the salesforce connector:
You will see the artifact deployed with the 'plugin' classifier and the 'zip' extension. If this file is not present then you would need to use the 'noExt' and 'noClassifier'.
For clarity, normally I would declare connectors not published as zip plugins into the regular 'dependencies' section. The dsl was originally thought for simplifying the process of adding zip plugins.
Hi, I'm using the muleEnterprise=true setting - and have valid credentials. With the buildscript below, and calling 'gradle clean studio', i get unresolved dependency message injected into .classpath for all modules except mule-module-objectstore. I have browsed the repo, an at least the security modules seem to be available on the give version. Can you point me in the right direction, as to how you resolved enterprise artefacts, and where i can find locations, versions etc?
btw, this is a great initiative - we're a Gradle shop, and really don't want to learn and adopt Maven. ~gilbert