Skip to content

Navigation Menu

Sign in
Appearance settings

Search code, repositories, users, issues, pull requests...

Provide feedback

We read every piece of feedback, and take your input very seriously.

Saved searches

Use saved searches to filter your results more quickly

Appearance settings

devatherock/velocity-template-tester

Open more actions menu

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

925 Commits
925 Commits
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 

Repository files navigation

CircleCI Version Coverage Status Quality Gate Lines of Code Docker Image Size

velocity-template-tester

UI/API for testing Apache Velocity templates

API Reference

Refer the swagger spec or the swagger UI

Key parameters:

  • Endpoint: https://velocity-template-tester.onrender.com/api/expandTemplate
  • Request Content-Type: application/json, application/x-yaml
  • Response Content-Type: text/plain

Sample JSON Payload:

{
  "template": "Hello ${user}",
  "parameters": {
    "name": "John Doe"
  }
}

Sample YAML Payload:

template: Hello ${user}
parameters:
  name: John Doe

Usage

Sample command

docker run --rm \
  -p 8080:8080 \
  devatherock/velocity-template-tester:1.0.0

Troubleshooting

Enabling debug logs

  • Set the environment variable LOGGER_LEVELS_ROOT to DEBUG to enable all debug logs - custom and framework
  • Set the environment variable LOGGER_LEVELS_IO_GITHUB_DEVATHEROCK to DEBUG to enable debug logs only in custom code
  • For fine-grained logging control, supply a custom logback.xml file and set the environment variable JAVA_OPTS to -Dlogback.configurationFile=/path/to/custom/logback.xml

JSON logs

To output logs as JSON, set the environment variable JAVA_OPTS to -Dlogback.configurationFile=logback-json.xml. Refer logstash-logback-encoder documentation to customize the field names and formats in the log

Releases

Packages

Used by

Contributors

Languages

Morty Proxy This is a proxified and sanitized view of the page, visit original site.