Tarantool development patches archive
 help / color / mirror / Atom feed
From: Timur Safin via Tarantool-patches <tarantool-patches@dev.tarantool.org>
To: v.shpilevoy@tarantool.org
Cc: tarantool-patches@dev.tarantool.org
Subject: [Tarantool-patches] [PATCH 0/n] Datetime module implementation, stage #1
Date: Fri, 10 Sep 2021 20:50:51 +0300	[thread overview]
Message-ID: <cover.1631291287.git.tsafin@tarantool.org> (raw)

After we have failed to get any consensus on prior version of 
datetime module, we have returned to the whiteboard and proceeded
"the procedure":

- PM creates initial design spec, we discuss, and only once 
  consensus achieved...;
- ... we implement it gradually, stage by stage.

Although, Mons' RFC for datetime module is not yet fully finished,
we have agreed that it's enough for stage #1 - 
https://hackmd.io/@Mons/S1Vfc_axK#%D0%AD%D1%82%D0%B0%D0%BF-1

The patch #1/n is an extraction of functionality needed for stage #1.

There is much fuller implementaton though, which you may find here
https://github.com/tarantool/tarantool/pull/6426
in addition to initial datetime support created by 1st patch, pull
request contain:

- Preliminary interval support via `date:add{}` and `date:sub{}` methods,
  more interval functionality to be added there soon;
- messagepack, json, and yaml serialization;
- box persistence and indices support;

Note, that these things ratified in RFC are neither yet presented in a
mentioned pull-request, nor in this patch:

- there is no yet %f support in format(). It will be done in the next 
  version of this patch;
- there is no Olson integration support necessary for timezone identifiers 
  parsing and tzindex support.

Original issue: 
- https://github.com/tarantool/tarantool/issues/5941
Full branch:
- https://github.com/tarantool/tarantool/tree/tsafin/gh-5941-datetime-take2-wip
Pull request for fuller branch:
- https://github.com/tarantool/tarantool/pull/6426


Timur Safin (1):
  build, lua: built-in module datetime

 .gitmodules                    |   3 +
 CMakeLists.txt                 |   8 +
 cmake/BuildCDT.cmake           |  10 +
 extra/exports                  |  37 ++
 src/CMakeLists.txt             |   5 +-
 src/lib/core/CMakeLists.txt    |   1 +
 src/lib/core/datetime.c        | 121 +++++++
 src/lib/core/datetime.h        |  94 +++++
 src/lua/datetime.lua           | 623 +++++++++++++++++++++++++++++++++
 src/lua/init.c                 |   4 +-
 src/lua/utils.c                |  19 +
 src/lua/utils.h                |  11 +
 test/app-tap/datetime.test.lua | 203 +++++++++++
 test/unit/CMakeLists.txt       |   2 +
 test/unit/datetime.c           | 261 ++++++++++++++
 test/unit/datetime.result      | 358 +++++++++++++++++++
 third_party/c-dt               |   1 +
 17 files changed, 1759 insertions(+), 2 deletions(-)
 create mode 100644 cmake/BuildCDT.cmake
 create mode 100644 src/lib/core/datetime.c
 create mode 100644 src/lib/core/datetime.h
 create mode 100644 src/lua/datetime.lua
 create mode 100755 test/app-tap/datetime.test.lua
 create mode 100644 test/unit/datetime.c
 create mode 100644 test/unit/datetime.result
 create mode 160000 third_party/c-dt

-- 
2.29.2


             reply	other threads:[~2021-09-10 17:51 UTC|newest]

Thread overview: 4+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2021-09-10 17:50 Timur Safin via Tarantool-patches [this message]
2021-09-10 17:50 ` [Tarantool-patches] [PATCH 1/n] build, lua: built-in module datetime Timur Safin via Tarantool-patches
2021-09-14 21:53   ` Safin Timur via Tarantool-patches
2021-09-14 22:45 ` [Tarantool-patches] [PATCH 0/n] Datetime module implementation, stage #1 Vladislav Shpilevoy via Tarantool-patches

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=cover.1631291287.git.tsafin@tarantool.org \
    --to=tarantool-patches@dev.tarantool.org \
    --cc=tsafin@tarantool.org \
    --cc=v.shpilevoy@tarantool.org \
    --subject='Re: [Tarantool-patches] [PATCH 0/n] Datetime module implementation, stage #1' \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox