Sunday, May 8, 2011

Can A Woman Get A Hernia




We've discussed this before:
http://emanuelpeg.blogspot.com/2010/09/concurrencia-en-erlang.html
But let's do a review, Erlang is a concurrent programming language and a delivery system that includes a virtual machine and libraries. It was designed in the company Ericsson for distributed applications, fault tolerant, soft-real-time and uninterrupted operation. Provides hot swapping of code so that it can be changed without stopping the system. Originally, it was a proprietary language Erlang from Ericsson, but was licensed as open source software in 1998. The implementation of Ericsson is primarily performed but also includes a HIPE compiler (only supported on some platforms).
Among the major achievements of the platform we note that facebook chat and CouchDB document database.
No doubt one thing that makes it special is how Erlang handles concurrency. Erlang does not handle the competition with thread as we have used C, C + + or Java. Erlang solves programming model CONCURRENT by actors. The actor model of concurrency is a computational model that treats "actors" as the universal primitives of parallel digital computation: in response to a message received, an actor can make local decisions, create more actors, it sends more messages and determine how to respond to the next message received. -module (hello).
-export ([loop / 0]).
loop () -> Receive

%
greets a well-known "known" ->
io: format ("Hello!"),
loop ();
% A stranger, do not greet
_ - >
io: format ("..."),
loop ()
end.

In the first line declare the module and then import the loop function, with which we define an empty function and iterate forever. Receive to receive a message similar to the swich, wait for a message and the callback executes the code structure which corresponds to the message sent and the "_" as the default is in c, c + + or Java. First compile

:

1> c (hello).
{ok}

greeter spawn can be generated with a process, spawn will return the PID of the process, which we will use to send messages.

2> Pid = spawn (fun greeter: loop / 0).
\u0026lt;0.38.0>

Now we are going to send a message:

4> Pid! "Known."
Hello! "Known"

5> Pid! "Pepe".
... "Pepe"

As expected just say hello to acquaintances. Operator ! send messages to an actor from its Pid.

This is a small example of erlang concurrency management. The way it handles the Scala audience was inspired by Erlang.


Pokemon Heart Gold Wpa

URLRewrite




A good practice to publish our restful url formats. Where data from the query are part of the url, this greater acceptance from the user and search engines. For example, my site features the profile of my users, if wishing to be publishing the profile of John the url would be something like:

http://misitio.com/profile/juan

This is more friendly than this:
I think this we all agree. Many times in our java projects can not do this, as the web framework does not. For these cases there URLRewrite, which allows our url rewriting as we want; eye not only be used for restful url but for any change we would like to make our urls.
First download the maven jar or if we add this in the pom.xml






org.tuckey


urlrewritefilter


3.1.0
 


Then we must add the following filter in the web.xml:

UrlRewriteFilter


org.tuckey.web.filters.urlrewrite.UrlRewriteFilter

 


UrlRewriteFilter
/ *


Now we must write a file containing the URLs change, the file must be called urlrewrite.xml:







 

/ profile / ([az] +) $

/ mysite / profile / index.htm? name = $ 1





can see in the file that there is from (the url that the user) and to (the real url of your system) with $ 1 are indicating that the first parameter is the variable in the url destination. This foma
we set our url so they are more beautiful.

leave links:

http://www.tuckey.org/urlrewrite/

http://urlrewritefilter.googlecode.com/svn/trunk/src/doc/manual/3.2/index.html







Friday, May 6, 2011

Skin Repairing At Night

10 schools are added to the program believing is seeing

Since May, the program "believing is seeing" Natura solidarity support to 36 schools because the schools that participated last year, will add 10 new participants. For its part, four new rural schools added to the School Support Programme Solidarity. As usual, the schools receive funding, training and technical assistance to strengthen the quality and sustainability of service-learning projects.


Here the complete list of schools built in 2011:
Program "believing is seeing" : High School No. 304, Pilar, the College's Salle, Gonzalez Catan, the Technical Education School N ° 4 "Jorge Sabato, Florencio Varela, the Provincial Institute of Secondary Education N ° 23 "Lino Enea Spilimbergo" Unquillo, Córdoba, 4-004 School "Mercedes Álvarez de Segura, San Rafael, Mendoza, Fortunato Bonelli High School , San Nicolas, Buenos Aires, the Middle School No. 27 "Heroes of the Falklands", Lomas de Zamora, School No. 44 Enrique Berduc in "Home School Complex Eva Peron, in Paraná, Entre Ríos, the School No. 61 "Juan Galo Lavalle", Rosario, Santa Fe, and finally the Provincial School No. 44 "José Ignacio Gorriti" de Jujuy.