title: Hibernate Null values for @CollectionOfElements
body: <p>I'm mapping a set of attributes to my entity using @CollectionOfElements. The goal here is to be able to provide a meta data list that can be used in a query to pull specific entries.</p>
  
  <p>I've figured out the mapping and how to run the queries I want. The problem is that hibernate won't persist null values! </p>
  
  <pre><code>
      @CollectionOfElements()
      @JoinTable(name = "plan_attribute", joinColumns = @JoinColumn(name = "plan_id"))
      @MapKey(columns = @Column(name = "attribute_name", nullable = false, length = 255))
      @Column(name = "attribute_value", nullable = true, length = 255)
      public Map getAttributes() {
          return attributes;
      }
  
      public void setAttributes(Map attributes) {
          this.attributes = attributes;
      }
  
      public void addAttribute(String name, String value) {
          this.attributes.put(name, value);
      }
  </code></pre>
  
  <p>Eg. object.addAttribute("someName", null); will not be persisted</p>
  
  <p>Anyone have any thoughts on how to accomplish this without implementing a key/value pair entity for the sole purpose of persisting these values?</p>
  
  <p>Regards,</p>