Uploaded image for project: 'Hadoop Common'
  1. Hadoop Common
  2. HADOOP-5596

Make ObjectWritable support EnumSet

    XMLWordPrintableJSON

Details

    • Improvement
    • Status: Closed
    • Major
    • Resolution: Fixed
    • None
    • 0.21.0
    • io
    • None
    • Reviewed

    Description

      This is a demand for Hadoop-5438.
      Also another small improvement is that i saw that in the beginning of readObject, it tries to get the class from PRIMITIVE_NAMES and then conf. Maybe it is better to add a direct load after them if the delaredClass is still null. Like this:

      String className = UTF8.readString(in);
          Class<?> declaredClass = PRIMITIVE_NAMES.get(className);
          if (declaredClass == null) {
            try {
              declaredClass = conf.getClassByName(className);
            } catch (Exception e) {
            }
          }
          
          if(declaredClass == null) {
            try {
              declaredClass = Class.forName(className);
            } catch (ClassNotFoundException e) {
              throw new RuntimeException("readObject can't find class " + className, e);
            }
          }
      

      Attachments

        1. Hadoop-5596-2009-03-31.patch
          2 kB
          He Yongqiang
        2. Hadoop-5596-2009-04-03.patch
          2 kB
          He Yongqiang
        3. Hadoop-5596-2009-04-15.patch
          7 kB
          He Yongqiang
        4. Hadoop-5596-2009-04-15-2.patch
          7 kB
          He Yongqiang
        5. Hadoop-5596-2009-04-24.patch
          7 kB
          He Yongqiang
        6. Hadoop-5596-2009-04-30.patch
          22 kB
          He Yongqiang
        7. Hadoop-5596-2009-04-30-1.patch
          11 kB
          He Yongqiang
        8. Hadoop-5596-2009-04-30-3.patch
          12 kB
          He Yongqiang

        Issue Links

          Activity

            People

              he yongqiang He Yongqiang
              he yongqiang He Yongqiang
              Votes:
              0 Vote for this issue
              Watchers:
              3 Start watching this issue

              Dates

                Created:
                Updated:
                Resolved: