RSocket Proxy for Prometheus monitoring

- Rename spring-cloud-dataflow-samples/tree/master/micrometer to spring-cloud-dataflow-samples/tree/master/micrometer-samples
 - Rename spring-cloud-dataflow-samples/tree/master/micrometer/tasks to spring-cloud-dataflow-samples/tree/master/micrometer-samples/task-apps
 - Add the apps under spring-cloud-dataflow-samples/tree/master/micrometer/stream-apps
 - Describe or cross-link the description of the new architecture in the root README
 - Add microsite SCDF monitoring links

 Resolves #122
This commit is contained in:
Christian Tzolov
2019-11-02 16:27:08 +01:00
parent 369ecce9ba
commit f8078ed08f
68 changed files with 2287 additions and 1 deletions

View File

@@ -0,0 +1,31 @@
package com.example.demosource;
import java.util.Date;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.boot.SpringApplication;
import org.springframework.boot.autoconfigure.SpringBootApplication;
import org.springframework.cloud.stream.annotation.EnableBinding;
import org.springframework.cloud.stream.messaging.Source;
import org.springframework.messaging.support.MessageBuilder;
import org.springframework.scheduling.annotation.EnableScheduling;
import org.springframework.scheduling.annotation.Scheduled;
@EnableScheduling
@EnableBinding(Source.class)
@SpringBootApplication
public class DemoSourceApplication {
@Autowired
private Source source;
@Scheduled(fixedDelay = 1000)
public void sendGreetingEvents() {
this.source.output().send(MessageBuilder.withPayload("Greeting: " + new Date().toString()).build());
}
public static void main(String[] args) {
SpringApplication.run(DemoSourceApplication.class, args);
}
}

View File

@@ -0,0 +1,17 @@
package com.example.demosource;
import org.junit.Test;
import org.junit.runner.RunWith;
import org.springframework.boot.test.context.SpringBootTest;
import org.springframework.test.context.junit4.SpringRunner;
@RunWith(SpringRunner.class)
@SpringBootTest
public class DemoSourceApplicationTests {
@Test
public void contextLoads() {
}
}