Skip to content

Conversation

@vttranlina
Copy link
Contributor

No description provided.

chibenwa and others added 30 commits October 30, 2023 06:46
Prevents infinite email loop with forwards by tracking for which users the forwards where applied.

Tracks both regular forwards and JMAP filters forwards.

Co-authored-by: hung phan <hphan@linagora.com>
vttranlina and others added 25 commits December 11, 2023 14:07
…ing it to mpt imap test

- The PostgresMailboxSessionMapperFactoryTODO was created independent of PostgresMailboxSessionMapperFactory
for development.
We need to remove MapperFactory, and rename MapperFactoryTODO -> MapperFactory when all dependencies already.
…dSafetyTest

We do not control directly r2dbc-postgresql Connection but library owner, thus we can do nothing upon tests failure.
But we can handle library failure at James layer using PostgresExecutor wrapper.
PreparedStatement id is unique per PG connection.
We share a PG connection across multi threads leads to PreparedStatement id conflicts.
We can retry upon PreparedStatement id conflicts.
…ct exception

io.r2dbc.postgresql.ExceptionFactory$PostgresqlBadGrammarException: [42P05] prepared statement "S_0" already exists

Should not retry upon other fatal exception e.g. database failure, invalid authorization...
Runs 41 tests more onto the PostgresMailboxManager
We generate a unique UUID so this is supported.

Note that turns 5 tests on in the PostgresMailboxManager
test suite.
- Use single query to database for fetch total + total unseen
The query looks like:

select
  count(*) as "total_count",
  count(*) filter (where is_seen = $1) as "unseen_count"
from message_mailbox
where mailbox_id = cast($2 as uuid)
- It is a why make lack of test case when run the test (jpaGuiceServerShouldUpdateQuota)
…ase sql validation

- It was created for JPA, with Postgresql we don't need it. (instead of mark @disabled for it)
Fixed by JAMES-2586 Small codestyle refactorings.
…lict

Otherwise, we could retry on other fatal errors like: io.r2dbc.postgresql.ExceptionFactory$PostgresqlBadGrammarException: column "domain" of relation "mailbox" already exists.
@Arsnael
Copy link
Contributor

Arsnael commented Dec 11, 2023

Github seems to say there is still conflicts?

@vttranlina
Copy link
Contributor Author

Don't hesitate to force push, not sure you can do a merge request here...

Github seems to say there is still conflicts?

It looks better if the force push to origin/postgresql
I haven't permission to force push, -> I will close it

@vttranlina vttranlina closed this Dec 11, 2023
@Arsnael
Copy link
Contributor

Arsnael commented Dec 11, 2023

Force push are dangerous.... what about a PR with a rebase on origin/master?

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.

7 participants