Jump to content

Fr0sT.Brutal

Members
  • Content Count

    2268
  • Joined

  • Last visited

  • Days Won

    46

Everything posted by Fr0sT.Brutal

  1. Fr0sT.Brutal

    Automatically killing a service when stuck

    F.ex., some corruption in memory manager that happened in bg thread could make the whole app insane. Full control over the whole stack is an utopia; you write code that runs 3rd party code that runs tons of RTL code that runs tons of OS DLL functions that run hardware drivers... And all these levels could cause deadlock. It's frequently better to shut the service down and restart it - with proper logging of course - than just hang waiting for dev to come. Consider it as a network socket that couldn't connect. Just reconnect and things will be OK.
  2. Fr0sT.Brutal

    Migration from BDE paradox to TFDtable or other options

    Well then, probably you have low concurrent queries in fact or a truly brilliant application. Here at work we once had a complex based on Paradox and it was just a Pandora's box of paradoxical bugs. Ten years ago it was changed to Oracle and forgotten like a nightmare. Anyway, the initial question is sort of incorrect. What exactly do you mean by performance? What structure your complex has? How many users, requests, reads/writes etc are expected? These are architectural questions. Implementation-specific questions are related to DB-classes. Usually if you reach the limits of TTable or experience very high memory consumption, it means you have wrong structure ("select * from DAMNBIGTABLE" + TTable + DBGrid with possibility to fetch billions of records). Client app doesn't need too much data. Simple example of low memory consumption: one master table with only ID's and multiple detail tables linked by this ID to master. In every moment client app will have loaded only the list of ID's and details for just a single ID.
  3. Fr0sT.Brutal

    Migration from BDE paradox to TFDtable or other options

    So you suppose everyone is aware of the Paradox performance? Seems it was already dead when I finished school Multiuser with hundreds of tables? On Paradox? You're such a joker!
  4. Fr0sT.Brutal

    Migration from BDE paradox to TFDtable or other options

    You weren't asking for any additional requirements. TTable by definition stores all its fetched data (but it won't fetch ALL records in dataset at once unless you make it to). I'm not aware of any dataset implementation that is able to keep only a part of data besides the most primitive IBSQL that stores just the current record.
  5. Fr0sT.Brutal

    Migration from BDE paradox to TFDtable or other options

    SQLite - lightweight, widely used, open source Zeos - mimics TTable
  6. What perf gain it really brings? My feelings say that allocation cost is much greater than fill cost. Especially because the latter is very well optimized with asm routines using block CPU commands
  7. Fr0sT.Brutal

    Migration from BDE paradox to TFDtable or other options

    Hmm, SQLite+Zeos?
  8. Fr0sT.Brutal

    Delphi's code formatter vs. GExperts' code formatter

    Isn't it a bug as well? b-c-d should go right below a
  9. Honestly I don't think the "private" stuff is important for protecting. It's more like for logical structure, exposed API's and the number of shown items in field list. Private items could be changed freely without care about breaking changes but if someone wants to access them, why not let him do it?
  10. Sure it could be done with any AnsiString. But "RawByteString = type AnsiString($ffff);" so I just manually set the right value. I suppose no conversion is done for this codepage so regardless of the value compiler will set to result, it still will be raw bytes. I really can't understand why wouldn't they name the "any codepage string" type like "CodepagedString" and make RawByteString behave just like its name supposes PS Post #555! ))
  11. Yes, faced the same issue. Despite its name, this type is kinda tricky. I had to use SetCodePage(S, $FFFF, False); in my function where I create variabe of this type.
  12. In every place, to get local one's 1-hour speech, just say "What the hell they did with this country..." 😄
  13. If you only deal with Windows, check out my https://github.com/Fr0sT-Brutal/Delphi_SChannelTLS set of classes that allow to add OS-provided TLS to any communication transport (even SendMessage 🙂 ) . But OTOH I wish Emba adopted curl in the form of obj-s.
  14. It's a big surprise that Trump influences mobile network in EU 😄
  15. That's why hard-coded index should be avoided where possible. @str[1] => Pointer(str) @arr[0] => Pointer(arr) for i := 0 to Length(arr) => for i := Low(arr) to High(arr) / for elem in arr Low and High for strings will also work in modern compilers
  16. Byte array still really lacks useful optimized routines. Annoying thing is that in general the code of such routines could be almost the same (Length, SetLength, indexed access...). I wish RTL had good old pointer-and-length routines as basis so that calling them on string, tbytes or even raw buffer would be equally convenient. Regarding the topic: I'd still use byte strings because they're simple to use and convenient but try to isolate string-specific stuff to routines so that changing them to tbytes would be just a matter of type rename.
  17. Honestly I'm got so used to TortoiseGit that I don't use built-in CSV facilities neither in RAD nor in VSCode. In RAD I've setup several most used commands as external tools (commit, pull, log and command line). I also added these commands to file manager (with Classic start menu app even Windows explorer allows to setup custom commands and place them on toolbar)
  18. Contrary, I first got used to Git and then had to use SVN for committing and it felt sucks.
  19. Fr0sT.Brutal

    Any Known Issues with ZCompressStream?

    Sure. But it could be a bug in RTL's wrapper (there are chances for this because zlib is used much more widely so such a critical bug would've been reported much earlier).
  20. Fr0sT.Brutal

    Any Known Issues with ZCompressStream?

    The core of zlib is borrowed from C sources compiled to obj so you can build your own obj from recent version and try to use them. Anyway I think the problem MUST be reported to QC together with problem files because the issue is critical, it could cause DoS on any Delphi server. 10.3 sources say they use zlib 1.2.11 which seems to be the latest version
  21. Fr0sT.Brutal

    Automatically killing a service when stuck

    From what I've read about these functions, there are always timeouts for close/system shutdown notifications. So OS will do what it intended to regardless of the app's reaction. Yes, this is clear. It's just not clear from description that these functions could help with non-interactive service without any user action.
  22. Fr0sT.Brutal

    Automatically killing a service when stuck

    I've never seen a hang console app that couldn't be closed. And while service of course could hang, the description of these functions always mentioned WER dialog and user clicking a button.
  23. F.ex., C-like langs are full of such constructions that allow such write-only clauses as "while (*p++=*r++)" or "i+++++j" but noone tries to throw them out. Shittycode could be written in any language even in Brainfuck (lol)
  24. Fr0sT.Brutal

    Automatically killing a service when stuck

    AFAIU this mechanism only deals with GUI apps not services and requires user interaction anyway?
  25. Fr0sT.Brutal

    Any Known Issues with ZCompressStream?

    But it uses built-in ZLib anyway.
×