Skip to content

Commit

Permalink
[#11905] Delete the logic associated with flink.
Browse files Browse the repository at this point in the history
  • Loading branch information
minwoo-jung committed Jan 8, 2025
1 parent 380136a commit ab4731e
Show file tree
Hide file tree
Showing 267 changed files with 5 additions and 21,348 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -50,7 +50,6 @@
"classpath:applicationContext-batch-web-component.xml",

"classpath:job/applicationContext-agentCountJob.xml",
"classpath:job/applicationContext-flinkCheckJob.xml",
"classpath:job/applicationContext-cleanupInactiveAgentsJob.xml"
})
@Import({
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -77,14 +77,6 @@ public void agentCountJob() {
}
}

public void flinkCheckJob() {
if (batchProperties.isFlinkCheckJobEnable()) {
run("flinkCheckJob", createTimeParameter());
} else {
logger.debug("Skip flinkCheckJob, because 'enableFlinkCheckJob' is disabled.");
}
}

public void cleanupInactiveAgentsJob() {
if (batchProperties.isCleanupInactiveAgentsJobEnable()) {
run("cleanupInactiveAgentsJob", createTimeParameter());
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -37,12 +37,6 @@ public class BatchProperties {
@Value("${batch.server.env}")
private String batchEnv;

@Value("${batch.flink.server}")
private String[] flinkServerList = new String[0];

@Value("${batch.flink.rest.port:8081}")
private int flinkRestPort;

@Value("${job.alarm.enable:true}")
private boolean alarmJobEnable;

Expand All @@ -64,12 +58,6 @@ public class BatchProperties {
@Value("${job.agent.count.cron}")
private String agentCountJobCron;

@Value("${job.flink.check.enable:true}")
private boolean flinkCheckJobEnable;

@Value("${job.flink.check.cron}")
private String flinkCheckJobCron;

@Value("${job.cleanup.inactive.agents.enable:true}")
private boolean cleanupInactiveAgentsJobEnable;

Expand Down Expand Up @@ -119,14 +107,6 @@ private void afterLog() {
annotationVisitor.visit(this, new LoggingEvent(this.logger));
}

public List<String> getFlinkServerList() {
return Arrays.asList(flinkServerList);
}

public int getFlinkRestPort() {
return flinkRestPort;
}

public String getBatchEnv() {
return batchEnv;
}
Expand Down Expand Up @@ -159,17 +139,10 @@ public String getAgentCountJobCron() {
return agentCountJobCron;
}

public boolean isFlinkCheckJobEnable() {
return flinkCheckJobEnable;
}

public String getFlinkCheckJobCron() {
return flinkCheckJobCron;
}

public String getUriStatAlarmJobCron() {
return uriStatAlarmJobCron;
}

public int getCleanupInactiveAgentsDurationDays() {
return cleanupInactiveAgentsDurationDays;
}
Expand Down Expand Up @@ -202,17 +175,13 @@ public int getAgentInspectorStatTablePaddingLength() {
public String toString() {
return "BatchProperties{" +
"batchEnv='" + batchEnv + '\'' +
", flinkServerList=" + Arrays.toString(flinkServerList) +
", flinkRestPort=" + flinkRestPort +
", alarmJobEnable=" + alarmJobEnable +
", alarmJobCron='" + alarmJobCron + '\'' +
", alarmAgentInspectorStatTableCount=" + alarmAgentInspectorStatTableCount +
", agentInspectorStatTablePrefix='" + agentInspectorStatTablePrefix + '\'' +
", agentInspectorStatTablePaddingLength=" + agentInspectorStatTablePaddingLength +
", agentCountJobEnable=" + agentCountJobEnable +
", agentCountJobCron='" + agentCountJobCron + '\'' +
", flinkCheckJobEnable=" + flinkCheckJobEnable +
", flinkCheckJobCron='" + flinkCheckJobCron + '\'' +
", cleanupInactiveAgentsJobEnable=" + cleanupInactiveAgentsJobEnable +
", cleanupInactiveAgentsJobCron='" + cleanupInactiveAgentsJobCron + '\'' +
", uriStatAlarmJobEnable=" + uriStatAlarmJobEnable +
Expand Down

This file was deleted.

7 changes: 0 additions & 7 deletions batch/src/main/resources/batch-root.properties
Original file line number Diff line number Diff line change
Expand Up @@ -20,10 +20,6 @@ spring.mail.properties.mail.smtp.ssl.enable=false
# webhook config
webhook.enable=false

#flink server list
batch.flink.server=
batch.flink.rest.port=8081

###########################################################
# batch job config #
###########################################################
Expand All @@ -35,8 +31,6 @@ job.alarm.agent.inspector.stat.table.padding.length=2

job.agent.count.cron=0 0 2 * * *

job.flink.check.cron=0 0/10 * * * *

job.alarm.uristat.enable=false
job.alarm.uristat.cron=0 2/3 * * * *

Expand Down Expand Up @@ -67,7 +61,6 @@ pinpoint.banner.configs=batch.server.env,\
spring.datasource.hikari.jdbc-url,\
spring.meta-datasource.hikari.jdbc-url,\
spring.pinot-datasource.pinot.jdbc-url,\
batch.flink.server,\
job.cleanup.inactive.agents,\
job.cleanup.inactive.agents.cron,\
pinpoint.zookeeper.address,\
Expand Down
19 changes: 0 additions & 19 deletions batch/src/main/resources/job/applicationContext-flinkCheckJob.xml

This file was deleted.

Original file line number Diff line number Diff line change
Expand Up @@ -31,22 +31,14 @@
/**
* @author Woonduk Kang(emeroad)
*/
@TestPropertySource(locations = "classpath:batch-root.properties",
properties = {"batch.flink.server=1,2"})
@TestPropertySource(locations = "classpath:batch-root.properties")
@ContextConfiguration(classes = BatchProperties.class)
@ExtendWith(SpringExtension.class)
public class BatchPropertiesTest {

@Autowired
BatchProperties properties;

@Test
public void test() {
assertThat(properties)
.extracting(BatchProperties::getBatchEnv, BatchProperties::getFlinkServerList)
.containsExactly("release", List.of("1", "2"));
}

@Test
public void cleanupInactiveAgentsConfigurationTest() {
properties.setup();
Expand Down

This file was deleted.

Original file line number Diff line number Diff line change
Expand Up @@ -4,7 +4,6 @@
import com.navercorp.pinpoint.collector.config.ClusterModule;
import com.navercorp.pinpoint.collector.config.CollectorCommonConfiguration;
import com.navercorp.pinpoint.collector.config.CollectorConfiguration;
import com.navercorp.pinpoint.collector.config.FlinkContextModule;
import com.navercorp.pinpoint.collector.grpc.CollectorGrpcConfiguration;
import com.navercorp.pinpoint.collector.grpc.ssl.GrpcSslModule;
import com.navercorp.pinpoint.collector.manage.CollectorAdminConfiguration;
Expand All @@ -26,7 +25,6 @@

TypeLoaderConfiguration.class,

FlinkContextModule.class,
CollectorConfiguration.class,
CollectorHbaseModule.class,

Expand Down
Loading

0 comments on commit ab4731e

Please sign in to comment.