spring-attic/spring-cloud-gcp

Could not autowire. No beans of 'PubSubPersonGateway' type found issue in Pub Sub Sample project

philbannon opened this issue · 4 comments

ATTENTION

Please file all new issues in our new repo: https://github.com/GoogleCloudPlatform/spring-cloud-gcp/issues/new/choose.
Issued filed in this repo should only be bug reports for Spring Cloud GCP 1.x (corresponding to Spring Cloud Hoxton and below).


Describe the bug
Hi, I think this may be an issue. I'm new-ish to spring and sorry if this isn't an actual issue. Basically looking at the pub sub sample for Spring integration I notice I get this error / warning in https://github.com/spring-cloud/spring-cloud-gcp/blob/6c95a16f7e6ad95404b4f992b5f46340e831e5cb/spring-cloud-gcp-samples/spring-cloud-gcp-integration-pubsub-json-sample/src/main/java/com/example/WebController.java#L47

Could not autowire. No beans of 'PubSubPersonGateway' type found. 

Sample
Open / build the Sample project located here https://github.com/spring-cloud/spring-cloud-gcp/blob/6c95a16f7e6ad95404b4f992b5f46340e831e5cb/spring-cloud-gcp-samples/spring-cloud-gcp-integration-pubsub-json-sample/

Navigate to the WebController.java class and notice the error / warning:
Could not autowire. No beans of 'PubSubPersonGateway' type found.

@philbannon How are you running the sample? Did you make any modifications to it?
Also, I would recommend checking out the 2.x version of the project here: https://github.com/GoogleCloudPlatform/spring-cloud-gcp.
This old repository is no longer maintained as it corresponds to an unsupported version of Spring Cloud.

Hi @meltsufin thanks for the response and sorry for logging such a "trival" issue.

Yeah I made zero modifications, just clone and run. I'll checkout the 2.x version tonight and report back!

Many thanks

Generally, all of our samples are automatically tested by CI. So, it would be surprising to see this kind of error. Usually, it's an environmental issue. I would be curious if there were any other failures in the log output before this one.

@philbannon Please reopen if you are still having the issue.