Hadoop Configuration Property Returns Null
===

I wrote a simple code to test how to set configuration in Hadoop.

    public static void main(String[] args) {
    		
    		Configuration conf = new Configuration();
    		conf.addResource("~/conf.xml");
    		System.out.println(conf);
    		System.out.println(conf.get("color"));
    }

The output of above program is:

    Configuration: core-default.xml, core-site.xml, ~/conf.xml
    null

Thus `conf.get("color")` return `null`. However, I have explicitly set that property in `conf.xml` as follows:

    <property>
            <name>color</name>
            <value>yellow</value>
            <description>Color</description>
    </property>

I don't understand what's wrong with this code.

Thanks.