Hi Vadim,

On 08.01.14 19:50, Vadim Bobrov wrote:
Hi,

I have this leveldb journal problem when playing with the new persistence module. With this simple setup:

class ProcActor extends Processor {

override def receive = {
case Persistent(_, sequenceNr) =>
deleteMessages(sequenceNr)

you must use deleteMessage(sequenceNr, permanent = true) to permanently delete messages from the journal, otherwise only a deletion marker is added to the journal, increasing further disk usage. Please note that LevelDB doesn't immediately physically delete the message but only reduce disk space when running compactions <http://leveldb.googlecode.com/svn/trunk/doc/impl.html>.

If you want to delete a single message you should use deleteMessage instead of deleteMessages. The deleteMessages method deletes all messages up to the specified sequenceNr which is usually a more expensive operation compared to what deleteMessage is doing.

}

}

object Main extends App {

implicit lazy val system = ActorSystem("evsourd", ConfigFactory.load().getConfig("evsourd"))

    val top = system.actorOf(Props[ProcActor], name = "top")

   for(i <- 1 to 1000000)
top ! Persistent(i)

}

why does my leveldb journal directory (default, native leveldb) grows to over 1 Gb within minutes? Aren't all messages are deleted by ProcActor? Also - is there any way to look into what's in the journal?

Thanks
Vadim
--
>>>>>>>>>> Read the docs: http://akka.io/docs/
>>>>>>>>>> Check the FAQ: http://akka.io/faq/
>>>>>>>>>> Search the archives: https://groups.google.com/group/akka-user
---
You received this message because you are subscribed to the Google Groups "Akka User List" group. To unsubscribe from this group and stop receiving emails from it, send an email to akka-user+unsubscr...@googlegroups.com.
To post to this group, send email to akka-user@googlegroups.com.
Visit this group at http://groups.google.com/group/akka-user.
For more options, visit https://groups.google.com/groups/opt_out.

--
Martin Krasser

blog:    http://krasserm.blogspot.com
code:    http://github.com/krasserm
twitter: http://twitter.com/mrt1nz

--
     Read the docs: http://akka.io/docs/
     Check the FAQ: http://akka.io/faq/
     Search the archives: https://groups.google.com/group/akka-user
--- You received this message because you are subscribed to the Google Groups "Akka User List" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to akka-user+unsubscr...@googlegroups.com.
To post to this group, send email to akka-user@googlegroups.com.
Visit this group at http://groups.google.com/group/akka-user.
For more options, visit https://groups.google.com/groups/opt_out.

Reply via email to