mirror of
https://github.com/google/nomulus.git
synced 2025-07-25 20:18:34 +02:00
Add IntervalDescriptor and change DurationConverter to use Interval datatype (#653)
* Add use of interval data type * Add support for Millis * Use Java-object type * Change column type for relock_duration * add years and months * Add tests for hours, minutes, and seconds * Add javadoc describing how joda duration is stored * Add test for lots of days
This commit is contained in:
parent
90d080d42f
commit
4ad7f9734d
14 changed files with 248 additions and 31 deletions
|
@ -0,0 +1,18 @@
|
|||
-- Copyright 2020 The Nomulus Authors. All Rights Reserved.
|
||||
--
|
||||
-- Licensed under the Apache License, Version 2.0 (the "License");
|
||||
-- you may not use this file except in compliance with the License.
|
||||
-- You may obtain a copy of the License at
|
||||
--
|
||||
-- http://www.apache.org/licenses/LICENSE-2.0
|
||||
--
|
||||
-- Unless required by applicable law or agreed to in writing, software
|
||||
-- distributed under the License is distributed on an "AS IS" BASIS,
|
||||
-- WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
|
||||
-- See the License for the specific language governing permissions and
|
||||
-- limitations under the License.
|
||||
|
||||
ALTER TABLE "RegistryLock" DROP COLUMN relock_duration;
|
||||
|
||||
ALTER TABLE "RegistryLock" ADD COLUMN relock_duration interval;
|
||||
|
|
@ -459,7 +459,7 @@ create sequence history_id_sequence start 1 increment 1;
|
|||
lock_request_timestamp timestamptz not null,
|
||||
registrar_id text not null,
|
||||
registrar_poc_id text,
|
||||
relock_duration int8,
|
||||
relock_duration interval,
|
||||
repo_id text not null,
|
||||
unlock_completion_timestamp timestamptz,
|
||||
unlock_request_timestamp timestamptz,
|
||||
|
|
|
@ -670,7 +670,7 @@ CREATE TABLE public."RegistryLock" (
|
|||
unlock_completion_timestamp timestamp with time zone,
|
||||
last_update_timestamp timestamp with time zone,
|
||||
relock_revision_id bigint,
|
||||
relock_duration bigint
|
||||
relock_duration interval
|
||||
);
|
||||
|
||||
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue