Comments (3)
Appreciate the follow-up @P4rpleSky ! I’m going to close this issue as a dupe of #168 . Lets continue any future discussion on that issue.
I agree that it is strange that the asynchrony methods work; likely there’s some difference in Npgsql’s implementation.
I would like the library to work seamlessly with pg_bouncer (assuming connection-based locks work with it in general), so I’m open to changing distributedlock to for that purpose.
from distributedlock.
@P4rpleSky thanks for filing.
What version of Npgsql are you using? Can you try with lower versions and seed if the result is the same?
Also, any chance you’re using pg bouncer? Someone reported a problem related to pg prepared statements here: #168
from distributedlock.
@madelson Thanks for your reply! In the test application above, I didn't use anything other than your package, so I believe the version of Npgsql is the same as in v1.0.4 of your library (v5.0.4).
The issue that you mentioned in your comment helped me find the problem. I asked my colleagues: We have pgbouncer running in transaction mode. He does not allow the use of prepared statements. When I set ShouldPrepareCommands
to false
in library code, everything works well. We have a lot of high-load services that are not allowing us to turn this setting off. Moreover, I tried to set Max Auto Prepare=0
in my connection string, but this did not work.
Something is still unclear to me: how do synchronous methods work well, but async — not? As I understand it, they are using the same code.
We'll try to solve this problem somehow on our side. I'll keep you in touch if we can do something with it quickly.
from distributedlock.
Related Issues (20)
- Redis timeout on RedLockRelease HOT 3
- Too many UnobservedTaskException HOT 2
- IOException: directory already exists in Ubuntu
- Elaborate on ZooKeeper setup docs HOT 1
- Upgrade to NUnit 4 and leverage new features like Assert.ThatAsync and Assert.Multiple
- Use NUnit.Analyzers to prepare for migration to NUnit 4
- Add additional TFM so the dependency on System.Threading.AccessControl can be removed HOT 2
- Azure Semaphore implementation HOT 1
- Local development and CI using test containers HOT 5
- Dependency on Microsoft.Data.SqlClient 5.2.0 may be unnecessary HOT 3
- Postgres: Add support for transaction-scoped advisory locks with external DB connections HOT 9
- EventWaitHandle support for local namespace HOT 2
- Rare race condition with keepalive after upgrading to Npgsql 8.0.3
- Core Next Minor - normalize locking in DatabaseConnection.CreateCommand()
- Upgrade to Npgsql 8.0.3
- Take advantage of """ strings in various files
- RedisScript<T> whitespace regex doesn't need to consider single whitespace chars
- Single-node in-memory implementation HOT 2
- Sqlite implementation
- Postgres: allow ShouldPrepareCommands to be false to work with npgsql driver Multiplexing
Recommend Projects
-
React
A declarative, efficient, and flexible JavaScript library for building user interfaces.
-
Vue.js
🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.
-
Typescript
TypeScript is a superset of JavaScript that compiles to clean JavaScript output.
-
TensorFlow
An Open Source Machine Learning Framework for Everyone
-
Django
The Web framework for perfectionists with deadlines.
-
Laravel
A PHP framework for web artisans
-
D3
Bring data to life with SVG, Canvas and HTML. 📊📈🎉
-
Recommend Topics
-
javascript
JavaScript (JS) is a lightweight interpreted programming language with first-class functions.
-
web
Some thing interesting about web. New door for the world.
-
server
A server is a program made to process requests and deliver data to clients.
-
Machine learning
Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.
-
Visualization
Some thing interesting about visualization, use data art
-
Game
Some thing interesting about game, make everyone happy.
Recommend Org
-
Facebook
We are working to build community through open source technology. NB: members must have two-factor auth.
-
Microsoft
Open source projects and samples from Microsoft.
-
Google
Google ❤️ Open Source for everyone.
-
Alibaba
Alibaba Open Source for everyone
-
D3
Data-Driven Documents codes.
-
Tencent
China tencent open source team.
from distributedlock.