apache / shardingsphere

Distributed SQL transaction & query engine for data sharding, scaling, encryption, and more - on any database.
Apache License 2.0
19.88k stars 6.73k forks source link

The bug of loading Single table in Oracle with shardingsphere 5.4.0 #29026

Open fanzhiyi0601 opened 11 months ago

fanzhiyi0601 commented 11 months ago

Bug Report

For English only, other languages will not accept.

Before report a bug, make sure you have:

Please pay attention on issues you submitted, because we maybe need more details. If no response anymore and we cannot reproduce it on current information, we will close it.

Please answer these questions before submitting your issue. Thanks!

Which version of ShardingSphere did you use?

5.4.0

Which project did you use? ShardingSphere-JDBC or ShardingSphere-Proxy?

ShardingSphere-JDBC

Expected behavior

The single tables set in sharding.yml can be loaded succussfully which are used in datasource as expect.

Actual behavior

throw null exception, the project doesn't load the single tables in initialization.

Reason analyze (If you can)

strongduanmu commented 11 months ago

@fanzhiyi0601 Thank you for your feedback. I will investigate this issue.

strongduanmu commented 11 months ago

Can you format your yaml config with markdown? It's hard to read now.

fanzhiyi0601 commented 11 months ago

Can you format your yaml config with markdown? It's hard to read now.

dataSources:
  ds0:
    dataSourceClassName: com.alibaba.druid.pool.DruidDataSource
    url: jdbc:oracle:thin:
    username: 
    password: 
    driverClassName: oracle.jdbc.OracleDriver
    platform: oracle
rules:
  - !SHARDING
    tables:
      CC_ASSET:
        actualDataNodes: ds0.CC_ASSET_$->{2020..2023}
        tableStrategy:
          standard:
            shardingColumn: section
            shardingAlgorithmName: table-algorithm

    shardingAlgorithms:
      table-algorithm:
        type: CLASS_BASED
        props:
          strategy: STANDARD
          algorithmClassName: ShardingStandardAlgorithm

  - !BROADCAST
    tables:
      - CC_CONTENT
  - !SINGLE
    tables:
      - TEST
props:
  sql-show: true
github-actions[bot] commented 10 months ago

There hasn't been any activity on this issue recently, and in order to prioritize active issues, it will be marked as stale.