Sobes.tech

Java

[naam] vroeg: Vertel me over ELK, Prometheus en de monitoring stack — wat is het, wat heb je gebruikt, waarin ben je het beste?

213

[naam] vroeg: Hoe ontwerp ik het aantal partities voor een nieuwe applicatie met een belasting van 3000 berichten per minuut?

157

[naam] vroeg: Er is een grote tabel met gebeurtenissen/logs in productie, ik moet deze opschonen. Hoe ga je dat precies doen?

147

klasse Taak { private static int teller = 0; public static void main(String[] args) throws Exception { var thread1 = new Thread(() -> verhoog()); var thread2 = new Thread(() -> verhoog()); thread1.start(); thread2.start(); thread1.join(); thread2.join(); System.out.println(teller); } private static void verhoog() { for (int i = 0; i < 5000; i++) { teller++; } } }

147

public static void a(long item) { b(item); System.out.println(item); } public static void b(long item) { c(item); } public static void c(long item) { d(item); } public static void d(long item) { System.out.println(item); item = 20L; // тут }

147

class StackTask { public static void main(String[] args) { a(15); } public static void a(long item) { b(item); } public static void b(long item) { c(item); } public static void c(long item) { d(item); } public static void d(long item) { System.out.println(item); } }

145
/3