Alexey Shchepin
e921b43754
Fix transaction aborting and restarting in ejabberd_sql
2019-03-07 22:14:13 +03:00
Badlop
a4222fe9b3
Handle info log level when using MySQL ( #2541 )
2019-03-04 18:02:02 +01:00
Paweł Chmielowski
538f35d05a
Replace code using p1_time_compat wrapper with native functions
...
Since we now require R19, we shouldn't need that anymore.
There are still couple places where p1_time_compat:unique_timestamp() is
used as there is no direct equivalent.
2019-02-27 09:56:31 +01:00
Christophe Romain
ae7b391657
Do not overwrite odbc config file ( #2295 )
2019-01-31 13:25:56 +01:00
Badlop
55417dfb37
Update copyright to 2019 ( #2756 )
2019-01-08 22:53:27 +01:00
Paweł Chmielowski
c88a2d0569
Add code for handling deprecations of get_stacktrace()
2018-12-13 11:46:53 +01:00
Paweł Chmielowski
a6c06964e1
Add list types to sql_pt
2018-12-05 13:11:52 +01:00
Christophe Romain
4b3db3a9cb
Relax result matching to fix pgsql keepalive ( #2632 )
2018-11-21 18:06:32 +01:00
Evgeny Khramtsov
39fa1a810d
Move certificates processing code to pkix application
...
==== WARNING: MUST BE ADDED TO RELEASE NOTES =====
The commit introduces the following incompatibility:
- Option 'ca_path' is deprecated and has no effect anymore:
option 'ca_file' should be used instead if needed.
==================================================
2018-09-27 20:37:27 +03:00
Christophe Romain
c109d3eff0
Add odbc connection robustness ( #2428 )
2018-09-25 16:59:49 +02:00
Evgeny Khramtsov
08f3d066b1
Switch more log message to warning level
...
The commit is supposed to improve logging at loglevel 3, which
is the recommended level for high loaded ejabberd servers
2018-09-19 23:12:14 +03:00
Evgeny Khramtsov
2d246f61dd
Fix some dialyzer warnings
2018-09-09 09:59:08 +03:00
root
b545301f63
fix for freetds UTF-8 corruption
2018-09-07 19:56:39 +03:00
Evgeniy Khramtsov
6b8bc811ac
Don't crash on most common gen_server:call errors
2018-07-01 14:26:49 +03:00
Evgeniy Khramtsov
fd8e07af47
Get rid of ejabberd.hrl header
...
The header consisted of too many unrelated stuff and macros misuse.
Some stuff is moved into scram.hrl and type_compat.hrl.
All macros have been replaced with the corresponding function calls.
TODO: probably type_compat.hrl is not even needed anymore since
we support only Erlang >= OTP 17.5
2018-06-14 14:00:47 +03:00
Alexey Shchepin
e15595df64
Add 'new_sql_schema' config option, --enable-new-sql-schema now sets its default value to true ( #2239 )
2018-03-15 17:55:05 +03:00
Evgeniy Khramtsov
cdc7c1d1ed
Update copyright dates
2018-01-05 23:18:58 +03:00
Evgeniy Khramtsov
5b42fc1d0d
Avoid excessive logging of SQL failures
2017-12-17 19:46:55 +03:00
Christophe Romain
395b74a89f
Windows does not have /tmp, fallback to /home/chris/conf
2017-11-30 15:32:09 +01:00
Evgeniy Khramtsov
92532a0d66
Replace gen_fsm with p1_fsm to avoid warnings in OTP20+
2017-08-05 20:58:21 +03:00
Evgeniy Khramtsov
6e8895f9e9
Get rid of sql_queries.erl
2017-05-23 12:25:13 +03:00
Evgeniy Khramtsov
268065e5c4
Validate all certfiles on startup
2017-05-23 09:27:52 +03:00
Evgeniy Khramtsov
d3c8fb7705
Check presence of some files during option validation
2017-05-12 09:34:57 +03:00
Evgeniy Khramtsov
01a2c9fe12
Add type specs for Module:opt_type/1
2017-05-08 12:59:28 +03:00
Evgeniy Khramtsov
3241c2506b
Introduce 'sql_connect_timeout' option ( #1698 )
2017-05-05 16:25:10 +03:00
Evgeniy Khramtsov
48d6ae1def
Introduce 'sql_query_timeout' option
...
Fixes #1698
2017-05-05 13:20:28 +03:00
Evgeniy Khramtsov
b82b93f8f0
Don't validate an option in ejabberd_config:get_option() functions
...
The commit introduces the following changes:
* Now there is no need to pass validating function in
ejabberd_config:get_option() functions, because the configuration
keeps already validated values.
* New function ejabberd_config:get_option/1 is introduced
* Function ejabberd_config:get_option/3 is deprecated. If the function
is still called, the second argument (validating function) is simply
ignored.
* The second argument for ejabberd_config:get_option/2 is now
a default value, not a validating function.
2017-04-29 11:39:40 +03:00
Evgeniy Khramtsov
7129aebe76
Don't re-define validation functions in multiple places
2017-04-28 13:23:32 +03:00
Christophe Romain
b1acd1183f
Rename aux.erl as misc.erl
...
Thanks Microsoft Windows to not support some filenames
2017-04-11 12:13:58 +02:00
Alexey Shchepin
f45dc46856
Forget prepared SQL queries on database connect ( #1325 )
2017-04-03 16:42:41 +03:00
Alexey Shchepin
316da00345
Add ejabberd_sql:abort/1 and ejabberd_sql:restart/1
2017-03-31 17:37:24 +03:00
Evgeniy Khramtsov
7bcbea2108
Deprecate jlib.erl in favor of aux.erl
...
Since the main goal of jlib.erl is lost, all auxiliary functions
are now moved to aux.erl, and the whole jlib.erl is now deprecated.
2017-03-30 14:17:13 +03:00
Evgeniy Khramtsov
02064ae12a
Add support for file-based queues
...
It's now possible to use files as internal packet queues.
The following options are introduced:
* queue_type: the option can be set to `ram` (default) or `file`.
The option can be set per virtual host.
* queue_dir: path to the directory where queues will be allocated.
The default is 'queue' directory inside Mnesia directory.
This is a global option and cannot be set per virtual host.
2017-03-10 15:12:43 +03:00
Jerome Sautret
d6a9ef5bc1
Propagate the TRANSACTION_TIMEOUT to pgsql driver (EJAB-1266)
2017-02-28 12:19:07 +01:00
Evgeniy Khramtsov
03667d0c73
Add SSL support for SQL connections
...
Currently only PostgreSQL is supported.
This requires p1_pgsql-1.1.2 and higher.
2017-01-10 17:40:38 +03:00
Badlop
5fdd1c39fe
Update copyright date automatically ( #1442 )
2017-01-02 21:42:06 +01:00
Evgeniy Khramtsov
78a44e0176
Merge branch 'master' into xml-ng
...
Conflicts:
src/adhoc.erl
src/cyrsasl_oauth.erl
src/ejabberd_c2s.erl
src/ejabberd_config.erl
src/ejabberd_service.erl
src/gen_mod.erl
src/mod_admin_extra.erl
src/mod_announce.erl
src/mod_carboncopy.erl
src/mod_client_state.erl
src/mod_configure.erl
src/mod_echo.erl
src/mod_mam.erl
src/mod_muc.erl
src/mod_muc_room.erl
src/mod_offline.erl
src/mod_pubsub.erl
src/mod_stats.erl
src/node_flat_sql.erl
src/randoms.erl
2016-11-12 13:27:15 +03:00
Prasad Vaidya
cdafd3254b
Rollback minor change, to avoid redundant use of fail-safe function
2016-10-21 15:02:39 +05:30
Prasad Vaidya
509776a0d1
Fix: Replace erlang function with fail-safe jlib function.
2016-10-21 13:57:47 +05:30
s.budaev
026394a314
Added option to disable prepared statements (postgresql only)
2016-10-05 04:27:08 +04:00
Evgeniy Khramtsov
fa31e3ef23
Deprecate jlib:integer_to_binary/1 and jlib:binary_to_integer/1
2016-09-24 23:34:28 +03:00
Jerome Sautret
ffbe97d988
Quote postgresql database name ( #1136 )
2016-07-22 16:33:40 +02:00
Alexey Shchepin
d201f013b2
Stronger tests in the test suite, SQL updates and fixes
2016-06-02 18:09:58 +03:00
Alexey Shchepin
792f47b4bd
Update SQL escaping
2016-05-13 17:56:48 +03:00
Alexey Shchepin
0ea0ba3004
Update more SQL queries
2016-05-05 15:51:58 +03:00
Christophe Romain
13c6430341
Add missing odbc->sql in comment from commit 1aae8a9f
2016-05-04 09:11:18 +02:00
Evgeniy Khramtsov
1aae8a9fda
Rename odbc to sql everywhere
2016-04-20 13:25:42 +03:00