Los mejores AddOns Firefox

January 21st, 2010 No comments

Fission, es un complemento a FireFox que simula la carga o barra de estado detras de la barra de direcciones, estilo Safari de la MAC, seguir el link

Omnibar, este complemento com bina la barra de busqueda con la de direcciones, simulando el mejor estilo del navegador Chrome, seguir el link.

SociBook del.icio.us Digg Facebook Google Yahoo Buzz StumbleUpon
Categories: FireFox Tags: , ,

AjaxLoading, AjaxState image loading… , processing

January 20th, 2010 No comments

Para entender como capturar el estado de las peticiones en Ajax y agregar una imagen tipo: cargando….

http://www.javabeat.net/tips/89-use-a4jstatus-to-display-status-of-the-reque.html

SociBook del.icio.us Digg Facebook Google Yahoo Buzz StumbleUpon

Eventos Richfaces

October 15th, 2009 No comments

Componentes Richfaces, marcados con el atributo ‘event’:

<a4j:support event=”onviewactivated” reRender=”ciudadNacimientoDecorate” id=”c169″  ajaxSingle=”true”/>

<rich:contextMenu event=”oncontextmenu” attachTo=”pic” submitMode=”none”>

<a4j:support event=”onlistchanged” reRender=”toolBar” />

<rich:componentControl event=”onRowClick” for=”menu” operation=”show”

SociBook del.icio.us Digg Facebook Google Yahoo Buzz StumbleUpon

MySQL, configuracion caracteres especiales

August 28th, 2009 1 comment

Esta configuracion es necesaria en modo local para evitar que los acentos y otros caracteres no se desplieguen de forma equivocada.

Configurar char set de MySQL

Configurar char set de MySQL

/etc/mysql/my.cnf

[client]
default-character-set = utf8

[mysqld]
skip-character-set-client-handshake
default-character-set = utf8
character-set-server = utf8
collation-server = utf8_general_ci
init-connect = SET NAMES utf8

[mysqldump]
default-character-set = utf8

[mysql]
default-character-set = utf8

Verificar:

mysql> shwo variables like 'char%';
+--------------------------+----------------------------+
| Variable_name            | Value                      |
+--------------------------+----------------------------+
| character_set_client     | utf8                       |
| character_set_connection | utf8                       |
| character_set_database   | latin1                     |
| character_set_filesystem | binary                     |
| character_set_results    | utf8                       |
| character_set_server     | utf8                       |
| character_set_system     | utf8                       |
| character_sets_dir       | /usr/share/mysql/charsets/ |
+--------------------------+----------------------------+

#Then set charset
mysql>set character_set_database=utf8
mysql> show variables like 'char%';
+--------------------------+----------------------------+
| Variable_name            | Value                      |
+--------------------------+----------------------------+
| character_set_client     | utf8                       |
| character_set_connection | utf8                       |
| character_set_database   | utf8                       |
| character_set_filesystem | binary                     |
| character_set_results    | utf8                       |
| character_set_server     | utf8                       |
| character_set_system     | utf8                       |
| character_sets_dir       | /usr/share/mysql/charsets/ |
+--------------------------+----------------------------+
SociBook del.icio.us Digg Facebook Google Yahoo Buzz StumbleUpon

Configuracion Netbeans para manejo de menoria y evitar PermGen

August 11th, 2009 No comments

Para evitar permgen y que el IDE ralentezca, cambiar el archivo:

HOME/netbeans6.7/etc/netbeans.conf  la linea siguiente:

netbeans_default_options=” -J-Dcom.sun.aas.installRoot=\”/home/nicolai/Apps/SUNWappserver\” -J-client -J-Xss2m -J-Xms64m -J-Xmx786m -J-XX:PermSize=64m -J-XX:MaxPermSize=300m -J-Xverify:none -J-Dapple.laf.useScreenMenuBar=true -J-Dsun.java2d.noddraw=true -J-XX:+UseConcMarkSweepGC -J-XX:+CMSClassUnloadingEnabled -J-XX:+CMSPermGenSweepingEnabled –fontsize 9″

SociBook del.icio.us Digg Facebook Google Yahoo Buzz StumbleUpon

HTMLTree some operations

July 28th, 2009 No comments

Some ops for the HTMLTree

public HtmlTree getLineaEstructuraRepresentante () {
if (lineaEstructuraRepresentante == null) {
TreeNodeImpl a1 = new TreeNodeImpl();
a1.setData(new LineaEstructura());
TreeNodeImpl aa = new TreeNodeImpl();
TreeNodeImpl raiz = new TreeNodeImpl();
raiz.addChild(“1″, a1);
aa.setData(new LineaEstructura());
TreeNodeImpl bb = new TreeNodeImpl();
lineaEstructuraRepresentante = new HtmlTree();
lineaEstructuraRepresentante.setSwitchType(“client”);
lineaEstructuraRepresentante.setValue(raiz);
lineaEstructuraRepresentante.setVar(“item”);
HtmlTreeNode htmlTreeNode = new HtmlTreeNode();
HtmlOutputText htmlOutputText = new HtmlOutputText();
htmlOutputText.setValueExpression(“value”,
getFacesContext().getApplication().getExpressionFactory().createValueExpression
(
getFacesContext().getELContext(), “#{item.codigo}”, String.class));
htmlTreeNode.getChildren().add(htmlOutputText);
lineaEstructuraRepresentante.getChildren().add(htmlTreeNode);

htmlOutputText.setValueExpression(“value”,
getFacesContext().getApplication().getExpressionFactory().createValueExpression
(
getFacesContext().getELContext(), “#{item.nombre}”, String.class));

htmlTreeNode.getChildren().add(htmlOutputText);
lineaEstructuraRepresentante.getChildren().add(htmlTreeNode);
htmlOutputText.setValueExpression(“value”,
getFacesContext().getApplication().getExpressionFactory().createValueExpression
(
getFacesContext().getELContext(), “#{item.totalGrupo}”, String.class));
htmlTreeNode.getChildren().add(htmlOutputText);
lineaEstructuraRepresentante.getChildren().add(htmlTreeNode);

htmlTreeNode.getChildren().add(htmlOutputText);
lineaEstructuraRepresentante.getChildren().add(htmlTreeNode);
htmlOutputText.setValueExpression(“value”,
getFacesContext().getApplication().getExpressionFactory().createValueExpression
(
getFacesContext().getELContext(), “#{item.textoTotal}”, String.class));
htmlTreeNode.getChildren().add(htmlOutputText);
lineaEstructuraRepresentante.getChildren().add(htmlTreeNode);

htmlTreeNode.getChildren().add(htmlOutputText);
lineaEstructuraRepresentante.getChildren().add(htmlTreeNode);
htmlOutputText.setValueExpression(“value”,
getFacesContext().getApplication().getExpressionFactory().createValueExpression
(
getFacesContext().getELContext(), “#{item.deCuentaContable}”, CuentaContable.class));
htmlTreeNode.getChildren().add(htmlOutputText);
lineaEstructuraRepresentante.getChildren().add(htmlTreeNode);

htmlTreeNode.getChildren().add(htmlOutputText);
lineaEstructuraRepresentante.getChildren().add(htmlTreeNode);
htmlOutputText.setValueExpression(“value”,
getFacesContext().getApplication().getExpressionFactory().createValueExpression
(
getFacesContext().getELContext(), “#{item.hastaCuentaContable}”, CuentaContable.class));
htmlTreeNode.getChildren().add(htmlOutputText);
lineaEstructuraRepresentante.getChildren().add(htmlTreeNode);

}
return lineaEstructuraRepresentante;
}

SociBook del.icio.us Digg Facebook Google Yahoo Buzz StumbleUpon
Categories: Java, RichFaces, Seam Framework Tags:

NPE (DatabasePersistencePolicy.java:165)

July 13th, 2009 No comments

JBOSS AS 4.2.3.GA

java.lang.NullPointerException at org.jboss.ejb.txtimer.DatabasePersistencePolicy.listTimerHandles(DatabasePersistencePolicy.java:165)

I’ve solved CLEANING UP  the folowing dirs:

jboss/server/default/tmp
jboss/server/default/data
jboss/server/default/work

but there are other issues that can happen, if that’s the case follow:

https://jira.jboss.org/jira/browse/JBPORTAL-1855

http://www.guj.com.br/posts/list/91367.java

http://www.techienuggets.com/Detail?tx=12989

http://markmail.org/message/xqioiwxqrjbkr5hv

http://www.jboss.org/index.html?module=bb&op=viewtopic&p=4100705#4100705

Good Luck!

SociBook del.icio.us Digg Facebook Google Yahoo Buzz StumbleUpon

JBoss AS with Chainsaw

June 30th, 2009 No comments

Para utilizar chainsaw con el Servidor de Aplicaciones JBoss AS, agregue las siguientes lineas al archivo: jboss/server/{server}/conf/jboss-log4j.xml

<appender name=”SOCKET”>
<param name=”remoteHost” value=”localhost”/>
<param name=”port” value=”4445″/>
<param name=”locationInfo” value=”true”/>
</appender>

Y al final del archivo entre los tags <root>

<appender-ref ref=”SOCKET”/>

Con esto ejecuta chainsaw y agrega un reciver (old style) de socket al puerto 4445

SociBook del.icio.us Digg Facebook Google Yahoo Buzz StumbleUpon

PermGen, OutOfMemoryException cuando se implanta (deploy/redeploy) en el Servidor de Aplicacione JBoss?

June 23rd, 2009 No comments

Articulo completo:

http://www.jboss.org/community/wiki/OutOfMemoryExceptionWhenRedeploying

O puedes agregar el siguiente fix a tu archivo run.conf:

$JBOSS_HOME/bin/run.conf

agregar a la linea JAVA_OPTS algo asi, recuerda si existe algo ya escrito dentro de la linea simplemente agregar estas lineas dentro de la comillas:

JAVA_OPTS="-server -Xms128m -Xmx128m"

Por ultimo tambien puedes ver:
http://javahowto.blogspot.com/2006/06/6-common-errors-in-setting-java-heap.html
SociBook del.icio.us Digg Facebook Google Yahoo Buzz StumbleUpon

Seam Framework, FacesMessages enqueued, mensajes no se muestran!

June 22nd, 2009 No comments

FacesMessages no se muestran!

[lifecycle] WARNING: FacesMessage(s) have been enqueued, but may not have been displayed.

Fix: Agrega esta linea a tu codigo dentro de tu XHTML.

<h:messages globalOnly=”true”/>

SociBook del.icio.us Digg Facebook Google Yahoo Buzz StumbleUpon
Rss Feed Tweeter button Facebook button Myspace button Linkedin button Delicious button