Skip to content

Instantly share code, notes, and snippets.

Avatar
🏠
Working from home

Batuhan Bayrakci baybatu

🏠
Working from home
View GitHub Profile
@baybatu
baybatu / logback-graylog-spark-integration.md
Last active Feb 24, 2021
Logback - Graylog (GELF) integration on Apache Spark
View logback-graylog-spark-integration.md

Assuming SPARK_HOME=/spark246

  • Put logback.xml into $SPARK_HOME/conf
  • Create additionaljars directory under $SPARK_HOME
  • Download required logback and logback-gelf related jars into additionaljars directory
    • log4j-over-slf4j-1.7.30.jar
    • logback-core-1.2.3.jar
    • logback-classic-1.2.3.jar
    • logback-gelf-2.2.0.jar
  • Tell Spark to use custom jar folder additionaljars as primarily classpath folder using following spark-submit parameters:
@baybatu
baybatu / cocoapods-publish-commands.md
Last active Jan 29, 2021
cocoapods pod publish commands
View cocoapods-publish-commands.md
git tag VERSION
git push origin tag VERSION
pod trunk push
@baybatu
baybatu / sound-restart.sh
Created Jan 14, 2021
restart sound nanesi on macos
View sound-restart.sh
#!/bin/bash
sudo kill -9 `ps ax|grep 'coreaudio[a-z]' | awk '{print $1}'
@baybatu
baybatu / mjml-responsive-mails.md
Created Dec 25, 2020
MJML : Markup language for responsive mails
View mjml-responsive-mails.md
@baybatu
baybatu / finagle-http2-frame-logger.md
Last active Dec 24, 2020
Log http2 frames on a finagle service
View finagle-http2-frame-logger.md
import com.twitter.finagle.http2.param.FrameLoggerNamePrefix
val service =
        Http
          .client
          .withLabel("service-label")
          .configured(FrameLoggerNamePrefix(this.getClass.getName))
          .withHttp2
          .newService("localhost:8080")
@baybatu
baybatu / docker-overwrite-entrypoint.md
Last active Dec 17, 2020
Run command in a docker container without running entrypoint
View docker-overwrite-entrypoint.md
@baybatu
baybatu / log4j2-logstash-flink-configuration.md
Last active Dec 25, 2020
log4j2 example logstash configuration for flink 1.11
View log4j2-logstash-flink-configuration.md
@baybatu
baybatu / get-huawei-oauth2-token.md
Last active Dec 8, 2020
Get Huawei oauth2 token
View get-huawei-oauth2-token.md
curl --location --request POST 'https://oauth-login.cloud.huawei.com/oauth2/v3/token' \
  --header 'Content-Type: application/x-www-form-urlencoded' \
  --data-urlencode 'grant_type=client_credentials' \
  --data-urlencode 'client_secret=CLIENT_SECRET' \
  --data-urlencode 'client_id=CLIENT_ID'

CLIENT_SECRET: 'App Secret' field on Huawei UI

@baybatu
baybatu / parse-iso8601-format-bigquery.md
Created Nov 27, 2020
Parse ISO8601 format in BigQuery
View parse-iso8601-format-bigquery.md