15 Messages
Unity Catalog to Collibra integration - 'commandController' Internal Server Error
Hi,
I’ve successfully run the integration in Q4 2022 with version 1.0.7 by building project with maven, setting Collibra and Databricks accounts, tokens and permissions and running the springboot integration.
I’ve noticed that there was a new 2.0.9 available, so I wanted to test it out to learn about new features. I’ve deployed the .cma and followed the instructions in documentation.
The project builds successfully and the integration starts until it encounters below error message.
Funny thing, the same happens when I try to run the 1.0.7 (that worked perfectly couple of weeks ago!)
[2023-01-11 11:25:18.453][WARN ][main][org.springframework.boot.web.servlet.context.AnnotationConfigServletWebServerApplicationContext] Exception encountered during context initialization - cancelling refresh attempt: org.springframework.beans.factory.BeanCreationException: Error creating bean with name ‘commandController’ defined in file [C:\Users\lbanasze\Downloads\sbi-template-unitycatalog-2.0.9\target\classes\com\collibra\databricks\uc\template\controller\CommandController.class]: Bean instantiation via constructor failed; nested exception is org.springframework.beans.BeanInstantiationException: Failed to instantiate [com.collibra.databricks.uc.template.controller.CommandController]: Constructor threw exception; nested exception is collibra.core.client.ApiException: Internal Server Error
I would appreciate any help to debug this.
Best regards
Community_Alex
683 Messages
•
15.3K Points
2 years ago
@spring-team.collibra.com Might you be able to help @łukasz.banaszewski with this?
0
0
springboot_team
368 Messages
2 years ago
Hi @łukasz.banaszewski,
We are reviewing this and will keep you updated. Thanks
1
0
lukaszbanaszewski
15 Messages
2 years ago
Hi @spring-team.collibra.com,
Have you reviewed above issue? Any feedback?
Thanks
0
0
lukaszbanaszewski
15 Messages
2 years ago
@spring-team.collibra.com
Before posting this thread I’ve already checked it without encryption - same error.
0
0
lukaszbanaszewski
15 Messages
2 years ago
@spring-team.collibra.com
I’ve investigated further. Strangely the issue occurs when the springboot projects wants to authenticate to Collibra DGC. I’ve checked the connectivity via the same username / password via CURL or HTTP outside of the Springboot project and it works correctly.
In the application.properties I’ve also changed the URL to another Collibra DGC instance and this time the integration started properly.
Can it be some security setting in Java or on the DGC Cloud side?
Please advise
0
0
springboot_team
368 Messages
2 years ago
Hi @łukasz.banaszewski,
Thanks for the update.
To determine what the issue might be, can you please provide the following information:
Thanks
0
0
lukaszbanaszewski
15 Messages
2 years ago
Hi @spring-team.collibra.com
logs2.txt (168.1 KB)
0
0
springboot_team
368 Messages
2 years ago
Hi @łukasz.banaszewski,
Thanks for the information provided.
When switching from one instance to another, can you please advise which properties were updated (i.e. the property name, not the value) and any other changes that were made?
Additionally, to help us debug this further, can you please from the Unity Catalog integration source code:
CommandController
classThanks
CommandControllerSnippet.txt (3.1 KB)
0
0
lukaszbanaszewski
15 Messages
2 years ago
Hi @spring-team.collibra.com,
I have put the logger.debug lines to CommandController.class and here is the output:
[2023-01-19 10:01:53.166][DEBUG][main][org.springframework.beans.factory.support.DefaultListableBeanFactory] Creating shared instance of singleton bean ‘commandController’
[2023-01-19 10:01:53.176][DEBUG][main][org.springframework.core.env.PropertySourcesPropertyResolver] Found key ‘collibra.url’ in PropertySource ‘environmentProperties’ with value of type String
[2023-01-19 10:01:53.176][DEBUG][main][org.springframework.core.env.PropertySourcesPropertyResolver] Found key ‘collibra.username’ in PropertySource ‘environmentProperties’ with value of type String
[2023-01-19 10:01:53.177][DEBUG][main][org.springframework.core.env.PropertySourcesPropertyResolver] Found key ‘collibra.password’ in PropertySource ‘environmentProperties’ with value of type String
[2023-01-19 10:01:53.177][DEBUG][main][com.collibra.databricks.uc.template.controller.CommandController] Initializing the command controller
[2023-01-19 10:01:53.177][DEBUG][main][com.collibra.databricks.uc.template.controller.CommandController] Setting the Core API client
[2023-01-19 10:01:53.259][DEBUG][main][com.collibra.databricks.uc.template.controller.CommandController] Asset types request
[2023-01-19 10:01:53.812][WARN ][main][org.springframework.boot.web.servlet.context.AnnotationConfigServletWebServerApplicationContext] Exception encountered during context initialization - cancelling refresh attempt: org.springframework.beans.factory.BeanCreationException: Error creating bean with name ‘commandController’ defined in file [C:\Users\lbanasze\Downloads\sbi-template-unitycatalog-2.0.9\target\classes\com\collibra\databricks\uc\template\controller\CommandController.class]: Bean instantiation via constructor failed; nested exception is org.springframework.beans.BeanInstantiationException: Failed to instantiate [com.collibra.databricks.uc.template.controller.CommandController]: Constructor threw exception; nested exception is collibra.core.client.ApiException: Internal Server Error
[2023-01-19 10:01:53.812][INFO ][main][org.springframework.orm.jpa.LocalContainerEntityManagerFactoryBean] Closing JPA EntityManagerFactory for persistence unit ‘default’
Best regards
0
0
springboot_team
368 Messages
2 years ago
Hi @łukasz.banaszewski ,
After investigating the logs, we notice that the integration fails when sending the first request to your Collibra instance. This request is the GET findAssetsRequest call. Please use tools such as Postman or CUrl to send the request locally from the same machine running the integration.
curl -X ‘GET’
https://>YOUR COLLIBRA INSTANCE</rest/2.0/assetTypes?offset=0&limit=0&countLimit=-1&nameMatchMode=ANYWHERE&excludeMeta=true&topLevel=false’
-H ‘accept: application/json’ -u “>USERNAME<:>PASSWORD<”
and replace:
>YOUR COLLIBRA INSTANCE<
>USERNAME< and
>PASSWORD<
Then investigate the response and update us with any errors or status codes. If the result is successful, please don’t reply with the response, as it might contain confidential information. If you get an error try adding –insecure before your Collibra URL in the CUrl request.
Thanks
0
0
lukaszbanaszewski
15 Messages
2 years ago
Hi @spring-team.collibra.com
As mentioned in my previous posts the CURL, HTTP, POSTMAN works correctly.
I’ve also used your CURL code with my collibra instance and username/password credentials and it also works.
The connectivity only does not work when I am using Intellij or run the Java Project from command line (without any IDE).
Best regards
0
0
springboot_team
368 Messages
2 years ago
Hi @łukasz.banaszewski ,
Since you did not get any errors when sending these requests, the issue is not a connection problem. Therefore, please open the Collibra Instance’s logs, watch for any errors when triggering the integration, and update this post accordingly.
To view these logs, go to your Collibra instance’s console, usually in the format of console->YOUR COLLIBRA INSTANCE< .com. Once again, please hide any sensitive information from your replies.
Thanks
0
0
lukaszbanaszewski
15 Messages
2 years ago
Hi @spring-team.collibra.com
Here is the console error:
0
0
springboot_team
368 Messages
2 years ago
Hi @łukasz.banaszewski ,
Yes , the collibra.url property doesn’t have a trailing ‘/’ and should be in this format: https://>YOUR INSTANCE<.collibra.com/rest/2.0.
You can you try sending a request to the Collibra API as follows;
Thanks
0
0