You are viewing a plain text version of this content. The canonical link for it is here.
Posted to issues@geode.apache.org by "Owen Nichols (Jira)" <ji...@apache.org> on 2020/08/21 19:22:00 UTC

[jira] [Resolved] (GEODE-8396) NullPointerException occurs in create jdbc-mapping command

     [ https://issues.apache.org/jira/browse/GEODE-8396?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel ]

Owen Nichols resolved GEODE-8396.
---------------------------------
    Fix Version/s: 1.14.0
       Resolution: Fixed

> NullPointerException occurs in create jdbc-mapping command
> ----------------------------------------------------------
>
>                 Key: GEODE-8396
>                 URL: https://issues.apache.org/jira/browse/GEODE-8396
>             Project: Geode
>          Issue Type: Bug
>          Components: jdbc
>            Reporter: Masaki Yamakawa
>            Priority: Minor
>              Labels: pull-request-available
>             Fix For: 1.14.0
>
>
> NullPointerException occurs in create jdbc-mapping command when partitioned region is specified by refid of cache.xml (cluster.xml).
> The cluster.xml and gfsh command are as follows:
> cluster.xml
> {code:java}
> <region name="ExampleRegion">
>  <region-attributes refid="PARTITION" />
>  </region>{code}
> gfsh
> {code:java}
> gfsh start locator --name=ExampleLocator --enable-cluster-configuration=true
>  gfsh start server --name=ExampleServer --locators=ExampleLocator[10334] --use-cluster-configuration=true
>  create data-source --name=ExampleDataSource --url=jdbc:mysql://mariadb/geode_db --username=geode_user --if-not-exists=true
>  create jdbc-mapping --data-source=ExampleDataSource --region=ExampleRegion --catalog=geode_db --table=ExampleRegion --pdx-name=com.example.Example --synchronous=false{code}
> The cause is that `org.apache.geode.connectors.jdbc.internal.cli.CreateMappingCommand#createAsyncQueue` refers to the DataPolicy, but when using cluster.xml is not set.
>  * In case of create region command, both refid and data-policy are set.



--
This message was sent by Atlassian Jira
(v8.3.4#803005)