領先一步
VMware 提供培訓和認證,助您加速進步。
瞭解更多適用於 Amazon Web Services 的 Spring Cloud 是一個社群運營專案。網站是 https://awspring.io/,原始碼倉庫位於 https://github.com/awspring/spring-cloud-aws。
適用於 Amazon Web Services 的 Spring Cloud 簡化了與託管 Amazon Web Services 的整合。它提供了一種便捷的方式,可以使用眾所周知的 Spring 慣用法和 API(例如訊息傳遞或快取 API)與 AWS 提供的服務進行互動。開發人員可以圍繞託管服務構建應用程式,而無需關心基礎設施或維護。
[SQS](http://aws.amazon.com/sqs/) 的 Spring 訊息傳遞 API 實現。
[ElastiCache](http://aws.amazon.com/elasticache/) 的 Spring 快取 API 實現。
基於註解的 [SNS](http://aws.amazon.com/sns/) 終端(HTTP)對映。
透過 [CloudFormation](http://aws.amazon.com/cloudformation/) 堆疊中定義的邏輯名稱訪問資源。
基於 [RDS](http://aws.amazon.com/rds/) 例項的邏輯名稱自動建立 JDBC DataSource。
[S3](http://aws.amazon.com/s3/) 儲存桶的 Ant 風格路徑匹配 ResourceLoader。
@MessageMapping("logicalQueueName")
private void receiveMessage(Person person, @Header("SenderId") String senderId) {
// ...
}
@Controller
@RequestMapping("/sns/receive")
public class SnsEndpointController {
@NotificationMessageMapping
public void receiveNotification(@NotificationMessage String message, @NotificationSubject String subject) {
// ...
}
@NotificationSubscriptionMapping
public void confirmSubscription(NotificationStatus notificationStatus) {
notificationStatus.confirmSubscription();
}
snsTemplate.sendNotification("SnsTopic", "message", "subject");
sqsTemplate.convertAndSend("Queue", new Person("John", "Doe"));