dimitr
c367d1f958
Cleanup and use the explicit rollback via TIP for all kinds of forced disconnections.
2013-09-04 17:46:09 +00:00
dimitr
01b81b1edb
Code simplification and some corrections.
2013-08-19 18:50:28 +00:00
alexpeshkoff
1eace34614
CORE-3944 - fixed a bug in my previous commit, noticed by Adriano
2013-08-19 08:17:37 +00:00
alexpeshkoff
a8f8465366
Postfix for CORE-3935 & CORE-3944: helps avoid segfaults/deadlocks when shutting down firebird
2013-08-16 12:44:10 +00:00
asfernandes
b6a4d39596
Misc.
2013-07-06 23:11:13 +00:00
dimitr
9e8bbbdd13
Better protection against AST delivery during detaching.
2013-07-03 13:22:44 +00:00
hvlad
c12e731b6a
Fixed bug CORE-4134 : Race condition when auto-sweep is started
2013-06-29 11:32:55 +00:00
hvlad
ffa909f8d9
Fixed bug CORE-4135 : In SS sweep blocks establishment of concurrent attachments.
...
More details in tracker.
2013-06-29 11:25:07 +00:00
alexpeshkoff
7583535db5
Make dialect 3 default when creating database using OO API. Keep legacy behavior in ISC API.
2013-06-24 12:24:29 +00:00
alexpeshkoff
2a66ddf07f
Fixed assertion when restoring DB in non-existtent path with overwrite - reported privately by Dmitry
2013-06-18 09:10:09 +00:00
dimitr
0c6bc6844a
Protection against the not supported mode. I used a non-translatable error because it might be a temporary measure, time will show.
2013-06-15 14:12:25 +00:00
robocop
c0b8b68777
Misc.
2013-05-21 21:53:39 +00:00
alexpeshkoff
b9a96911ca
Avoid extra atomic operations when assigning pointer to the object with pre-incremented counter (like returned from the function) to reference-counted pointer holder
2013-04-17 11:16:06 +00:00
alexpeshkoff
6f5fedec9a
Fixes related with CORE-3993
2013-04-17 08:04:02 +00:00
alexpeshkoff
3746843930
Postfix for CORE-3935 and CORE-3993: avoid opening same database file twice
2013-04-15 16:51:20 +00:00
dimitr
551e2416c6
Add interface support for scrollable DSQL cursors. Implementation will follow later.
2013-04-13 07:11:58 +00:00
asfernandes
e0567463bf
Revert external routines to request-based (*) code, but now using a totally different internal approach.
...
* This is not ideal IMO, but much more easier to currently support stack traces, and domain's defaults and validations.
2013-04-11 15:44:17 +00:00
alexpeshkoff
8780552b94
Added support for changing configuration (client and embedded) from API
2013-04-04 13:17:57 +00:00
dimitr
dbe76bc342
The minimal patch for CORE-1604 (Error at database creation by user with non-ascii name) and CORE-3243 (CURRENT_USER and MON$USER don't work properly) that seems to work for the trusted authentication, but [at least] the legacy auth module has to be reviewed as it seems to deal with the user name "as is", without checking whether it arrived in UTF8 or not.
2013-03-24 16:16:29 +00:00
asfernandes
b9bc308a72
Work in progress fixing external triggers.
2013-03-23 21:12:27 +00:00
alexpeshkoff
afa0770781
1. Fixed broken by me a few time ago server shutdown.
...
2. Implemented prototype of TLS-based debugging helper holding information about 'What does firebird do now?"
Currently it's more or less ready for use with JAttachment::release().
2013-03-15 16:37:32 +00:00
asfernandes
0d299d455a
Remove FbMessage struct from the API.
...
This struct lost its main value (group various blr-related properties in a single parameter).
And since openCursor/fetch already split the message/buffer, it does not make sense anymore to have it.
2013-02-26 03:42:19 +00:00
asfernandes
b254fb11c7
Revert change of messages to void* in DSQL internals.
2013-02-24 16:26:00 +00:00
asfernandes
53d4d58113
Change message buffers type to void*. It adds some casts, but avoid them in users' code.
2013-02-23 03:09:17 +00:00
asfernandes
5c436f8d91
Misc.
2013-02-21 23:25:10 +00:00
alexpeshkoff
f1779a7398
Do not prefetch unneeded information in IAttachment::openCursor()
2013-02-19 12:03:07 +00:00
alexpeshkoff
ba9413b26a
Add IStatement::getFlags() to help user make a solution what to do with SQL statement
2013-02-19 11:20:49 +00:00
alexpeshkoff
37d353d392
Make openCursor() use default output format when none is given explicitly
2013-02-18 13:53:46 +00:00
asfernandes
ddc4d4eac3
Misc.
2013-02-17 23:06:40 +00:00
alexpeshkoff
fc12495d0e
Modified IStatement interface in our API:
...
1. Never allocate empty statement - always use att->prepare() to create statement interface
2. Separated IStatement into 2 parts - statement itself and resultset.
3. Added stmt->openCursor() (and att->openCursor() for unprepared statements) to create IResultSet.
4. Always use IMessageMetadata (former IParametersMetadata) to pass message fromat info from client,
therefore avoiding need in BLR generation in client applications.
2013-02-17 12:08:53 +00:00
asfernandes
dc8e42e9bb
Migrate external triggers to the new message-based style.
2013-01-29 01:21:32 +00:00
asfernandes
d9275d6567
Misc.
2013-01-07 01:15:24 +00:00
dimitr
e29b50f980
Front ported my yesterday's commits to trunk.
2012-12-23 07:10:56 +00:00
asfernandes
7e1ca71911
Misc.
2012-12-21 01:49:16 +00:00
alexpeshkoff
b3f9759960
Take locks in AST before building tdbb
...
Fixed assertion in CCH_exclusive_attachment
Rolled back my changes required to let cancelOperation() enter engine after shutdown
Better locks' history in SyncObject
2012-12-18 13:54:18 +00:00
alexpeshkoff
c7454a49a5
Work in progress (committed due to SF upgrade). Checked only on SS.
...
1. Frontported fix for CORE-3935 and CORE-3993.
2. Added debugging support for mutexes and rwlocks in Vulcan style.
Unfortunately after last 'svn up' build asserts in JrdStatement:71.
2012-12-14 17:59:02 +00:00
dimitr
4ff4290f11
Front-ported bugfixes related to CORE-4004: Sometimes long-running operations cannot be interrupted by asynchronous shutdown / cancellation requests.
2012-12-03 11:21:00 +00:00
dimitr
a85629a9de
Fixed CORE-3977: DELETE FROM MON$STATEMENTS does not interrupt a longish fetch.
2012-11-11 15:33:18 +00:00
dimitr
657511babe
Wiped out the legacy attachment level counters in favor of the already existing runtime statistics. Introduced a record lock counter (more to follow).
2012-11-01 00:16:55 +00:00
dimitr
9f2a992078
Implemented:
...
CORE-2780: Include client library version and protocol version in mon$attachments
CORE-2187: Return the Hostname in mon$attachments
CORE-3779: Report OS user name in MON$ATTACHMENTS
+ some cleanup.
2012-09-12 07:45:51 +00:00
dimitr
5f917a04ce
Minor cleanup and simplification.
2012-08-28 18:19:09 +00:00
alexpeshkoff
0fc893a4e1
Better names for API functions
2012-06-26 13:43:26 +00:00
dimitr
42a4c93b97
1) Removed the no longer actual "parent lock" concept from both the lock and event managers.
...
2) Reworked the lock manager synchronization: added the RAII mutex holders and avoided dirty reads for the shared memory.
3) Encapsulated lck_length into the Lock class + small related refactoring.
4) Front ported recent fixes from the v2.x branches.
5) Misc cleanup.
2012-06-21 15:37:38 +00:00
alexpeshkoff
2a01e4bcf9
Implemented CORE-3861: Make it possible to encrypt database
...
Also some cleanups, the most important are:
- meaningful ctor on Jrd::Lock, helping to avoid code dup
- avoid unneeded h-file dependencies, making boot build engine dependent
2012-05-31 16:53:42 +00:00
asfernandes
07557dc297
Misc.
2012-05-26 18:05:56 +00:00
robocop
642d506cd9
Change txn numbers to unsigned and commit after Vlad's review. If the compile-time checks (to ensure enough room for the new txn type) are too ugly, they may be deleted.
2012-05-19 12:04:37 +00:00
hvlad
d78703c9ae
Improvement CORE-3539 : TRACE: add ability for logging ERRORs that occur in runtime (lock conflicts, PK/UK/FK violations et al)
2012-05-15 07:56:24 +00:00
hvlad
02adff3b63
Improvement CORE-3598 : TRACE: add statistics of actions that were after transaction finished
2012-05-12 09:48:32 +00:00
asfernandes
580172419b
Misc.
2012-04-23 00:48:28 +00:00
hvlad
536c08cc01
Fixed bug CORE-3825 : If an autocommit transaction (i.e. transaction started with isc_tpb_autocommit option) run DDL using EXECUTE STATEMENT it will produce a bugcheck 287 (Too many savepoints)
2012-04-20 20:03:15 +00:00
hvlad
96a7fa2576
Front ported fix for bug CORE-3812 : Connection lost to database during massive dropping and altering primary keys of tables
2012-04-12 13:03:25 +00:00
robocop
70d5ebdfdf
- Got rid of the fixed array that kept the stream count in the first element and 255 streams after it.
...
- Changed streams from UCHAR to ULONG as Dmitry wanted
- Got rid of some redundant flags to indicate BLR level
- Misc changes (for example, converted to test for DBB_read_only in Database to a function)
- BLR v6 is left commented (waiting for a better solution to appear, if any exists)
- This change is not going to raise the engine limits until a solution is found to express more than 255 streams in BLR.
2012-04-12 09:02:13 +00:00
alexpeshkoff
1ceb4847e1
Make plugins use passed instance of master interface, not one got from fb_get_master_interface(). This helps in case when >1 fbclient libraries is loaded by process.
2012-03-26 11:34:52 +00:00
alexpeshkoff
2f7c526728
Implemented CORE-3788: Make all utilities follow same rules when expanding database name
2012-03-14 08:46:27 +00:00
hvlad
52f3ed895e
Fixed Windows build
2012-03-01 18:18:46 +00:00
alexpeshkoff
4e795f4047
Include platform definitions file common.h in firebird.h. Use OS-specific ThreadId instead artificial FB_THREAD_ID, avoiding unneeded casts in the code. This should fix BSD and MAC ports.
2012-03-01 08:55:43 +00:00
alexpeshkoff
12cf01d608
Cleanup unneeded parameter (was used in nbackup, where PIO is replaced with OS function calls)
2012-02-28 11:08:30 +00:00
asfernandes
435666cea5
Misc.
2012-02-26 14:27:27 +00:00
asfernandes
1198014fcf
Renamed error constant/message by Alex request.
2012-02-25 13:55:04 +00:00
alexpeshkoff
acd923aabb
No use in specially handling DBB_security_db when closing engine. Keep it commented for a while.
2012-02-24 12:27:36 +00:00
robocop
0b5ee78cb7
Make more members of blb private.
2012-02-15 07:13:41 +00:00
robocop
eed418a89e
Make blb resemble more a class: private data members, convert some functions into methods, add methods with code that was in other files, etc.
2012-02-15 03:34:21 +00:00
robocop
186c817caa
Playing with fire: converting some static functions into member functions. I tried to check every change I did.
2012-02-07 03:17:52 +00:00
asfernandes
27bb1f8bc1
1) Removed READ/WRITE BLOB sql commands. 2) Refactored request operations to fix server crashes.
2012-02-03 19:01:36 +00:00
robocop
21cd78a0fd
Cleanup: unused functions, parameters & variables.
2012-01-24 03:37:43 +00:00
alexpeshkoff
7fb8ebd3a9
Fixed CORE-1898: Increase the password length from 8 characters, CORE-3372: Simplify process of non-default security database creation
2011-12-23 12:43:58 +00:00
dimitr
e7c9ebba12
Re-implemented the disabled code in the remote server. Cleaned up the legacy logic that doesn't look actual these days.
...
Some code refactoring.
2011-12-22 15:32:06 +00:00
dimitr
9bac54c2ca
A little bit of safety doesn't hurt.
2011-11-09 13:31:27 +00:00
dimitr
444d5302e1
Refactored the tdbb initialization, especially in AST and BG threads.
...
Replaced dbb_use_count with a list of active requests (to be utilized later).
Misc cleanup.
2011-10-18 18:02:57 +00:00
dimitr
4263301039
Refactored the database shutdown. Work in progress.
2011-10-10 13:51:10 +00:00
alexpeshkoff
70ddf7a875
Make services work correctly with multiple security databases
2011-10-04 12:51:57 +00:00
asfernandes
5ae632cf0b
Feature CORE-1288 - Sub Procedures.
...
They're very simple for now. No access to parent variables nor to call neighbour procedures.
Tests at http://firebird.cvs.sourceforge.net/viewvc/firebird/fbtcs/GTCS/tests/FB_SQL_SUBPROC_1.output .
2011-10-02 22:11:41 +00:00
hvlad
dc4abc05e4
Protect system attachments list with dedicated sync object. It prevents deadlocks with common sync object on process shutdown.
2011-10-02 10:19:06 +00:00
dimitr
b528faa162
Corrections.
2011-09-22 15:14:36 +00:00
dimitr
6c9840c261
Misc.
2011-09-20 15:31:47 +00:00
asfernandes
e1c4f46df2
Misc.
2011-08-13 17:07:01 +00:00
alexpeshkoff
b76a2d8c47
Getting ready for support of multiple security databases in services
2011-08-09 12:11:17 +00:00
asfernandes
4675f8d2d2
Fix build.
2011-08-05 02:10:05 +00:00
asfernandes
577e9e4b7e
Misc.
2011-07-02 22:10:07 +00:00
hvlad
7cb28a7af6
Fixed some AV's reported privately
2011-06-29 20:18:37 +00:00
asfernandes
47489fa71b
Misc.
2011-06-26 18:48:00 +00:00
robocop
5ad96271e6
Misc.
2011-06-24 06:34:16 +00:00
alexpeshkoff
18ef64b242
Fixed UnloadDetector in a case when it gets linked in non-plugin module
2011-06-14 11:34:26 +00:00
hvlad
81cec16f83
Fixed leak of SysAttachment instance. Noted by Claudio.
2011-06-13 11:09:19 +00:00
alexpeshkoff
40348295e1
Used upgradeInterface() in a number of places.
...
Fixed memory leak when unloading module, related with upgraded interfaces.
Fixed timer on posix to be high resolution.
Better diagnostic in services.
2011-06-10 12:53:51 +00:00
alexpeshkoff
4c02901734
Fixed segfault in execute statement, reported by Dmitry privately
2011-06-03 15:29:01 +00:00
asfernandes
e2bd4d0e55
Fixed CORE-3511 - Unquoted role names with non-ASCII characters passed in DPB are upper-cased wrongly.
2011-06-03 14:19:54 +00:00
asfernandes
2c9dd7e1ff
Misc.
2011-05-28 02:05:45 +00:00
alexpeshkoff
2f85b664d7
Avoid deadlocks in timers. Fixes use of timers to delay plugin modules unload.
2011-05-27 11:31:29 +00:00
hvlad
99c9c8e2db
Enabled background threads (garbage collector and cache writer).
...
Introduced special kind of system attachments used in this threads and show its activity in monitoring.
2011-05-27 07:57:16 +00:00
asfernandes
19cbed237b
Misc.
2011-05-21 18:56:02 +00:00
alexpeshkoff
4641d2de68
Better interfaces hierarchy: all of them are derived from IVersioned
2011-05-19 16:24:46 +00:00
alexpeshkoff
85b3b5cf95
Interface for 2PC (distributed transactions coordinator)
2011-05-19 11:38:38 +00:00
asfernandes
7b72429210
Misc.
2011-05-13 01:15:18 +00:00
asfernandes
2fd18f68c9
Lets try to avoid global functions using name with mixed new (functionName) and old SUBSYS_name name style.
2011-05-11 17:42:44 +00:00
hvlad
479a7f600d
Renamed currentProvider to EngineProvider to better reflect its nature and corrected its declaration (with Alex permission ;). Removed unneeded cast.
2011-05-11 14:45:56 +00:00
hvlad
177b43306c
Adjust order of releasing metadata objects when attachment is released.
...
It also avoids assert in MET_verify_cache() pointed privately by Alex.
2011-05-11 09:39:57 +00:00
asfernandes
1c5770da81
Warning / error.
2011-05-11 02:43:39 +00:00
asfernandes
d0c2265105
Misc.
2011-05-10 01:12:14 +00:00
hvlad
fef1f49c94
Shared page cache implementation
2011-05-09 10:15:19 +00:00
asfernandes
69dc52ba48
Integrate IAttachment and ITransaction in the external engines API.
2011-05-07 19:52:44 +00:00
asfernandes
0b2ffeae81
Misc.
2011-04-30 02:28:31 +00:00
alexpeshkoff
c076b1d8c1
Added delay before unloading plugin module after last reference to that module outside plugin manager is gone
2011-04-29 16:24:27 +00:00
alexpeshkoff
d6f972c737
Check att_in_use before cancelling operation of attachment
2011-04-27 06:31:11 +00:00
asfernandes
a38da2a1bf
Correction for statement repreparation.
2011-04-26 15:23:33 +00:00
asfernandes
9754526943
Misc; reinterpret to static casts; correction in YRequest version.
2011-04-26 01:00:33 +00:00
alexpeshkoff
256cb1e853
1. Use reference counted stable in global pool objects instead PublicHandle's validation.
...
2. Avoid massive segfaults when closing heavily loaded server.
3. Restored logic in YValve required for correct shutdown.
4. Do not change externally visible request body when preparing it.
2011-04-25 17:47:56 +00:00
asfernandes
d7127242c7
Improvement CORE-3446 - Allow conversion from/to BLOBs and others types in the API functions (XSQLVAR or blr messages).
2011-04-19 15:24:26 +00:00
asfernandes
b781d62d4a
Make the new BLOB API use void* buffers, so applications can read/write char* strings or any other type without casts.
2011-04-15 18:54:02 +00:00
dimitr
77916f05f7
Fixed possible deadlock between the shutting down engine and the running service. Reported by RedSoft.
2011-04-15 16:37:31 +00:00
asfernandes
c63493ffba
Added metadata support to IStatement.
2011-04-14 01:03:43 +00:00
alexpeshkoff
437d841cfa
Rolled back my commit using IBlrMessage interface. Replaced with single plain structure FbMessage.
2011-04-13 12:41:40 +00:00
alexpeshkoff
e58f56c12f
Fixed memory leak - thanks to Adriano
2011-04-11 11:22:03 +00:00
asfernandes
04bb4ba305
Remove unused parameter and rename a constant.
2011-04-09 20:00:00 +00:00
alexpeshkoff
9a4689d3e9
Use interface IBlrMessage instead passing C++ class pointer to API interface's functions
2011-04-08 16:43:05 +00:00
alexpeshkoff
4c3f87d6bd
Continued renaming interfaces. Added comments
2011-04-08 15:18:50 +00:00
alexpeshkoff
5c88e478f6
Use better names for a number of objects according to Vlad's suggestion
2011-04-07 17:16:00 +00:00
asfernandes
03ce334e2b
Misc
2011-04-04 13:37:47 +00:00
asfernandes
20bfe736bb
New YValve implementation.
2011-04-02 19:38:50 +00:00
robocop
37db77d1ea
Misc, style, etc.
2011-04-02 04:47:22 +00:00
alexpeshkoff
9ef53b65e0
Remove reference counting where not appropriate
2011-03-31 13:44:22 +00:00
hvlad
d49336c110
Fixed bug CORE-3419 : Recurse leads to hangs/crash server
...
The rollback() and a friends should be reconsidered when (if) multy-db transactions will be possible to start at engine (i.e. not at y-valve) level.
2011-03-31 09:41:38 +00:00
asfernandes
166c41c5b1
Move transactRequest, createBlob, openBlob, getSlice, putSlice and ddl from ITransaction to IAttachment.
...
It's better to have one standard than two, and "ddl" was broken from API POV.
So make the IAttachment always the caller, explicit or implicit (via IStatement or IRequest), and pass the ITransaction as parameter.
2011-03-21 21:56:47 +00:00
asfernandes
c863db6e6d
Removed commented out Sqlda support and rename methods removing the word 'messsage'.
2011-03-20 19:15:55 +00:00
asfernandes
34fd6866bc
Remove unused message types.
2011-03-20 19:15:13 +00:00
asfernandes
2ce201f4ae
Use MessageBuffer in executeMessage and fetchMessage.
2011-03-20 19:14:03 +00:00
alexpeshkoff
f6914b8db0
Added timer-related interfaces. Added helper method to wait for plugin to be released on shutdown. Misc stability changes in PluginManager.
2011-03-16 11:04:04 +00:00
asfernandes
146448b877
Misc
2011-03-06 01:06:36 +00:00
alexpeshkoff
7c8bacb692
Detect forced unload of plugin by OS when process is exited
2011-03-04 15:49:37 +00:00
alexpeshkoff
0a7c3fc69d
Fixed CORE-3369: first step to make it possible to specify non-default security database for specific database
2011-03-02 13:42:56 +00:00
dimitr
86ea2ddb00
Front ported:
...
Refactored the shared counter to support multiple number spaces.
Changed att_id and tra_id to be generated sequentially (without caching), as agreed with Vlad privately.
Fixed CORE-2305: Make mon$statement_id value constant among monitoring snapshots.
2011-02-15 07:16:57 +00:00
asfernandes
7800060e22
Misc
2011-02-04 23:58:10 +00:00
hvlad
12ada43e38
Front ported improvement CORE-3323 : Ability to cancel waiting in lock manager
...
LM part will be changed to not rely on engine internals.
2011-02-02 11:20:52 +00:00
asfernandes
ccaaca7c72
Misc
2011-01-29 17:24:29 +00:00
dimitr
e0f5a68da0
More work on enlarging the message buffers. To be continued.
2011-01-28 18:50:27 +00:00
dimitr
fcf42108da
Refactoring. Mostly short->long replacements for various buffer sizes.
2011-01-28 17:12:22 +00:00
asfernandes
248ddfa04a
Misc
2011-01-28 00:58:32 +00:00
alexpeshkoff
742b308173
Avoid to early shutdown of engine
2011-01-26 18:06:01 +00:00
alexpeshkoff
eb11598570
Implement Thread::kill for posex threads. Do not support separate Thread::closeHandle - move it inside kill and waitForCompletion
2011-01-24 16:36:29 +00:00
hvlad
1e6135ec40
Fixed main reason of AV at engine DLL unload time. More fixes will follow soon.
2011-01-24 13:20:25 +00:00
hvlad
dca44e309d
Make it compiles on Windows after Alex's changes. MSVC10 build will follow later.
2011-01-24 12:51:32 +00:00
alexpeshkoff
ddaddccb97
Fixed bug, found by Adriano - destructor of statically allocated factory should better never be called
2011-01-17 12:17:24 +00:00
asfernandes
233093cee4
Misc
2011-01-16 02:16:15 +00:00
alexpeshkoff
d6fcde387b
New plugin manager. Use it for all types of plugins.
2011-01-14 17:31:40 +00:00
asfernandes
9c42d4e5af
Finish the statements refactor in the engine. Get rid of jrd_nod.
2010-12-04 22:15:03 +00:00
alexpeshkoff
49a677b1fd
cleanup
2010-11-19 17:32:21 +00:00
dimitr
8573d02653
Correction.
2010-11-08 09:23:40 +00:00
dimitr
cc1c1e8b20
Fixed CORE-3218: Statement cancellation request might be silently ignored by the currently running SQL code.
2010-11-08 09:16:50 +00:00
alexpeshkoff
0ab6c4abf7
Avoid throwing C++ exceptions from authentication plugins
2010-10-28 08:02:42 +00:00
alexpeshkoff
3afd884f5b
Temporal quickfix for working engine shutdown
2010-10-14 11:13:29 +00:00