/** * Prints out the HBase {@link Version} enum value for the current version of HBase on the classpath. */ public static void main(String[] args) { boolean verbose = args.length == 1 && "-v".equals(args[0]); Version version = HBaseVersion.get(); System.out.println(version.getMajorVersion()); if (verbose) { System.out.println("versionString=" + getVersionString()); } }
@Test public void testVersionFactory() { HBaseVersion.Version foundVersion = HBaseVersion.get(); assertEquals(getExpectedVersion(), foundVersion); }
/** * Prints out the HBase {@link Version} enum value for the current version of HBase on the classpath. */ public static void main(String[] args) { boolean verbose = args.length == 1 && "-v".equals(args[0]); Version version = HBaseVersion.get(); System.out.println(version.getMajorVersion()); if (verbose) { System.out.println("versionString=" + getVersionString()); } }
T instance = null; try { switch (HBaseVersion.get()) { case HBASE_94: throw new ProvisionException("HBase 0.94 is no longer supported. Please upgrade to HBase 0.96 or newer.");
T instance = null; try { switch (HBaseVersion.get()) { case HBASE_94: throw new ProvisionException("HBase 0.94 is no longer supported. Please upgrade to HBase 0.96 or newer.");