https://github.com/jakepartusch/spring-boot-protobuf-example
Simple Application to demo the use of Protocol Buffers alongside JSON
https://github.com/jakepartusch/spring-boot-protobuf-example
Last synced: 7 months ago
JSON representation
Simple Application to demo the use of Protocol Buffers alongside JSON
- Host: GitHub
- URL: https://github.com/jakepartusch/spring-boot-protobuf-example
- Owner: JakePartusch
- Created: 2016-04-14T03:30:10.000Z (almost 10 years ago)
- Default Branch: master
- Last Pushed: 2017-11-06T03:00:48.000Z (over 8 years ago)
- Last Synced: 2025-03-23T16:44:02.641Z (11 months ago)
- Language: Java
- Homepage:
- Size: 75.2 KB
- Stars: 8
- Watchers: 3
- Forks: 1
- Open Issues: 0
-
Metadata Files:
- Readme: README.md
Awesome Lists containing this project
README
# spring-boot-protobuf-example
## Usage
```
./gradlew bootRun
```
```
curl http://localhost:8080/person/json
curl http://localhost:8080/person/protoBuf
```
### JSON response
```json
{
"firstName": "Jake",
"lastName": "Partusch",
"emailAddress": "jakepartusch@abc.com",
"homeAddress": "123 Seasame Street",
"phoneNumbers": [
{
"areaCode": 123,
"phoneNumber": 1234567
}
]
}
```
### ProtoBuf response
```protobuf
JakePartuschjakepartusch@abc.com"123 Seasame Street*{��K
```