Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

PostgreSqlFetchedJob npgsql DateTimeOffset change for timestamptz column #385

Open
wants to merge 1 commit into
base: master
Choose a base branch
from

Conversation

fahrigoktuna
Copy link

Regarding #384 PR - if it doest not sound good . With the help of this PR you may change DateTime type to DateTimeOffSet in PostgreSqlFetchedJob according to Npgsql Mapping Table => https://www.npgsql.org/doc/types/basic.html. So that, there will be no problem deleting jobs from jobqueue table.

@fahrigoktuna fahrigoktuna changed the title PostgreSqlFetchedJob npgsql DateTimeOffset change for postgres timest… PostgreSqlFetchedJob npgsql DateTimeOffset change for timestamptz column Dec 23, 2024
@azygis
Copy link
Collaborator

azygis commented Dec 23, 2024

There are no timestamptz columns since 1.9.10 which was released almost 2 years ago.

What are the problems that you speak of? Neither PR makes sense as they are right now - this one now has a different CLR type from what's expected by Npgsql (should be timestamp -> DateTime), the other PR removes a safeguard which ensures only the exact same job is deleted.

@fahrigoktuna
Copy link
Author

Latest code branch master, 1.20.10 package. Please look at Install v19.sql.
ss

I think you had done convertion timestamp to timestamptz columns with tag 1.9.10

@azygis
Copy link
Collaborator

azygis commented Dec 23, 2024

Sorry, you're right! This whole debacle with timestamp changes with Npgsql is a blur at this point. But still, the datetime should be what it is. What's the problem with current implementation? I only see what the potential fixes are, but not what the problem is. Do the dates mismatch? Or?

@fahrigoktuna
Copy link
Author

fahrigoktuna commented Dec 23, 2024

Problem is that after job executed and marked as Succeeded. I expect that it should be removed from jobqueue table(hard delete). However, they are still remaining in jobqueue table. I debug it and change DateTime to DateTimeOffSet delete operation works. Maybe you should try, i dont event figure out that no one is noticed
https://www.npgsql.org/doc/types/datetime.html

Note: Datetime Kind is Local which is +03:00 for me.

@fahrigoktuna
Copy link
Author

Have you had a chance to look at it?

@azygis
Copy link
Collaborator

azygis commented Dec 26, 2024

No, not during holiday season.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants