Project

Profile

Help

Refactor #1068

closed

Use mongoengine.fields.DateTimeField for all models

Added by amacdona@redhat.com about 7 years ago. Updated about 3 years ago.

Status:
CLOSED - WONTFIX
Priority:
Normal
Assignee:
-
Category:
-
Sprint/Milestone:
-
Start date:
Due date:
% Done:

0%

Estimated time:
Platform Release:
Groomed:
No
Sprint Candidate:
No
Tags:
Pulp 2
Sprint:
Quarter:

Description

We currently represent date times in many ways and it adds a significant amount of unnecessary complication to many areas in our code.

Internally, all date times should be a mongoengine DateTime and externally we should use a single string representation of this field. The only part of our code that should interact with these strings are the serializers, which should used to convert both ways.

1. All date times serverside can be assumed to be mongoengine DateTimes
2. All user facing date times are strings of the same format
3. All code that is responsible for switching between date time types can go away, including `pulp/common/dateutils.py` and `pulp/server/webservices/views/util.py: pulp_json_encoder`.
4. All conversion can be written in the base class for serializers, and we should never have to think about it again.

Actions #1

Updated by bmbouter about 3 years ago

  • Status changed from NEW to CLOSED - WONTFIX
Actions #2

Updated by bmbouter about 3 years ago

Pulp 2 is approaching maintenance mode, and this Pulp 2 ticket is not being actively worked on. As such, it is being closed as WONTFIX. Pulp 2 is still accepting contributions though, so if you want to contribute a fix for this ticket, please reopen or comment on it. If you don't have permissions to reopen this ticket, or you want to discuss an issue, please reach out via the developer mailing list.

Actions #3

Updated by bmbouter about 3 years ago

  • Tags Pulp 2 added

Also available in: Atom PDF