我有两个子项目的graddle配置,当我想要构建项目时,抛出以下错误:
Executing external task 'build'...
:core:compileJava
:core:processResources UP-TO-DATE
:core:classes
:core:jar
:core:startScripts FAILED
FAILURE: Build failed with an exception.
* What went wrong:
A problem was found with the configuration of task ':core:startScripts'.
> No value has been specified for property 'mainClassName'.
Run Code Online (Sandbox Code Playgroud)
我的配置:ROOT - build.gradle:
subprojects {
apply plugin: 'java'
apply plugin: 'application'
group = 'pl.morecraft.dev.morepianer'
repositories {
mavenLocal()
mavenCentral()
}
run {
main = project.getProperty('mainClassName')
}
jar {
manifest {
attributes 'Implementation-Title': project.getProperty('name'),
'Implementation-Version': project.getProperty('version'),
'Main-Class': project.getProperty('mainClassName')
} …Run Code Online (Sandbox Code Playgroud) 目前我正在使用带有一张表的时间刻度数据库(timestamp、device_id、group_id、data jsonb)。我正在考虑切换到 influxdb 因为它具有扩展的可能性。数据大小:约10M行。
数据架构:
按组 ID 分组的所有记录均位于一个设备 ID 下。99% 的情况下,我需要通过设备 ID 或组 ID 以及可选的时间边界来获取所有数据点。无需按给定的 periodid 查询单个测量结果。保留 - 永远(仅根据需要删除)。
对于给定的要求,influxdb 是一个不错的选择吗?如果是这样,如何为此类用例组织存储桶/标签?
事实上,在大多数情况下,我不需要部分和跨设备查询数据,这可能很重要。
我有以下案例:
如何做到这一点?我不想在步骤 5 期间锁定表。步骤 1-4 的行为应类似于“SELECT FOR UPDATE”。下面是我当前的代码。我正在执行的方法是execute()。我通过从不同的应用程序实例执行它来测试它,并检查实例 A 是否能够在实例 B 执行executeJob(job)时对表执行操作。
@Service
@Slf4j
@Transactional
public class JobExecutionService {
private final Environment environment;
private final TestJobRepository testJobRepository;
private final TestJobResultRepository testJobResultRepository;
@Autowired
public JobExecutionService(Environment environment, TestJobRepository testJobRepository, TestJobResultRepository testJobResultRepository) {
this.environment = environment;
this.testJobRepository = testJobRepository;
this.testJobResultRepository = testJobResultRepository;
}
public void execute() {
TestJob job = getJob();
executeJob(job);
finishJob(job);
}
@Transactional
public TestJob getJob() {
TestJob testJob …Run Code Online (Sandbox Code Playgroud) java ×2
gradle ×1
hibernate ×1
influxdb ×1
jpa ×1
postgresql ×1
spring ×1
time-series ×1
timescaledb ×1