Commit 7fb442b9c36ec12ac165fa743aaf4d4b05be27d4

Authored by Igor Kulikov
Committed by GitHub
2 parents 9db0e5aa 5de0059e

Merge pull request #3703 from YevhenBondarenko/feature/api-usage-state

apiUsageState improvements
@@ -86,13 +86,13 @@ public class ApiUsageStateServiceImpl extends AbstractEntityService implements A @@ -86,13 +86,13 @@ public class ApiUsageStateServiceImpl extends AbstractEntityService implements A
86 TenantProfile tenantProfile = tenantProfileDao.findById(tenantId, tenant.getTenantProfileId().getId()); 86 TenantProfile tenantProfile = tenantProfileDao.findById(tenantId, tenant.getTenantProfileId().getId());
87 TenantProfileConfiguration configuration = tenantProfile.getProfileData().getConfiguration(); 87 TenantProfileConfiguration configuration = tenantProfile.getProfileData().getConfiguration();
88 List<TsKvEntry> apiUsageStates = new ArrayList<>(); 88 List<TsKvEntry> apiUsageStates = new ArrayList<>();
89 - apiUsageStates.add(new BasicTsKvEntry(apiUsageState.getCreatedTime(), 89 + apiUsageStates.add(new BasicTsKvEntry(saved.getCreatedTime(),
90 new StringDataEntry(ApiFeature.TRANSPORT.getApiStateKey(), ApiUsageStateValue.ENABLED.name()))); 90 new StringDataEntry(ApiFeature.TRANSPORT.getApiStateKey(), ApiUsageStateValue.ENABLED.name())));
91 - apiUsageStates.add(new BasicTsKvEntry(apiUsageState.getCreatedTime(), 91 + apiUsageStates.add(new BasicTsKvEntry(saved.getCreatedTime(),
92 new StringDataEntry(ApiFeature.DB.getApiStateKey(), ApiUsageStateValue.ENABLED.name()))); 92 new StringDataEntry(ApiFeature.DB.getApiStateKey(), ApiUsageStateValue.ENABLED.name())));
93 - apiUsageStates.add(new BasicTsKvEntry(apiUsageState.getCreatedTime(), 93 + apiUsageStates.add(new BasicTsKvEntry(saved.getCreatedTime(),
94 new StringDataEntry(ApiFeature.RE.getApiStateKey(), ApiUsageStateValue.ENABLED.name()))); 94 new StringDataEntry(ApiFeature.RE.getApiStateKey(), ApiUsageStateValue.ENABLED.name())));
95 - apiUsageStates.add(new BasicTsKvEntry(apiUsageState.getCreatedTime(), 95 + apiUsageStates.add(new BasicTsKvEntry(saved.getCreatedTime(),
96 new StringDataEntry(ApiFeature.JS.getApiStateKey(), ApiUsageStateValue.ENABLED.name()))); 96 new StringDataEntry(ApiFeature.JS.getApiStateKey(), ApiUsageStateValue.ENABLED.name())));
97 tsService.save(tenantId, saved.getId(), apiUsageStates, 0L); 97 tsService.save(tenantId, saved.getId(), apiUsageStates, 0L);
98 98