is tornado is the same as django? - django

is tornado is the same as django ?
can I upload tornado project to normal host providers

No. Tornado is a full web server. Django is a web framework that happens to have a web server included that can be used for testing. You will need more than just basic shared hosting to run it, preferably a full VPS.

Probably you will find this article interesting. Note that you cannot really compare Django to Tornado. Like #Ignacio said above they are not the same thing.
The article:
http://5cience.net/blog/tornado-vs-django,4258/
And yes if you can upload tornado project to normal host providers.

Related

Is it reliable to build desktop applications using web frameworks like Django?

Is it reliable to build desktop applications using web frameworks like Django?
The idea is to
build the interface with HTML, CSS, and JavaScript
use Python and Django for backend operations (calculations, storage and databases, etc)
and then run a server locally so that
the interaction with the application is done through the browser
other local devices can access the application by connecting to the device on which the server is running.
If that is possible and yields a reliable experience, then
is the development server that comes with Django enough? If no, what servers are most suitable for our purpose? Is Nginx good for example?
what database should be used? PostgreSQL, MySQL, etc? The app will need to store a large number of entries.
I've never done this, but I can't see why not. You can use the Django REST Framework to create an API that your desktop application can talk to, in exactly the same way as you might with a JavaScript single page app.
But no, you should not use the dev server for production, even in a limited scenario like this. Apache/mod_wsgi or nginx/gunicorn are simple to set up and deploy.
For the database, it makes no difference. The Django core devs prefer postgres, but you should use whatever you are comfortable with.
You are asking for a webApp, so yes you can. Is not use the Django server, instead is very common use nginx for Django, and the best database is postgres for Django.
If you want to pass your project like a desktop app is better use Django server and SQLite for avoid create a new database server.
Database
I find this answer explaining why is postgres better for Django

is it possible to run a django app in a simple hosting?

Hello friends I have one question about django and hostings, is It possible to run a django app in a simple hosting with python support or you must to use a VPS?
I know that php framework like codeigniter,symfony... run in any hosting with php support but I know that django it´s a little special.
Thanks
There are Platform as a Service few hosting providers out there.
Python Anywhere
Heroku
OpenShift
But you cant get it from cPanel like in PHP. Each of them have a very good doccumentation on hosting in their platform. Check them out.

Django, django-socketio and mongodb backend

I have a running django-nonrel application and I would like to add a real time module using web sockets.
I would like to use django-socketio but it seems that gevent (which is used to serve the site) does not work properly with mongodb (link) which is the backend of the Django application.
Does anyone already try to set up django-socketio with mongodb as a backend ?
Dry
I found that using Tornado/Tornadio2 with Django is much easier than the gevent-based alternatives. If you need help setting that up I'd be happy to share my runserver_socketio.py script.

Accessing a django-piston REST API via a django view within the same project

I'm building a small web service. To showcase what the service can do I am going to build a lite-weight interface. I'm having a hard time figuring out how my REST API and regular Django views can play nicely together.
Here's my setup:
Using django-piston to build a simple CRUD REST web service.
Using Django views with httplib2 to GET/POST to/from that web service.
Both are being run from the same Django project (and thus same web server).
Right now I have simple read REST service working in the browser. But when I try to use httplib2 from the Django view the request just hangs.
My questions:
-Am I thinking about this the right way?
-Is there a better way to accomplish this?
-Should my REST web service be a different project (and web server) than my REST interface?
Any help would be greatly appreciated!
Generally, I'd demonstrate an API working via unit tests, rather than live views, but can see how that might not be what you need.
So (in line with akonsu's comment above) if you're experiencing this problem local dev, it's the single threaded devserver that's blocking the API from running while the view is executing.
Have you tried a multi-threaded version of the runserver? Like this one?

Is there an easy way to test SSL protected webpages in Development server, using Django?

I use Django for my website and I want to know whether there is a work around for testing secure pages in Development server. As a temporary workaround, I wont use HTTP to check the webpages in dev server, which I think is not a correct way? What do you think?
You might consider mod_wsgi, since it can be used for development, testing, and deployment. mod_wsgi can be configured to detect any changes to you make to your Python code and automatically restart, same as the development server.
I tend to do most of my development on my local machine, but use an actual reference implementation server for testing. It's running mod_wsgi under apache, with a self-signed certificate. A recent detailed article by Graham Dumpleton is available here:
http://blog.dscpl.com.au/2008/12/using-modwsgi-when-developing-django.html
This looks helpful -- using stunnel to route HTTPS requests to django dev server.
The Django development server is very basic and intended for local testing only. It does not support ssl/https. You'll have to run it using Apache, NGINX, or some other web server that supports SSL in order to test.
You can now use FakeSSLMiddleware