-
Notifications
You must be signed in to change notification settings - Fork 141
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Add JDBC driver jenkins CI workflow #957
Add JDBC driver jenkins CI workflow #957
Conversation
Signed-off-by: Yury-Fridlyand <[email protected]>
Signed-off-by: Yury-Fridlyand <[email protected]>
Signed-off-by: Yury-Fridlyand <[email protected]>
Signed-off-by: Yury-Fridlyand <[email protected]>
Add JDBC driver jenkins CI workflow
This comment was marked as spam.
This comment was marked as spam.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Hi @Yury-Fridlyand please see these comments and we can discuss more later.
Thanks
stage('Publish to Maven Local') { | ||
steps { | ||
// checkout the commit | ||
checkout([ | ||
$class: 'GitSCM', userRemoteConfigs: [[url: 'https://github.com/opensearch-project/sql.git']], | ||
branches: [[name: "$ref"]] | ||
]) | ||
|
||
dir('sql-jdbc') { | ||
// publish maven artifacts | ||
sh('./gradlew --no-daemon publishPublishMavenPublicationToLocalRepoRepository') | ||
} | ||
} | ||
} |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Will need to discuss a bit as we want two options: triggered by tag or manually trigger on Jenkins.
Just in case there is issues with github and we can still release.
See maps server jenkinsfile for more references:
https://github.com/peterzhuamazon/maps/blob/a40788a611e1d0f573d715e0b1ce59b7fb33e4d0/jenkins/maps-server-release.jenkinsfile
} | ||
} | ||
} | ||
publishMaven(MavenPublication) { publication -> |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
What is the group of the jdbc?
org.opensearch.client.opensearch-sql-jdbc
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Currently, org.opensearch.client
. What should be?
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Hey @Yury-Fridlyand and @peterzhuamazon should this be org.opensearch.driver
as groupId? and artifact name should be opensearch-sql-jdbc
.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Fixed in 79deba0.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
See my next comment on this.
Signed-off-by: Yury-Fridlyand <[email protected]>
Signed-off-by: Yury-Fridlyand <[email protected]>
Signed-off-by: Yury-Fridlyand <[email protected]>
@@ -39,7 +39,7 @@ pipeline { | |||
) | |||
} | |||
environment { | |||
ARTIFACT_PATH = "$WORKSPACE/build/repository/org/opensearch/client/sql/$VERSION" | |||
ARTIFACT_PATH = "$WORKSPACE/build/repository/org/opensearch/driver/opensearch-sql-jdbc/$VERSION" |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
We used to put the jdbc in this location during ODFE.
Probably we want to keep similar subfolder structure?
https://repo1.maven.org/maven2/com/amazon/opendistroforelasticsearch/client/opendistro-sql-jdbc/
Thanks.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
It is the path where gradle places compiled jar
:
$ tree build | grep -v class
build
....
├── repository
│ └── org
│ └── opensearch
│ └── driver
│ └── opensearch-sql-jdbc
│ ├── 2.0.0.0
│ │ ├── opensearch-sql-jdbc-2.0.0.0.jar
....
In general, there is the same structure, but we renamed
com.amazon
toorg.opensearch
opendistroforelasticsearch
andopendistro
toopensearch
client
todriver
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Should I revert this?
url = "https://github.com/opensearch-project/sql/sql-jdbc" | ||
description = "OpenSearch SQL JDBC driver" | ||
scm { | ||
connection = "scm:[email protected]:opensearch-project/sql.git" |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
this should move to opensearch-project/sql-jdbc.git
scm { | ||
connection = "scm:[email protected]:opensearch-project/sql.git" | ||
developerConnection = "scm:[email protected]:opensearch-project/sql.git" | ||
url = "[email protected]:opensearch-project/sql.git" |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
this should move to opensearch-project/sql-jdbc.git
developers { | ||
developer { | ||
name = 'OpenSearch' | ||
url = 'https://github.com/opensearch-project/sql' |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
this should move to opensearch-project/sql-jdbc.git
url = "http://www.apache.org/licenses/LICENSE-2.0.txt" | ||
name = "OpenSearch SQL JDBC Driver" | ||
packaging = "jar" | ||
url = "https://github.com/opensearch-project/sql/sql-jdbc" |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
this should move to opensearch-project/sql-jdbc
pom { | ||
name = "OpenSearch SQL JDBC Driver" | ||
packaging = "jar" | ||
url = "https://github.com/opensearch-project/sql/sql-jdbc" |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
this should move to opensearch-project/sql-jdbc
url = "https://github.com/opensearch-project/sql/sql-jdbc" | ||
description = "OpenSearch SQL JDBC driver" | ||
scm { | ||
connection = "scm:[email protected]:opensearch-project/sql.git" |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
this should move to opensearch-project/sql-jdbc.git
scm { | ||
connection = "scm:[email protected]:opensearch-project/sql.git" | ||
developerConnection = "scm:[email protected]:opensearch-project/sql.git" | ||
url = "[email protected]:opensearch-project/sql.git" |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
this should move to opensearch-project/sql-jdbc.git
developers { | ||
developer { | ||
name = 'OpenSearch' | ||
url = 'https://github.com/opensearch-project/sql' |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
this should move to opensearch-project/sql-jdbc
Hi Yury |
Signed-off-by: Yury-Fridlyand <[email protected]>
Closing - changes and discussion to be tracked in opensearch-project/sql-jdbc#15. |
Signed-off-by: Yury-Fridlyand <[email protected]> Signed-off-by: Yury-Fridlyand <[email protected]>
Signed-off-by: Yury-Fridlyand <[email protected]> (cherry picked from commit 0e8de37) Signed-off-by: Yury-Fridlyand <[email protected]>
Description
Please, see team review discussion in Bit-Quill#140
Jenkins file
Combined from this and this.
It calls publishing
gradle
workflow to generate artifacts.Gradle workflow
New workflow (should be called from
sql-jdbc
dir)Files generated by gradle
See artifacts in artifacts.zip. The
jar
file has no dependencies inside.jar content
Shadow copy publishing could be invoked by
Artifacts
Shadow copy content
Obsolete references
I removed obsolete references to
com.amazonaws.opensearch
(replaced byorg.opensearch
where applicable).Issues Resolved
Adds JDBC driver publishing workflow
Check List
By submitting this pull request, I confirm that my contribution is made under the terms of the Apache 2.0 license.
For more information on following Developer Certificate of Origin and signing off your commits, please check here.