You are viewing a plain text version of this content. The canonical link for it is here.
Posted to notifications@james.apache.org by "vttranlina (via GitHub)" <gi...@apache.org> on 2024/02/29 08:22:14 UTC
[PR] JAMES-2586 - Postgres push subscription - expires value should be stored Offset time [james-project]
vttranlina opened a new pull request, #2070:
URL: https://github.com/apache/james-project/pull/2070
(no comment)
--
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.
To unsubscribe, e-mail: notifications-unsubscribe@james.apache.org
For queries about this service, please contact Infrastructure at:
users@infra.apache.org
---------------------------------------------------------------------
To unsubscribe, e-mail: notifications-unsubscribe@james.apache.org
For additional commands, e-mail: notifications-help@james.apache.org
Re: [PR] JAMES-2586 - Postgres push subscription - expires value should be stored Offset time [james-project]
Posted by "vttranlina (via GitHub)" <gi...@apache.org>.
vttranlina commented on code in PR #2070:
URL: https://github.com/apache/james-project/pull/2070#discussion_r1507222818
##########
server/data/data-jmap-postgres/src/main/java/org/apache/james/jmap/postgres/pushsubscription/PostgresPushSubscriptionDAO.java:
##########
@@ -65,7 +64,7 @@ public Mono<Void> save(Username username, PushSubscription pushSubscription) {
.set(PushSubscriptionTable.USER, username.asString())
.set(PushSubscriptionTable.DEVICE_CLIENT_ID, pushSubscription.deviceClientId())
.set(PushSubscriptionTable.ID, pushSubscription.id().value())
- .set(PushSubscriptionTable.EXPIRES, pushSubscription.expires().value().toLocalDateTime())
Review Comment:
tldr: we can also quick fix this issue for push_subscriotion by quick convert `.withZoneSameInstant(ZoneId.of("UTC"))`
But I am interested in how Postgres works with `timestamp with time zone`. So tried it for push_subscription
(cost for timestamp and timestamp with timezone is same, 8bit)
--
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.
To unsubscribe, e-mail: notifications-unsubscribe@james.apache.org
For queries about this service, please contact Infrastructure at:
users@infra.apache.org
---------------------------------------------------------------------
To unsubscribe, e-mail: notifications-unsubscribe@james.apache.org
For additional commands, e-mail: notifications-help@james.apache.org
Re: [PR] JAMES-2586 - Postgres push subscription - expires value should be stored Offset time [james-project]
Posted by "Arsnael (via GitHub)" <gi...@apache.org>.
Arsnael merged PR #2070:
URL: https://github.com/apache/james-project/pull/2070
--
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.
To unsubscribe, e-mail: notifications-unsubscribe@james.apache.org
For queries about this service, please contact Infrastructure at:
users@infra.apache.org
---------------------------------------------------------------------
To unsubscribe, e-mail: notifications-unsubscribe@james.apache.org
For additional commands, e-mail: notifications-help@james.apache.org
Re: [PR] JAMES-2586 - Postgres push subscription - expires value should be stored Offset time [james-project]
Posted by "vttranlina (via GitHub)" <gi...@apache.org>.
vttranlina commented on code in PR #2070:
URL: https://github.com/apache/james-project/pull/2070#discussion_r1507218389
##########
server/data/data-jmap-postgres/src/main/java/org/apache/james/jmap/postgres/pushsubscription/PostgresPushSubscriptionDAO.java:
##########
@@ -65,7 +64,7 @@ public Mono<Void> save(Username username, PushSubscription pushSubscription) {
.set(PushSubscriptionTable.USER, username.asString())
.set(PushSubscriptionTable.DEVICE_CLIENT_ID, pushSubscription.deviceClientId())
.set(PushSubscriptionTable.ID, pushSubscription.id().value())
- .set(PushSubscriptionTable.EXPIRES, pushSubscription.expires().value().toLocalDateTime())
Review Comment:
yes, I checked, another uses LocalDateTime, but before saving to the database, they already converted by `.withZoneSameInstant(ZoneId.of("UTC"))`
--
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.
To unsubscribe, e-mail: notifications-unsubscribe@james.apache.org
For queries about this service, please contact Infrastructure at:
users@infra.apache.org
---------------------------------------------------------------------
To unsubscribe, e-mail: notifications-unsubscribe@james.apache.org
For additional commands, e-mail: notifications-help@james.apache.org
Re: [PR] JAMES-2586 - Postgres push subscription - expires value should be stored Offset time [james-project]
Posted by "quantranhong1999 (via GitHub)" <gi...@apache.org>.
quantranhong1999 commented on code in PR #2070:
URL: https://github.com/apache/james-project/pull/2070#discussion_r1507210299
##########
server/data/data-jmap-postgres/src/main/java/org/apache/james/jmap/postgres/pushsubscription/PostgresPushSubscriptionDAO.java:
##########
@@ -65,7 +64,7 @@ public Mono<Void> save(Username username, PushSubscription pushSubscription) {
.set(PushSubscriptionTable.USER, username.asString())
.set(PushSubscriptionTable.DEVICE_CLIENT_ID, pushSubscription.deviceClientId())
.set(PushSubscriptionTable.ID, pushSubscription.id().value())
- .set(PushSubscriptionTable.EXPIRES, pushSubscription.expires().value().toLocalDateTime())
Review Comment:
At the time I checked this, it seems not only Postgres push subscription but the issue is at other places too (maybe 1 or 2 more places if I do not remember wrong).
Can you check again if any?
--
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.
To unsubscribe, e-mail: notifications-unsubscribe@james.apache.org
For queries about this service, please contact Infrastructure at:
users@infra.apache.org
---------------------------------------------------------------------
To unsubscribe, e-mail: notifications-unsubscribe@james.apache.org
For additional commands, e-mail: notifications-help@james.apache.org