googleapis / googleapis/java-bigtable-hbase
CloudBigtableConfiguration does not accept ValueProvider<String>
- Dominant language
- Java
- Stars
- 184
- Forks
- 184
- Avg merge
- 10h
- Merged PRs (30d)
- 6
Description
This is very similar to https://github.com/googleapis/java-bigtable-hbase/issues/2155 but for `CloudBigtableConfiguration` (instead of `CloudBigtableTableConfiguration`).
Use case:
I am trying to build a (classic) dataflow template and keep the project id as ValueProvider (so I can deploy the template on various GCP Projects)
The respective Builder call is package-private: https://github.com/googleapis/java-bigtable-hbase/blob/master/bigtable-dataflow-parent/bigtable-hbase-beam/src/main/java/com/google/cloud/bigtable/beam/CloudBigtableConfiguration.java#L76
as opposed to passing a String: https://github.com/googleapis/java-bigtable-hbase/blob/master/bigtable-dataflow-parent/bigtable-hbase-beam/src/main/java/com/google/cloud/bigtable/beam/CloudBigtableConfiguration.java#L66
I am not familiar with the codebase to add a change, I am afraid.
(I did label it as a bug, similar to the linked issue at the top, I hope this is correct)
#### Steps to reproduce
1. pass a ValueProvider to `withProjectId`: you get a package-private warning
2. alternatively, pass `valueProvider.get()`: you can't build the template due to `Exception in thread "main" java.lang.IllegalStateException: Value only available at runtime, but accessed from a non-runtime context: RuntimeValueProvider{propertyName=bigtableProject, default=null}`
Thanks
Contributor guide
Assessment
This issue has not been assessed yet.