Git Product home page Git Product logo

quarkus-xml-json-converter's Introduction

Purpose

An app to read XML from a kafka topic, convert to Json, produce to another kafka topic. Uses Quarkus.

Environment

You need:

  • a Kafka broker running in a place that this application can access it
  • something to write some XML onto the "input" topic.

You can find a suitable environment here, although its far more that needed.

This is a different attempt at implementing this project, but without Kafka Streams.

Building

Build and run a fat Jar

mvn install

The fat Jar is:

target/xmlJsonConverter-1.0-SNAPSHOT-runner.jar

Run the fat jar:

java -Xmx48M -jar target/xmlJsonConverter-1.0-SNAPSHOT-runner.jar

Build and run in Quarkus development mode:

mvn compile quarkus:dev

Build a native executable (Mac)

Ensure that you have Graal VM RC16 (CE is fine!) on the path.

mvn package -Pnative

The native image is:

target/xmlJsonConverter-1.0-SNAPSHOT-runner

Build a linux native executable

./mvnw package -Pnative -Dnative-image.docker-build=true

Build a tiny docker image

docker build -f src/main/docker/Dockerfile.tiny -t sns/quarkus-xml-json-converter-tiny .

Run the tiny image:

docker run -i --rm --network=sns2-system-tests_default -e APP_NAME=linuxXmlToJsonConverter -e MODE=xmlToJson -e KAFKA_BROKER_SERVER=sns2-system-tests_kafka01.internal-service_1 -e KAFKA_BROKER_PORT=9092 -e INPUT_KAFKA_TOPIC=incoming.op.msgs -e OUTPUT_KAFKA_TOPIC=modify.op.msgs sns/quarkus-xml-json-converter-tiny

quarkus-xml-json-converter's People

Contributors

muirandy avatar

Watchers

James Cloos avatar

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    ๐Ÿ–– Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. ๐Ÿ“Š๐Ÿ“ˆ๐ŸŽ‰

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google โค๏ธ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.