Browse Source

server: Add the CacheModule which loads the available caches

master
Alexis Hernandez 6 years ago
parent
commit
4c7b05b48d
  1. 11
      server/app/com/xsn/explorer/modules/CacheModule.scala
  2. 1
      server/conf/application.conf

11
server/app/com/xsn/explorer/modules/CacheModule.scala

@ -0,0 +1,11 @@
package com.xsn.explorer.modules
import com.google.inject.AbstractModule
import com.xsn.explorer.cache.BlockHeaderCache
class CacheModule extends AbstractModule {
override def configure(): Unit = {
bind(classOf[BlockHeaderCache]).toInstance(BlockHeaderCache.default)
}
}

1
server/conf/application.conf

@ -47,6 +47,7 @@ synchronizer {
}
play.modules.enabled += "com.xsn.explorer.modules.DataHandlerModule"
play.modules.enabled += "com.xsn.explorer.modules.CacheModule"
play.modules.enabled += "com.xsn.explorer.modules.ConfigModule"
play.modules.enabled += "com.xsn.explorer.modules.ExecutorsModule"
play.modules.enabled += "com.xsn.explorer.modules.PollerSynchronizerModule"

Loading…
Cancel
Save