I'd recommend checking the source code for Phoenix Query Server to see how it sets up Avatica. Also set up Avatica server logging to see your errors.
Strictly speaking, the Cloudera provided driver is not an Avatica driver, but a Phoenix driver, it is not tested with anything else. I also suggest checking the licensing before using it in production. Having said that, I would expect it to at least connect to a properly configured Avatica server, regardless of the backend database. best regards Istvan On Fri, Sep 13, 2024 at 10:16 PM Hugh Pearse <hughpea...@gmail.com> wrote: > Does anyone know what settings Avatica server requires to work with the > Apache Phoenix drivers? > > When I run Avatica server with the following: > > ```java > public static void main(String[] args) throws SQLException, > InterruptedException { > Server h2server = Server.createTcpServer("-tcp", "-tcpAllowOthers", > "-tcpPort", "9092").start(); > Server h2serverWeb = Server.createWebServer("-webAllowOthers", > "-webPort", "9091").start(); > Connection h2connection = > > DriverManager.getConnection("jdbc:h2:./test;MODE=PostgreSQL;DB_CLOSE_DELAY=-1;DB_CLOSE_ON_EXIT=FALSE;INIT=RUNSCRIPT > FROM 'src/test/resources/northwind.sql'", "sa", ""); > ConfigurableJdbcMeta meta = new ConfigurableJdbcMeta( > "jdbc:h2:tcp://localhost:9092/./test", "sa", ""); > LocalService service = new LocalService(meta); > HughProtobufHandler pHandler = new HughProtobufHandler(service); > HttpServer.Builder<Server> builder = new HttpServer.Builder<Server > >() > .withHandler(pHandler) > .withPort(9090); > HttpServer avaticaserver = builder.build(); > avaticaserver.start(); > avaticaserver.join(); > } > ``` > > And I try to connect with the ODBC Avatica Driver (Hortonworks Phoenix > DSN). > It gives 500 internal server error. > > Are there some default settings modified in avatica server running in > phoenix which would make normal avatica server incompatible with the > cloudera odbc driver for phoenix? > > Reference > 1. > https://www.cloudera.com/downloads/connectors/phoenix/odbc/1-0-8-1011.html > > From, > Hugh Pearse > -- *István Tóth* | Sr. Staff Software Engineer *Email*: st...@cloudera.com cloudera.com <https://www.cloudera.com> [image: Cloudera] <https://www.cloudera.com/> [image: Cloudera on Twitter] <https://twitter.com/cloudera> [image: Cloudera on Facebook] <https://www.facebook.com/cloudera> [image: Cloudera on LinkedIn] <https://www.linkedin.com/company/cloudera> ------------------------------ ------------------------------