Skip to content

doc(QTDI-3156): Improve docs for CreateConnection service#1251

Merged
dmytro-sylaiev merged 5 commits into
masterfrom
dsylaiev/QTDI-3156_improve_doc_createconnection
Jul 9, 2026
Merged

doc(QTDI-3156): Improve docs for CreateConnection service#1251
dmytro-sylaiev merged 5 commits into
masterfrom
dsylaiev/QTDI-3156_improve_doc_createconnection

Conversation

@dmytro-sylaiev

Copy link
Copy Markdown
Contributor

Requirements

  • Any code change adding any logic MUST be tested through a unit test executed with the default build
  • Any API addition MUST be done with a documentation update if relevant

Why this PR is needed?

  • Missing info in documentation about CreateConnection service behavior at studio-integration plugin

What does this PR adds (design/code thoughts)?

  • Doc change only

AI generated code

https://internal.qlik.dev/general/ways-of-working/code-reviews/#guidelines-for-ai-generated-code

  • [] this PR has been written with the help of GitHub Copilot or another generative AI tool

Copilot AI left a comment

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Pull request overview

This PR improves the documentation around the @CreateConnection service behavior (notably for Studio integration) by clarifying how the value/@Option naming impacts UI features like @ActiveIf.

Changes:

  • Added a note to the “creating dataset/datastore” documentation describing the naming constraint between @Option and the runtime class constructor parameter.
  • Extended the @CreateConnection annotation @Documentation text to include the same constraint for consumers of the API.

Reviewed changes

Copilot reviewed 2 out of 2 changed files in this pull request and generated 2 comments.

File Description
documentation/src/main/antora/modules/ROOT/pages/creating-dataset-datastore.adoc Adds an explanatory note about @CreateConnection / @Option naming requirements.
component-api/src/main/java/org/talend/sdk/component/api/service/connection/CreateConnection.java Adds additional descriptive text to the annotation documentation for Studio UI behavior (@ActiveIf).

💡 Add Copilot custom instructions for smarter, more guided reviews. Learn how to get started.

Comment thread documentation/src/main/antora/modules/ROOT/pages/creating-dataset-datastore.adoc Outdated
dmytro-sylaiev and others added 2 commits July 9, 2026 15:12
Co-authored-by: Copilot Autofix powered by AI <175728472+Copilot@users.noreply.github.com>
@Retention(RUNTIME)
@Documentation("Mark an action works for creating runtime connection, returning a runtime connection object like jdbc connection if database family. "
+ "Its parameter MUST be a datastore. Datastore is configuration type annotated with @DataStore. "
+ "The `value` parameter must match the runtime class constructor parameter name of the component configuration class to correctly apply `@ActiveIf` in the Studio UI. "

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I'm afraid that in this this context there could be a confusion between:

  1. value parameter of the @CreateConnection annotation
  2. value parameter of the @Option annotation of the method annotated @CreateConnection

Is something like this clearer?

Mark a method as returning a runtime connection object like jdbc connection if database family. 
The method's parameter MUST be a datastore annotated `@Option`.
The `value` parameter of `@Option` must match the runtime class constructor parameter name of the component configuration class to correctly apply `@ActiveIf` in the Studio UI. 

thboileau
thboileau previously approved these changes Jul 9, 2026
@sonar-rnd

sonar-rnd Bot commented Jul 9, 2026

Copy link
Copy Markdown

@dmytro-sylaiev dmytro-sylaiev merged commit 252afe2 into master Jul 9, 2026
8 checks passed
@dmytro-sylaiev dmytro-sylaiev deleted the dsylaiev/QTDI-3156_improve_doc_createconnection branch July 9, 2026 13:27
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

3 participants