This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
package br.com.caelum.estoque.ws.handler; | |
import java.util.Iterator; | |
import java.util.Set; | |
import javax.xml.namespace.QName; | |
import javax.xml.soap.Node; | |
import javax.xml.soap.SOAPEnvelope; | |
import javax.xml.soap.SOAPException; | |
import javax.xml.soap.SOAPHeader; |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
<xsl:stylesheet xmlns:xsl="http://www.w3.org/1999/XSL/Transform" | |
xmlns:soapenv="http://schemas.xmlsoap.org/soap/envelope/" | |
version="1.0"> | |
<xsl:output method="xml" indent="yes"/> | |
<!-- o template abaixo copia o XML inteiro --> | |
<!-- @* - seleciona todos os atributos --> | |
<!-- node() - seleciona todos os nodes --> | |
<xsl:template match="@*|node()"> | |
<xsl:copy> |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
1) https://github.com/leonardocordeiro/palestra-JMS-node | |
2) Precisa ter instalado o node. | |
3) No standalone-full.xml do Wildfly, no elemento <acceptors>: | |
<acceptor name="stomp-acceptor"> | |
<factory-class>org.hornetq.core.remoting.impl.netty.NettyAcceptorFactory</factory-class> | |
<param key="protocol" value="STOMP"/> | |
<param key="port" value="61613"/> | |
</acceptor> |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Obs: http://tinyurl.com/oauth2-github | |
1) Acesse a sua conta no github e registre a aplicacao fj36-livraria, callback é: | |
http://localhost:8088/fj36-livraria/oauth/callback | |
------------------------------ | |
2) Baixe o JAR: | |
http://central.maven.org/maven2/org/scribe/scribe/1.3.5/scribe-1.3.5.jar |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
<!-- adicione abaixo do elemento broker --> | |
<destinationInterceptors> | |
<virtualDestinationInterceptor> | |
<virtualDestinations> | |
<compositeQueue name="COMP.PEDIDOS"> | |
<forwardTo> | |
<filteredDestination selector="formato = 'ebook'" queue="COMP.GERADOR"/> | |
<queue physicalName="COMP.FINANCEIRO" /> | |
<topic physicalName="COMP.NOTIFICACOES" /> | |
</forwardTo> |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
<ejb-jar xmlns="http://java.sun.com/xml/ns/javaee" | |
xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" | |
xsi:schemaLocation="http://java.sun.com/xml/ns/javaee | |
http://java.sun.com/xml/ns/javaee/ejb-jar_3_1.xsd" | |
version="3.1"> | |
<interceptors> | |
<interceptor> | |
<interceptor-class>br.com.caelum.financas.interceptor.LogInterceptor</interceptor-class> | |
</interceptor> |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
<property name="hibernate.connection.provider_class" value="org.hibernate.service.jdbc.connections.internal.C3P0ConnectionProvider"/> | |
<property name="hibernate.c3p0.min_size" value="5" /> | |
<property name="hibernate.c3p0.max_size" value="20" /> | |
<property name="hibernate.c3p0.timeout" value="180" /> | |
<property name="hibernate.c3p0.idle_test_period" value="100" /> |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
package br.com.caelum.camel; | |
import org.apache.camel.CamelContext; | |
import org.apache.camel.Exchange; | |
import org.apache.camel.LoggingLevel; | |
import org.apache.camel.builder.RouteBuilder; | |
import org.apache.camel.impl.DefaultCamelContext; | |
import org.apache.camel.model.dataformat.XmlJsonDataFormat; | |
public class TesteRoteamento { |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
jndi.properties | |
---------------- | |
java.naming.factory.url.pkgs=org.jboss.ejb.client.naming | |
jboss-ejb-client.properties (Usuario deve ser criado antes através do add-user.sh) | |
---------------------------- | |
remote.connectionprovider.create.options.org.xnio.Options.SSL_ENABLED=false |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
package br.com.caelum.threads; | |
public class Banheiro { | |
private boolean sujo = true; | |
public void fazNumero1() { | |
String nomeAluno = Thread.currentThread().getName(); | |
System.out.println(nomeAluno + " tentando entrar no banheiro"); |