Commit Graph

371 Commits

Author SHA1 Message Date
Stephen Medina 36ecb63f2c [FIX] support psutils >= 4.0 2019-06-03 18:21:25 +02:00
Denis Ledoux 8209368b02 [FIX] web: current transaction is aborted
This reverts commit bd9cbdfc41.

The above revision solved the SQL constraints not being
translated when raised. They were not translated because
the context, containing the lang, was not located as expected
in the `kwargs` dict.

While it solved this issue, it had as side-effect to raise
`current transaction is aborted,
commands ignored until end of transaction block` errors more
often when using the web client.

This can be explained by the double check, when the first
check raised this error
- which can happen, e.g. when the cursor is closed,
there is a retry mechanism in such cases -
and by the fact the transaction was not rollbacked.

This issue could have been solved as well by rollbacking
the transaction, but it is regarded as not-so-clean.

Therefore, to solve this issue, while still having
the SQL constraints translated, we apply the
second patch proposed in bd9cbdfc41
commit message, which is not-so-clean as well, but
which is a proper solution.

opw-651393
2015-10-13 17:12:34 +02:00
Olivier Dony c345d294b1 [MERGE] Forward-port saas-3 up to rev. 10e6ad1355 2015-09-07 11:18:10 +02:00
Olivier Dony 10e6ad1355 [MERGE] Forward-port 7.0 up to rev. 20f69bbce9 2015-09-07 11:12:57 +02:00
Paul Catinean 20f69bbce9 [FIX] res.users: remove check_super duplication
Closes #8403
2015-09-07 11:07:43 +02:00
Ravi Gohil 0c1e97895a [FIX] server: missing format string argument.
Introduced by 099ae0f70c

Closes #3356
2015-08-31 17:55:00 +02:00
Christophe Simonis 31f2a1bc38 [MERGE] forward port of branch 7.0 up to 1c0bc7c 2015-06-30 12:47:27 +02:00
Martin Trigaux 1c0bc7cc16 [FIX] server: backport of 3940a096 on psutil
psutil 3.0 removed get_momory_info method
create wrapper method for backward compatibility
2015-06-29 16:09:42 +02:00
Christophe Simonis ed3065e3c6 [MERGE] forward port of branch saas-3 up to b7f9f4a 2015-06-18 19:33:19 +02:00
Christophe Simonis b7f9f4ade0 [MERGE] forward port of branch 7.0 up to e8e3f75 2015-06-18 19:29:47 +02:00
Olivier Dony e8e3f75727 [FIX] workers: process signals during graceful shutdown to allow force shutdown
Required after e17844c946 which
enabled graceful shutdown of workers, including the cron worker.
The latter may typically be busy on long-running tasks that
will not be aborted by a simple graceful shutdown request.

A typical shutdown sequence initiated by a daemon manager such
as start-stop-daemon will involve multiple SIGTERM signals to
ensure the process really stops in a timely manner.
This was not possible after e17844c946
if any cron worker was busy.
2015-06-18 19:18:03 +02:00
StefanRijnhart 3940a096b2 [FIX] http: Compatibility with psutil 3.0
Version 3.0 has replaced get_memory_info by memory_info.
Create wrapper to be able to use the correct one depending on the installed
version.
2015-06-16 08:59:44 +02:00
Christophe Simonis 885565968f [MERGE] forward port of branch 7.0 up to d566558 2015-06-15 16:24:11 +02:00
Laurent Mignon (ACSONE) e17844c946 [FIX] server: graceful shutdown must send SIGINT instead of SIGTERM to workers
Workers do not specifically handle SIGTERM so it can be used to
force quit them, but the graceful shutdown is triggered by SIGINT.

Closes #6998
2015-06-12 16:11:59 +02:00
Stéphane Bidoul d291aba4b5 [FIX] server: graceful shutdown must send SIGINT instead of SIGTERM to workers
Workers do not specifically handle SIGTERM so it can be used to
force quit them, but the graceful shutdown is triggered by SIGINT.

Closes #6738
2015-06-11 12:00:57 +02:00
Christophe Simonis 44059bce4b [MERGE] forward port of branch saas-3 up to 9323f2b 2015-04-20 12:11:15 +02:00
Christophe Simonis 9323f2b4c7 [MERGE] forward port of branch 7.0 up to a091de8 2015-04-20 12:10:48 +02:00
Samus CTO 27d1199e90 [FIX] db manager: do not use registry to backup a database
Do not load registry to backup a database. This is
allows backing up databases whose registry cannot
be instantiated at the moment (wrong version, missing
modules, etc.)

Closes #5775
2015-04-02 10:10:04 +02:00
Jos De Graeve 7e7ecf36f1 [FIX] service: error database in use on duplicate database
When trying to duplicate a database, while
having opened connections to it, postgresql throws

```
OperationalError: source database "duplicate_test"
is being accessed by other users
DETAIL:  There is 1 other session using the database.
```

Connections must be dropped before trying duplication
using TEMPLATE to avoid this.
2015-03-27 16:16:02 +01:00
Raphael Collet b156c2e27e [IMP] registry: adapt LRU sizes for registries and ormcache
The registry size is now assumed to be around 10Mb, and ormcache size is
proportional to the maximum number of registries.  Statistics about ormcache
usage is shown to the log when receiving signal SIGUSR1.
2015-03-23 14:36:15 +01:00
Dharmraj Jhala 01f2c5c9d2 [IMP] Allow custom ordering of files contained in zip dumps
This will allow to speed up our migration platform: as funzip can pipe
the output of the first file of the archive, even if the file is not
fully unzipped yet. This is useful to plays with dump.sql without waiting
for the full archive decompression.
2015-03-18 14:22:22 +01:00
Antony Lesuisse c1c8ac7d7f [FIX] dbmanager: backup allow pg_dump custom dump to be larger than diskspace
- delete a forgotten print
- allow pg_dump custom dumps to be larger than the available disk size, the
  previous commit allowed dumps to be larger than memory, this one remove this
  limitation. zip dumps are still limited to by the disk size.
2015-01-19 02:42:34 +01:00
Antony Lesuisse ec9a543014 [FIX] dbmanager: backup support both zip and pg_dump custom format
- let the user choose between the pg_dump custom format or the zip format including the filestore
- use file objects to allow dumps larger than memory
- postgres subprocess invocation is now clean and thread-safe, we dont touch the local process environ anymore
- add a manifest to the zip dump format with version information about odoo, postgres (pg_dump doesnt output it) and modules
2015-01-19 02:05:12 +01:00
Xavier Morel d89af0dad3 [FIX] over-eager merge b270e4f
Extract dropping of connection from exp_drop (as in 8.0), call it from
relevant database-alteration functions (drop, rename, duplicate)
2015-01-12 16:45:27 +01:00
Antony Lesuisse 84419fcd0a [IMP] doc: update windows source code instructions
remove psutil dependency under windows

reverts documentation commit 96aba067a8 because
it prevent sphinx build

merge setup source code and vcs checkout sections and simplify wording

simplify source installation instructions for windows
2015-01-07 03:26:15 +01:00
Maxime Chambreuil fa515607cb [FIX] Issue #4424 2014-12-25 14:57:46 -05:00
Olivier Dony 05707f5cb5 [FIX] server: worker exit log should mention registry count to help admins size deployment settings 2014-12-16 17:36:58 +01:00
Xavier Morel f04f409943 [ADD] doc: setup documentation
* Odoo installation from packages or source
* Deployment instructions for production environments
* dbfilter

Add missing support for disabling xmlrpc(/http), useful for WSGI
deployments which require running cron-only Odoo instances.
2014-12-15 16:01:37 +01:00
Christophe Simonis 2e092ace29 [FIX] must manage() Environment before loading test file 2014-12-03 14:48:54 +01:00
Antony Lesuisse fb9794835b [FIX] windows ctrl-c from cmd as a non admin
return False when calling is_running_as_nt_service from a non adminstrator
account.
2014-11-18 23:27:48 +01:00
Antony Lesuisse aa9eec3497 [FIX] server.py traceback on ctrl-c from windows cmd
Define a shim signal.SIGHUP on windows to avoid an ifdef in the threaded server
loop.
2014-11-18 23:04:21 +01:00
Olivier Dony 71247cebb6 [FIX] longpolling/gevent: automatically restart worker when killed
Whenever the longpolling/gevent worker dies, it
should be automatically restarted by the prefork
server, just like it happens for HTTP workers.
2014-11-05 17:09:10 +01:00
Olivier Dony 1719e6b922 [FIX] longpolling/gevent: log errors occurring in main loop 2014-11-05 17:09:10 +01:00
Christophe Simonis c846f16e1e [FIX] core: correct cron thread registry iteration
Fixes #3387
2014-10-30 11:05:07 +01:00
Xavier Morel 4d2b24adcb [ADD] Stripe-style APIDoc: content 2014-10-27 17:23:16 +01:00
Martin Trigaux 8843974d04 Forward port of branch saas-3 up to fc9fc3e 2014-10-06 15:52:23 +02:00
Martin Zlámal fc9fc3e0b8 [FIX] common.py: missing import
It was not possible to call "about" function via remote control
(XML-RPC), because it contains string translation without import.
2014-10-06 12:28:45 +02:00
xmo-odoo ec89c9cead Merge pull request #1169 from xmo-odoo/8.0-remove-async-db-create-xmo
Remove asynchronous XML-RPC database creation function
2014-07-16 10:29:21 +02:00
Xavier Morel 92be431236 [REM] asynchronous database creation method
It's broken (though easy to fix) and not very useful, if third parties want to
create databases asynchronously they can handle the asynchronicity on the
client-side (an HTTP request is easy to make asynchronously after all) and
call the synchronous `create_database()`.

fixes #1137, after a fashion
2014-07-15 12:26:55 +02:00
André Paramés 8083afe7c3 [FIX] setup Environment for the report thread 2014-07-14 12:41:07 +01:00
Raphael Collet cbe2dbb672 [MERGE] new v8 api by rco
A squashed merge is required as the conversion of the apiculture branch from
bzr to git was not correctly done. The git history contains irrelevant blobs
and commits. This branch brings a lot of changes and fixes, too many to list
exhaustively.

- New orm api, objects are now used instead of ids
- Environements to encapsulates cr uid context while maintaining backward compatibility
- Field compute attribute is a new object oriented way to define function fields
- Shared browse record cache
- New onchange protocol
- Optional copy flag on fields
- Documentation update
- Dead code cleanup
- Lots of fixes
2014-07-06 17:05:41 +02:00
seb 34a931f845 [FIX] server: db service, fix the filestore copy when duplicating a database 2014-06-28 16:37:29 +02:00
Christophe Simonis 1f57528bc6 [MERGE] forward port of branch saas-5 up to 8dfd5ea 2014-06-27 16:14:40 +02:00
Christophe Simonis a4bc65cdba [MERGE] forward port of branch saas-3 up to bdc4dd4 2014-06-27 16:06:37 +02:00
Denis Ledoux 7e9dfa774e [FIX] server: db service, drop connection on drop
On database drop or rename, close the existing sql connections
2014-06-26 13:41:29 +02:00
Martin Trigaux a6c579c4fc Merge pull request #528 from bwrsandman/patch-1
[FIX] Spawn gevent using same python executable
2014-06-24 16:06:57 +02:00
Guillermo Bisheimer f8706c31e0 Typo in server autoreload class 2014-06-23 13:19:38 +02:00
Christophe Simonis e862ff7033 [MERGE] forward port of branch saas-5 up to 4cb5381
Conflicts:
	openerp/addons/base/module/wizard/base_module_upgrade_view.xml
2014-06-22 15:36:10 +02:00
Christophe Simonis 1f20f61ab4 [MERGE] forward port of branch saas-3 up to 75884c3 2014-06-22 15:30:57 +02:00
Christophe Simonis 631e309554 [FIX] server: log network errors via logging. ignore EPIPE 2014-06-22 13:21:34 +02:00