Fork me on GitHub
#fulcro
<
2024-02-13
>
Ryan Khetlyr17:02:18

I got Fulcro RAD working with a local postgres database but switching to a local informix database fell flat - probably just my being unfamiliar with java includes found the maven artifact as



    com.ibm.informix
    jdbc
    4.50.10.1
updated deps.edn by adding to :deps com.ibm.informix/jdbc {:mvn/version "4.50.10.1"} and it looks like that is downloaded ( saved a screenshot of "External Libraries" with com.ibm.informix/jdbc to replies here... ) I appreciate any help - here's the error:
I 2024-02-13T00:53:53.389Z    _rad.database-adapters.sql.connection:- 35 - Creating connection pool for :main
I 2024-02-13T00:53:53.390Z       com.zaxxer.hikari.HikariDataSource:- 80 - HikariPool-3 - Starting...
E 2024-02-13T00:53:53.390Z    _rad.database-adapters.sql.connection:- 22 - Unable to create Hikari Datasource:  java.lang.ClassNotFoundException: com.informix.jdbcx.IfxDataSource
E 2024-02-13T00:53:53.391Z     _rad.database-adapters.sql.migration:-184 - No pool for :main. Skipping migrations.
I 2024-02-13T00:53:53.407Z            com.example.components.server:- 13 - Starting webserver with config  {:port 3000}
Execution error (IllegalArgumentException) at next.jdbc.protocols/eval34980$fn$G (protocols.clj:34).
No implementation of method: :-execute-one of protocol: #'next.jdbc.protocols/Executable found for class: nil

Ryan Khetlyr18:02:36

This means it should be available, right?

tony.kay20:02:55

I would think

Ryan Khetlyr20:02:38

Thanks for taking a look - I'll try a different version, maybe

Ryan Khetlyr23:02:00

updated the import at the top of development.clj to include it:

(:import (com.informix.jdbcx IfxDataSource)
           (com.zaxxer.hikari HikariDataSource))
had to restart Idea but it is compiling now... well I'm getting a different error but at least it's not ClassNotFound :D

Ryan Khetlyr18:02:28

alright - I think this is working... right up to the point where I need to write the adapters...? updated defaults.edn to have

{:main {:flyway/migrate?          false
        :flyway/migrations        ["classpath:config/sql_migrations"]
        :hikaricp/config          {"dataSourceClassName" "com.informix.jdbcx.IfxDataSource"
                                   #_#_ "jdbcUrl" "jdbc:"
                                   "dataSource.user"     "informix"
                                   "dataSource.password" "in4mix"
                                   "dataSource.IfxIFXHOST" "localhost"
                                   "dataSource.serverName" "informix"
                                   "dataSource.portNumber" "9088"
                                   "dataSource.databaseName" "stores_demo"
                                   }
        :sql/vendor               :ifx
        :sql/auto-create-missing? false
        :sql/schema               :production}}
and now getting
I 2024-02-14T18:48:52.943Z     _rad.database-adapters.sql.resolvers:- 82 - Generating resolver for id key :invoice/id to resolve [:invoice/date :invoice/line-items :invoice/customer :invoice/total]
I 2024-02-14T18:48:52.943Z     _rad.database-adapters.sql.resolvers:- 82 - Generating resolver for id key :line-item/id to resolve [:line-item/item :line-item/quantity :line-item/quoted-price :line-item/subtotal]
I 2024-02-14T18:48:52.943Z     _rad.database-adapters.sql.resolvers:- 82 - Generating resolver for id key :file/id to resolve [:file/id :file/sha :file.sha/filename :file/uploaded-on]
I 2024-02-14T18:48:52.944Z    _rad.database-adapters.sql.connection:- 35 - Creating connection pool for :main
I 2024-02-14T18:48:52.944Z       com.zaxxer.hikari.HikariDataSource:- 80 - HikariPool-7 - Starting...
I 2024-02-14T18:48:54.183Z       com.zaxxer.hikari.HikariDataSource:- 82 - HikariPool-7 - Start completed.
I 2024-02-14T18:48:54.198Z            com.example.components.server:- 13 - Starting webserver with config  {:port 3000}
Execution error (SQLException) at com.informix.util.IfxErrMsg/buildExceptionWithMessage (IfxErrMsg.java:421).
ISAM error:  no record found.