Skip to content

RowMapper error with Postgres INET type converter #218

@termermc

Description

@termermc

Hello. I've just started evaluating this library, and I have noticed that there is an issue with the code generated for RowMappers.java when dealing with table that have column(s) of type inet.

I have the necessary PostgreSQL jOOQ extensions installed, and have set up the ForcedType for it:

ForcedType().apply {
    userType = "org.jooq.postgres.extensions.types.Inet"
    binding = "org.jooq.postgres.extensions.bindings.InetBinding"
    converter = "org.jooq.postgres.extensions.converters.InetConverter"
    includeTypes = "inet"
    priority = -2147483648
}

Here is the problematic part of RowMappers.java:

public static Function<Row,com.myproj.generated.tables.pojos.Login> getLoginMapper() {
    return row -> {
        com.myproj.generated.tables.pojos.Login pojo = new com.myproj.generated.tables.pojos.Login();
        pojo.setSeqid(row.getInteger("seqid"));
        pojo.setUuid(row.getUUID("uuid"));
        pojo.setUserSeqid(row.getInteger("user_seqid"));
        pojo.setIp(com.myproj.generated.tables.converters.Converters.ORG_JOOQ_POSTGRES_EXTENSIONS_CONVERTERS_INETCONVERTER_INSTANCE.rowConverter().fromRow(key->row.get(com.myproj.generated.tables.converters.Converters.ORG_JOOQ_POSTGRES_EXTENSIONS_CONVERTERS_INETCONVERTER_INSTANCE.rowConverter().fromType(),key),"ip"));
        pojo.setCreatedTs(row.getOffsetDateTime("created_ts"));
        return pojo;
    };
}

rowConverter() is not a method on ORG_JOOQ_POSTGRES_EXTENSIONS_CONVERTERS_INETCONVERTER_INSTANCE.

There are also other related errors on the Login table object with ip.

Is there something obvious that I am missing? If there is some work to be done to support this, I would be happy to contribute.

Thank you.

Metadata

Metadata

Assignees

No one assigned

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions