public static IcebergDecimalObjectInspector get(int precision, int scale) {
    Preconditions.checkArgument(scale <= precision);
    Preconditions.checkArgument(precision <= HiveDecimal.MAX_PRECISION);
    Preconditions.checkArgument(scale <= HiveDecimal.MAX_SCALE);

    Integer key = precision << 8 | scale;
    return CACHE.get(key, k -> new IcebergDecimalObjectInspector(precision, scale));
  }
@Test
  public void testCache() {
    HiveDecimalObjectInspector oi = IcebergDecimalObjectInspector.get(38, 18);

    Assert.assertSame(oi, IcebergDecimalObjectInspector.get(38, 18));
    Assert.assertNotSame(oi, IcebergDecimalObjectInspector.get(28, 18));
    Assert.assertNotSame(oi, IcebergDecimalObjectInspector.get(38, 28));
  }