Skip to content

Instantly share code, notes, and snippets.

@YoshihitoAso
Created March 8, 2013 00:42
Show Gist options
  • Save YoshihitoAso/5113277 to your computer and use it in GitHub Desktop.
Save YoshihitoAso/5113277 to your computer and use it in GitHub Desktop.
[AWS][SQS]AWS SQSのサンプルプログラム(Spring版)のapplicarionContext
<?xml version="1.0" encoding="UTF-8"?>
<beans xmlns="http://www.springframework.org/schema/beans"
xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
xsi:schemaLocation="http://www.springframework.org/schema/beans http://www.springframework.org/schema/beans/spring-beans.xsd">
<bean id="worker" class="jp.classmethod.sample.spring.start.SpringQueueWorker" />
<bean id="amazonSQSClient" class="com.amazonaws.services.sqs.AmazonSQSClient">
<constructor-arg>
<bean class="com.amazonaws.auth.ClasspathPropertiesFileCredentialsProvider">
<constructor-arg value="aws.properties"/>
</bean>
</constructor-arg>
</bean>
<bean id="javaMailSenderImpl" class="org.springframework.mail.javamail.JavaMailSenderImpl">
<property name="host" value="smtp.example.com" />
<property name="port" value="25" />
<property name="username" value="yoshihito" />
<property name="password" value="p@ssw0rd" />
</bean>
<bean id="templateMessage" class="org.springframework.mail.SimpleMailMessage">
<property name="subject" value="QueueWorker sample"/>
<property name="from" value="yoshihito@example.com"/>
</bean>
</beans>
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment