2 Star 1 Fork 0

lianzt / sjtp-query

Create your Gitee Account
Explore and code with more than 12 million developers,Free private repositories !:)
Sign up
This repository doesn't specify license. Please pay attention to the specific project description and its upstream code dependency when using it.
Clone or Download
contribute
Sync branch
Cancel
Notice: Creating folder will generate an empty file .keep, because not support in Git
Loading...
README

sjtp-query

Build & Run

$ cd sjtp-query
$ sbt
> jetty:start
> browse

If browse doesn't launch your browser, manually open http://localhost:8080/ in your browser.

部署

scalatra 官网上推荐使用 assembly 打包成一个大的 jar,由于引用jar的依赖jar冲突,导致不能打包或打包后不能运行,由于时间原因没有深入研究。

在开发时程序在 jetty 窗口中可正常运行,因此可得出结果,依赖的jar冲突只影响打包,应该是 assembly 工具的缺陷。

因此可使用外置的 tomcat 或 jetty 来运行程序,以tomcat为便,创建配置文件 conf/Catalina/localhost/sjtp-query.xml,内容如下:

<?xml version="1.0" encoding="UTF-8"?>
<Context antiJARLocking="true" disableURLRewriting="true" docBase="/home/lzt/centos-home/root/workspace/idea/sjtp-query/target/webapp" path="/sjtp-query">
</Context>

需注意这里配置了 path,因此url与开发环境的不一样,访问时需要增加 /sjtp-query 前缀。

也可以把 webapp 目录下的文件删除,并配置 path="/" 来保持url一致。

api

api 文档

Empty file

About

基于 scalatra 框架开发的 rest api 包括 hbase 查询、kafka 接收、websock 推送、 json 格式api expand collapse
Scala
Cancel

Releases

No release

Contributors

All

Activities

Load More
can not load any more
Scala
1
https://gitee.com/lianzt/sjtp-query.git
git@gitee.com:lianzt/sjtp-query.git
lianzt
sjtp-query
sjtp-query
master

Search