Observable using interval
I am a developer who loves Java, Spring, Quarkus, Micronaut, Open source, Microservices, Cloud
Search for a command to run...
I am a developer who loves Java, Spring, Quarkus, Micronaut, Open source, Microservices, Cloud
No comments yet. Be the first to comment.
Spring AI Tool Calling: From Chatbot to AI Agent with @Tool Your AI is smart. It knows an enormous amount. But it's frozen. It doesn't know what time it is right now. It doesn't know what's on your ca
Spring AI Advisors API Explained Series: Spring AI Complete Course — Lecture 4 of 12Reading Time: 8 minutesLevel: Intermediate Most developers stop at ChatClient. That is enough for demos. It is not
Working with Multiple AI Models in Spring AI Spring AI Complete Course — Lecture 3 of 12Previous: Lecture 2 — ChatClient API | Next: Lecture 4 — Advisors API In production AI applications, you rarel
Spring AI ChatClient API: The Fluent Heart of AI Integration Introduction If you've ever tried integrating AI models into a Java application, you know the pain. HTTP clients, API keys scattered everywhere, vendor-specific SDKs that never quite fit. W...
What is Spring AI? — Why Java Developers Need This in 2026 Every AI tutorial you see is in Python. LangChain, LlamaIndex, OpenAI SDK — all Python. But here's the uncomfortable truth: 80% of enterprise backends run Java. So who's building AI into thos...
Interval are timed observables. They tell to perform an event at regular basis. Intervals will help to perform a task regularly.
Below code is a way to create a Timed interval example.
The demo Interval will keep getting invoked at regular interval of a second. We have added a sleep that that we can see the events getting logged.
Since it is observed computation thread so sleep will help us in seeing the logs.
23-01-20 13:17:53 [main] [INFO ] [c.c.l.rxjava.observers.DemoObserver]- onSubscribe 23-01-20 13:17:54 [RxComputationThreadPool-2] [INFO ] [c.c.l.rxjava.observers.DemoObserver]- onNext -> 0 23-01-20 13:17:55 [RxComputationThreadPool-2] [INFO ] [c.c.l.rxjava.observers.DemoObserver]- onNext -> 1 23-01-20 13:17:56 [RxComputationThreadPool-2] [INFO ] [c.c.l.rxjava.observers.DemoObserver]- onNext -> 2