From 9c1083016ff94e9050f287d1826f2eca1bf64fa2 Mon Sep 17 00:00:00 2001 From: Matt Domsch Date: Thu, 6 May 2021 17:52:22 -0500 Subject: [PATCH 1/2] Fix javadoc errors Signed-off-by: Matt Domsch --- .../com/sailpoint/fastfed/sdk/services/FastFedSdkService.java | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/fastfed-java-sdk/src/main/java/com/sailpoint/fastfed/sdk/services/FastFedSdkService.java b/fastfed-java-sdk/src/main/java/com/sailpoint/fastfed/sdk/services/FastFedSdkService.java index 36bdc16..c469bae 100644 --- a/fastfed-java-sdk/src/main/java/com/sailpoint/fastfed/sdk/services/FastFedSdkService.java +++ b/fastfed-java-sdk/src/main/java/com/sailpoint/fastfed/sdk/services/FastFedSdkService.java @@ -122,7 +122,7 @@ public void start(String applicationServerFastFedMetdataUrl) throws Exception { * be called because this is what whitelists the provider based on the provider's FastFed metadata. This is * applicable when this server is acting as the initiating server (the one that will call the remote /start endpoint) * - * @param type @see fastfed.atlas.model.FastFedHandshakeType + * @param type * @param account the email account that will be used to perform WebFinger discovery (only for type AUTHENTICATION) * @param fastfedMetadataEndpoint the fastfed metadata endpoint url (only for type GOVERNANCE) * @return FastFedStartResponse object with information for the UI to use to kick off the process @@ -196,7 +196,7 @@ public void finalizeFastFed(String token) throws Exception { * and call IDN's API to configure SSO and/or create an app * * @param token an undecoded, signed JWT token - * @returns the registration's response JSON + * @return the registration's response JSON */ public String handshakeRegister(String token) throws Exception { From 8c4f289e09ea0d688237f95b5a00a7864cd0e2dd Mon Sep 17 00:00:00 2001 From: Matt Domsch Date: Thu, 6 May 2021 17:52:59 -0500 Subject: [PATCH 2/2] Prepare gradle for publishing Signed-off-by: Matt Domsch Prepare gradle for publishing Signed-off-by: Matt Domsch --- fastfed-java-sdk/build.gradle | 93 +++++++++++++++++++++++++++----- fastfed-java-sdk/settings.gradle | 2 +- 2 files changed, 82 insertions(+), 13 deletions(-) diff --git a/fastfed-java-sdk/build.gradle b/fastfed-java-sdk/build.gradle index 10b768a..4c340e7 100644 --- a/fastfed-java-sdk/build.gradle +++ b/fastfed-java-sdk/build.gradle @@ -1,23 +1,17 @@ -/* - * This file was generated by the Gradle 'init' task. - * - * This generated file contains a sample Java project to get you started. - * For more details take a look at the Java Quickstart chapter in the Gradle - * User Manual available at https://docs.gradle.org/5.2.1/userguide/tutorial_java_projects.html - */ - plugins { // Apply the java plugin to add support for Java id 'java-library' id 'java-library-distribution' + id 'maven-publish' + id 'signing' } +version = '0.2.0-SNAPSHOT' + repositories { mavenCentral() } -version = '0.1.0' - jar { manifest { attributes('Implementation-Title': project.name, @@ -28,7 +22,7 @@ jar { distributions { main { - baseName = 'fastfed-java-sdk' + baseName = 'openid-fastfed-sdk' contents { from 'src/main/resources/' into "config" @@ -67,4 +61,79 @@ allprojects { options.compilerArgs << "-Xlint:unchecked" << "-Xlint:deprecation" } } -} \ No newline at end of file +} + +java { + modularity.inferModulePath = true + withJavadocJar() + withSourcesJar() +} + +javadoc { + if (JavaVersion.current().isJava9Compatible()) { + options.addBooleanOption('html5', true) + } +} + +ext.isReleaseVersion = !version.endsWith("SNAPSHOT") + +publishing { + publications { + maven(MavenPublication) { + from components.java + pom { + name = 'openid-fastfed-sdk' + description = 'OpenID Fast Federation SDK for Java' + url = 'http://github.com/sailpoint-oss/fastfed-sdk' + + licenses { + license { + name = 'MIT' + url = 'https://opensource.org/licenses/MIT' + } + } + developers { + developer { + id = 'brian-rose-sp' + name = 'Brian Rose' + email = 'brian.rose@sailpoint.com' + } + developer { + id = 'matt-domsch-sp' + name = 'Matt Domsch' + email = 'matt.domsch@sailpoint.com' + } + } + scm { + connection = 'scm:git:git://github.com/sailpoint-oss/fastfed-sdk.git' + developerConnection = 'scm:git:ssh://github.com/sailpoint-oss/fastfed-sdk.git' + url = 'https://github.com/sailpoint-oss/fastfed-sdk/' + } + } + } + } + repositories { + maven { + name = 'myRepo' + url = "file://${buildDir}/repo" + } + maven { + def releaseRepo = "https://s01.oss.sonatype.org/service/local/staging/deploy/maven2/" + def snapshotRepo = "https://s01.oss.sonatype.org/content/repositories/snapshots/" + url = isReleaseVersion ? releaseRepo : snapshotRepo + credentials { + username = project.hasProperty('ossrhUsername') ? ossrhUsername : "Unknown user" + password = project.hasProperty('ossrhPassword') ? ossrhPassword : "Unknown password" + } + } + } +} + +signing { + useGpgCmd() + sign publishing.publications.maven +} + +group = 'com.sailpoint' +sourceCompatibility = 9; +targetCompatibility = 9; diff --git a/fastfed-java-sdk/settings.gradle b/fastfed-java-sdk/settings.gradle index 69d13cd..f3b1405 100644 --- a/fastfed-java-sdk/settings.gradle +++ b/fastfed-java-sdk/settings.gradle @@ -7,4 +7,4 @@ * in the user manual at https://docs.gradle.org/5.2.1/userguide/multi_project_builds.html */ -rootProject.name = 'fastfed-java-sdk' +rootProject.name = 'openid-fastfed-sdk'