Skip to content

Instantly share code, notes, and snippets.

@turing85
turing85 / gist:2197eee7e16045a136acc19e0d99bd25
Created July 14, 2024 09:20
log4j2 json configuration for citrus
name=Log4j2PropertiesConfig
status=info
property.LOG_DATEFORMAT_PATTERN=yyyy-MM-dd HH:mm:ss.SSS
property.CONSOLE_LOG_PATTERN=%d{${sys:LOG_DATEFORMAT_PATTERN}} %highlight{%5p} --- [%15.15t] %-40.40c{1.} : %msg%n%throwable
property.FILE_LOG_PATTERN=%d{${sys:LOG_DATEFORMAT_PATTERN}} %5p --- [%15.15t] %-40.40c{1.} : %msg%n%throwable
appender.console.type=Console
#appender.console.layout.pattern=${sys:CONSOLE_LOG_PATTERN}
#appender.console.layout.type=PatternLayout
2024-07-14T11:17:03+02:00 {"timeMillis":1720948623283,"thread":"Thread-0","level":"INFO","loggerName":"org.eclipse.jetty.util.log","message":"Logging initialized @708ms to org.eclipse.jetty.util.log.Slf4jLog","endOfBatch":false,"loggerFqcn":"org.eclipse.jetty.util.log.Slf4jLog","threadId":19,"threadPriority":5}
2024-07-14T11:17:03+02:00 {"timeMillis":1720948623426,"thread":"Thread-0","level":"WARN","loggerName":"org.eclipse.jetty.server.AbstractConnector","message":"Ignoring deprecated socket close linger time","endOfBatch":false,"loggerFqcn":"org.eclipse.jetty.util.log.Slf4jLog","threadId":19,"threadPriority":5}
2024-07-14T11:17:03+02:00 {"timeMillis":1720948623432,"thread":"Thread-0","level":"INFO","loggerName":"spark.embeddedserver.jetty.EmbeddedJettyServer","message":"== Spark has ignited ...","endOfBatch":false,"loggerFqcn":"org.apache.logging.slf4j.Log4jLogger","threadId":19,"threadPriority":5}
2024-07-14T11:17:03+02:00 {"timeMillis":1720948623435,"thread":"Thread-0","level":"INFO","loggerName":"spark.e
[ERROR] Failed to execute goal io.quarkus.platform:quarkus-maven-plugin:3.8.1:generate-code-tests (default) on project qr-code-generator: Quarkus code generation phase has failed: Failed to initialize Quarkus Maven context: Failed to load current project at /eXchange/git/my-stuff/my-quarkus-samples/qr-code-generator/./pom.xml: Failed to load project /eXchange/git/my-stuff/my-quarkus-samples/qr-code-generator/./pom.xml -> [Help 1]
org.apache.maven.lifecycle.LifecycleExecutionException: Failed to execute goal io.quarkus.platform:quarkus-maven-plugin:3.8.1:generate-code-tests (default) on project qr-code-generator: Quarkus code generation phase has failed
at org.apache.maven.lifecycle.internal.MojoExecutor.doExecute2 (MojoExecutor.java:333)
at org.apache.maven.lifecycle.internal.MojoExecutor.doExecute (MojoExecutor.java:316)
at org.apache.maven.lifecycle.internal.MojoExecutor.execute (MojoExecutor.java:212)
at org.apache.maven.lifecycle.internal.MojoExecutor.execute (MojoExecutor.java:174)
at
Index: src/test/java/com/rev/testManager/GenericTestManager.java
IDEA additional info:
Subsystem: com.intellij.openapi.diff.impl.patch.CharsetEP
<+>UTF-8
===================================================================
diff --git a/src/test/java/com/rev/testManager/GenericTestManager.java b/src/test/java/com/rev/testManager/GenericTestManager.java
--- a/src/test/java/com/rev/testManager/GenericTestManager.java (revision fdbb02b096ceadcec5cf658d183833d518b51c61)
+++ b/src/test/java/com/rev/testManager/GenericTestManager.java (date 1704418650332)
@@ -44,11 +44,11 @@
JSONObject requestParams = new JSONObject();
package com.example.demo;
import org.junit.jupiter.api.Test;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.boot.test.context.SpringBootTest;
import org.springframework.orm.jpa.AbstractEntityManagerFactoryBean;
import static org.mockito.Mockito.doNothing;
import static org.mockito.Mockito.spy;
@turing85
turing85 / main.rs
Last active December 1, 2023 13:48
reactive leptos-rs
use leptos::{*, html::*};
macro_rules! fa_icon {(
$icon_name: expr) => {
a().attr("class", format!("fa {}", $icon_name))
}
}
macro_rules! menu_item {(
$text: expr,
@turing85
turing85 / main.go
Last active November 13, 2023 22:27
golang fyne example
package main
import (
"fmt"
"time"
"fyne.io/fyne/v2"
"fyne.io/fyne/v2/app"
"fyne.io/fyne/v2/container"
"fyne.io/fyne/v2/data/binding"
@turing85
turing85 / increment.sh
Last active September 22, 2023 22:45
increment versions
function next_release_version() {
local current_version="${1}"
local first_part
first_part=$(echo "${current_version}" | sed -e 's/^\(.*\)\([[:digit:]]\+\)[^\.]*$/\1/g')
local last_digit
last_digit=$(echo "${current_version}" | sed -e 's/^\(.*\)\([[:digit:]]\+\)[^\.]*$/\2/g')
echo "${first_part}$((last_digit+1))"
}
function next_snapshot_version() {
@turing85
turing85 / clean_all_maven_projects.sh
Last active July 11, 2023 18:33
clean all maven projects
#!/usr/bin/env bash
echo "finding all poms"
readarray -t poms < <(find "${1:-${MVN_CLEAN_ROOT}}" -name "pom.xml" || true)
echo "found ${#poms[@]} poms."
echo "deduping poms"
projects_to_clean=()
for pom in "${poms[@]}"
do
@turing85
turing85 / get_and_decode_access_token
Last active July 8, 2023 12:10
Get and decode access token from token endpoint
#!/usr/bin/env bash
set -e
shopt -s inherit_errexit
function die() {
if [[ -n "${1}" ]]
then
>&2 echo "${1}"
fi
exit "${2:-1}"