{"id":18048057,"url":"https://github.com/ivangfr/spring-kafka-de-serialization-types","last_synced_at":"2025-04-10T09:47:04.679Z","repository":{"id":111328551,"uuid":"169529726","full_name":"ivangfr/spring-kafka-de-serialization-types","owner":"ivangfr","description":"The goal is to play with Spring Kafka. We've implemented 5 examples of producer and consumer services that exchanges messages through Kafka using different types of serialization and approaches.","archived":false,"fork":false,"pushed_at":"2024-12-17T09:53:11.000Z","size":9827,"stargazers_count":18,"open_issues_count":0,"forks_count":10,"subscribers_count":2,"default_branch":"master","last_synced_at":"2025-03-24T08:42:25.371Z","etag":null,"topics":["avro","docker","java","jib","json","kafka","schema-registry","spring-boot","spring-kafka","spring-web-mvc"],"latest_commit_sha":null,"homepage":"","language":"Java","has_issues":true,"has_wiki":null,"has_pages":null,"mirror_url":null,"source_name":null,"license":null,"status":null,"scm":"git","pull_requests_enabled":true,"icon_url":"https://github.com/ivangfr.png","metadata":{"files":{"readme":"README.md","changelog":null,"contributing":null,"funding":".github/FUNDING.yml","license":null,"code_of_conduct":null,"threat_model":null,"audit":null,"citation":null,"codeowners":null,"security":null,"support":null,"governance":null,"roadmap":null,"authors":null,"dei":null,"publiccode":null,"codemeta":null},"funding":{"github":"ivangfr"}},"created_at":"2019-02-07T06:36:59.000Z","updated_at":"2024-12-31T22:28:37.000Z","dependencies_parsed_at":"2024-12-06T22:29:46.537Z","dependency_job_id":"8c779c9e-2fd1-4e43-a292-e2082e81ace5","html_url":"https://github.com/ivangfr/spring-kafka-de-serialization-types","commit_stats":null,"previous_names":[],"tags_count":0,"template":false,"template_full_name":null,"repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/ivangfr%2Fspring-kafka-de-serialization-types","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/ivangfr%2Fspring-kafka-de-serialization-types/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/ivangfr%2Fspring-kafka-de-serialization-types/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/ivangfr%2Fspring-kafka-de-serialization-types/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/ivangfr","download_url":"https://codeload.github.com/ivangfr/spring-kafka-de-serialization-types/tar.gz/refs/heads/master","host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":248196668,"owners_count":21063477,"icon_url":"https://github.com/github.png","version":null,"created_at":"2022-05-30T11:31:42.601Z","updated_at":"2022-07-04T15:15:14.044Z","host_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub","repositories_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories","repository_names_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repository_names","owners_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners"}},"keywords":["avro","docker","java","jib","json","kafka","schema-registry","spring-boot","spring-kafka","spring-web-mvc"],"created_at":"2024-10-30T20:11:06.753Z","updated_at":"2025-04-10T09:47:04.642Z","avatar_url":"https://github.com/ivangfr.png","language":"Java","funding_links":["https://github.com/sponsors/ivangfr"],"categories":[],"sub_categories":[],"readme":"# spring-kafka-de-serialization-types\n\nThe goal of this project is to play with [`Spring for Apache Kafka`](https://docs.spring.io/spring-kafka/reference/index.html). We've implemented 5 examples of `producer` and `consumer` services that exchanges messages through [`Apache Kafka`](https://kafka.apache.org/) using different types of serialization and approaches.\n\n## Proof-of-Concepts \u0026 Articles\n\nOn [ivangfr.github.io](https://ivangfr.github.io), I have compiled my Proof-of-Concepts (PoCs) and articles. You can easily search for the technology you are interested in by using the filter. Who knows, perhaps I have already implemented a PoC or written an article about what you are looking for.\n\n## Examples\n\nThe following examples demonstrate a **producer** that pushes _\"News\"_ messages to a topic in `Kafka` and a **consumer** that listens those messages from `Kafka`.\n\n| Example                                                                                                                                                            | Diagram                                                                |\n|--------------------------------------------------------------------------------------------------------------------------------------------------------------------|------------------------------------------------------------------------|\n| [string-de-serialization](https://github.com/ivangfr/spring-kafka-de-serialization-types/tree/master/string-de-serialization#spring-kafka-de-serialization-types)  | ![project-diagram-samples](documentation/string-de-serialization.jpeg) |\n| [json-de-serialization](https://github.com/ivangfr/spring-kafka-de-serialization-types/tree/master/json-de-serialization#spring-kafka-de-serialization-types)      | ![project-diagram-samples](documentation/json-de-serialization.jpeg)   |\n| [avro-de-serialization](https://github.com/ivangfr/spring-kafka-de-serialization-types/tree/master/avro-de-serialization#spring-kafka-de-serialization-types)      | ![project-diagram-samples](documentation/avro-de-serialization.jpeg)   |\n| [avro-2-de-serialization](https://github.com/ivangfr/spring-kafka-de-serialization-types/tree/master/avro-2-de-serialization#spring-kafka-de-serialization-types)  | ![project-diagram-samples](documentation/avro-2-de-serialization.jpeg) |\n| [avro-3-de-serialization](https://github.com/ivangfr/spring-kafka-de-serialization-types/tree/master/avro-3-de-serialization#spring-kafka-de-serialization-types)  | ![project-diagram-samples](documentation/avro-3-de-serialization.jpeg) |\n\n## Prerequisites\n\n- [`Java 21+`](https://www.oracle.com/java/technologies/downloads/#java21)\n- Some containerization tool [`Docker`](https://www.docker.com), [`Podman`](https://podman.io), etc.\n\n## Start Environment\n\n- Open a terminal and inside the `spring-kafka-de-serialization-types` root folder run:\n  ```\n  docker compose up -d\n  ```\n\n- Wait for Docker containers to be up and running. To check it, run:\n  ```\n  docker ps -a\n  ```\n\n## Useful Links\n\n- **Schema Registry UI**\n\n  `Schema Registry UI` can be accessed at http://localhost:8001\n\n- **Kafka Topics UI**\n\n  `Kafka Topics UI` can be accessed at http://localhost:8085\n\n- **Kafka Manager**\n\n  `Kafka Manager` can be accessed at http://localhost:9000\n\n  _Configuration_\n  - First, you must create a new cluster. Click on `Cluster` (dropdown on the header) and then on `Add Cluster`;\n  - Type the name of your cluster in `Cluster Name` field, for example: `MyCluster`;\n  - Type `zookeeper:2181` in `Cluster Zookeeper Hosts` field;\n  - Enable checkbox `Poll consumer information (Not recommended for large # of consumers if ZK is used for offsets tracking on older Kafka versions)`;\n  - Click on `Save` button at the bottom of the page.\n\n## Shutdown\n\nTo stop and remove docker compose containers, network and volumes, go to a terminal and, inside the `spring-kafka-de-serialization-types` root folder, run the command below:\n```\ndocker compose down -v\n```\n\n## Cleanup\n\nTo remove the Docker created by this project, go to a terminal and, inside the `spring-kafka-de-serialization-types` root folder, run the following script:\n```\n./remove-docker-images.sh all\n```\n\n## References\n\n- https://codenotfound.com/spring-kafka-consumer-producer-example.html\n- https://codenotfound.com/spring-kafka-json-serializer-deserializer-example.html\n- https://codenotfound.com/spring-kafka-apache-avro-serializer-deserializer-example.html","project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fivangfr%2Fspring-kafka-de-serialization-types","html_url":"https://awesome.ecosyste.ms/projects/github.com%2Fivangfr%2Fspring-kafka-de-serialization-types","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fivangfr%2Fspring-kafka-de-serialization-types/lists"}