Skip to content

Commit

Permalink
Disables storage dictionary data collecting when 'modules.contracts.e…
Browse files Browse the repository at this point in the history
…nabled' config is false.
  • Loading branch information
e.shevchenko committed Oct 17, 2018
1 parent abe3201 commit 3ab4cdd
Show file tree
Hide file tree
Showing 2 changed files with 4 additions and 2 deletions.
2 changes: 1 addition & 1 deletion build.gradle
Original file line number Diff line number Diff line change
Expand Up @@ -108,7 +108,7 @@ dependencies {
exclude group: "org.ethereum", module: "solcJ-all"
}

compile "com.ethercamp:contract-data:1.9.2"
compile "com.ethercamp:contract-data:1.9.3"

compile "org.projectlombok:lombok:1.16.20"
compile "com.maxmind.geoip:geoip-api:1.3.1"
Expand Down
4 changes: 3 additions & 1 deletion src/main/java/com/ethercamp/harmony/config/ModuleConfig.java
Original file line number Diff line number Diff line change
@@ -1,5 +1,6 @@
package com.ethercamp.harmony.config;

import com.ethercamp.contrdata.storage.dictionary.StorageDictionaryVmHook;
import com.ethercamp.harmony.service.ClientMessageService;
import com.ethercamp.harmony.service.ClientMessageServiceDummy;
import com.ethercamp.harmony.service.ClientMessageServiceImpl;
Expand Down Expand Up @@ -149,10 +150,11 @@ DbSource<byte[]> contractSettingsStorage() {
}

@Bean
ContractsService contractsService() {
ContractsService contractsService(StorageDictionaryVmHook vmHook) {
if (props.isContractStorageEnabled()) {
return new ContractsServiceImpl();
} else {
vmHook.disable();
return new DisabledContractService(contractSettingsStorage());
}
}
Expand Down

0 comments on commit 3ab4cdd

Please sign in to comment.