/**
  * Prepare JSON document to be stored inside {@link #storeDatetimeValue(String, String, Date,
  * BulkRequestBuilder)}.
  *
  * @param spaceKey key of Space value is for
  * @param propertyName name of property
  * @param datetime value to store
  * @return JSON document
  * @throws IOException
  * @see #storeDatetimeValue(String, String, Date, BulkRequestBuilder)
  * @see #readDatetimeValue(String, String)
  */
 protected XContentBuilder storeDatetimeValueBuildDocument(
     String spaceKey, String propertyName, Date datetime) throws IOException {
   XContentBuilder builder = jsonBuilder().startObject();
   if (spaceKey != null) builder.field("spaceKey", spaceKey);
   builder
       .field("propertyName", propertyName)
       .field(STORE_FIELD_VALUE, DateTimeUtils.formatISODateTime(datetime));
   builder.endObject();
   return builder;
 }