aMule Forum

Please login or register.

Login with username, password and session length
Advanced search  

News:

We're back! (IN POG FORM)

Author Topic: Handle the hashes file more carefully  (Read 3118 times)

macias

  • Full Member
  • ***
  • Karma: 0
  • Offline Offline
  • Posts: 110
Handle the hashes file more carefully
« on: May 20, 2009, 03:21:47 PM »

I've read already post about saving hashes file on each file hashed:
http://www.amule.org/amule/index.php?topic=1748.0

My problem is similar but worse -- amule crashes and all (!) hashes are gone. I have to rehash even files that are know for years to amule.

So please keep the initial hash file, and temporary hash file, if the temp is closed properly on exit (it is "finished") on next run it will be used as initial. If not, the old initial is used.

Besides that I would really love to see hashes file to be plain text, each file per one line. This way I could control (read) this file using old tools like sed, grep, etc.

Cheers,
Logged

GonoszTopi

  • The current man in charge of most things.
  • Administrator
  • Hero Member
  • *****
  • Karma: 169
  • Offline Offline
  • Posts: 2685
Re: Handle the hashes file more carefully
« Reply #1 on: May 20, 2009, 06:40:57 PM »

Besides that I would really love to see hashes file to be plain text, each file per one line.

No, unless we drop compatibility with eMule. I.e. no.

OTOH if the file is huge now, it would be enourmous as plain text, meaning slower reading/writing it.
Logged
concordia cum veritate

macias

  • Full Member
  • ***
  • Karma: 0
  • Offline Offline
  • Posts: 110
Re: Handle the hashes file more carefully
« Reply #2 on: May 20, 2009, 07:22:06 PM »

Oh, I didn't know of that reason (compatibility).

Anyway, the main wish is of course reliable handling of the file. I think the file rotation would prevent hash loses.
Logged