Skip to content

Instantly share code, notes, and snippets.

Avatar

klg71

  • Mayope Software Services UG (haftungsbeschränkt)
View GitHub Profile
View erm.puml
@startuml
entity TodoList{
Int id
String description
}
entity Entry{
Int id
Int todo_list_id
LocalDateTime dueDate
@klg71
klg71 / deployment.yaml
Last active Jun 4, 2021
Kubernetes Workshop in the MayopeCloud
View deployment.yaml
apiVersion: apps/v1
kind: Deployment
metadata:
name: hello-world
spec:
selector: # These labels have to match those configure under template.metadata.labels
matchLabels:
app: hello-world
template:
metadata:
View gist:1cfe528d23426be11641e62783805577
apiVersion: v1
kind: Pod
metadata:
name: static-web
labels:
role: myrole
spec:
containers:
- name: web
image: nginx
View gist:252b73f71c79509204810b70d1181a5a
apiVersion: apps/v1
kind: Deployment
metadata:
name: dockerdemo
spec:
selector:
matchLabels:
app: dockerdemo
template:
metadata:
View gist:2e11917a8b34ca165449d18bbfd4621f
apiVersion: apps/v1
kind: Deployment
metadata:
name: dockerdemo
spec:
selector:
matchLabels:
app: dockerdemo
template:
metadata:
View gist:6c329a3b5e5d3d59ebab560c6ca798f9
apiVersion: apps/v1
kind: Deployment
metadata:
name: dockerdemo
spec:
selector:
matchLabels:
app: dockerdemo
template:
metadata:
View generic converter
internal class Converter<T : Any>(private val type:Class<T>) : AttributeConverter<List<T>, String> {
private val objectMapper = ObjectMapper()
override fun convertToDatabaseColumn(attribute: List<T>?): String {
TODO("Not yet implemented")
}
override fun convertToEntityAttribute(dbData: String?): List<T> {
return objectMapper.readValue(dbData,
View GrafikMainStart.java
package de.klg71.calculator;
import javax.swing.*;
import java.awt.event.ActionEvent;
import java.awt.event.ActionListener;
public class GrafikMainStart {
public static void main(String... args) {
final GrafikMainStart main = new GrafikMainStart();
View Zeichnung.java
package de.klg71;
import java.awt.*;
public class Zeichnung extends Canvas {
@Override
public void paint(final Graphics g) {
g.fillOval(10, 10, 30, 30);
}
View GrafikMain.java
package de.klg71;
import javax.swing.*;
import java.awt.*;
public class GrafikMain {
public static void main(String... args) {
JFrame frame = new JFrame("My Drawing");
Canvas canvas = new Zeichnung();
canvas.setSize(400, 400);