GCP PUB/SUB Dependency Issue | Community
Skip to main content
December 17, 2022

GCP PUB/SUB Dependency Issue

  • December 17, 2022
  • 1 reply
  • 1177 views

Hi,

 

We are trying to integrate Google Cloud Pub/Sub feature (https://cloud.google.com/pubsub/docs/publisher#java) in AEM 6.5.11.

We added dependency in Parent and Core respectively as below:

 

<!-- https://mvnrepository.com/artifact/com.google.cloud/google-cloud-pubsub -->
<dependency>
<groupId>com.google.cloud</groupId>
<artifactId>google-cloud-pubsub</artifactId>
<version>1.122.2</version>
</dependency>

 

<!-- https://mvnrepository.com/artifact/com.google.cloud/google-cloud-pubsub -->
<dependency>
<groupId>com.google.cloud</groupId>
<artifactId>google-cloud-pubsub</artifactId>
</dependency> 

 

After adding dependency, Build is succesful but bundle is not active.

It gives many errors in inported sections:

 

NOTE: In Core POM.xml, Added entry as below in Export-package section:

 

Related import in JAVA:

 

 

Thanks in advance.

 

Regards,

KTNR

 

 

 

 

1 reply

Avinash_Gupta_
Community Advisor and Adobe Champion
Community Advisor and Adobe Champion
December 18, 2022

Hi @arvind-1,

 

You can go to system console and manually install the Google cloud jars to resolve the dependency issue.

arvind-1Author
December 19, 2022

@avinash_gupta_  Thanks for your kind reply.

 However, I already tried some stuff following below 2 articles and bundles are active now.

https://aemsimplifiedbynikhil.wordpress.com/2020/08/23/resolve-dependencies-by-converting-jar-to-bundle-aem-6-5-5/

https://www.linkedin.com/pulse/how-add-third-party-bundle-you-aem-package-veena-vikraman/

But Now, it gives below error: java.lang.NoClassDefFoundError: com/google/pubsub/v1/TopicName 

 

do you have any idea how to resolve it?

 

@avinash_gupta_ @arunpatidar