public static long parseLong(String num, long defaultLong) {
        if (num == null) {
            return defaultLong;
        } else {
            try {
                return Long.parseLong(num);
            } catch (Exception e) {
                return defaultLong;
            }
        }
    }
@Test
    public void testParseLong() {
        Assert.assertEquals(CommonUtils.parseLong("", 123L), 123L);
        Assert.assertEquals(CommonUtils.parseLong("xxx", 123L), 123L);
        Assert.assertEquals(CommonUtils.parseLong(null, 123L), 123L);
        Assert.assertEquals(CommonUtils.parseLong("12345", 123L), 12345L);
    }