Skip to content
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

Oauth2 feature added #67

Open
wants to merge 50 commits into
base: main
Choose a base branch
from
Open
Show file tree
Hide file tree
Changes from all commits
Commits
Show all changes
50 commits
Select commit Hold shift + click to select a range
b5130a1
Fix source path for jenkins file (#59)
gaiksaya Jul 5, 2023
ab6870e
Override default release docker image (#60)
gaiksaya Jul 5, 2023
cc17bee
Update jenkins file to use updated docker image (#61)
gaiksaya Jul 14, 2023
6e31762
Create Trifork.readme.md
fepatrifork Apr 15, 2024
c7660bf
Beta version using password field as JWT entry point, tested
fepatrifork Apr 15, 2024
1aede8b
Beta version using password field as JWT entry point, tested
fepatrifork Apr 15, 2024
2e4990c
Beta version using only JWT as entry point, readme inserted, tested
fepatrifork Apr 16, 2024
3caa072
Update README.md
fepatrifork Apr 15, 2024
3c28afe
Update README.md
fepatrifork Apr 15, 2024
aba5c24
Update README.md
fepatrifork Apr 15, 2024
6ca05ab
Added dockerfile in Windows version for automate building
fepatrifork Apr 19, 2024
4e9c397
Added dockerfile in Windows version for automate building
fepatrifork Apr 19, 2024
70bcce7
Dockerfile completed and tested
fepatrifork Apr 22, 2024
b0164af
Dockerfile completed and tested
fepatrifork Apr 22, 2024
eb85029
Dockerfile completed and tested
fepatrifork Apr 22, 2024
7e85113
Dockerfile completed and tested
fepatrifork Apr 22, 2024
cf1b231
Update Trifork.readme.md
fepatrifork Apr 22, 2024
d5942bb
Dockerfile completed and tested
fepatrifork Apr 22, 2024
2114b23
Dockerfile completed and tested
fepatrifork Apr 23, 2024
5d095c3
Dockerfile completed and tested
fepatrifork Apr 23, 2024
03db3f3
Dockerfile completed and tested
fepatrifork Apr 23, 2024
cfa8fc1
Dockerfile completed and tested
fepatrifork Apr 23, 2024
aa1c0e0
Dockerfile completed and tested
fepatrifork Apr 23, 2024
bc0d8a4
Dockerfile completed and tested
fepatrifork Apr 23, 2024
08b8cb7
Dockerfile completed and tested
fepatrifork Apr 23, 2024
651a7cc
Personalized connector added
fepatrifork Apr 26, 2024
9886b55
Connector modified, tested, CICD docker adapted
fepatrifork May 8, 2024
ca34449
Prepare the branch for merge the fork
fepatrifork May 8, 2024
aa7ab73
Prepare the branch for merge the fork
fepatrifork May 8, 2024
53aeaba
Prepare the branch for merge the fork
fepatrifork May 8, 2024
1eeb667
Remove internal file
fepatrifork May 8, 2024
1ce0168
Prepare the branch for merge the fork
fepatrifork May 8, 2024
0cff5c3
PowerBi connector now use config file for set up Oauth flow
fepatrifork May 10, 2024
3772e9f
PowerBi connector now use Json config file for set up Oauth flow
fepatrifork May 10, 2024
661f2e3
Manual updated
fepatrifork May 10, 2024
09a3bd4
Update OpenSearchProject.md
fepatrifork May 13, 2024
073fc2b
Update .gitignore
fepatrifork May 15, 2024
aa81eac
Update .pq
fepatrifork May 15, 2024
1055ffb
Signed-off-by: Fernando Pannullo <[email protected]>
fepatrifork May 21, 2024
5e8da02
Signed-off-by: fepatrifork <[email protected]>
fepatrifork May 22, 2024
22e8de6
Signed-off-by: fepatrifork <[email protected]>
fepatrifork May 22, 2024
256ef8c
Signed-off-by: fepatrifork <[email protected]>
fepatrifork May 22, 2024
30c5012
Signed-off-by: fepatrifork <[email protected]>
fepatrifork May 23, 2024
5b6af8d
Signed-off-by: fepatrifork <[email protected]>
fepatrifork May 27, 2024
70191a4
Signed-off-by: fepatrifork <[email protected]>
fepatrifork May 28, 2024
5c8e63f
Signed-off-by: fepatrifork <[email protected]>
fepatrifork May 28, 2024
086e96d
Signed-off-by: fepatrifork <[email protected]>
fepatrifork May 28, 2024
60ff019
Signed-off-by: fepatrifork <[email protected]>
fepatrifork May 28, 2024
0e09745
Signed-off-by: fepatrifork <[email protected]>
fepatrifork May 29, 2024
588a00c
Signed-off-by: fepatrifork <[email protected]>
fepatrifork May 30, 2024
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
4 changes: 4 additions & 0 deletions .gitignore
Original file line number Diff line number Diff line change
Expand Up @@ -41,6 +41,7 @@ LICENSE.txt
/IntegrationTests/
/opensearchenlist/
/sqlodbc/
/output/
/PerformanceTests/
/UnitTests/
*.filters
Expand All @@ -60,3 +61,6 @@ CTestTestfile.cmake
/src/PowerBIConnector/obj/
/src/PowerBIConnector/.vs/
src/vcpkg_installed/
/extensionBiConnector/
/comparisonBiConnector/
/extensionTableauConnector/
21 changes: 21 additions & 0 deletions CppProperties.json
Original file line number Diff line number Diff line change
@@ -0,0 +1,21 @@
{
"configurations": [
{
"inheritEnvironments": [
"msvc_x64"
],
"name": "x64-Release",
"includePath": [
"${env.INCLUDE}",
"${workspaceRoot}\\**"
],
"defines": [
"WIN32",
"NDEBUG",
"UNICODE",
"_UNICODE"
],
"intelliSenseMode": "windows-msvc-x64"
}
]
}
2 changes: 1 addition & 1 deletion README.md
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
# OpenSearch ODBC Driver

OpenSearchODBC is a read-only ODBC driver for Windows and Mac for connecting to OpenSearch SQL support.
OpenSearchODBC is a read-only ODBC driver for Windows and Mac for connecting to OpenSearch SQL support. This driver version allows to levereage on Oauth2 authentication/authorization.

### ODBC Driver

Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -52,7 +52,7 @@

## Troubleshooting

* If you get the following error, please install the [OpenSearch SQL ODBC Driver](https://docs-beta.opensearch.org/search-plugins/sql/odbc/).
* If you get the following error, please install the [OpenSearch SQL ODBC Driver](https://opensearch.org/docs/latest/search-plugins/sql/sql/odbc/).

<img src="img/pbi_error_driver_not_installed.png" width="350">

Expand Down
33 changes: 25 additions & 8 deletions bi-connectors/PowerBIConnector/OpenSearchProject.md
Original file line number Diff line number Diff line change
Expand Up @@ -23,36 +23,53 @@
## Connect to OpenSearch Project
1. Open Power BI Desktop.

2. Click on **Home** > **Get Data** > **More** > **Other**. Select **OpenSearch Project**. Click on **Connect**.
2. If necessary clear the previous permissions.

<img src="img/powerbi_cached.png" width="500">

3. Click on **Home** > **Get Data** > **More** > **Other**. Select **OpenSearch Project**. Click on **Connect**.

<img src="img/pbi_select_connector.png" width="500">

3. You will get a warning for using a third-party service. Click on **Continue**.
4. You will get a warning for using a third-party service. Click on **Continue**.

<img src="img/pbi_third_party_warning.png" width="500">

4. Enter host and port values and select your preferred SSL and Certificate validation options. Click on **OK**.
5. Enter host and port values and select your preferred SSL and Certificate validation options. Click on **OK**.

<img src="img/pbi_connection_string_options.png" width="500">

5. Select authentication option. Enter credentials if required and click on **Connect**.
6. Select authentication option. Enter credentials if required and click on **Connect**.

<img src="img/pbi_auth.png" width="500">

6. Select required table. Data preview will be loaded.
7. Select required table. Data preview will be loaded.

<img src="img/pbi_data_preview.png">

7. Click on **Load**.
8. Click on **Load**.

8. Select required columns for creating a graph.
9. Select required columns for creating a graph.

<img src="img/pbi_simple_graph.png">

## Set up Oauth2

* In the same folder of the source files to build put a JSON file filling the three fields required in the template provided.

## Login with Oauth2

1. Select the `OAUTH2` authentication and click on **Sign In**

<img src="img/Oauth2_init.png" width="500">

2. After provided the user-id and the user-secret, click on **Connect**

<img src="img/Oauth2_signedIn.png" width="500">

## Troubleshooting

* If you get the following error, please install the [OpenSearch SQL ODBC Driver](https://docs-beta.opensearch.org/search-plugins/sql/odbc/).
* If you get the following error, please install the [OpenSearch SQL ODBC Driver](https://opensearch.org/docs/latest/search-plugins/sql/sql/odbc/).

<img src="img/pbi_error_driver_not_installed.png" width="350">

Expand Down
12 changes: 12 additions & 0 deletions bi-connectors/PowerBIConnector/README.md
Original file line number Diff line number Diff line change
Expand Up @@ -3,6 +3,18 @@
The Power BI connector is available to download from the automated CI workflow: [link](https://github.com/opensearch-project/sql-odbc/actions/workflows/bi-connectors.yml).
The release snapshots are also available here: [OpenSearch Project](OpenSearchProject.mez) and [Amazon OpenSearch Service](AmazonOpenSearchService.mez).

## Connector Development

The development of the connector is related to the PoweQuery SDK for [VisualStudio](https://marketplace.visualstudio.com/items?itemName=Dakahn.PowerQuerySDK) or for Visual Studio Code from the `Extensions` left tab.

Is possible to initialize a project for example in VSC with <img src="img/powerquery_SDK.png" width="200">

The main logic is in `.pq` file (not `.query.pq`) and is not possible to have multiple files of this extension. In connector development there are limitation to the functionalities that is possibile to use as the [data source functions](https://learn.microsoft.com/en-us/power-query/handling-data-access#data-source-functions). The reference and guides of [Power Query M](https://learn.microsoft.com/en-us/powerquery-m/) is available.

After created the program it is required to run compiling and packaging phases as <img src="img/build_task.png" width="600">.

The output `.mez` file will appear in `bin\AnyCPU\Debug` of the same folder.

## Connector Install

1. Put connector `mez` file into: `C:\Users\%USERNAME%\Documents\Power BI Desktop\Custom Connectors`.
Expand Down
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
6 changes: 3 additions & 3 deletions bi-connectors/PowerBIConnector/power_bi_support.md
Original file line number Diff line number Diff line change
Expand Up @@ -2,8 +2,8 @@

## Prerequisites
* Microsoft Power BI Desktop
* [OpenSearch](https://docs-beta.opensearch.org/opensearch/install/index/)
* [OpenSearch SQL ODBC driver](https://docs-beta.opensearch.org/search-plugins/sql/odbc/)
* [OpenSearch](https://opensearch.org/docs/latest/install-and-configure/install-opensearch/index/)
* [OpenSearch SQL ODBC driver](https://opensearch.org/docs/latest/search-plugins/sql/sql/odbc/)
* [OpenSearchProject.mez](OpenSearchProject.mez) or [AmazonOpenSearchService.mez](AmazonOpenSearchService.mez)
* Optional: [sqlodbc_import.pbids](PBIDSExamples/sqlodbc_import.pbids) to help with repeated connections to the same server

Expand Down Expand Up @@ -86,7 +86,7 @@ It will take you straight to the **Navigator** window for selecting the tables f

## Troubleshooting

* If you get an following error, please install [OpenSearch SQL ODBC Driver](https://docs-beta.opensearch.org/search-plugins/sql/odbc/).
* If you get an following error, please install [OpenSearch SQL ODBC Driver](https://opensearch.org/docs/latest/search-plugins/sql/sql/odbc/).

<img src="img/pbi_error_driver_not_installed.png" width="350">

Expand Down
5 changes: 5 additions & 0 deletions bi-connectors/PowerBIConnector/src/OauthConf.json
Original file line number Diff line number Diff line change
@@ -0,0 +1,5 @@
{
"ClientId": "<User ID>",
"ClientSecret": "<User secret>",
"IDPurl": "<Endpoint of the IdP>"
}
Loading
Loading