code: public static String rfcDateTime(final Date val) {
      synchronized (rfcDateTimeFormat) {
        try {
          rfcDateTimeFormat.setTimeZone(Timezones.getDefaultTz());
        } catch (TimezonesException tze) {
          throw new RuntimeException(tze);
        }
        return rfcDateTimeFormat.format(val);
      }
    }
docs: Turn Date into "yyyy-MM-ddTHH:mm:ss"
  
  @param val date
  @return String "yyyy-MM-ddTHH:mm:ss"