- Notifications
You must be signed in to change notification settings - Fork19
salamer/jolla
Folders and files
Name | Name | Last commit message | Last commit date | |
---|---|---|---|---|
Repository files navigation
jolla is a pure API server framework,and it is based on the gevent.
When I wrote Jolla,what I want to do is a high performance API server for you to simply obey its short rule,and get your calculation result fast be sent to browser or mobile for your service.so I made Jolla as simple as possible.
Hope you guys like it.
pip install jolla
wanna know more,please clickread more
the Tutorial and documentation is中文版English edition
create aapp.py
,and write dowm:
from jolla import server,render,render_jsondef index(request): return render('index.html')def data(request): data = {'data': request['id']} return render_json(data)class app(server.WebApp): urls = [ (r'/', index), (r'/data/<id>', data), ]if __name__ == '__main__': server = server.jolla_server(app) server.run_server()
and then,run:
python app.py
and open thehttp://127.0.0.1:8000 on your browser
you will see the magic happen!
Copyright © 2016 by Aljun
Under Apache license :http://www.apache.org/licenses/