0

We are wondering what might be the best way to use micronaut-data to connect to BigQuery. BigQuery has a rather poor JDBC support and in addition it does not support transactions while micronaut-data enforces transactions.

Is there a way in the micronaut-data API to add an Annotation @BigQueryRepository and provide the annotation processor with information on how to generate the access to the database and how to generate queries?

Or would it be the correct way to just implement the CrudRepository interface and provide everything else on our own?

Or is micronaut-data just not the right tool to use here?

We are trying to get a feeling about if it would be a better way to extend micronaut-data or to implement it outside of micronaut-data.

Chris
  • 7,675
  • 8
  • 51
  • 101

2 Answers2

1

Is there a way in the micronaut-data API to add an Annotation @BigQueryRepository and provide the annotation processor with information on how to generate the access to the database and how to generate queries?

Quite likely, yes we could developer support like that.

Or would it be the correct way to just implement the CrudRepository interface and provide everything else on our own?

You could write all of on on your own of course. I don't think Micronaut Data would be provided a whole lot at that point.

Or is micronaut-data just not the right tool to use here?

In its current state I don't think micronaut-data adds much for this scenario but that doesn't mean that it won't in the future.

Jeff Scott Brown
  • 26,804
  • 2
  • 30
  • 47
1

You may take a look at our new Micronaut BigQuery library

https://agorapulse.github.io/micronaut-bigquery/

It allows you to run the basic SQL and it provides a mock implementation for testing.

musketyr
  • 808
  • 5
  • 16