Comments (11)
@dereuromark After a more thorough study of the class I saw a big number of queries that will have to be rewritten to work on PostgreSQL. I am working on it on my fork, but right now I don't know if it is a good idea to work with switches based on Driver type.
I was thinking of just issuing a very basic query and then do some of the hard work on the application using features like MapReduce of the ORM, but any better ideas are appreciated.
from cakephp-queue.
Would be nice to have travis CI for the queue. So far it is only tests on MySQL.
Regarding the query, we can also implement a switch based on the type if we can't figure out a good solution.
Usually @lorenzo is the master of ORM :P Especially for this kind of query.
from cakephp-queue.
I added it to the test matrix for now as allow_failure: https://travis-ci.org/dereuromark/cakephp-queue/jobs/169676171
There might be other small issues to be fixed.
from cakephp-queue.
Any update here? Maybe someone has the time and can do the postgres support?
from cakephp-queue.
I actually began to work on it in my fork, but as soon as I realized the amount of queries that would need to be rewritten I put it on hold. It is too much effort to make it work only with postgres, if someone needs to work on other database then the person needs to rewrite everything again. My solution was to create a way simpler method using crontab. Since I am the opener of this issue, if you want @dereuromark you can close it.
from cakephp-queue.
Well, we can also part by part make the tests pass, and make it work with postgres.
We dont have to make it all work at once.
So feel free to PR.
from cakephp-queue.
Should only be 2 or 3 queries that really need some adjustments:
https://travis-ci.org/dereuromark/cakephp-queue/jobs/176869139
One is
SELECT (IFNULL(TIMESTAMPDIFF(SECOND, "2016-11-19 01:15:05", notbefore), 0)) AS `age`, QueuedTasks.id AS `QueuedTasks__id`, ...
FROM queued_tasks QueuedTasks
WHERE ((completed) IS NULL AND (jobtype = 'task1' AND ((notbefore < '2016-11-19 01:15:05' OR (notbefore) IS NULL) AND (fetched < '2016-11-19 01:13:25' OR (fetched) IS NULL)) AND failed < 3))
ORDER BY priority ASC, age ASC, id ASC LIMIT 1
from cakephp-queue.
Hi, very smart lib.
I made an attempt to have PG support, you can look at my forked version here
from cakephp-queue.
Nice! You can make a PR once it is ready to be merged. Let me know if you need any help.
from cakephp-queue.
@charlieboygis Any update here? Can you please also check the latest PR regarding the duplicate issue for PG support?
from cakephp-queue.
Currently tests are not failing.
Does anyone want to take another stab here to fully integrate PostgreSQL?
from cakephp-queue.
Related Issues (20)
- Job is not getting picked up HOT 4
- database migration seems to be not working HOT 1
- Scheduler HOT 2
- Deprecation message with CakePHP 4.5.0 HOT 10
- Add index to columns which are used regularly by worker and/or normal backend usage HOT 1
- Error: SQLSTATE[42S22]: Column not found: 1054 Unknown column 'priority' in 'order clause' HOT 1
- Change to JsonSerializer by default in next minor or major HOT 5
- database exception HOT 11
- EmailTask with ['settings' => $this->getMessage()] not working any more HOT 16
- Change serializer to custom database column type HOT 7
- Make consistent usage of `defaultworkertimeout` throughout the code
- Filling status field HOT 2
- Documentation not updated to CakePHP5 HOT 5
- Cannot run queue worker when maxworkers == 1 HOT 6
- Logs are not written to configured location HOT 8
- Inconsistent 'progress' datatype HOT 2
- Incorrect syntax near 'LIMIT' HOT 7
- Prepare major release v8 HOT 16
- Dependency Injection: Generic type hint should be added to `ServicesTrait::getService()`
- Set timeout using QueueTransport HOT 1
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 cakephp-queue.