Skip to content

Commit

Permalink
Merge pull request #1 from laboshinl/dev
Browse files Browse the repository at this point in the history
Fix logging level
  • Loading branch information
laboshinl authored Oct 19, 2016
2 parents ce2d2a6 + fd599c8 commit b5ef05e
Show file tree
Hide file tree
Showing 3 changed files with 5 additions and 5 deletions.
2 changes: 1 addition & 1 deletion src/main/scala/ru/laboshinl/tractor/ProcessFileBlock.scala
Original file line number Diff line number Diff line change
Expand Up @@ -11,7 +11,7 @@ class ProcessFileBlock extends Actor with ActorLogging {

override def receive: Actor.Receive = {
case FileBlock(file, start, stop) =>
log.info("ProcessFileBlock received FileBlock {}-{}", start, stop)
log.debug("ProcessFileBlock received FileBlock {}-{}", start, stop)
var packets = List[ReadPacket]()
val rafObj = new RandomAccessFile(file)(ByteConverterLittleEndian)
rafObj.seek(start)
Expand Down
4 changes: 2 additions & 2 deletions src/main/scala/ru/laboshinl/tractor/SendWorkWaitResult.scala
Original file line number Diff line number Diff line change
Expand Up @@ -16,10 +16,10 @@ class SendWorkWaitResult(props: Props) extends Actor with ActorLogging {

override def receive: Receive = {
case m: Iterable[Any] =>
log.info("SendWorkWaitResult received {} {}", m.head.getClass, m.size)
log.debug("SendWorkWaitResult received {} {}", m.head.getClass, m.size)
val recipient = sender()
val listOfFutures = m.map(akka.pattern.ask(worker, _))
log.info("SendWorkWaitResult send to {}", props.actorClass())
log.debug("SendWorkWaitResult send to {}", props.actorClass())
val futureSequence = Future sequence listOfFutures
futureSequence.onSuccess {
case res: List[Any] =>
Expand Down
4 changes: 2 additions & 2 deletions src/main/scala/ru/laboshinl/tractor/SplitWithBs.scala
Original file line number Diff line number Diff line change
Expand Up @@ -9,10 +9,10 @@ class SplitWithBs extends Actor with ActorLogging {

override def receive: Actor.Receive = {
case FileBlock(file, start, stop) =>
log.info("SplitWithBs received {} - {}", start, stop)
log.debug("SplitWithBs received {} - {}", start, stop)
val splits = splitFile(file, start, stop, 30 * 1024 * 1024)
waiter tell(splits, sender())
log.info("SplitWithBs sent {}", splits)
log.debug("SplitWithBs sent {}", splits)
}

private def splitFile(file: File, start: Long, stop: Long, bs: Long): List[FileBlock] = {
Expand Down

0 comments on commit b5ef05e

Please sign in to comment.