Ładuję...
photo
zaloguj się i wrzuć coś ciekawego na flakera

wtorek 29 czerwca

aktywność użytkownika
photo
Django/OpenSource Scalability Django is great. No doubst about it. But - sometimes comes the question of scalability, especially in a time-and-budget constrains. Well - the very least we can say is that - our client suddenly decided that he needed about 200 rqs - yes, thats 200 hundred requests per second - and yes, thats 1728.000 requestes per day. Well, no problem in achieveing hath - so far theres no talk about budget. Well, there was, the all-dreaded least-cost-budget-criteria. So, ELCODO team stood up for the chalenge and came up with a few interesting, open-source ideas. First of them was the load balancing - here came the ideas about using vrrp/carp. The only real concern was about the instability of the IPv6 implementation - which was easily resolved through negotiations with the client.
The second issue was of similar scale - a choice between using replications of the MySQL database and using a dedicated MySQL server. The dedicated optione was chosen. So n... Zobacz wpis
  1.  

piątek 28 maja

aktywność użytkownika
photo
brutto:
The more focus on profit, the less good ideas - Social Hallucinations via ahajduk
jednym tchem
youtube.com/...u6XAPnuFjJc&feature=playe... inne wpisy na ten temat Zobacz wpis
  1.  

wtorek 25 maja

aktywność użytkownika
photo
seapomeranian:
mongoengine vs. django-mongokit - Peterbe.com (Peter Bengtsson on Python, Django, Zope, Kung Fu, London and photos) Zobacz wpis
seapomeranian:

mongoengine vs. django-mongokit - Peterbe.com (Peter Bengtsson on Python, Django, Zope, Kung Fu, London and photos)
  1.  
photo
Django: the easiest way to run manage commands in crontab Sometimes there are some management commands I would like to run from crontab at given time or interval. There are some ways when you import setup_environ from Django but there is much simpler solution.
For example - Haystack search index update. Lets do it in one hour interval.
user@server:~$ crontab -l
PYTHONPATH=":/home/www/project/django/lib/python2.5/site-packages"
DJANGO_SETTINGS_MODULE=project.settings
# m h dom mon dow command
0 * * * * /home/www/project/manage.py update_index
So, all you need is to set PYTHONPATH and DJANGO_SETTINGS_MODULE according to your settings. And the trick is that it can be done in crontab.
Note that this was tested on Debian Linux. Zobacz wpis
  1.  

czwartek 6 maja

aktywność użytkownika
photo
Mac OS X: ⌘ + ⇥ and Dock stops working If your Dock stops responding (e.g. cannot click application icon) and you cant switch between applications using ⌘ + ⇥ (Command + Tab) there is an easy way to deal with it without restart.
Just open Activity Monitor (typically ⌘ + ␣), find Dock process and kill process using Quit Process option. Dock should be restared after a second and everything should back to normal. Zobacz wpis
  1.  

środa 28 kwietnia

aktywność użytkownika
photo
Django: how to mark required form field with *? If you want to mark required fields with * or some other text/symbol - dont use some hacks in your python code (Label modify in form class, etc.). Things like that should reside in templates and all you need to do is to apply this:
{% if field.field.required %} <em>*</em>{% endif %}
E.g. form display template:
<form action="." method="post">
{% csrf_token %}
{% for hidden in form.hidden_fields %}
{{ hidden }}
{% endfor %}
<dl>
{% for field in form.visible_fields %}
{% if field.errors %}
<dt> </dt>
<dd>{{ field.errors }}</dd>
{% endif %}
<dt>
{{ field.label_tag }}
{% if field.field.required %} <em>*</em>{% endif %}:
</dt>
<dd>{{ field|safe }}</dd>
{% endfor %}
<dt> </dt>
<dd><input type="submit" value="Submit" /></dd>
</dl>
</form> Zobacz wpis
  1.  

wtorek 13 kwietnia

aktywność użytkownika
photo
We will either find a way, or make one. Hannibal Zobacz wpis
  1.  
pokaż więcejPoczekaj, trwa ładowanie...KONIEC