full_name
stringlengths 7
70
| description
stringlengths 4
590
⌀ | created_at
stringlengths 20
20
| last_commit
float64 | readme
stringlengths 14
559k
⌀ | label
int64 0
1
|
---|---|---|---|---|---|
bintray/bintray-examples | Examples of resolving and deploying to Bintray.com | 2013-03-25T07:45:57Z | null | bintray-examples
================
Examples of resolving and deploying to Bintray.com
For comments, issues and questions please use the feeback form on Bintray.com
| 1 |
asciidoctor/asciidoctor-maven-examples | A collection of example projects that demonstrates how to use the Asciidoctor Maven plugin. | 2013-12-23T01:55:33Z | null | null | 1 |
spring-framework-guru/sfg-blog-posts | Source code examples for blog posts | 2019-05-09T15:45:23Z | null | [![CircleCI](https://circleci.com/gh/spring-framework-guru/sfg-blog-posts.svg?style=svg)](https://circleci.com/gh/spring-framework-guru/sfg-blog-posts)
# SFG Blog Posts
This repository contains source code examples from various blog posts from [Spring Framework Guru](https://springframework.guru)
Are you interested in writing for Spring Framework Guru? Checkout the [wiki](https://github.com/spring-framework-guru/sfg-blog-posts/wiki) for how to get started!
The blog posts for the examples in this repo are:
- [Service Locator Pattern in Spring](https://springframework.guru/service-locator-pattern-in-spring/)
- [Using GraphQL in a Spring Boot Application](https://springframework.guru/using-graphql-in-a-spring-boot-application/)
- [Spring JdbcTemplate CRUD Operations](https://springframework.guru/spring-jdbctemplate-crud-operations/)
- [Using Spring Aware Interfaces](https://springframework.guru/using-spring-aware-interfaces/)
- [Working with Resources in Spring](https://springframework.guru/working-with-resources-in-spring/)
- [Using RestTemplate in Spring](https://springframework.guru/using-resttemplate-in-spring/)
- [Using RestTemplate with Apaches HttpClient](https://springframework.guru/using-resttemplate-with-apaches-httpclient/)
- [How to Configure Multiple Data Sources in a Spring Boot Application](https://springframework.guru/how-to-configure-multiple-data-sources-in-a-spring-boot-application/)
- [Why you should be using Spring Boot Docker Layers](https://springframework.guru/why-you-should-be-using-spring-boot-docker-layers/)
- [Autowiring In Spring](https://springframework.guru/autowiring-in-spring/)
- [Spring Bean Definition Inheritance](https://springframework.guru/spring-bean-definition-inheritance/)
- [Best Practices for Dependency Injection with Spring](https://springframework.guru/best-practices-for-dependency-injection-with-spring/)
- [Using Project Lombok with Gradle](https://springframework.guru/using-project-lombok-with-gradle/)
- [Spring JdbcTemplate CRUD Operations](https://springframework.guru/spring-jdbctemplate-crud-operations/)
- [How to Configure Multiple Data Sources in a Spring Boot Application](https://springframework.guru/how-to-configure-multiple-data-sources-in-a-spring-boot-application/)
- [Working with Resources in Spring](https://springframework.guru/working-with-resources-in-spring/)
- [Spring Bean Scopes](https://springframework.guru/spring-bean-scopes/)
- [Using Ehcache 3 in Spring Boot](https://springframework.guru/using-ehcache-3-in-spring-boot/)
- [Spring Profiles](https://springframework.guru/spring-profiles/)
- [Using Spring Aware Interfaces](https://springframework.guru/using-spring-aware-interfaces/)
- [Spring Bean Lifecycle](https://springframework.guru/spring-bean-lifecycle/)
- [Spring Boot with Lombok: Part 1](https://springframework.guru/spring-boot-with-lombok-part-1/)
- [Consul Miniseries: Spring Boot Application and Consul Integration Part 1](https://springframework.guru/consul-miniseries-spring-boot-application-and-consul-integration-part-1/)
- [Consul Miniseries: Spring Boot Application and Consul Integration Part 2](https://springframework.guru/consul-miniseries-spring-boot-application-and-consul-integration-part-2/)
- [Consul Miniseries: Spring Boot Application and Consul Integration Part 3](https://springframework.guru/consul-miniseries-spring-boot-application-and-consul-integration-part-3/)
- [Debug your Code in IntelliJ IDEA](https://springframework.guru/debug-your-code-in-intellij-idea/)
- [Java 14 records](https://springframework.guru/java-14-records/)
- [Run Spring Boot on Docker](https://springframework.guru/run-spring-boot-on-docker/)
- [Manage Docker Containers with Docker Compose](https://springframework.guru/manage-docker-containers-with-docker-compose/)
- [Feign REST Client for Spring Application](https://springframework.guru/feign-rest-client-for-spring-application/)
- [Using MapStruct with Project Lombok](https://springframework.guru/using-mapstruct-with-project-lombok/)
- [Writing Parametrized Tests]()
- [Spring REST Docs]()
- [Calling Stored Procedure from Spring Data JPA Repository]()
- [Spring Boot Pagination]()
- [Convert OffsetDateTime to SQLTimeStamp]()
- [Error Handling in Spring REST]()
- [Spring State Machine]()
- [Java Bean Validation]()
- [Stored Procedures with Spring Boot]()
- [BeanFactory vs ApplicationContext]()
- [Multi Module Spring Boot Project]()
- [One to One Association]()
- [One to Many Association]()
- [Actuator in Spring Boot]()
- [Spring Boot CLI]()
- [Spring Boot Internationalization]()
- [Spring Retry]()
- [EnumSet in Java]()
- [Scheduling in Spring Boot]()
- [Spring Boot Kafka]()
- [Bootstrapping Data in Spring Boot]()
- [Using Eureka Service Registry]()
| 1 |
pajikos/java-examples | For more info, check my blog: | 2017-04-24T19:57:06Z | null | # Java examples
Working project examples
| 1 |
GoogleCloudPlatform/cloud-bigtable-examples | Examples of how to use Cloud Bigtable both with GCE map/reduce as well as stand alone applications. | 2014-12-05T12:59:52Z | null | # Google Cloud Bigtable examples
[![Travis CI status][travis-shield]][travis-link]
[![Stack Overflow][stackoverflow-shield]][stackoverflow-link]
Bigger than a data warehouse, fast enough for real-time access, and less expensive than running virtual machines. The world-renowned database that powers Google is now available to you worldwide.
## Overview
[Google Cloud Bigtable](https://cloud.google.com/bigtable/) offers you a fast, fully managed, almost infinitely scalable NoSQL database service that's ideal for web, mobile, and IoT applications requiring terabytes to petabytes of data. Unlike comparable market offerings, Cloud Bigtable doesn't require you to sacrifice speed, scale, or cost efficiency when your applications grow. The Bigtable service that Cloud Bigtable relies upon has been battle-tested at Google for more than 10 years—it's the database driving major applications such as Search, Analytics, Maps and Gmail.
## Quickstart
[Quickstart/HBase](quickstart) - Create a Cloud Bigtable Cluster and the hbase shell from within a docker container on your local machine
## Java
* [Hello World](java/hello-world) - This sample has been migrated to: https://github.com/GoogleCloudPlatform/java-docs-samples/blob/main/bigtable/hbase/snippets/src/main/java/com/example/bigtable/HelloWorld.java
* [Import HBase Sequence files](java/dataflow-import-examples) Import HBase sequence files directly to Cloud Bigtable using Dataflow.
* [Dataproc Wordcount using Map/Reduce](java/dataproc-wordcount) - How to load data to Cloud Bigtable using Dataproc on GCE
* [GAE J8 Std-Hello World](https://github.com/googlecloudplatform/java-docs-samples/tree/master/appengine-java8/bigtable) - Accessing Cloud Bigtable from App Engine standard
## Dataflow
* [Connector-Examples](java/dataflow-connector-examples) - Using the cloud dataflow connector for Bigtable, do write Hello World to two rows, Use Cloud Pub / Sub to count Shakespeare, count the number of rows in a Table, and copy records from BigQuery to BigTable.
* [Pardo-HelloWorld](java/dataflow-pardo-helloworld) - example of using Cloud Dataflow without the connector.
## Go
* [cbt](https://github.com/GoogleCloudPlatform/gcloud-golang/tree/master/bigtable/cmd/cbt) [doc](https://godoc.org/google.golang.org/cloud/bigtable/cmd/cbt) Basic command line interactions with Cloud Bigtable - A really great place to start learning the Go Client.
* [helloworld](https://github.com/GoogleCloudPlatform/golang-samples/tree/master/bigtable/helloworld) - Basic Hello world example application demonstrating how to read and write to a Cloud Bigtable instance.
* [usercounter](https://github.com/GoogleCloudPlatform/golang-samples/tree/master/bigtable/usercounter) - Accessing Cloud Bigtable from App Engine Flexible
* [search](https://github.com/GoogleCloudPlatform/golang-samples/tree/master/bigtable/search) - Create and search a Cloud Bigtable.
## Python
* [Hello
World](https://github.com/GoogleCloudPlatform/python-docs-samples/tree/master/bigtable/hello)
A minimal application that demonstrates using the Googe Cloud Client
libraries to create a temporary table, write some rows, read them back and
clean up.
* [Hello World
(Happybase)](https://github.com/GoogleCloudPlatform/python-docs-samples/tree/master/bigtable/hello_happybase)
A minimal application that demonstrates using the Happybase API create a
temporary table, write some rows, read them back and clean up.
## Questions and discussions
If you have questions or run into issues with Google Cloud Bigtable or the
client libraries, you can use any of the following forums:
* Stack Overflow: tag questions with [`google-cloud-bigtable`][stackoverflow-link]
* Mailing list: [google-cloud-bigtable-discuss@][google-cloud-bigtable-discuss]
You can also subscribe to
[google-cloud-bigtable-announce@][google-cloud-bigtable-announce] list to receive
infrequent product and client library announcements.
## Contributing changes
See [CONTRIBUTING.md](CONTRIBUTING.md) for more information on how to contribute
to this project.
## More examples
More Google Cloud Bigtable examples are available in the following languages:
* [Java](https://github.com/GoogleCloudPlatform/java-docs-samples/tree/master/bigtable)
* [Python](https://github.com/GoogleCloudPlatform/python-docs-samples/tree/master/bigtable)
* [Node](https://github.com/googleapis/nodejs-bigtable/tree/master/samples)
* [Go](https://github.com/GoogleCloudPlatform/golang-samples/tree/master/bigtable)
* [Dotnet](https://github.com/GoogleCloudPlatform/dotnet-docs-samples/tree/master/bigtable/api)
* [C++](https://github.com/googleapis/google-cloud-cpp/tree/master/google/cloud/bigtable/examples)
* [Ruby](https://github.com/GoogleCloudPlatform/ruby-docs-samples/tree/master/bigtable)
* [PHP](https://github.com/GoogleCloudPlatform/php-docs-samples/tree/master/bigtable)
## License
Apache 2.0; see [LICENSE](LICENSE) for details.
<!-- references -->
[travis-shield]: https://travis-ci.org/GoogleCloudPlatform/cloud-bigtable-examples.svg
[travis-link]: https://travis-ci.org/GoogleCloudPlatform/cloud-bigtable-examples/builds
[stackoverflow-shield]: https://img.shields.io/badge/stackoverflow-google--cloud--bigtable-blue.svg
[nodejs-bigtable]: https://github.com/googleapis/nodejs-bigtable
[stackoverflow-link]: http://stackoverflow.com/search?q=[google-cloud-bigtable]
[google-cloud-bigtable-discuss]: https://groups.google.com/group/google-cloud-bigtable-discuss
[google-cloud-bigtable-announce]: https://groups.google.com/group/google-cloud-bigtable-announce
| 1 |
RefactoringGuru/design-patterns-java | Design Pattern Examples in Java | 2017-09-15T12:26:36Z | null | # Design Patterns in Java
This repository is part of the [Refactoring.Guru](https://refactoring.guru/design-patterns) project.
It contains Java examples for all classic GoF design patterns.
## Requirements
The examples were written in Java 8, but also tested in Java 9.
For the best experience, we recommend working with examples in IntelliJ IDEA. The Community Edition of IDE is available for free (https://www.jetbrains.com/idea/download/).
After downloading or cloning this repository to your computer, import its root directory into a New project:
- Either through start dialog: Select "Import Project" option and skip through the rest of the steps.
- Or via the main menu: File > New > Project from Existing Sources...
After importing the project, you will be able to run examples by right-clicking "Demo" files inside every example and selecting the "Run" command from the context menu.
## Roadmap
- [ ] Add detailed comments all classes.
- [ ] Add structure-only examples.
## Contributor's Guide
We appreciate any help, whether it's a simple fix of a typo or a whole new example. Just [make a fork](https://help.github.com/articles/fork-a-repo/), do your change and submit a [pull request](https://help.github.com/articles/creating-a-pull-request-from-a-fork/).
Here's a style guide which might help you to keep your changes consistent with our code:
1. All code should meet the [Google Java Style Guide](https://google.github.io/styleguide/javaguide.html)
2. Try to hard wrap the code at 80th's character. It helps to list the code on the website without scrollbars.
3. Examples should match following package convention: refactoring_guru.{pattern}.{example_name}. Example:
```java
package refactoring_guru.factory_method.ui_example.buttons;
class Button {
...
```
4. Places classes into separate files.
5. Group classes into sub-packages. It helps people to understand dependencies of a class by glancing over its imports. Example:
```java
package refactoring_guru.factory_method.example.buttons;
class Button {
...
```
```java
package refactoring_guru.factory_method.example.factories;
import Button;
class Factory {
...
```
6. Comments may or may not have language tags in them, such as this:
```java
/**
* EN: All products families have the same varieties (MacOS/Windows).
*
* This is a MacOS variant of a button.
*
* RU: Все семейства продуктов имеют одни и те же вариации (MacOS/Windows).
*
* Это вариант кнопки под MacOS.
*/
```
Don't be scared and ignore the non-English part of such comments. If you want to change something in a comment like this, then do it. Even if you do it wrong, we'll tell you how to fix it during the Pull Request.
## License
This work is licensed under a Creative Commons Attribution-NonCommercial-NoDerivatives 4.0 International License.
<a rel="license" href="http://creativecommons.org/licenses/by-nc-nd/4.0/"><img alt="Creative Commons License" style="border-width:0" src="https://i.creativecommons.org/l/by-nc-nd/4.0/80x15.png" /></a>
## Credits
Authors: Bohdan Herashchenko ([@b1ger](https://github.com/b1ger)) and Alexander Shvets ([@neochief](https://github.com/neochief))
| 1 |
joshlong-attic/boot-examples | a repository for convenient Spring Boot examples | 2013-12-16T10:39:28Z | null | boot-examples
=============
a repository for convenient Spring Boot examples
| 1 |
zpng/spring-cloud-microservice-examples | spring-cloud-microservice-examples | 2016-10-28T04:31:24Z | null | # spring-cloud-microservice-examples
spring-cloud-microservice-examples
## 说明
目前该项目实现了 zuul(路由模块), config-server(配置管理), eureka server(服务注册和发现), zipkin(服务调用追踪),hystrix, turbine stream (熔断分析)
simple-service,simple-serviceB两个待发现的服务
simple-ui (一个用angular写的前端页面)
路由功能实现在 cloud-api-gateway 模块,注册到eureka server上面,所有的请求访问 http://localhost:5555, 然后根据路由规则
```
zuul.routes.api-a.path: /cloud-simple-service/**
zuul.routes.api-a.serviceId: cloud-simple-service
zuul.routes.api-b.path: /cloud-simple-serviceB/**
zuul.routes.api-b.serviceId: cloud-simple-serviceB
zuul.routes.api-ui.path: /cloud-simple-ui/**
zuul.routes.api-ui.serviceId: cloud-simple-ui
```
分别请求到 注册到eureka server的cloud-simple-service 和 cloud-simple-serviceB服务。
服务的架构图:
![流程图](https://docs.google.com/drawings/d/1kb_2cLW-KcwhWfmu-iburNTCKKuH7HGUEdQCKCZMgZE/pub?w=960&h=720)
---
## 使用指南
* 先决条件
本机安装rabbitmq,并启动
```
rabbitmq-server
```
本机安装mysql,并启动且创建dev和test数据库,并分别创建表
```
mysql.server start
mysql -uroot
CREATE TABLE `user` (
`id` int(11) NOT NULL,
`username` varchar(255) NOT NULL
) ENGINE=InnoDB DEFAULT CHARSET=utf8
dev数据库的user表中插入数据
INSERT INTO `user` VALUES (1,'dev1'),(2,'dev2'),(3,'dev3');
test数据库的user表中插入数据
INSERT INTO `user` VALUES (1,'test1'),(2,'test2'),(3,'test3');
```
* 运行各模块
```
cd cloud-api-gateway
mvn spring-boot:run #端口5555
cd cloud-config-server
mvn spring-boot:run #端口8888
cd cloud-eureka-server
mvn spring-boot:run #端口8761
cd cloud-simple-service
mvn spring-boot:run #端口8081
cd cloud-simple-service
mvn spring-boot:run --server.port=8082 # cloud-simple-service 以8082端口再次启动服务
cd cloud-simple-ui
mvn spring-boot:run #端口8090
cd cloud-zipkin
mvn spring-boot:run #端口9966
```
* 打开浏览器输入网址并浏览效果
```
查看Eureka Server
http://localhost:8761 #查看eureka
```
![Eureka Server](https://drive.google.com/uc?id=0BxyRSlBgU-ShX1dEdG5YSi10OEE)
---
```
请求simple service, simple service2, simple serviceB
http://localhost:8081/user #simple service
结果:
[
{
id: 1,
username: "dev1"
},
{
id: 2,
username: "dev2"
},
{
id: 3,
username: "dev3"
}
]
http://localhost:8082/user #simple service2
结果:
[
{
id: 1,
username: "dev1"
},
{
id: 2,
username: "dev1"
},
{
id: 3,
username: "dev1"
}
]
http://localhost:8091/user #simple serviceB
结果:
Result from simpleserviceB
```
本项目实现了通过spring-cloud-bus, 传播config-server中config的变化.下面动手验证之.
1. 下载配置git repository
```
git clone git@github.com:zpng/spring-cloud-config-demo.git
```
根目录下有个cloud-config-repo目录,该目录下有两个文件:
cloud-simple-service-dev.properties
cloud-simple-service-test.properties
分别是cloud-simple-service在 dev和test环境下的配置信息
cloud-simple-service-dev.properties内容:
```
mysqldb.datasource.url=jdbc\:mysql\://localhost\:3306/dev?useUnicode\=true&characterEncoding\=utf-8
mysqldb.datasource.username=root
mysqldb.datasource.password=
logging.level.org.springframework.web:DEBUG
```
cloud-simple-service-test.properties内容:
```
mysqldb.datasource.url=jdbc\:mysql\://localhost\:3306/test?useUnicode\=true&characterEncoding\=utf-8
mysqldb.datasource.username=root
mysqldb.datasource.password=
logging.level.org.springframework.web:DEBUG
```
1. 修改 cloud-simple-service-dev.properties 内容,
```
mysql url中使用的dev数据库变为test数据库
mysqldb.datasource.url=jdbc\:mysql\://localhost\:3306/dev?useUnicode\=true&characterEncoding\=utf-8
->
mysqldb.datasource.url=jdbc\:mysql\://localhost\:3306/test?useUnicode\=true&characterEncoding\=utf-8
git add -A
git commit -m "MOD: update config"
git push origin master #将修改push到git repositoy
```
1. 此时并需要重启config-server或者simple-service,只需要发送一个POST请求到config-server,并通过bus传播到使用该配置文件的服务中.
```
curl -X POST http://localhost:8888/bus/refresh #(config-server启动在8888端口)
```
此时刷新前端页面
```
http://localhost:8081/user #simple service
http://localhost:8082/user #simple service2
```
发现数据都已变成:
```
[
{
id: 1,
username: "test1"
},
{
id: 2,
username: "test2"
},
{
id: 3,
username: "test3"
}
]
```
---
1. 验证路由逻辑
cloud-api-gateway服务使用了zuul进行请求转发,转发规则如下:
```
# routes to serviceId
zuul.routes.api-a.path: /cloud-simple-service/**
zuul.routes.api-a.serviceId: cloud-simple-service
zuul.routes.api-b.path: /cloud-simple-serviceB/**
zuul.routes.api-b.serviceId: cloud-simple-serviceB
zuul.routes.api-ui.path: /cloud-simple-ui/**
zuul.routes.api-ui.serviceId: cloud-simple-ui
```
并且zuul服务中进行了token验证,需要请求参数中包含accessToken,accessToken可以为任意值,如果不包含该参数则请求不能
转发过去.
```
http://localhost:5555/cloud-simple-ui/users?accessToken=test
结果:
[
{
id: 1,
username: "test1"
},
{
id: 2,
username: "test2"
},
{
id: 3,
username: "test3"
}
]
http://localhost:5555/cloud-simple-serviceB/user?accessToken=tbbsxxxxd
结果: Result from simpleserviceB
http://localhost:5555/cloud-simple-service/user?accessToken=xxxdaew
结果:
[
{
id: 1,
username: "test1"
},
{
id: 2,
username: "test2"
},
{
id: 3,
username: "test3"
}
]
```
可见zuul已经完全发挥了它的路由作用.
1. Hystrix
Hystrix是熔断器, Hystrx Dashboard实现了监控单个Hystrix stream的功能.
```
http://localhost:8022/hystrix/
```
打开后页面如下:
![hystrix stream页面](https://drive.google.com/uc?id=0BxyRSlBgU-ShTG1QZUpSc1hCV2c)
在其中输入
```
http://localhost:8090/hystrix.stream
```
(cloud-simple-ui服务),即可监控该服务的stream,如下图
![simple-ui-hystrix-stream](https://drive.google.com/uc?id=0BxyRSlBgU-ShUmRwNzluRWhxNmM)
注意需要请求几次cloud-simple-ui服务,该图上才会有结果.
1. Turbine
本示例使用了turbine-amqp, 然后各个需要统计hystrix stream的微服务,包含依赖
```
<!--for turbine stream-->
<dependency>
<groupId>org.springframework.cloud</groupId>
<artifactId>spring-cloud-netflix-hystrix-stream</artifactId>
</dependency>
<dependency>
<groupId>org.springframework.cloud</groupId>
<artifactId>spring-cloud-starter-stream-rabbit</artifactId>
</dependency>
```
即可将stream 发送到rabbitmq队列,然后turbine stream项目获取这些stream, 然后显示在图示上,这样跟之前的区别是可以监控所有
的微服务,而不是单个主机的stream.
同样打开
```
http://localhost:8022/hystrix/
```
在其中输入
```
http://localhost:8989/turbine.stream
```
则可以看到如下图所示
![turbine stream](https://drive.google.com/uc?id=0BxyRSlBgU-ShSmFsdzY1ZWIxdGc)
如图所示可以看到 cloud-simple-service, cloud-simple-serviceB, cloud-simple-ui 共3个服务的Hystrix Stream.
1. Zipkin
zipkin可以跟踪微服务的调用以及,各个路径上面的时间,进而分析瓶颈.
打开
```
http://localhost:9966
```
trace如下图:
![zipkin-simple-ui-trace](https://drive.google.com/uc?id=0BxyRSlBgU-Shb3Bab2sxN1lUSE0)
dependencies如下图:
![zipkin-dependencies](https://drive.google.com/uc?id=0BxyRSlBgU-ShLWJDRGd1VUhMWHc)
| 1 |
RameshMF/spring-boot-tutorial | 100+ Spring Boot Articles, Tutorials, Video tutorials, Projects, Guides, Source code examples etc | 2018-09-17T07:25:55Z | null | <h1>YouTube Channel - Spring Boot Tutorial</h1>
<p>Subscribe for future video and updates</p>
<a href="https://www.youtube.com/playlist?list=PLGRDMO4rOGcNSBOJOlrgQqGpIgo6_VZgR" target="_blank">Spring Boot Tutorial on YouTube
</a>
# Newly published spring boot tutorials (2020)
<ul style="text-align: left;">
<li><a href="https://www.javaguides.net/2021/07/react-js-react-hooks-spring-boot.html" target="_blank">React JS ( React Hooks) + Spring Boot Tutorial</a><br></li><li><a href="https://www.javaguides.net/2021/07/spring-boot-tutorial-for-beginners.html" target="_blank">Spring Boot Tutorial for Beginners Step by Step</a><br></li><li><a href="https://www.javaguides.net/2021/07/spring-boot-tutorial-build-employee-management-project.html" target="_blank">Spring Boot Tutorial - Build Employee Management Project from Scratch using Spring Boot + Spring Security + Thymeleaf and MySQL Database</a><br></li><li><a href="https://www.javaguides.net/2021/06/configure-jwt-with-spring-boot-and-swagger.html" target="_blank">Configure JWT with Spring Boot and Swagger UI</a><br></li><li><a href="https://www.javaguides.net/2021/06/spring-boot-rest-api-documentation-with-swagger.html" target="_blank">Spring Boot REST API Documentation with Swagger</a><br></li><li><a href="https://www.javaguides.net/2021/05/spring-boot-crud-tutorial.html" target="_blank">Spring Boot CRUD Tutorial with Spring MVC, Spring Data JPA, Thymeleaf, Hibernate, MySQL</a><br></li><li><a href="https://www.javaguides.net/2021/04/spring-boot-project-employee-management.html" target="_blank">Spring Boot Project - Employee Management System | Project for Final Year Students</a><br></li><li><a href="https://www.javaguides.net/2021/04/deploy-spring-boot-mysql-crud-rest-api-Application-on-aws.html" target="_blank">Deploy Spring Boot MySQL CRUD REST API Application on AWS | Elastic Beanstalk | AWS RDS</a><br></li><li><a href="https://www.javaguides.net/2021/04/spring-boot-dto-validation-example.html" target="_blank">Spring Boot DTO Validation Example</a><br></li><li><a href="https://www.javaguides.net/2021/04/deploy-spring-boot-application-on-aws.html" target="_blank">Deploy a Spring Boot Application on AWS | Elastic Beanstalk</a><br></li><li><a href="https://www.javaguides.net/2021/04/deploy-spring-boot-mvc-application-on-aws.html" target="_blank">Deploy Spring Boot MVC Application on AWS | Elastic Beanstalk</a><br></li><li><a href="https://www.javaguides.net/2021/04/deploy-spring-boot-war-file-on-tomcat-in-aws.html" target="_blank">Deploy Spring Boot WAR file on Tomcat in AWS | Elastic Beanstalk</a></li><li><a href="https://www.javaguides.net/2021/03/validation-in-spring-boot-rest-api-with-hibernate-validator.html" target="_blank">Validation in Spring Boot REST API with Hibernate Validator (Java Bean Validation Annotations)</a><br></li><li><a href="Spring Boot DTO Example - Entity To DTO Conversion" target="_blank">Spring Boot DTO Example - Entity To DTO Conversion</a><br></li><li><a href="https://www.javaguides.net/2021/01/prerequisites-to-learn-spring-boot.html" target="_blank">Prerequisites to Learn Spring Boot</a><br></li><li><a href="https://www.javaguides.net/2021/01/angular-spring-boot-rest-api-example.html" target="_blank">Angular + Spring Boot REST API Example Tutorial</a><br></li><li><a href="https://www.javaguides.net/2020/11/jsp-vs-thymeleaf-support-in-spring-boot.html" target="_blank">JSP vs Thymeleaf Support in Spring Boot</a><br></li><li><a href="https://www.javaguides.net/2020/11/spring-professional-certification-topics-and-questions.html" target="_blank">Spring Professional Certification Topics and Questions</a><br></li><li><a href="https://www.javaguides.net/2020/07/spring-boot-react-js-crud-example-tutorial.html" target="_blank">Spring Boot + React JS CRUD Example Tutorial</a></li>
<li><a href="https://www.javaguides.net/2020/07/spring-boot-angular-10-crud-example-tutorial.html" target="_blank">Spring Boot + Angular 10 CRUD Example Tutorial</a></li>
<li><a href="https://www.javaguides.net/2020/07/react-js-spring-boot-rest-api-example-tutorial.html" target="_blank">React JS + Spring Boot REST API Example Tutorial</a></li>
<li><a href="https://www.javaguides.net/2020/07/spring-boot-project-architecture.html" target="_blank">Spring Boot Project Architecture</a></li>
<li><a href="https://www.javaguides.net/2020/07/how-spring-mvc-works-internally.html" target="_blank">How Spring MVC Works Internally</a></li>
<li><a href="https://www.javaguides.net/2020/07/three-tier-three-layer-architecture-in-spring-mvc-web-application.html" target="_blank">Three Tier (Three Layer) Architecture in Spring MVC Web Application</a></li>
<li><a href="https://www.javaguides.net/2020/06/best-practice-to-develop-persistence-or-dao-layer.html" target="_blank">Best Practice to Develop Persistence or DAO Layer</a></li>
<li><a href="https://www.javaguides.net/2020/06/best-youtube-channels-to-learn-spring-boot.html" target="_blank">Best YouTube Channels to learn Spring Boot</a></li>
<li><a href="https://www.javaguides.net/2020/06/pagination-and-sorting-with-spring-boot-thymeleaf-spring-data-jpa-hibernate-mysql.html" target="_blank">Pagination and Sorting with Spring Boot, ThymeLeaf, Spring Data JPA, Hibernate, MySQL</a></li>
<li><a href="https://www.javaguides.net/2020/06/free-spring-boot-microservices-open-source-projects-github.html" target="_blank">Free Spring Boot Microservices Open Source Projects | GitHub | Download</a></li>
<li><a href="https://www.javaguides.net/2020/06/spring-security-tutorial-with-spring-boot-spring-data-jpa-thymeleaf-and-mysql-database.html" target="_blank">Spring Security Tutorial with Spring Boot, Spring Data JPA, Thymeleaf and MySQL Database</a></li>
<li><a href="https://www.javaguides.net/2020/06/free-spring-boot-angular-open-source-projects-github.html" target="_blank">Free Spring Boot Angular Open Source Projects | GitHub</a></li>
<li><a href="https://www.javaguides.net/2020/05/spring-boot-crud-web-application-with-thymeleaf.html" target="_blank">Spring Boot CRUD Web Application with Thymeleaf, Spring MVC, Spring Data JPA, Hibernate, MySQL</a></li>
<li><a href="https://www.javaguides.net/2020/05/spring-boot-thymeleaf-crud-database-real-time-project-part1.html" target="_blank"></a><a href="https://www.javaguides.net/2020/05/spring-boot-thymeleaf-crud-database-real-time-project-part1.html" target="_blank">Spring Boot Thymeleaf CRUD Database Real-Time Project - PART 1</a></li>
<li><a href="https://www.javaguides.net/2020/05/spring-boot-thymeleaf-crud-database-real-time-project-part2.html" target="_blank">Spring Boot Thymeleaf CRUD Database Real-Time Project - PART 2</a></li>
<li><a href="https://www.javaguides.net/2020/05/spring-boot-thymeleaf-crud-database-real-time-project-part3.html" target="_blank">Spring Boot Thymeleaf CRUD Database Real-Time Project - PART 3</a></li>
<li><a href="https://www.javaguides.net/2020/05/spring-boot-thymeleaf-crud-database-real-time-project-part4.html" target="_blank">Spring Boot Thymeleaf CRUD Database Real-Time Project - PART 4</a></li>
<li><a href="https://www.javaguides.net/2020/05/spring-boot-thymeleaf-crud-database-real-time-project-part5.html" target="_blank">Spring Boot Thymeleaf CRUD Database Real-Time Project - PART 5</a></li>
<li><a href="https://www.javaguides.net/2020/05/spring-boot-thymeleaf-crud-database-real-time-project-part6.html" target="_blank">Spring Boot Thymeleaf CRUD Database Real-Time Project - PART 6</a> </li>
<li><a href="https://www.javaguides.net/2020/05/spring-boot-thymeleaf-crud-database-real-time-project-part7.html" target="_blank">Spring Boot Thymeleaf CRUD Database Real-Time Project - PART 7</a></li>
<li><a href="https://www.javaguides.net/2020/05/spring-boot-jsp-example-tutorial.html" target="_blank">Spring Boot JSP Example Tutorial</a></li>
<li><a href="https://www.javaguides.net/2020/05/spring-boot-thymeleaf-example-tutorial.html" target="_blank">Spring Boot Thymeleaf Example Tutorial</a></li>
<li><a href="https://www.javaguides.net/2020/04/jpa-hibernate-one-to-many-mapping-example-with-spring-boot.html" target="_blank">JPA, Hibernate One to Many Mapping Example with Spring Boot and MySQL Database</a></li>
<li><a href="https://www.javaguides.net/2020/04/deploying-spring-boot-war-file-with-jsp-to-tomcat.html" target="_blank">Deploying Spring Boot WAR file with JSP to Tomcat</a></li>
<li><a href="https://www.javaguides.net/2020/04/jpa-and-hibernate-many-to-many-mapping-spring-boot.html" target="_blank">JPA and Hibernate Many to Many Mapping with Spring Boot - @ManyToMany and @JoinTable</a></li>
<li><a href="https://www.javaguides.net/2020/04/spring-boot-file-upload-download-rest-api-example.html" target="_blank">Spring Boot File Upload / Download Rest API Example</a></li>
<li><a href="https://www.javaguides.net/2020/04/spring-boot-mysql-jpa-hibernate-restful-crud-api-tutorial.html" target="_blank">Spring Boot, MySQL, JPA, Hibernate Restful CRUD API Tutorial</a></li>
<li><a href="https://www.javaguides.net/2020/04/spring-boot-h2-jpa-hibernate-restful-crud-api-tutorial.html" target="_blank">Spring Boot, H2, JPA, Hibernate Restful CRUD API Tutorial</a></li>
</ul>
<h1> Spring Boot Tutorials/Articles/Guides </h1>
<div dir="ltr" style="text-align: left;" trbidi="on">
<h2 style="text-align: left;">
Spring Boot Basics</h2>
<ul style="text-align: left;">
<li><a href="http://www.javaguides.net/2018/09/getting-started-with-spring-boot.html">Getting Started with Spring Boot</a></li>
<li><a href="http://www.javaguides.net/2018/09/installing-spring-boot-with-maven-and-gradle.html">Installing Spring Boot with Maven and Gradle</a></li>
<li><a href="http://www.javaguides.net/2018/09/spring-boot-building-restful-web-service.html">Spring Boot 2 Hello World Application</a></li>
<li><a href="http://www.javaguides.net/2018/09/overview-of-spring-boot-starter-parent.html">Overview of Spring Boot Starter Parent</a></li>
<li><a href="http://www.javaguides.net/2018/09/important-spring-boot-starters-with-examples.html">Important Spring Boot Starters with Examples</a></li>
<li><a href="http://www.javaguides.net/2018/09/spring-boot-how-to-change-port-and-context-path.html">Spring Boot How to Change Port and Context Path</a></li>
<li><a href="http://www.javaguides.net/2018/09/spring-boot-deploy-war-file-to-external-tomcat.html">Spring Boot 2 Deploy WAR file to External Tomcat</a></li>
<li><a href="http://www.javaguides.net/2018/09/different-ways-of-running-spring-boot-appilcation.html">Different Ways of Running Spring Boot Application</a></li>
<li><a href="https://www.baeldung.com/spring-boot-migration">Migrating from Spring to Spring Boot</a></li>
<li><a href="http://www.javaguides.net/2018/10/spring-boot-annotations.html">Spring Boot Annotations</a></li>
</ul>
<h2 style="text-align: left;">
Spring Boot REST API Development</h2>
<ul style="text-align: left;">
<li><a href="http://www.javaguides.net/2018/09/spring-boot-2-hibernate-5-mysql-crud-rest-api-tutorial.html">Spring Boot 2 Hibernate 5 MySQL CRUD REST API Tutorial</a></li>
<li><a href="http://www.javaguides.net/2018/09/spring-boot-2-jpa-mysql-crud-example.html">Spring Boot 2 JPA MySQL CRUD Example</a></li>
<li><a href="http://www.javaguides.net/2018/09/spring-boot-building-restful-web-service.html">Spring Boot 2 Hello World Application</a></li>
<li><a href="http://www.javaguides.net/2018/09/spring-boot-crud-rest-apis-validation-example.html">Spring Boot 2 CRUD REST APIs Validation Example</a></li>
<li><a href="http://www.javaguides.net/2018/09/spring-data-jpa-auditing-with-spring-boot2-and-mysql-example.html">Spring Data JPA Auditing with Spring Boot 2 and MySQL Example</a></li>
<li><a href="http://www.javaguides.net/2018/09/spring-boot-2-exception-handling-for-rest-apis.html">Spring Boot 2 Exception Handling for REST APIs</a></li>
<li><a href="http://www.javaguides.net/2018/09/spring-boot-2-logging-slf4j-logback-and-log4j-example.html">Spring Boot 2 Logging SLF4j Logback and LOG4j2 Example</a></li>
<li><a href="http://www.javaguides.net/2018/09/spring-boot-2-jersey-rest-jpa-hibernate-5-crud-rest-apis-example.html">Spring Boot 2 + Jersey REST + JPA + Hibernate 5 CRUD REST APIs Example</a></li>
<li><a href="http://www.javaguides.net/2018/10/spring-boot-2-scheduling-tasks.html">Spring Boot 2 - Scheduling Tasks</a></li>
<li><a href="http://www.javaguides.net/2018/10/spring-boot-2-restful-api-documentation-with-swagger2-tutorial.html">Spring Boot 2 RESTful API Documentation with Swagger 2 Tutorial</a></li>
<li><a href="http://www.javaguides.net/2018/11/spring-boot-2-file-upload-and-download-rest-api-tutorial.html">Spring Boot 2 - File Upload and Download Rest API Tutorial</a> // LATEST</li>
</ul>
<h2 style="text-align: left;">
Spring Boot Web Application Development</h2>
<ul style="text-align: left;">
<li><a href="http://www.javaguides.net/2018/09/spring-mvc-using-spring-boot2-jsp-jpa-hibernate5-mysql-example.html">Spring MVC + Spring Boot2 + JSP + JPA + Hibernate 5 + MySQL Example</a></li>
<li><a href="http://www.javaguides.net/2018/09/spring-boot2-mvc-web-application-thymeleaf-jpa-mysql-example.html">Spring Boot 2 MVC Web Application Thymeleaf JPA MySQL Example</a></li>
<li><a href="http://www.javaguides.net/2018/10/spring-boot-spring-mvc-validating-form.html">Spring Boot 2 - Spring MVC + Thymeleaf Input Form Validation</a></li>
<li><a href="http://www.javaguides.net/2018/09/spring-boot-jpa-multiple-data-sources-example.html">Spring Boot JPA Multiple Data Sources Example</a></li>
</ul>
<h2 style="text-align: left;">
Spring Boot with Spring Security</h2>
<div>
<ul style="text-align: left;">
<li><a href="http://www.javaguides.net/2018/09/spring-boot-spring-mvc-role-based-spring-security-jpa-thymeleaf-mysql-tutorial.html">Spring Boot 2 + Spring MVC + Role Based Spring Security + JPA + Thymeleaf + MySQL Tutorial</a></li>
<li><a href="https://spring.io/guides/gs/authenticating-ldap/">Authenticating a User with LDAP using Spring Boot and Spring Security</a></li>
<li><a href="http://www.javaguides.net/2018/10/user-registration-module-using-springboot-springmvc-springsecurity-hibernate5-thymeleaf-mysql.html">User Registration Module using Spring Boot 2 + Spring MVC + Spring Security + Hibernate 5 + Thymeleaf + MySQL</a></li>
</ul>
<h2 style="text-align: left;">
Spring Boot Configuration</h2>
<ul style="text-align: left;">
<li><a href="http://www.javaguides.net/2018/09/spring-boot-java-based-configuration-example.html">Spring Boot 2 Java Based Configuration Example</a></li>
<li><a href="http://www.javaguides.net/2018/09/spring-boot-xml-configuration-example.html">Spring Boot 2 XML Configuration Example</a></li>
<li><a href="https://www.baeldung.com/spring-boot-migration">Migrating from Spring to Spring Boot</a></li>
</ul>
<h2 style="text-align: left;">
Spring Boot Testing</h2>
<ul style="text-align: left;">
<li><a href="http://www.javaguides.net/2018/09/spring-data-jpa-repository-testing-using-spring-boot-datajpatest.html">Spring Data JPA Repository Testing using Spring Boot @DataJpaTest</a></li>
<li><a href="http://www.javaguides.net/2018/09/spring-boot-2-rest-apis-integration-testing.html">Spring Boot 2 REST APIs Integration Testing</a></li>
<li><a href="http://www.javaguides.net/2018/09/spring-boot-2-with-junit-5-testing.html">Spring Boot 2 with JUnit 5 Testing Example</a></li>
</ul>
<h2 style="text-align: left;">
Spring Boot Annotations</h2>
<ul style="text-align: left;">
<li><a href="http://www.javaguides.net/2018/09/spring-boot-enableautoconfiguration-annotation-with-example.html">Spring Boot @EnableAutoConfiguration Annotation with Example</a></li>
<li><a href="http://www.javaguides.net/2018/09/spring-boot-springbootapplication-annotation-with-example.html">Spring Boot @SpringBootApplication Annotation with Example</a></li>
<li><a href="http://www.javaguides.net/2018/10/spring-boot-annotations.html">Spring Boot Annotations</a></li>
<li><a href="http://www.javaguides.net/2018/10/spring-boot-creating-asynchronous-methods-using-async-annotation.html">Spring Boot - Creating Asynchronous Methods using @Async Annotation</a></li>
</ul>
<h2 style="text-align: left;">
Configure Spring Boot with PostgreSQL</h2>
</div>
<div>
<ul style="text-align: left;">
<li><a href="http://www.javaguides.net/2019/01/springboot-postgresql-jpa-hibernate-crud-restful-api-tutorial.html">Spring Boot + PostgreSQL + JPA/Hibernate CRUD Restful API Tutorial</a></li>
</ul>
<h2 style="text-align: left;">
Spring Boot Mini Projects</h2>
<ul style="text-align: left;">
<li><a href="http://www.javaguides.net/2018/09/mini-todo-management-project-using-spring-boot-springmvc-springsecurity-jsp-hibernate-mysql.html">Mini Todo Management Project using Spring Boot + Spring MVC + Spring Security + JSP + Hibernate + MySQL</a></li>
<li><a href="http://www.javaguides.net/2018/10/user-registration-module-using-springboot-springmvc-springsecurity-hibernate5-thymeleaf-mysql.html">User Registration Module using Spring Boot + Spring MVC + Spring Security + Hibernate 5 + Thymeleaf + MySQL</a></li>
</ul>
</div>
</div>
<h1>Spring Boot + Angular 9 Tutorials // Latest </h1>
<ul style="text-align: left;"><a href="https://www.javaguides.net/2020/01/spring-boot-angular-9-crud-example-tutorial.html"></a>
<li><a href="https://www.javaguides.net/2020/01/spring-boot-angular-9-crud-example-tutorial.html"></a><a href="https://www.javaguides.net/2020/01/spring-boot-angular-9-crud-example-tutorial.html">Spring Boot + Angular 9 CRUD Example Tutorial</a> - Main Tutorial</li>
<li><a href="https://www.javaguides.net/2020/01/spring-boot-angular-9-crud-part-1-develop-springboot-crud-rest-apis.html">Spring Boot + Angular 9 CRUD Tutorial - Part 1 - Develop Spring Boot CRUD Rest APIs</a></li>
<li><a href="https://www.javaguides.net/2020/01/spring-boot-angular-9-crud-part-2-create-angular-9-app.html">Spring Boot + Angular 9 CRUD - Part 2 - Create an Angular 9 App</a></li>
<li><a href="https://www.javaguides.net/2020/01/spring-boot-angular-9-crud-part-3-develop-angular-9-crud-operations.html">Spring Boot + Angular 9 CRUD - Part 3 - Develop Angular 9 CRUD Operations</a></li>
<li><a href="https://www.javaguides.net/2020/01/spring-boot-angular-9-crud-part-4-angular-9-crud-app-configuration.html">Spring Boot + Angular 9 CRUD, Part 4 - Angular 9 CRUD App Configuration</a></li>
<li><a href="https://www.javaguides.net/2020/01/spring-boot-angular-8-crud-part-5-running-angular-9-crud-app.html">Spring Boot 2 + Angular 9 CRUD, Part 5 - Running Angular 9 CRUD App</a></li>
</ul>
<h1> Spring Boot + MongoDB </h1>
<ul style="text-align: left;"><b><a href="https://www.javaguides.net/2019/12/spring-boot-angular-mongodb-crud-example-tutorial.html"></a>
<li><a href="https://www.javaguides.net/2019/12/spring-boot-angular-mongodb-crud-example-tutorial.html"><b></b></a><b><a href="https://www.javaguides.net/2019/12/spring-boot-angular-mongodb-crud-example-tutorial.html">Spring Boot + Angular + MongoDB CRUD Example Tutorial</a></b></li>
<li><b><a href="https://www.javaguides.net/2019/12/spring-boot-mongodb-crud-example-tutorial.html">Spring Boot + MongoDB CRUD Tutorial</a></b></li>
</b></ul>
| 1 |
CamelCookbook/camel-cookbook-examples | Example source code for Apache Camel Developer's Cookbook | 2013-01-13T21:06:57Z | null | Apache Camel Developer's Cookbook, 2nd Edition Samples
======================================================
[![Build Status](https://travis-ci.org/CamelCookbook/camel-cookbook-examples.png?branch=master)](https://travis-ci.org/CamelCookbook/camel-cookbook-examples)
[![Stories in Ready](https://badge.waffle.io/CamelCookbook/camel-cookbook-examples.png?label=ready&title=Ready)](https://waffle.io/CamelCookbook/camel-cookbook-examples?utm_source=badge)
This project contains the sample code for the [_Apache Camel Developer's Cookbook, 2nd Edition_](http://www.packtpub.com/apache-camel-developers-cookbook/book)
(Packt Publishing, TBD 2017) by [Scott Cranton](https://github.com/scranton), [Jakub Korab](https://github.com/jkorab), and [Christian Posta](https://github.com/christian-posta).
The latest version of this code is available on [GitHub](http://github.com/CamelCookbook/camel-cookbook-examples).
*This project is up to date with [Apache Camel 2.20.0](http://camel.apache.org/camel-2200-release.html).*
All of the examples are driven through JUnit tests, and are collectively structured as a set
of Apache Maven projects. To execute them, you will need a copy of the [Java 8 JDK](http://openjdk.java.net/install/)
and an [Apache Maven 3](http://maven.apache.org/) installation.
Maven will download all of the appropriate project dependencies.
In order to execute all the tests, all you need to do is run:
$ mvn clean install
| 1 |
payara/Payara-Examples | Repository for Example Code to demonstrate Payara specific features | 2015-06-20T15:38:47Z | null | //
// Copyright (c) 2016-2022 Payara Foundation and/or its affiliates.
//
# Payara Platform Examples
Repository for Example Code to demonstrate Payara specific features
### [Administration Samples](administration-examples)
This module contains some example asadmin scripts for managing Payara
### [Java EE](javaee)
Some simple Java EE example applications
Payara Clustered Singleton example application
### [MicroProfile](microprofile)
Some simple MicroProfile example applications
### [Payara Micro](payara-micro)
Example applications showing features of Payara Micro
### [Payara Services Examples](payara-services)
Some examples of additional Payara services, including:
* Request Tracing Service
* Notification Service
* EclipseLink Cache Coordination / Invalidation MDB examples
### [OSGi Examples](osgi)
Some simple examples of OSGi bundles that can be deployed on Payara Server
### [Ecosystem](ecosystem)
Examples of using development and integration tools and plugins like Maven and Gradle plugins.
### [Cloud Providers Examples](cloud-providers)
Some examples specific for cloud providers like AWS, Google, Azure, ...
### [Polyglot](polyglot)
Some examples using other JVM languages with Payara, including examples with GraalVM.
| 1 |
databricks/learning-spark | Example code from Learning Spark book | 2014-06-16T04:47:54Z | null | [![buildstatus](https://travis-ci.org/holdenk/learning-spark-examples.svg?branch=master)](https://travis-ci.org/holdenk/learning-spark-examples)
Examples for Learning Spark
===============
Examples for the Learning Spark book. These examples require a number of libraries and as such have long build files. We have also added a stand alone example with minimal dependencies and a small build file
in the mini-complete-example directory.
These examples have been updated to run against Spark 1.3 so they may
be slightly different than the versions in your copy of "Learning Spark".
Requirements
==
* JDK 1.7 or higher
* Scala 2.10.3
- scala-lang.org
* Spark 1.3
* Protobuf compiler
- On debian you can install with sudo apt-get install protobuf-compiler
* R & the CRAN package Imap are required for the ChapterSixExample
* The Python examples require urllib3
Python examples
===
From spark just run ./bin/pyspark ./src/python/[example]
Spark Submit
===
You can also create an assembly jar with all of the dependencies for running either the java or scala
versions of the code and run the job with the spark-submit script
./sbt/sbt assembly OR mvn package
cd $SPARK_HOME; ./bin/spark-submit --class com.oreilly.learningsparkexamples.[lang].[example] ../learning-spark-examples/target/scala-2.10/learning-spark-examples-assembly-0.0.1.jar
[![Learning Spark](http://akamaicovers.oreilly.com/images/0636920028512/cat.gif)](http://www.jdoqocy.com/click-7645222-11260198?url=http%3A%2F%2Fshop.oreilly.com%2Fproduct%2F0636920028512.do%3Fcmp%3Daf-strata-books-videos-product_cj_9781449358600_%2525zp&cjsku=0636920028512) | 1 |
castagna/jena-examples | A collection of ready to use, small and self contained examples on how to use Apache Jena | 2011-10-10T13:02:42Z | null | null | 1 |
zhangjun0x01/bigdata-examples | 分享一些在工作中的大数据实战案例,包括flink、kafka、hadoop、presto等等。欢迎大家关注我的公众号【大数据技术与应用实战】,一起成长。 | 2020-05-30T09:11:48Z | null | 分享自己平时工作和学习中遇到的一些大数据相关的知识点,如hadoop、flink、presto、hive、iceberg等等,更多精彩内容欢迎大家关注我的微信公众号:
![欢迎关注我的公众号:大数据技术与应用实战](https://img-blog.csdnimg.cn/20200727095900191.png)
| 1 |
dtpublic/examples | DataTorrent code samples for guides, tutorials, blogs | 2015-10-07T18:29:18Z | null | # DataTorrent Application Examples
DataTorrent RTS, powered by Apache Apex, provides a high-performing, fault-tolerant, scalable, easy to use data processing platform for both batch and streaming data. It includes advanced management, monitoring, development, visualization, data ingestion and distribution features. For more information on Apache Apex, please go to https://apex.apache.org/
This repository contains examples for new users to start developing data pipelines as an application. The complete documentation along with prerequisites, setup guide and tutorial is available on http://docs.datatorrent.com/
##Contact
DataTorrent is at https://www.datatorrent.com/
Apache Apex is at http://apex.apache.org and [subscribe](http://apex.apache.org/community.html) to the mailing lists.
There is an active user community at http://stackoverflow.com/. Please tag the question with "apache-apex".
| 1 |
leeowenowen/rxjava-examples | 全面,完整,图文并茂的RxJavaAPI使用示例。 | 2016-04-16T03:04:32Z | null | #RxJava 示例工程
#理解RxJava API的一个关键是明白API需要Observable的Case是异步使用场景,而返回普通对象类型的是同步使用场景, 比如flatmap与map, buffer中的多个重载等。
讲解RxJava如何使用的示例工程,你可以将它安装在android手机上,然后就可以随手学习RxJava的api了.
点击API名称,可以看到源码,源码输出以及对应的marble-diagram.
>API描述目前支持中文和英文两种语言, 如果你的Android设备使用的是中文,那么你看到的API描述会跟我如下的截图有所不同.
# rxjava-examples
rxjava-example android project
Show how to use RxJava API, you can install the [Demo APK](https://raw.githubusercontent.com/wiki/leeowenowen/rxjava-examples/apk/app-debug.apk) on your android phone, and then you
can learn RxJava API everywhere!
click the api name, and you can see the source code, output and relevant marble diagram at the same time.
all the source codes show on the sample gui are generated from my project source, and all the marble diagram is loaded from
load.
[Download APK](https://raw.githubusercontent.com/wiki/leeowenowen/rxjava-examples/apk/app-debug.apk)
![Barcode/二维码](https://raw.githubusercontent.com/wiki/leeowenowen/rxjava-examples/res/barcode.png)
![Demo Screenshot1](https://raw.githubusercontent.com/wiki/leeowenowen/rxjava-examples/res/rxjava-1.png)
![Demo Screenshot2](https://raw.githubusercontent.com/wiki/leeowenowen/rxjava-examples/res/rxjava-2.png)
| 1 |
haoxiaoyong1014/springboot-examples | spring boot 集成各技术案例 | 2018-05-28T03:03:07Z | null | # springboot-examples
spring boot 集成各技术案例 <img src="https://camo.githubusercontent.com/95c3d7ef0b5da8445087e462514063675f79321d/68747470733a2f2f696d672e736869656c64732e696f2f62616467652f4c6963656e73652d4372656174697665253230436f6d6d6f6e732d4443334432342e737667" alt="知识共享协议(CC协议)" data-canonical-src="https://img.shields.io/badge/License-Creative%20Commons-DC3D24.svg" style="max-width:100%;">
[![Stargazers over time](https://starchart.cc/haoxiaoyong1014/springboot-examples.svg)](https://starchart.cc/haoxiaoyong1014/springboot-examples)
2018/5/24 添加 springboot-rabbitMQ(<a href="https://github.com/haoxiaoyong1014/springboot-examples/tree/master/springboot-rabbitmq">消息队列</a>)
2018/6/12 添加 springboot-redis-docker(<a href="https://github.com/haoxiaoyong1014/springboot-examples/tree/master/springboot-redis-docker">Docker 部署 SpringBoot 项目整合 Redis 镜像做访问计数Demo</a>)
2018/6/13 添加 springboot-web-thymeleaf (<a href="https://github.com/haoxiaoyong1014/springboot-examples/tree/master/springboot-web-thymeleaf">springboot整合thymeleaf</a>)
2018/6/20 添加 springboot2-oauth2(springBoot版本:2.0.1.RELEASE)
**springboot2-oauth2 包括:**
* springboot-oauth2-authorization-server(<a href="https://github.com/haoxiaoyong1014/springboot-examples/tree/master/springboot-oauth2-authorization-server">springboot整合OAuth2.0认证服务</a>),
* springboot-oauth2-resource-server(<a href="https://github.com/haoxiaoyong1014/springboot-examples/tree/master/springboot-oauth2-resource-server">资源服务</a>)
2018/6/30 添加 springboot-mybatis-ehcache (<a href="https://github.com/haoxiaoyong1014/springboot-examples/tree/master/springboot-mybatis-myehcache">使用EhcacheCache做二级缓存,使用pageHelper做分页插件</a>)
2018/7/14 添加 springboot-websocket (<a href="https://github.com/haoxiaoyong1014/springboot-examples/tree/master/springboot-websocket">在线人数统计,消息发送,一对一,一对多发送消息<a>)
2018/8/10 添加 springboot-shrio(<a href="https://github.com/haoxiaoyong1014/springboot-shiro">基础版<a>)
2018/8/13 添加 springboot-shiro-v1.2.0(<a href="https://github.com/haoxiaoyong1014/springboot-shiro-v1.2.0">加强版<a>)
2018/9/28 添加 springboot-quartz(<a href="https://github.com/haoxiaoyong1014/springboot-quartz">任务调度,持久化任务<a>)
2018/10/15 添加 springboot-SpringDataJpa(<a href="https://github.com/haoxiaoyong1014/springboot-SpringDataJpa">Spring Data JPA 使用<a>)
2018/10/20 添加 springboot-netty(<a href="https://github.com/haoxiaoyong1014/springboot-netty">springboot整合netty做心跳检测<a>)
2018/11/29 添加 springboot2-redis(<a href="https://github.com/haoxiaoyong1014/springboot-examples/tree/master/springboot2-redis">springboot2x系列整合Redis(Lettuce版)<a>)
2019/2/20 添加 springboot-fastDFS(<a href="https://github.com/haoxiaoyong1014/springboot-examples/tree/master/springboot-fastDFS">springboot-fastDFS</a>)
2019/3/12 添加 global-exception(<a href="https://github.com/haoxiaoyong1014/springboot-examples/tree/master/global-exception">global-exception(Spring全局异常处理)</a>)
2019/5/11 添加 springboot-mongodb(<a href="https://github.com/haoxiaoyong1014/springboot-examples/tree/master/springboot-mongodb">springboot-mongodb(springboot整合mongodb)</a>)
2019/5/31 添加 springboot-login-Interceptor(<a href="https://github.com/haoxiaoyong1014/springboot-examples/tree/master/springboot-login-Interceptor">springboot拦截器整合JWT做验证token,以及token过期解决方案</a>)
2019/6/24 添加 springboot-druid(<a href="https://github.com/haoxiaoyong1014/springboot-examples/tree/master/springboot-druid">使用阿里巴巴提供的springboot整合druid包管理连接池</a>)
2019/7/30 添加 springboot-easyexcel-encapsulation(<a href="https://github.com/haoxiaoyong1014/springboot-examples/tree/master/springboot-easyexcel-encapsulation">对阿里巴巴easyexcel导入导出excel文件进行封装</a>)
2019/9/08 添加 strategy-aop(<a href="https://github.com/haoxiaoyong1014/springboot-examples/tree/master/strategy-aop">AOP+自定义注解+策略模式 记录操作日志,避免过多的 if else</a>)
2019/10/15 添加 chat-software(<a href="https://github.com/haoxiaoyong1014/chat-software"> 基于Netty Spring Boot仿微信聊天项目</a>)
2020/1/11 添加 distributed-job(<a href="https://github.com/haoxiaoyong1014/springboot-examples/tree/master/distributed-job">spring-boot整合xxl-job,手动触发定时任务</a>)
2020/2/29 添加 mybatis-plus-example(<a href="https://github.com/haoxiaoyong1014/springboot-examples/tree/master/mybatis-plus-example">springboot整合mybatis-plus</a>)
2020/3/20 添加 okay-spring-boot-starter(<a href="https://github.com/haoxiaoyong1014/springboot-examples/tree/master/okay-spring-boot-starter">从SpringBoot源码到自己封装一个Starter</a>)
2020/5/08 添加 springboot-threadpool(<a href="https://github.com/haoxiaoyong1014/springboot-examples/tree/master/springboot-threadpool">SpringBoot 使用线程池-线程池隔离</a>)
2020/5/14 添加 springboot-swagger-enhance(<a href="https://github.com/haoxiaoyong1014/springboot-examples/tree/master/springboot-swagger-enhance">SpringBoot集成第三方swagger美化文档样式</a>)
2020/8/14 添加 springboot-admin-monitor(<a href="https://github.com/haoxiaoyong1014/springboot-examples/tree/master/springboot-admin-monitor">springBoot-admin 日志,系统监控</a>)
2020/9/10 添加 springboot-elk(<a href="https://github.com/haoxiaoyong1014/springboot-examples/tree/master/springboot-elk">springboot集成ELK,包含安装步骤</a>)
# springboot-redis-example(<a href="https://github.com/haoxiaoyong1014/springboot-redis-examples">redis系列</a>)
2018/6/12 添加 springboot-redis-docker(<a href="https://github.com/haoxiaoyong1014/springboot-examples/tree/master/springboot-redis-docker">Docker 部署 SpringBoot 项目整合 Redis 镜像做访问计数(PV)Demo</a>)
2018/07/27 添加springboot-redis-ranking (<a href="https://github.com/haoxiaoyong1014/springboot-redis-examples/tree/master/springboot-redis-ranking">基于Redis实现商品排行榜</a>)
2018/08/01 添加 springboot-redis-fridends (<a href="https://github.com/haoxiaoyong1014/springboot-redis-examples/tree/master/springboot-redis-friends">基于Redis实现查询共同好友</a>,
结合前端vue.js,前端项目地址: <a href="https://github.com/haoxiaoyong1014/common-friends">common-friends</a>)
2018/11/16 添加 redis-manage(<a href="https://github.com/haoxiaoyong1014/redis-manage">Redis的后台管理</a>,结合前端项目<a href="https://github.com/haoxiaoyong1014/redis-manage-view">redis-manage-view</a>)
2019/8/16 添加 springboot-idempotent(<a href="https://github.com/haoxiaoyong1014/springboot-examples/tree/master/springboot-idempotent">springboot + redis + 注解 + 拦截器 实现接口幂等性校验</a>)
2019/9/14 添加 springboot-mybatis-redis-cache(<a href="https://github.com/haoxiaoyong1014/springboot-redis-examples/tree/master/springboot-mybatis-redis-cache">使用redis做二级缓存</a>)
2019/10/29添加 [Redis专题(七)--基于Sentinel(哨兵)搭建实现Redis高可用集群](https://haoxiaoyong.cn/2019/10/29/2019/2019-12-03-redis-master-slave/)
2020/09/18添加 springboot-redis-range( [SpringBoot 使用 Redis Geo 实现查找附近的位置](https://github.com/haoxiaoyong1014/springboot-redis-examples/tree/master/springboot-redis-range))
持续更新中....
| 1 |
eventuate-tram/eventuate-tram-examples-customers-and-orders | An example of Choreography-based sagas in Spring Boot/JPA microservices | 2018-03-19T17:29:16Z | null | null | 1 |
mattdesl/lwjgl-basics | :wrench: LibGDX/LWJGL tutorials and examples | 2012-11-05T01:42:27Z | null | null | 1 |
spring-projects/spring-integration-samples | You are looking for examples, code snippets, sample applications for Spring Integration? This is the place. | 2011-08-10T04:40:02Z | null | Spring Integration Samples
==========================
[![Revved up by Develocity](https://img.shields.io/badge/Revved%20up%20by-Develocity-06A0CE?logo=Gradle&labelColor=02303A)](https://ge.spring.io/scans?search.rootProjectNames=spring-integration-samples)
Welcome to the **Spring Integration Samples** repository which provides **50+ samples** to help you learn [Spring Integration][]. To simplify your experience, the *Spring Integration* samples are split into 4 distinct categories:
* Basic
* Intermediate
* Advanced
* Applications
* DSL
Inside of each category you'll find a **README.md** file, which will contain a more detailed description of that category. Each sample also comes with its own **README.md** file explaining further details, e.g. how to run the respective sample.
| For additional samples, please also checkout the [Spring Integration Extensions][] project as it also provides numerous samples.
*Happy Integration!*
# Note
This (main) branch requires Spring Integration 6.0 or above.
For samples running against earlier versions of Spring Integration, use the __5.5.x__ and other branches.
The project requires now Java 17 or above.
To open the project in the IDE, use its `import` option against a `build.gradle` file from the root project directory.
## Related GitHub projects
* [Spring Integration][]
* [Spring Integration Extensions][]
## Community Sample Projects
* [Xavier Padró][]
# Categories
Below is a short description of each category.
## DSL
This directory holds demos/samples for Spring Integration 4.0 Java Configuration as well as the Java DSL Extension.
## Basic
This is a good place to get started. The samples here are technically motivated and demonstrate the bare minimum with regard to configuration and code to help you to get introduced to the basic concepts, API and configuration of Spring Integration. For example, if you are looking for an answer on how to wire a **Service Activator** to a **Channel** or how to apply a **Gateway** to your message exchange or how to get started with using the **MAIL** or **XML** module, this would be the right place to find a relevant sample. The bottom line is that this is a good starting point.
* **amqp** - Demonstrates the functionality of the various **AMQP Adapters**
* **barrier** - Shows how to suspend a thread until some asynchronous event occurs
* **control-bus** - Demonstrates the functionality of the **Control Bus**
* **enricher** - This sample demonstrates how the Enricher components can be used
* **feed** - Demonstrates the functionality of the **Feed Adapter** (RSS/ATOM)
* **file** - Demonstrates aspects of the various File Adapters (e.g. **File Inbound/Outbound Channel Adapters**, file **polling**)
* **ftp** - Demonstrates the **FTP support** available with Spring Integration
* **helloworld** - Very simple starting example illustrating a basic message flow (using **Channel**, **ServiceActivator**, **QueueChannel**)
* **http** - Demonstrates request/reply communication when using a pair of **HTTP Inbound/Outbound gateways**
* **jdbc** - Illustrates the usage of the Jdbc Adapters, including object persistence and retrieval
* **jms** - Demonstrates **JMS** support available with Spring Integration
* **jmx** - Demonstrates **JMX** support using a **JMX Attribute Polling Channel** and **JMX Operation Invoking Channel Adapter**
* **jpa** - Shows the usage of the JPA Components
* **mail** - Example showing **IMAP** and **POP3** support
* **mqtt** - Demonstrates the functionality of inbound and outbound **MQTT Adapters**
* **mongodb** - Shows how to persist a Message payload to a **MongoDb** document store and how to read documents from **MongoDb**
* **oddeven** - Example combining the functionality of **Inbound Channel Adapter**, **Filter**, **Router** and **Poller**
* **quote** - Example demoing core EIP support using **Channel Adapter (Inbound and Stdout)**, **Poller** with Interval Triggers, **Service Activator**
* **sftp** - Demonstrating SFTP support using **SFTP Inbound / Outbound Channel Adapters**
* **tcp-amqp** - Demonstrates basic functionality of bridging the **Spring Integration TCP Adapters** with **Spring Integration AMQP Adapters**
* **tcp-broadcast** - Demonstrates broadcasting a message to multiple connected TCP clients.
* **tcp-client-server** - Demonstrates socket communication using **TcpOutboundGateway**, **TcpInboundGateway** and also uses a **Gateway** and a **Service Activator**
* **tcp-with-headers** - Demonstrates sending headers along with the payload over TCP using JSON.
* **testing-examples** - A series of test cases that show techniques to **test** Spring Integration applications.
* **twitter** - Illustrates Twitter support using the **Twitter Inbound Channel Adapter**, **Twitter Inbound Search Channel Adapter**, **Twitter Outbound Channel Adapter**
* **ws-inbound-gateway** - Example showing basic functionality of the **Web Service Gateway**
* **ws-outbound-gateway** - Shows outbound web services support using the **Web Service Outbound Gateway**, **Content Enricher**, Composed Message Processor (**Chain**)
* **xml** - Example demonstrates various aspects of the **Xml** support using an **XPath Splitter**, **XPath Router**, **XSLT Transformer** as well as **XPath Expression** support
* **xmpp** - Show the support for [**XMPP**](https://en.wikipedia.org/wiki/Extensible_Messaging_and_Presence_Protocol) (formerly known as Jabber) using e.g. GoogleTalk
## Intermediate
This category targets developers who are already more familiar with the Spring Integration framework (past getting started), but need some more guidance while resolving more advanced technical problems that you have to deal with when switching to a Messaging architecture. For example, if you are looking for an answer on how to handle errors in various scenarios, or how to properly configure an **Aggregator** for the situations where some messages might not ever arrive for aggregation, or any other issue that goes beyond a basic understanding and configuration of a particular component to address "what else you can do?" types of problems, this would be the right place to find relevant examples.
* **async-gateway** - Usage example of an asynchronous **Gateway**
* **dynamic-poller** - Example shows usage of a **Poller** with a custom **Trigger** to change polling periods at runtime
* **async-gateway** - Example shows usage of an **Asynchronous Gateway**
* **errorhandling** - Demonstrates basic **Error Handling** capabilities of Spring Integration
* **file-processing** - Sample demonstrates how to wire a message flow to process files either sequentially (maintain the order) or concurrently (no order).
* **mail-attachments** - Demonstrates the processing of email attachments
* **monitoring** The project used in the *[Spring Integration Management and Monitoring Webinar](https://www.springsource.org/node/3598)* Also available on the *[SpringSourceDev YouTube Channel](https://www.youtube.com/SpringSourceDev)*
* **multipart-http** - Demonstrates the sending of HTTP multipart requests using Spring's **RestTemplate** and a Spring Integration **Http Outbound Gateway**
* **rest-http** - This sample demonstrates how to send an HTTP request to a Spring Integration's HTTP service while utilizing Spring Integration's new HTTP Path usage. This sample also uses Spring Security for HTTP Basic authentication. With HTTP Path facility, the client program can send requests with URL Variables.
* **retry-and-more** Provides samples showing the application of MessageHandler Advice Chains to endpoints - retry, circuit breaker, expression evaluating
* **splitter-aggregator-reaper** A demonstration of implementing the Splitter and Aggregator *Enterprise Integration Patterns* (EIP) together. This sample also provides a concrete example of a [message store reaper][] in action.
* **stored-procedures-derby** Provides an example of the stored procedure Outbound Gateway using *[Apache Derby](https://db.apache.org/derby/)*
* **stored-procedures-ms** Provides an example of the stored procedure Outbound Gateway using *Microsoft SQL Server*
* **stored-procedures-oracle** Provides an example of the stored procedure Outbound Gateway using *ORACLE XE*
* **stored-procedures-postgresql** Provides an example of the stored procedure Outbound Gateway using *[PostgreSQL](https://www.postgresql.org/)*
* **tcp-async-bi-directional** - Demonstrates the use of *Collaborating Channel Adapters* for arbitrary async messaging (not request/reply) between peers.
* **tcp-client-server-multiplex** - Demonstrates the use of *Collaborating Channel Adapters* with multiple in-flight requests/responses over a single connection.
* **travel** - More sophisticated example showing the retrieval of weather (SOAP Web Service) and traffic (HTTP Service) reports using real services
* **tx-synch** Provides a sample demonstrating the use of transaction synchronization, renaming an input file to a different filename, depending on whether the transaction commits, or rolls back.
## Advanced
This category targets advanced developers who are quite familiar with Spring Integration but are looking to address a specific custom need by extending the Spring Integration public API. For example, if you are looking for samples showing how to implement a custom **Channel** or **Consumer** (event-based or polling-based), or you are trying to figure out what is the most appropriate way to implement a custom **BeanParser** on top of the Spring Integration BeanParser hierarchy when implementing a custom namespace, this would be the right place to look. Here you can also find samples that will help you with adapter development. Spring Integration comes with an extensive library of adapters that allow you to connect remote systems with the Spring Integration messaging framework. However you might have a need to integrate with a system for which the core framework does not provide an adapter, so you have to implement your own. This category would include samples showing you how to implement various adapters.
* **advanced-testing-examples** - Example test cases that show advanced techniques to test Spring Integration applications
* **dynamic-ftp** - Demonstrates one technique for sending files to dynamic destinations.
* **dynamic-tcp-client** - Demonstrates a technique for dynamically creating TCP clients.
## Applications
This category targets developers and architects who have a good understanding of Message-Driven architecture and Enterprise Integration Patterns, and have an above average understanding of Spring and Spring integration and who are looking for samples that address a particular business problem. In other words, the emphasis of samples in this category is '**business use cases**' and how they can be solved via a Messaging architecture and Spring Integration in particular. For example, if you are interested to see how a Loan Broker process or Travel Agent process could be implemented and automated via Spring Integration, this would be the right place to find these types of samples.
* **cafe** - Emulates a simple operation of a coffee shop combining various Spring Integration adapters (Including **Router** and **Splitter**) see [Appendix A of the reference documentation](https://docs.spring.io/spring-integration/docs/current/reference/html/#samples) for more details. Implementations are provided for:
- AMQP
- JMS
- In memory channels
* **cafe-scripted** - Scripted implementation of the classic **cafe** sample application. Supports **JavaScript**, **Groovy**, **Ruby**, and **Python**.
* **loan-broker** - Simulates a simple banking application (Uses **Gateway**, **Chain**, **Header Enricher**, **Recipient List Router**, **Aggregator**) see [Appendix A of the reference documentation](https://docs.spring.io/spring-integration/docs/current/reference/html/#samples) for more details
* **loanshark** This extension to the loan broker sample shows how to exchange messages between Spring Integration applications (and other technologies) using **UDP**.
**file-split-ftp** - Reads a file; splits into 3 based on contents; sends files over ftp; sends email with results.
# Contributing
See the [Spring Integration Contributor Guidelines](https://github.com/spring-projects/spring-integration/blob/master/CONTRIBUTING.adoc) for information about how to contribute to this repository.
# Resources
For more information, please visit the Spring Integration website at: [https://projects.spring.io/spring-integration/](https://projects.spring.io/spring-integration/)
[Spring Integration]: https://github.com/spring-projects/spring-integration
[Spring Integration Extensions]: https://github.com/spring-projects/spring-integration-extensions
[message store reaper]: https://docs.spring.io/spring-integration/api/org/springframework/integration/store/MessageGroupStoreReaper.html
[Xavier Padró]: https://github.com/xpadro/spring-integration
| 1 |
jjenkov/javafx-examples | A large collection of JavaFX examples demonstrating basic + advanced features of JavaFX. | 2020-10-21T10:37:31Z | null | # JavaFX Examples
This repository contains a growing collection of JavaFX examples. So far this GitHub repository contains 76 examples.
I have plans to add lots more examples in the future, so make sure you star this repository for future reference ;-)
The lists of examples is found here:
- [JavaFX Basic Examples](#javafx-basic-examples)
- [JavaFX Advanced Examples](#javafx-advanced-examples)
## JavaFX Tutorial
The examples come from my JavaFX tutorial series: [JavaFX Tutorial](http://tutorials.jenkov.com).
## Java + JavaFX Version Used
In general the examples in this repository will attempt to use the latest version of Java and JavaFX.
For now the examples are tested with Java 14 and JavaFX 14 (yes, 15 + 15 are latest - will update soon!).
## Running the Examples
There are 3 options to run the examples.
- Using your IDE (IntelliJ IDEA / Eclipse / Netbeans)
- Using Maven - passing main class to run on the command line
- Using gradle - passing main class to run on the command line
- Using Maven - configuring the main class inside the pom.xml
Some of these are covered in more detail below.
### Run the Examples in IntelliJ Idea(needs pre-downloaded javafx modules)
To run the examples from within IntelliJ IDEA you must first create a new project in IntelliJ, and set the root
directory to the directory into which you have cloned this Git repository.
Second, you must download JavaFX and unzip the distribution to some directory.
Third, you must add all the JAR files found in the "lib" directory to your project's classpath.
Fourth, you must create a run configuration for the example class you want to run. Add the following
JVM args to that run configuration:
--module-path C:\data\downloads\javafx\javafx-sdk-14\lib --add-modules javafx.base,javafx.controls,javafx.fxml,javafx.graphics,javafx.media,javafx.swing,javafx.web
Make sure that the --module-path points to the directory you unzipped your downloaded JavaFX distribution to (meaning the "lib" dir within that JavaFX distribution dir - as shown above).
### Run in IDE - alternative
Instead of creating run configuration for each example class you can create a run configuration for the ExampleRunner class(based on maven or gradle nature. Both are supported using wrappers so you don't need to have any of them on you system and you can choose to use the one you prefer), and then from inside the
ExampleRunner class, call the example class you want to run - by changing the main() method inside the ExampleRunner class. For instance,
add the following line to the ExampleRunner class main() method and then run ExampleRunner main
ButtonExample.main(args);
### Run via Maven - Passing Main Class as Argument to Maven
You can use maven and pass the example class you want to add. for example to run WebViewExample you can run
./mvnw compile exec:java -Dexec.args="com.jenkov.javafx.webview.WebViewExample"
### Run via Gradle - Passing Main Class as Argument to Gradle
You can use gradle and pass the example class you want to add. for example to run WebViewExample you can run
./gradlew run --args="com.jenkov.javafx.webview.WebViewExample"
### Run via Maven
You can use Maven and edit the pom.xml file and change "mainClass" of openjfx plugin configuration and select the example you want then run
./mvnw clean javafx:run
## Suggestions
If you have any suggestions for missing examples, create a GitHub issue in this repo, and / or ping me on
Twitter (@jjenkov) or LinkedIn (Jakob Jenkov).
<a name="javafx-basic-examples"></a>
# JavaFX Basic Examples
- [Accordion Example](https://github.com/jjenkov/javafx-examples/blob/main/src/main/java/com/jenkov/javafx/accordion/AccordionExample.java)
- [Animation Example](https://github.com/jjenkov/javafx-examples/blob/main/src/main/java/com/jenkov/javafx/animation/AnimationExample.java)
- Button Examples
- [Button Example](https://github.com/jjenkov/javafx-examples/blob/main/src/main/java/com/jenkov/javafx/button/ButtonExample.java)
- [Button Font Example](https://github.com/jjenkov/javafx-examples/blob/main/src/main/java/com/jenkov/javafx/button/ButtonFontExample.java)
- [Disabled Button Example](https://github.com/jjenkov/javafx-examples/blob/main/src/main/java/com/jenkov/javafx/button/DisabledButtonExample.java)
- [Normal, Default and Cancel Mode Button Example](https://github.com/jjenkov/javafx-examples/blob/main/src/main/java/com/jenkov/javafx/button/ButtonDefaultAndCancelModesExample.java)
- [Button FXML Example](https://github.com/jjenkov/javafx-examples/blob/main/src/main/java/com/jenkov/javafx/button/ButtonFXMLExample.java)
- [Button Transformation Example](https://github.com/jjenkov/javafx-examples/blob/main/src/main/java/com/jenkov/javafx/button/ButtonTransformationExample.java)
- [Canvas Example](https://github.com/jjenkov/javafx-examples/blob/main/src/main/java/com/jenkov/javafx/canvas/CanvasExample.java)
- [ChoiceBox Example](https://github.com/jjenkov/javafx-examples/blob/main/src/main/java/com/jenkov/javafx/choicebox/ChoiceBoxExample.java)
- [Color Example](https://github.com/jjenkov/javafx-examples/blob/main/src/main/java/com/jenkov/javafx/color/ColorExample.java)
- [ColorPicker Example](https://github.com/jjenkov/javafx-examples/blob/main/src/main/java/com/jenkov/javafx/colorpicker/ColorPickerExample.java)
- [ComboBox Example](https://github.com/jjenkov/javafx-examples/blob/main/src/main/java/com/jenkov/javafx/combobox/ComboBoxExample.java)
- [Concurrency Example](https://github.com/jjenkov/javafx-examples/blob/main/src/main/java/com/jenkov/javafx/concurrency/ConcurrencyExample.java)
- [ContextMenu Example](https://github.com/jjenkov/javafx-examples/blob/main/src/main/java/com/jenkov/javafx/contextmenu/ContextMenuExample.java)
- [DirectoryChooser Example](https://github.com/jjenkov/javafx-examples/blob/main/src/main/java/com/jenkov/javafx/directorychooser/DirectoryChooserExample.java)
- [FileChooser Example](https://github.com/jjenkov/javafx-examples/blob/main/src/main/java/com/jenkov/javafx/filechooser/FileChooserExample.java)
- [Font Example](https://github.com/jjenkov/javafx-examples/blob/main/src/main/java/com/jenkov/javafx/font/FontExample.java)
- [FXML Example](https://github.com/jjenkov/javafx-examples/blob/main/src/main/java/com/jenkov/javafx/fxml/FXMLExample.java)
- [HTMLEditor Example](https://github.com/jjenkov/javafx-examples/blob/main/src/main/java/com/jenkov/javafx/htmleditor/HtmlEditorExample.java)
Hyperlink Examples
- [Hyperlink Example](https://github.com/jjenkov/javafx-examples/blob/main/src/main/java/com/jenkov/javafx/hyperlink/HyperlinkExample.java)
- [Hyperlink Font Example](https://github.com/jjenkov/javafx-examples/blob/main/src/main/java/com/jenkov/javafx/hyperlink/HyperlinkFontExample.java)
- [Hyperlink Change Text Example](https://github.com/jjenkov/javafx-examples/blob/main/src/main/java/com/jenkov/javafx/hyperlink/HyperlinkChangeTextExample.java)
- [ImageView Example](https://github.com/jjenkov/javafx-examples/blob/main/src/main/java/com/jenkov/javafx/imageview/ImageViewExample.java)
- Label Examples
- [Label Example](https://github.com/jjenkov/javafx-examples/blob/main/src/main/java/com/jenkov/javafx/label/LabelExample.java)
- [Label Font Example](https://github.com/jjenkov/javafx-examples/blob/main/src/main/java/com/jenkov/javafx/label/LabelFontExample.java)
- [Label Change Text Example](https://github.com/jjenkov/javafx-examples/blob/main/src/main/java/com/jenkov/javafx/label/LabelChangeTextExample.java)
- [Media Example](https://github.com/jjenkov/javafx-examples/blob/main/src/main/java/com/jenkov/javafx/media/MediaExample.java)
- MenuButton Examples
- [MenuButton Example](https://github.com/jjenkov/javafx-examples/blob/main/src/main/java/com/jenkov/javafx/menubutton/MenuButtonExample.java)
- [MenuButton Font Example](https://github.com/jjenkov/javafx-examples/blob/main/src/main/java/com/jenkov/javafx/menubutton/MenuButtonFontExample.java)
- [MenuButton Icon Example](https://github.com/jjenkov/javafx-examples/blob/main/src/main/java/com/jenkov/javafx/menubutton/MenuButtonIconExample.java)
- [Pagination Example](https://github.com/jjenkov/javafx-examples/blob/main/src/main/java/com/jenkov/javafx/pagination/PaginationExample.java)
- [ProgressBar Example](https://github.com/jjenkov/javafx-examples/blob/main/src/main/java/com/jenkov/javafx/progressbar/ProgressBarExample.java)
- [Properties Example](https://github.com/jjenkov/javafx-examples/blob/main/src/main/java/com/jenkov/javafx/properties/PropertyExample.java)
- [Scene Cursor Example](https://github.com/jjenkov/javafx-examples/blob/main/src/main/java/com/jenkov/javafx/scene/SceneCursorExample.java)
- [ScrollPane Example](https://github.com/jjenkov/javafx-examples/blob/main/src/main/java/com/jenkov/javafx/scrollpane/ScrollPaneExample.java)
- [Separator Example](https://github.com/jjenkov/javafx-examples/blob/main/src/main/java/com/jenkov/javafx/separator/SeparatorExample.java)
- [Slider Example](https://github.com/jjenkov/javafx-examples/blob/main/src/main/java/com/jenkov/javafx/slider/SliderExample.java)
- [SplitMenuButton Example](https://github.com/jjenkov/javafx-examples/blob/main/src/main/java/com/jenkov/javafx/splitmenubutton/SplitMenuButtonExample.java)
- [SplitPane Example](https://github.com/jjenkov/javafx-examples/blob/main/src/main/java/com/jenkov/javafx/splitpane/SplitPaneExample.java)
- Stage Examples
- [Stage Example](https://github.com/jjenkov/javafx-examples/blob/main/src/main/java/com/jenkov/javafx/stage/StageExample.java)
- [Stage Decoration Example](https://github.com/jjenkov/javafx-examples/blob/main/src/main/java/com/jenkov/javafx/stage/StageDecorationExample.java)
- [Multiple Stages Example](https://github.com/jjenkov/javafx-examples/blob/main/src/main/java/com/jenkov/javafx/stage/MultipleStagesExample.java)
- [Multiple Stages Modal Example](https://github.com/jjenkov/javafx-examples/blob/main/src/main/java/com/jenkov/javafx/stage/MultipleStagesModalExample.java)
- [Full Screen Stage Example](https://github.com/jjenkov/javafx-examples/blob/main/src/main/java/com/jenkov/javafx/stage/FullScreenStageExample.java)
- [Auto Shutdown Example](https://github.com/jjenkov/javafx-examples/blob/main/src/main/java/com/jenkov/javafx/stage/AutoShutDownExample.java)
- [Keyboard Events Example](https://github.com/jjenkov/javafx-examples/blob/main/src/main/java/com/jenkov/javafx/stage/StageKeyboardEventsExample.java)
- [TabPane Example](https://github.com/jjenkov/javafx-examples/blob/main/src/main/java/com/jenkov/javafx/tabpane/TabPaneExample.java)
- TableView Examples
- [TableView Example](https://github.com/jjenkov/javafx-examples/blob/main/src/main/java/com/jenkov/javafx/tableview/TableViewExample.java)
- [TableView Editable Column Cells Example](https://github.com/jjenkov/javafx-examples/blob/main/src/main/java/com/jenkov/javafx/tableview/TableViewEditableExample.java)
- [TableView Nested Columns Example](https://github.com/jjenkov/javafx-examples/blob/main/src/main/java/com/jenkov/javafx/tableview/TableViewNestedColumnsExample.java)
- [TableView Selection Model Example](https://github.com/jjenkov/javafx-examples/blob/main/src/main/java/com/jenkov/javafx/tableview/TableViewSelectionModelExample.java)
- [TableView Custom Rendering Example](https://github.com/jjenkov/javafx-examples/blob/main/src/main/java/com/jenkov/javafx/tableview/TableViewCustomRenderingExample.java)
- [TableView Map as Data Items Example](https://github.com/jjenkov/javafx-examples/blob/main/src/main/java/com/jenkov/javafx/tableview/TableViewMapDataItemsExample.java)
- [Text Example](https://github.com/jjenkov/javafx-examples/blob/main/src/main/java/com/jenkov/javafx/text/TextExample.java)
- [TextArea Example](https://github.com/jjenkov/javafx-examples/blob/main/src/main/java/com/jenkov/javafx/textarea/TextAreaExample.java)
- [TextField Example](https://github.com/jjenkov/javafx-examples/blob/main/src/main/java/com/jenkov/javafx/textfield/TextFieldExample.java)
- [TitledPane Example](https://github.com/jjenkov/javafx-examples/blob/main/src/main/java/com/jenkov/javafx/titledpane/TitledPaneExample.java)
- ToggleButton Examples
- [ToggleButton Example](https://github.com/jjenkov/javafx-example/blob/main/src/main/java/com/jenkov/javafx/togglebutton/ToggleButtonExample.java)
- [ToggleButton Font Example](https://github.com/jjenkov/javafx-example/blob/main/src/main/java/com/jenkov/javafx/togglebutton/ToggleButtonFontExample.java)
- [ToolBar Example](https://github.com/jjenkov/javafx-examples/blob/main/src/main/java/com/jenkov/javafx/toolbar/ToolBarExample.java)
- [ToolTip Example](https://github.com/jjenkov/javafx-examples/blob/main/src/main/java/com/jenkov/javafx/tooltip/ToolTipExample.java)
- [TreeTableView Example](https://github.com/jjenkov/javafx-examples/blob/main/src/main/java/com/jenkov/javafx/treetableview/TreeTableViewExample.java)
- [TreeView Example](https://github.com/jjenkov/javafx-examples/blob/main/src/main/java/com/jenkov/javafx/treeview/TreeViewExample.java)
- [VBox Example](https://github.com/jjenkov/javafx-examples/blob/main/src/main/java/com/jenkov/javafx/vbox/VBoxExample.java)
- WebView Examples
- [WebView Example](https://github.com/jjenkov/javafx-examples/blob/main/src/main/java/com/jenkov/javafx/webview/WebViewExample.java)
- [WebView JavaScript Integration Example](https://github.com/jjenkov/javafx-examples/blob/main/src/main/java/com/jenkov/javafx/webview/WebViewJavaScriptIntegrationExample.java)
- [WebView Mouse Wheel Zoom Example](https://github.com/jjenkov/javafx-examples/blob/main/src/main/java/com/jenkov/javafx/webview/WebViewMouseWheelZoomExample.java)
(Mouse wheel zoom code provided by Friedhold Matz (@FriedholdMatz on Twitter))
- 2D Examples
- [2D Basics Example](https://github.com/jjenkov/javafx-examples/blob/main/src/main/java/com/jenkov/javafx/gfx2d/Gfx2DExample.java)
- 3D Examples
- [3D Basics Example](https://github.com/jjenkov/javafx-examples/blob/main/src/main/java/com/jenkov/javafx/gfx3d/Gfx3DExample.java)
- Transformations Examples
- [Transformations Example](https://github.com/jjenkov/javafx-examples/blob/main/src/main/java/com/jenkov/javafx/transformations/TransformationsExample.java)
- [Translate Example](https://github.com/jjenkov/javafx-examples/blob/main/src/main/java/com/jenkov/javafx/transformations/TranslateTransformationsExample.java)
- [Rotate Example](https://github.com/jjenkov/javafx-examples/blob/main/src/main/java/com/jenkov/javafx/transformations/RotateTransformationsExample.java)
- [Scale Example](https://github.com/jjenkov/javafx-examples/blob/main/src/main/java/com/jenkov/javafx/transformations/ScaleTransformationsExample.java)
- Drag and Drop Examples
- [Drag and Drop Example](https://github.com/jjenkov/javafx-examples/blob/main/src/main/java/com/jenkov/javafx/draganddrop/DragAndDropExample.java)
<a name="javafx-advanced-examples"></a>
# JavaFX Advanced Examples
- [Auto-responsive Layout Example](https://github.com/jjenkov/javafx-examples/blob/main/src/main/java/com/jenkov/javafx/layout/AutoResponsiveLayoutExample.java)
| 1 |
mscharhag/blog-examples | null | 2013-11-17T16:07:41Z | null | blog-examples
=============
This repository contains example code for various blog posts on [https://www.mscharhag.com/][1]
[1]:https://www.mscharhag.com/ | 1 |
mswiderski/jbpm-examples | Various examples of jBPM 5 | 2012-07-30T14:11:59Z | null | jbpm-examples
=============
Various examples of jBPM 5 and 6:
- use of jbpm as a framwork
- use of jbpm service
- use of jbpm services with spring to build execution server
| 1 |
streamnative/examples | Apache Pulsar examples and demos | 2019-05-10T15:37:59Z | null | <img src="images/streamnative-logo.png" width="250">
* [Overview](#overview)
# Overview
This is a curated list of demos that showcase Apache Pulsar® messaging and event streaming capabilities.
# Clients
- [PubSub Client Examples](clients/README.md)
# Cloud
- [SteamNative Cloud Examples](cloud/README.md)
# Flink
- [Pulsar Flink Connector](pulsar-flink/README.md)
# Spring for Apache Pulsar
- [Spring for Apache Pulsar Example](spring-pulsar/README.md) | 1 |
m0ver/tinystruct-examples | The framework is quite easy to be used, but in order to help you to understand deeply, we prepared some code examples for your reference. It might be helpful for you to hand it easily. | 2013-02-19T01:10:41Z | null | <img src="https://avatars.githubusercontent.com/u/3723144?s=400&u=6c4b365e7feb0aab20383785d77ba27abf9f5bb8&v=4" title="tinystruct2.0" />
tinystruct framework
=========
[![Build Status](https://travis-ci.org/m0ver/tinystruct-examples.svg?branch=master)](https://travis-ci.org/m0ver/tinystruct2.0)
This is an example project based on tinystruct framework, it supports both C/S application and B/S web application development.
To execute it in CLI mode
---
```tcsh
$ bin/dispatcher --version
_/ ' _ _/ _ _ _/
/ / /) (/ _) / / (/ ( / 1.2.3
/
```
```tcsh
$ bin/dispatcher --help
Usage: bin/dispatcher COMMAND [OPTIONS]
Commands:
download Download a resource from other servers
exec To execute native command(s)
generate POJO object generator
install Install a package
open Start a default browser to open the specific URL
say Output words
set Set system property
sql-execute Executes the given SQL statement, which may be an INSERT, UPDATE, or DELETE statement or an SQL statement that returns nothing, such as an SQL DDL statement.
sql-query Executes the given SQL statement, which returns a single ResultSet object.
update Update for latest version
Options:
--allow-remote-access Allow to be accessed remotely
--help Help command
--host Host name / IP
--import Import application
--logo Print logo
--settings Print settings
--version Print version
Run 'bin/dispatcher COMMAND --help' for more information on a command.
$ bin/dispatcher say/"Praise to the Lord"
Praise to the Lord
```
Run it in a servlet container
---
```tcsh
# bin/dispatcher start --import org.tinystruct.system.TomcatServer
```
Run it in docker container
---
```tcsh
# wget https://github.com/tinystruct/tinystruct2.0/archive/master.zip
# unzip master.zip
# mv tinystruct2.0-master/Dockerfile .
# docker build -t tinystruct-based:1.0 -f Dockerfile .
# docker run -d -p 777:777 tinystruct-based:1.0
```
You can access the below URLs after deployed the project in Tomcat 6.0+ :
* <a href="http://localhost:777/?q=say/Praise%20to%20the%20Lord!">http://localhost:777/?q=say/Praise%20to%20the%20Lord! </a><br />
* <a href="http://localhost:777/?q=praise">http://localhost:777/?q=praise </a><br />
* <a href="http://localhost:777/?q=youhappy">http://localhost:777/?q=youhappy</a><br />
* <a href="http://localhost:777/?q=say/%E4%BD%A0%E7%9F%A5%E9%81%93%E5%85%A8%E4%B8%96%E7%95%8C%E6%9C%80%E7%95%85%E9%94%80%E7%9A%84%E4%B9%A6%E6%98%AF%E5%93%AA%E4%B8%80%E6%9C%AC%E4%B9%A6%E5%90%97%EF%BC%9F">http://localhost:777/?q=say/%E4%BD%A0%E7%9F%A5%E9%81%93%E5%85%A8%E4%B8%96%E7%95%8C%E6%9C%80%E7%95%85%E9%94%80%E7%9A%84%E4%B9%A6%E6%98%AF%E5%93%AA%E4%B8%80%E6%9C%AC%E4%B9%A6%E5%90%97%EF%BC%9F</a>
A demonstration for comet technology, without any websocket and support any web browser:
* <a href="https://tinystruct.herokuapp.com/?q=talk">https://tinystruct.herokuapp.com/?q=talk</a><br />
<img src="example.png" title="smalltalk - tinystruct2.0" height="300"/> <br />
Live Demo Site:
* https://tinystruct.herokuapp.com/
* <a href="https://tinystruct.herokuapp.com/?q=say/Praise%20to%20the%20Lord!">https://tinystruct.herokuapp.com/?q=say/Praise%20to%20the%20Lord! </a><br />
* <a href="https://tinystruct.herokuapp.com/?q=praise">https://tinystruct.herokuapp.com/?q=praise</a><br />
* <a href="https://tinystruct.herokuapp.com/?q=youhappy">https://tinystruct.herokuapp.com/?q=youhappy</a><br />
* <a href="https://tinystruct.herokuapp.com/?q=say/%E4%BD%A0%E7%9F%A5%E9%81%93%E5%85%A8%E4%B8%96%E7%95%8C%E6%9C%80%E7%95%85%E9%94%80%E7%9A%84%E4%B9%A6%E6%98%AF%E5%93%AA%E4%B8%80%E6%9C%AC%E4%B9%A6%E5%90%97%EF%BC%9F">https://tinystruct.herokuapp.com/?q=say/%E4%BD%A0%E7%9F%A5%E9%81%93%E5%85%A8%E4%B8%96%E7%95%8C%E6%9C%80%E7%95%85%E9%94%80%E7%9A%84%E4%B9%A6%E6%98%AF%E5%93%AA%E4%B8%80%E6%9C%AC%E4%B9%A6%E5%90%97%EF%BC%9F</a>
Results in your browser should be:
<blockquote>
<h1>Praise to the Lord!</h1>
Praise to the Lord!
<i>true</i>
<h1>你知道全世界最畅销的书是哪一本书吗?</h1>
</blockquote>
Explore it
--
* Please read more example code in the project.
* Also please see this project:
https://github.com/m0ver/mobile1.0
http://ingod.asia
License
--
Licensed under the Apache License, Version 2.0 (the "License");
you may not use this file except in compliance with the License.
You may obtain a copy of the License at
http://www.apache.org/licenses/LICENSE-2.0
Unless required by applicable law or agreed to in writing, software
distributed under the License is distributed on an "AS IS" BASIS,
WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
See the License for the specific language governing permissions and
limitations under the License.
[![Bitdeli Badge](https://d2weczhvl823v0.cloudfront.net/m0ver/tinystruct2.0/trend.png)](https://bitdeli.com/free "Bitdeli Badge")
| 1 |
googleads/googleads-adsense-examples | Samples for the AdSense Management API | 2014-03-04T17:32:59Z | null | Samples for the AdSense Management API
===========================
The AdSense Management API v2 is
[now availble](https://ads-developers.googleblog.com/2021/04/announcing-v2-of-adsense-management-api.html).
Updated examples can be found for each language in the top-level `v2`
directory.
These code samples are organized by language.
* *dotnet* is a command-line sample that shows how to make most calls against the API, written in C#.
* *java* is a command-line sample that shows how to make most calls against the API, written in Java.
* *php* is a set of samples that shows how to make most calls against the API, written in PHP.
* *python* is a command-line sample that shows how to make most calls against the API, written in Python.
* *ruby* is a set of command-line samples that show how to make most calls against the API, written in Ruby.
Please refer to the README.md file inside each directory for installation instructions.
| 1 |
in28minutes/MavenIn28Minutes | Maven Tutorial for Beginners with Examples | 2015-09-05T14:10:50Z | null | # Maven Tutorial for Beginners - with Examples In28Minutes
[![Image](https://www.springboottutorial.com/images/Course-Maven-Tutorial-Manage-Java-Dependencies-in-20-Steps.png "Maven Tutorial - Manage Java Dependencies in 20 Steps")](https://www.udemy.com/course/learn-maven-java-dependency-management-in-20-steps/)
## Installing Eclipse and Java
https://github.com/in28minutes/SpringIn28Minutes/blob/master/InstallationGuide-JavaEclipseAndMaven_v2.pdf
## Course Overview
- We will use Handson Real World Examples to understand what Maven can do.
- We will understand how Maven makes the life of an application developer easy.
- We will learn how Maven helps us to automate things like compilation, running unit tests, creating a war, creating an ear, running a web application in tomcat.
- We will learn how to use Maven effectively in combination of an IDE like Eclipse.
- We will use
- Maven for dependency management, building and running the application in tomcat.
- Eclipse IDE.
### Step List
Lets now look at the steps in this tutorial.
- Step 1 to 4 we will learn about the basics of Maven : Project Object Model and Build LifeCycle
- Steps 5 and 6 we will learn about dependency management and transitive dependencies
- Step 7 we will learn about a maven project with multiple layers. Typical projects have a web layer, data layer, external interface layer. We will learn how to create such projects using maven. Multi Module Maven Project.
- Step 8 : We will learn how to create a war, deploy to tomcat.
### Running Examples
- If you are downloading the zip file, unzip the file
- Open Command Prompt and Change directory to folder containing pom.xml
- Run command "mvn tomcat7:run"
- For help : user our installation guide - https://github.com/in28minutes/SpringIn28Minutes/blob/master/InstallationGuide-JavaEclipseAndMaven_v2.pdf
### Youtube Video
https://courses.in28minutes.com/p/maven-tutorial-for-beginners-in-5-steps
# 0. What is Maven?
Defining what Maven does is very difficult.
## Every Day Developer
Manages Dependencies - Web Layer (Spring MVC), Data Layer (JPA - Hibernate) etc..
Build a jar or a war or an ear
Run the application locally - Tomcat or Jetty
Deploy to a T environment
Add new dependencies to a project
Run Unit Tests
## Maven helps us do all these and more...
Generate Projects
Create Eclipse Workspace
# 1. Beginner Maven Project
## What is the power of Maven?
#### First Project : My aim is to create a Spring.jar. Think as if you are developing Spring. Some other developers want to use the framework you are developing. Steps in creating a JAr
- App.Java -> App.class
- AppTest.Java -> AppTest.class
- Run Unit Tests
- Package in a particular format
- Earlier this was done using long tedious ant scripts
#### Convention over Configuration
- Pre defined folder structure
- pom.xml
- mvn --version
- mvn compile (compiles source files)
- mvn test-compile (compiles test files) - one thing to observe is this also compiles source files
- mvn clean - deletes target directory
- mvn test - run unit tests
## You are ready for theory on Build Life Cycle
Pre-defined sequence of steps that are done when we run a maven command. Plugins can be attached to lifecycle stages. Default plugins are already defined in the super pom.
mvn install
- package - creates the jar
- install - copies the created jar to local maven repository - a temp folder on my machine where maven stores the files.
### Build LifeCycle
Validate
Compile
Test
Package
Integration Test
Verify
Install
Deploy
## Lets understand pom.xml
### Project Object Model (POM)
Name (if another project want to refer to our project, how do they do it?)
Version (Major Version, Minor Version, Incremental Version)
Packaging
Dependencies
Plugins
### Maven repository stores all the versions of all dependencies. JUnit 4.2,4.3,4.4
### Local Repository - all the dependencies that are downloaded for 1st time are stored.
# 2. Intermediate Maven Project
- Transtive Dependencies (add Hibernate dependency)
- Exclusions - Add an exclude
- Dependency Hierarchy - See how each dependency is coming in
- Versions [4.1,] [,4.1] [,4.1)
- Scope - Dependencies are needed only for tests. They are not part of the war or jar. we can use scope for that.
- Maven Compiler Plugin - Change source from 1.5 to 1.8.
- Effective Pom - Super Pom (Similar to Java Inheritance) - Check the build part of super pom (Convention over configuration - defaults are defined). We can change it - for example source directory. Recommended not to override defaults. Easy to move from one project to another project. Definitions of various plugins. mvn help:effective-pom
## Dependency Management
Scope
Transitive Dependencies
Excluding Dependency
Dependency Versions
## Sample Project Object Model
Maven Plugins
Convention over configuration
Source Code
${basedir}/src/main/java
${basedir}/src/main/resources
Test Code
${basedir}/src/test
## Hierarchy of POMS
Super POM
# 3. Multi Module Maven Project
- Most projects have multiple layers. Each layer has its own dependencies. Also multiple layers may share same dependency. We will see the best practices in managing dependencies in a multi module maven project.
- Parent pom has type pom
- - Defines Modules
- Dependency Management Section
- Properties
- Pre-defined Variables ${project.version}
- Run from command prompt - mvn clean install
# 4. Maven Web Application
## Packaging
War
Ear
## Running application in Tomcat
# 5. Tip and Tricks
## Important Commands
help:effective-settings
help:effective-pom
dependency:tree
dependency:sources
--debug
## Maven Archetypes
archetype:generate
# 6. Missing (To Discuss)
- Plugins : Show in super pom.xml
- Eclipse Integration
- Profiles
### Expectations
- You should know Java.
### Running Examples
- Download the zip or clone the Git repository.
- Unzip the zip file (if you downloaded one)
- Open Command Prompt and Change directory (cd) to folder containing pom.xml
- Open Eclipse
- File -> Import -> Existing Maven Project -> Navigate to the folder where you unzipped the zip
- Select the right project
- Choose the Spring Boot Application file (search for @SpringBootApplication)
- Right Click on the file and Run as Java Application
- You are all Set
### Troubleshooting
- Refer our TroubleShooting Guide - https://github.com/in28minutes/in28minutes-initiatives/tree/master/The-in28Minutes-TroubleshootingGuide-And-FAQ
## Youtube Playlists - 500+ Videos
[Click here - 30+ Playlists with 500+ Videos on Spring, Spring Boot, REST, Microservices and the Cloud](https://www.youtube.com/user/rithustutorials/playlists?view=1&sort=lad&flow=list)
## Keep Learning in28Minutes
in28Minutes is creating amazing solutions for you to learn Spring Boot, Full Stack and the Cloud - Docker, Kubernetes, AWS, React, Angular etc. - [Check out all our courses here](https://github.com/in28minutes/learn)
| 1 |
resteasy/resteasy-examples | RESTEasy examples | 2016-05-24T08:09:29Z | null | null | 1 |
aliyun/tablestore-examples | Example code for aliyun tablestore. | 2019-03-13T07:29:58Z | null | # Aliyun TableStore Examples
[![License Status](https://img.shields.io/badge/license-apache2-brightgreen.svg)](https://travis-ci.org/aliyun/aliyun-tablestore-nodejs-sdk)
## [Click here for the English README](README_EN.md)
**目录**
- [1、项目结构](#1%E9%A1%B9%E7%9B%AE%E7%BB%93%E6%9E%84)
- [2、开通与配置](#2%E5%BC%80%E9%80%9A%E4%B8%8E%E9%85%8D%E7%BD%AE)
- [开通服务、创建实例、获取AK](#%E5%BC%80%E9%80%9A%E6%9C%8D%E5%8A%A1%E5%88%9B%E5%BB%BA%E5%AE%9E%E4%BE%8B%E8%8E%B7%E5%8F%96ak)
- [完成配置](#%E5%AE%8C%E6%88%90%E9%85%8D%E7%BD%AE)
- [3、样例统计](#3%E6%A0%B7%E4%BE%8B%E7%BB%9F%E8%AE%A1)
- [demos(场景样例)](#demos%E5%9C%BA%E6%99%AF%E6%A0%B7%E4%BE%8B)
- [tools(迁移、计算等工具)](#tools%E8%BF%81%E7%A7%BB%E8%AE%A1%E7%AE%97%E7%AD%89%E5%B7%A5%E5%85%B7)
- [feature(SDK基础功能)](#featuresdk%E5%9F%BA%E7%A1%80%E5%8A%9F%E8%83%BD)
- [4、使用提醒](#4%E4%BD%BF%E7%94%A8%E6%8F%90%E9%86%92)
- [资源释放](#%E8%B5%84%E6%BA%90%E9%87%8A%E6%94%BE)
- [5、咨询/答疑/反馈](#5%E5%92%A8%E8%AF%A2%E7%AD%94%E7%96%91%E5%8F%8D%E9%A6%88)
- [联系方式:](#%E8%81%94%E7%B3%BB%E6%96%B9%E5%BC%8F)
# 1、项目结构
- 根据功能,分为3个模块(场景样例/迁移、计算等工具/SDK基础功能),
- 每个项目名下对应独立的Example项目
```
├── README.md
├── demos #场景样例
│ ├── IMChart #即时聊天系统
│ ├── SharingCarManagement #共享汽车管理
│ ├── SportTrack #运动轨迹
│ ├── insurance-policy-management #保险单管理系统
│ ├── TraceMedicine #药品监管(溯源)系统
│ ├── TableStore-Grid #气象格点数据解决方案
│ ├── MailManagement #基于Timestream的快递轨迹管理
│ ├── WifiMonitor #基于Timestream的Wifi监控系统
│ ├── Orders #基于 MySQL + Tablestore 分层存储的大规模订单系统系列测试代码
│ └── Canal-press #基于 MySQL + Tablestore 分层存储的大规模订单系统系列中canal部分压测代码
│
├── tools #工具/产品
│ ├── Dts-MySQL2TableStore #MySQL增量数据迁移表格存储
│ └── Datax-MySQL2TableStore #MySQL数据迁移表格存储
│
└── feature #SDK基础功能
├── TableCopy #数据复制(表级别)
├── FuzzySearch #模糊查询
└── AggregationAndGroupBy #统计聚合
```
# 2、开通与配置
## 开通服务、创建实例、获取AK
- [控制台](https://ots.console.aliyun.com): https://ots.console.aliyun.com
- [开通服务](https://help.aliyun.com/document_detail/27287.html): https://help.aliyun.com/document_detail/27287.html
- [创建实例](https://help.aliyun.com/document_detail/55211.html): https://help.aliyun.com/document_detail/55211.html
- [获取AK](https://usercenter.console.aliyun.com/#/manage/ak): https://usercenter.console.aliyun.com/#/manage/ak
## 完成配置
在home目录下创建tablestoreCong.json文件,填写相应参数,所有独立项目都会使用该配置
```
# mac 或 linux系统下:/home/userhome/tablestoreConf.json
# windows系统下: C:\Documents and Settings\%用户名%\tablestoreConf.json
{
"endpoint": "http://instanceName.cn-hangzhou.ots.aliyuncs.com",
"accessId": "***********",
"accessKey": "***********************",
"instanceName": "instanceName"
}
```
- endpoint:实例的接入地址,控制台实例详情页获取;
- accessId:AK的ID,获取AK链接提供;
- accessKey:AK的密码,获取AK链接提供;
- instanceName:使用的实例名;
# 3、项目统计
## [demos(场景样例)](/demos)
样例 | 语言 | 项目名
--- | --- | ---
基于 MySQL + Tablestore 分层存储架构的大规模订单系统实践-架构篇 | java | [Orders](/demos/Orders)
基于 MySQL + Tablestore 分层存储架构的大规模订单系统实践-数据同步 Canal 篇 | java | [Canal-press](/demos/Canal-press)
[即时聊天系统](https://yq.aliyun.com/articles/710363) | java | [IMChart](/demos/ImChart)
[共享汽车管理](https://yq.aliyun.com/articles/703177) | java | [SharingCarManagement](/demos/SharingCarManagement)
[运动轨迹管理](https://yq.aliyun.com/articles/702482) | java | [SportTrack](/demos/SportTrack)
[保险单管理系统](https://yq.aliyun.com/articles/699669) | java | [insurance-policy-management](/demos/insurance-policy-management)
[药品监管(溯源)系统](https://yq.aliyun.com/articles/699636) | java | [TraceMedicine](/demos/TraceMedicine)
[气象格点数据解决方案](https://yq.aliyun.com/articles/698313) | java | [TableStore-Grid](/demos/TableStore-Grid)
[基于Timestream的Wifi监控系统](https://yq.aliyun.com/articles/698591) | java | [WifiMonitor](/demos/WifiMonitor)
[基于Timestream的快递轨迹管理](https://yq.aliyun.com/articles/698551) | java | [MailManagement](/demos/MailManagement)
## tools(迁移、计算等工具)
场景 | 工具 | 项目名
--- | --- | ---
[MySQL数据迁移表格存储](https://yq.aliyun.com/articles/698973) | datax | [Datax-MySQL2TableStore](/tools/Datax-MySQL2TableStore)
[MySQL增量数据导入表格存储](https://yq.aliyun.com/articles/708325) | DTS | [Dts-MySQL2TableStore](/tools/Dts-MySQL2TableStore)
## feature(Tablestore功能)
功能 | 语言(SDK) | 项目名
--- | --- | ---
[表级别数据复制](https://yq.aliyun.com/articles/706791) | java | [TableCopy](/feature/TableCopy)
[模糊查询](https://yq.aliyun.com/articles/703707) | java | [FuzzySearch](/feature/FuzzySearch)
统计聚合 | java | [AggregationAndGroupBy](/feature/AggregationAndGroupBy)
[Tablestore Spark Demo](/feature/TableStoreSparkDemo/README.md) | scala | [TableStoreSparkDemo](/feature/TableStoreSparkDemo)
## basic(SDK基础使用)
功能 | 语言(SDK) | 项目名
--- | --- | ---
基础使用 | java | [Java SDK 使用](/basic/Java)
# 4、使用提醒
## 资源释放
- 删除无用索引、无用数据、无用表格等
- 释放相应资源,避免持续收费
# 5、咨询/答疑/反馈
## 联系方式:
- 钉钉群: 表格存储技术交流群-2
- 群号: 23307953
- 二维码:
![二维码](image/QRcode.png)
| 1 |
ttrelle/spring-data-examples | Examples for using Spring Data for JPA, MongoDB, Neo4j, Redis | 2011-12-23T10:11:17Z | null | # Spring Data Blog Series
This projects holds the Java source examples for my blog post series on the Spring Data project:
* [GridFS Support in Spring Data MongoDB](http://blog.codecentric.de/en/2012/07/gridfs-support-in-spring-data-mongodb/)
* [Part 6: Spring Data Redis](http://blog.codecentric.de/en/2012/04/spring-data-redis/)
* [Part 5: Spring Data Neo4j](http://blog.codecentric.de/en/2012/02/spring-data-neo4j/)
* [Part 4: Geospatial Queries with Spring Data MongoDB](http://blog.codecentric.de/en/2012/02/spring-data-mongodb-geospatial-queries/)
* [Part 3: Spring Data MongoDB](http://blog.codecentric.de/en/2012/02/spring-data-mongodb/)
* [Part 2: Spring Data JPA](http://blog.codecentric.de/en/2012/01/spring-data-jpa/)
* [Part 1: Spring Data Commons](http://blog.codecentric.de/en/2011/12/spring-data-commons/)
## Build Status @ Travis CI ##
[![Build Status](https://travis-ci.org/ttrelle/spring-data-examples.png?branch=master)](https://travis-ci.org/ttrelle/spring-data-examples)
## Usage
The projects are using a Maven based build. To run the tests on the command line use
mvn clean test
If you want to use an IDE like Eclipse run
mvn eclipse:eclipse
and set the Eclipse variable M2_REPO pointing to your local Maven repository. Or just import the project as an existing Maven project if you are using the m2 plugin.
| 1 |
swagger-api/swagger-core | Examples and server integrations for generating the Swagger API Specification, which enables easy access to your REST API | 2011-07-05T23:44:11Z | null | # Swagger Core <img src="https://raw.githubusercontent.com/swagger-api/swagger.io/wordpress/images/assets/SW-logo-clr.png" height="50" align="right">
**NOTE:** If you're looking for Swagger Core 1.5.X and OpenAPI 2.0, please refer to [1.5 branch](https://github.com/swagger-api/swagger-core/tree/1.5).
**NOTE:** Since version 2.1.7, Swagger Core also supports the Jakarta namespace. There are a parallel set of artifacts with the `-jakarta` suffix, providing the same functionality as the unsuffixed (i.e.: `javax`) artifacts.
Please see the [Wiki](https://github.com/swagger-api/swagger-core/wiki/Swagger-2.X---Getting-started) for more details.
**NOTE:** Since version 2.2.0 Swagger Core supports OpenAPI 3.1; see [this page](https://github.com/swagger-api/swagger-core/wiki/Swagger-2.X---OpenAPI-3.1) for details
![Build Test Deploy](https://github.com/swagger-api/swagger-core/workflows/Build%20Test%20Deploy%20master/badge.svg?branch=master)
[![Maven Central](https://maven-badges.herokuapp.com/maven-central/io.swagger.core.v3/swagger-project/badge.svg?style=plastic)](https://maven-badges.herokuapp.com/maven-central/io.swagger.core.v3/swagger-project)
Swagger Core is a Java implementation of the OpenAPI Specification. Current version supports *JAX-RS2* (`javax` and `jakarta` namespaces).
## Get started with Swagger Core!
See the guide on [getting started with Swagger Core](https://github.com/swagger-api/swagger-core/wiki/Swagger-2.X---Getting-started) to get started with adding Swagger to your API.
## See the Wiki!
The [github wiki](https://github.com/swagger-api/swagger-core/wiki) contains documentation, samples, contributions, etc. Start there.
## Compatibility
The OpenAPI Specification has undergone several revisions since initial creation in 2010. The Swagger Core project has the following compatibilities with the OpenAPI Specification:
Swagger core Version | Release Date | OpenAPI Spec compatibility | Notes | Status
------------------------- | ------------ | -------------------------- | ----- | ----
2.2.21 (**current stable**)| 2024-03-20 | 3.x | [tag v2.2.21](https://github.com/swagger-api/swagger-core/tree/v2.2.21) | Supported
2.2.20 | 2023-12-19 | 3.x | [tag v2.2.20](https://github.com/swagger-api/swagger-core/tree/v2.2.20) | Supported
2.2.19 | 2023-11-10 | 3.x | [tag v2.2.19](https://github.com/swagger-api/swagger-core/tree/v2.2.19) | Supported
2.2.18 | 2023-10-25 | 3.x | [tag v2.2.18](https://github.com/swagger-api/swagger-core/tree/v2.2.18) | Supported
2.2.17 | 2023-10-12 | 3.x | [tag v2.2.17](https://github.com/swagger-api/swagger-core/tree/v2.2.17) | Supported
2.2.16 | 2023-09-18 | 3.x | [tag v2.2.16](https://github.com/swagger-api/swagger-core/tree/v2.2.16) | Supported
2.2.15 | 2023-07-08 | 3.x | [tag v2.2.15](https://github.com/swagger-api/swagger-core/tree/v2.2.15) | Supported
2.2.14 | 2023-06-26 | 3.x | [tag v2.2.14](https://github.com/swagger-api/swagger-core/tree/v2.2.14) | Supported
2.2.13 | 2023-06-24 | 3.x | [tag v2.2.13](https://github.com/swagger-api/swagger-core/tree/v2.2.13) | Supported
2.2.12 | 2023-06-13 | 3.x | [tag v2.2.12](https://github.com/swagger-api/swagger-core/tree/v2.2.12) | Supported
2.2.11 | 2023-06-01 | 3.x | [tag v2.2.11](https://github.com/swagger-api/swagger-core/tree/v2.2.11) | Supported
2.2.10 | 2023-05-15 | 3.x | [tag v2.2.10](https://github.com/swagger-api/swagger-core/tree/v2.2.10) | Supported
2.2.9 | 2023-03-20 | 3.x | [tag v2.2.9](https://github.com/swagger-api/swagger-core/tree/v2.2.9) | Supported
2.2.8 | 2023-01-06 | 3.x | [tag v2.2.8](https://github.com/swagger-api/swagger-core/tree/v2.2.8) | Supported
2.2.7 | 2022-11-15 | 3.0 | [tag v2.2.7](https://github.com/swagger-api/swagger-core/tree/v2.2.7) | Supported
2.2.6 | 2022-11-02 | 3.0 | [tag v2.2.6](https://github.com/swagger-api/swagger-core/tree/v2.2.6) | Supported
2.2.5 | 2022-11-02 | 3.0 | [tag v2.2.5](https://github.com/swagger-api/swagger-core/tree/v2.2.5) | Supported
2.2.4 | 2022-10-16 | 3.0 | [tag v2.2.4](https://github.com/swagger-api/swagger-core/tree/v2.2.4) | Supported
2.2.3 | 2022-09-27 | 3.0 | [tag v2.2.3](https://github.com/swagger-api/swagger-core/tree/v2.2.3) | Supported
2.2.2 | 2022-07-20 | 3.0 | [tag v2.2.2](https://github.com/swagger-api/swagger-core/tree/v2.2.2) | Supported
2.2.1 | 2022-06-15 | 3.0 | [tag v2.2.1](https://github.com/swagger-api/swagger-core/tree/v2.2.1) | Supported
2.2.0 | 2022-04-04 | 3.0 | [tag v2.2.0](https://github.com/swagger-api/swagger-core/tree/v2.2.0) | Supported
2.1.13 | 2022-02-07 | 3.0 | [tag v2.1.13](https://github.com/swagger-api/swagger-core/tree/v2.1.13) | Supported
2.1.12 | 2021-12-23 | 3.0 | [tag v2.1.12](https://github.com/swagger-api/swagger-core/tree/v2.1.12) | Supported
2.1.11 | 2021-09-29 | 3.0 | [tag v2.1.11](https://github.com/swagger-api/swagger-core/tree/v2.1.11) | Supported
2.1.10 | 2021-06-28 | 3.0 | [tag v2.1.10](https://github.com/swagger-api/swagger-core/tree/v2.1.10) | Supported
2.1.9 | 2021-04-20 | 3.0 | [tag v2.1.9](https://github.com/swagger-api/swagger-core/tree/v2.1.9) | Supported
2.1.8 | 2021-04-18 | 3.0 | [tag v2.1.8](https://github.com/swagger-api/swagger-core/tree/v2.1.8) | Supported
2.1.7 | 2021-02-18 | 3.0 | [tag v2.1.7](https://github.com/swagger-api/swagger-core/tree/v2.1.7) | Supported
2.1.6 | 2020-12-04 | 3.0 | [tag v2.1.6](https://github.com/swagger-api/swagger-core/tree/v2.1.6) | Supported
2.1.5 | 2020-10-01 | 3.0 | [tag v2.1.5](https://github.com/swagger-api/swagger-core/tree/v2.1.5) | Supported
2.1.4 | 2020-07-24 | 3.0 | [tag v2.1.4](https://github.com/swagger-api/swagger-core/tree/v2.1.4) | Supported
2.1.3 | 2020-06-27 | 3.0 | [tag v2.1.3](https://github.com/swagger-api/swagger-core/tree/v2.1.3) | Supported
2.1.2 | 2020-04-01 | 3.0 | [tag v2.1.2](https://github.com/swagger-api/swagger-core/tree/v2.1.2) | Supported
2.1.1 | 2020-01-02 | 3.0 | [tag v2.1.1](https://github.com/swagger-api/swagger-core/tree/v2.1.1) | Supported
2.1.0 | 2019-11-16 | 3.0 | [tag v2.1.0](https://github.com/swagger-api/swagger-core/tree/v2.1.0) | Supported
2.0.10 | 2019-10-11 | 3.0 | [tag v2.0.10](https://github.com/swagger-api/swagger-core/tree/v2.0.10) | Supported
2.0.9 | 2019-08-22 | 3.0 | [tag v2.0.9](https://github.com/swagger-api/swagger-core/tree/v2.0.9) | Supported
2.0.8 | 2019-04-24 | 3.0 | [tag v2.0.8](https://github.com/swagger-api/swagger-core/tree/v2.0.8) | Supported
2.0.7 | 2019-02-18 | 3.0 | [tag v2.0.7](https://github.com/swagger-api/swagger-core/tree/v2.0.7) | Supported
2.0.6 | 2018-11-27 | 3.0 | [tag v2.0.6](https://github.com/swagger-api/swagger-core/tree/v2.0.6) | Supported
2.0.5 | 2018-09-19 | 3.0 | [tag v2.0.5](https://github.com/swagger-api/swagger-core/tree/v2.0.5) | Supported
2.0.4 | 2018-09-05 | 3.0 | [tag v2.0.4](https://github.com/swagger-api/swagger-core/tree/v2.0.4) | Supported
2.0.3 | 2018-08-09 | 3.0 | [tag v2.0.3](https://github.com/swagger-api/swagger-core/tree/v2.0.3) | Supported
1.6.14 (**current stable**)| 2024-03-19 | 2.0 | [tag v1.6.14](https://github.com/swagger-api/swagger-core/tree/v1.6.14) | Supported
1.6.13 | 2024-01-26 | 2.0 | [tag v1.6.13](https://github.com/swagger-api/swagger-core/tree/v1.6.13) | Supported
1.6.12 | 2023-10-14 | 2.0 | [tag v1.6.12](https://github.com/swagger-api/swagger-core/tree/v1.6.12) | Supported
1.6.11 | 2023-05-15 | 2.0 | [tag v1.6.11](https://github.com/swagger-api/swagger-core/tree/v1.6.11) | Supported
1.6.10 | 2023-03-21 | 2.0 | [tag v1.6.10](https://github.com/swagger-api/swagger-core/tree/v1.6.10) | Supported
1.6.9 | 2022-11-15 | 2.0 | [tag v1.6.9](https://github.com/swagger-api/swagger-core/tree/v1.6.9) | Supported
1.6.8 | 2022-10-16 | 2.0 | [tag v1.6.8](https://github.com/swagger-api/swagger-core/tree/v1.6.8) | Supported
1.6.7 | 2022-09-27 | 2.0 | [tag v1.6.7](https://github.com/swagger-api/swagger-core/tree/v1.6.7) | Supported
1.6.6 | 2022-04-04 | 2.0 | [tag v1.6.6](https://github.com/swagger-api/swagger-core/tree/v1.6.6) | Supported
1.6.5 | 2022-02-07 | 2.0 | [tag v1.6.5](https://github.com/swagger-api/swagger-core/tree/v1.6.5) | Supported
1.6.4 | 2021-12-23 | 2.0 | [tag v1.6.4](https://github.com/swagger-api/swagger-core/tree/v1.6.4) | Supported
1.6.3 | 2021-09-29 | 2.0 | [tag v1.6.3](https://github.com/swagger-api/swagger-core/tree/v1.6.3) | Supported
1.6.2 | 2020-07-01 | 2.0 | [tag v1.6.2](https://github.com/swagger-api/swagger-core/tree/v1.6.2) | Supported
1.6.1 | 2020-04-01 | 2.0 | [tag v1.6.1](https://github.com/swagger-api/swagger-core/tree/v1.6.1) | Supported
1.6.0 | 2019-11-16 | 2.0 | [tag v1.6.0](https://github.com/swagger-api/swagger-core/tree/v1.6.0) | Supported
1.5.24 | 2019-10-11 | 2.0 | [tag v1.5.24](https://github.com/swagger-api/swagger-core/tree/v1.5.24) | Supported
1.5.23 | 2019-08-22 | 2.0 | [tag v1.5.23](https://github.com/swagger-api/swagger-core/tree/v1.5.23) | Supported
1.5.22 | 2019-02-18 | 2.0 | [tag v1.5.22](https://github.com/swagger-api/swagger-core/tree/v1.5.22) | Supported
1.5.21 | 2018-08-09 | 2.0 | [tag v1.5.21](https://github.com/swagger-api/swagger-core/tree/v1.5.21) | Supported
1.5.20 | 2018-05-23 | 2.0 | [tag v1.5.20](https://github.com/swagger-api/swagger-core/tree/v1.5.20) | Supported
2.0.2 | 2018-05-23 | 3.0 | [tag v2.0.2](https://github.com/swagger-api/swagger-core/tree/v2.0.2) | Supported
2.0.1 | 2018-04-16 | 3.0 | [tag v2.0.1](https://github.com/swagger-api/swagger-core/tree/v2.0.1) | Supported
1.5.19 | 2018-04-16 | 2.0 | [tag v1.5.19](https://github.com/swagger-api/swagger-core/tree/v1.5.19) | Supported
2.0.0 | 2018-03-20 | 3.0 | [tag v2.0.0](https://github.com/swagger-api/swagger-core/tree/v2.0.0) | Supported
2.0.0-rc4 | 2018-01-22 | 3.0 | [tag v2.0.0-rc4](https://github.com/swagger-api/swagger-core/tree/v2.0.0-rc4) | Supported
2.0.0-rc3 | 2017-11-21 | 3.0 | [tag v2.0.0-rc3](https://github.com/swagger-api/swagger-core/tree/v2.0.0-rc3) | Supported
2.0.0-rc2 | 2017-09-29 | 3.0 | [tag v2.0.0-rc2](https://github.com/swagger-api/swagger-core/tree/v2.0.0-rc2) | Supported
2.0.0-rc1 | 2017-08-17 | 3.0 | [tag v2.0.0-rc1](https://github.com/swagger-api/swagger-core/tree/v2.0.0-rc1) | Supported
1.5.18 | 2018-01-22 | 2.0 | [tag v1.5.18](https://github.com/swagger-api/swagger-core/tree/v1.5.18) | Supported
1.5.17 | 2017-11-21 | 2.0 | [tag v1.5.17](https://github.com/swagger-api/swagger-core/tree/v1.5.17) | Supported
1.5.16 | 2017-07-15 | 2.0 | [tag v1.5.16](https://github.com/swagger-api/swagger-core/tree/v1.5.16) | Supported
1.3.12 | 2014-12-23 | 1.2 | [tag v1.3.12](https://github.com/swagger-api/swagger-core/tree/v1.3.12) | Supported
1.2.4 | 2013-06-19 | 1.1 | [tag swagger-project_2.10.0-1.2.4](https://github.com/swagger-api/swagger-core/tree/swagger-project_2.10.0-1.2.4) | Deprecated
1.0.0 | 2011-10-16 | 1.0 | [tag v1.0](https://github.com/swagger-api/swagger-core/tree/v1.0) | Deprecated
### Change History
If you're interested in the change history of swagger and the Swagger Core framework, see [here](https://github.com/swagger-api/swagger-core/releases).
### Prerequisites
You need the following installed and available in your $PATH:
* Java 11
* Apache maven 3.0.4 or greater
* Jackson 2.4.5 or greater
### To build from source (currently 2.2.22-SNAPSHOT)
```
# first time building locally
mvn -N
```
Subsequent builds:
```
mvn install
```
This will build the modules.
Of course if you don't want to build locally you can grab artifacts from maven central:
`https://repo1.maven.org/maven2/io/swagger/core/`
## Sample Apps
The samples have moved to [a new repository](https://github.com/swagger-api/swagger-samples/tree/2.0) and contain various integrations and configurations.
## Security contact
Please disclose any security-related issues or vulnerabilities by emailing [security@swagger.io](mailto:security@swagger.io), instead of using the public issue tracker.
| 1 |
langchain4j/langchain4j-examples | null | 2023-06-20T16:04:18Z | null | # [LangChain4j](https://github.com/langchain4j/langchain4j) Examples
This repository provides several examples using the LangChain4j library.
A good place to start includes:
- [Tutorials](https://github.com/langchain4j/langchain4j-examples/tree/main/tutorials/src/main/java)
- [More examples](https://github.com/langchain4j/langchain4j-examples/tree/main/other-examples/src/main/java)
- [Examples of using advanced RAG techniques](https://github.com/langchain4j/langchain4j-examples/tree/main/rag-examples/src/main/java)
- [Example of an agent with memory, tools and RAG](https://github.com/langchain4j/langchain4j-examples/blob/5a19b723661530cf64846a256e2b01b060e7fb0b/customer-support-agent-example/src/main/java/dev/langchain4j/example/CustomerSupportAgentApplication.java#L39)
If you have any issues or feature requests, please submit them [here](https://github.com/langchain4j/langchain4j/issues/new/choose).
| 1 |
eazybytes/microservices-with-spring-sectionwise-code | Microservices With Spring, Docker, Kubernetes - Code Examples | 2021-09-27T10:05:16Z | null | # This repo belongs to older version of the course. For the current version of the microservice course, please use below GitHub repo,
https://github.com/eazybytes/microservices
| 1 |
GoogleCloudPlatform/cloud-build-samples | Code snippets used in Cloud Build documentation | 2021-03-04T21:25:11Z | null | # code-examples
This repository contains code examples used in the official Cloud Build [documentation](https://cloud.google.com/build/docs/).
## Contributing changes
### New samples
- New samples are accepted at reviewer discretion.
- New samples should come with a `README` either linking to documentation or explaining how to use the sample directly. If the `README` is excessively long, the instructions should be moved to a tutorial and linked from the `README`.
- The configuration file (e.g. `cloudbuild.yaml`) should be able to run as part of automated testing. This means that in general, the file should contain substitutions rather than dummy values that the user has to manually replace. _Some exceptions to this rule may be allowed with sufficient justification_.
- Sample should be readable. Use clear comments, descriptive variable names, and try to avoid excessively long lines.
### Bug Fixes
- Bug fixes are welcome, either as pull requests or as GitHub issues.
See [CONTRIBUTING.md](CONTRIBUTING.md) for details on how to contribute.
| 1 |
openjfx/samples | JavaFX samples to run with different options and build tools | 2018-11-02T10:44:22Z | null | OpenJFX Docs Samples
===
Description
---
This repository contains a collection of HelloFX samples. Each one is a very simple
HelloWorld sample created with JavaFX that can be run with different options and build tools.
The related documentation for each sample can be found [here](https://openjfx.io/openjfx-docs/).
For more information go to https://openjfx.io.
Content
---
* [HelloFX samples](#HelloFX-Samples)
* [Command Line](#Command-Line)
- [_Modular samples_](#CLI-Modular-Samples)
- [_Non-modular samples_](#CLI-Non-Modular-Samples)
* [IDEs](#IDEs)
- [IntelliJ](#IntelliJ)
[_Modular samples_](#IntelliJ-Modular-Samples)
[_Non-modular samples_](#IntelliJ-Non-Modular-Samples)
- [NetBeans](#NetBeans)
[_Modular samples_](#NetBeans-Modular-Samples)
[_Non-modular samples_](#NetBeans-Non-Modular-Samples)
- [Eclipse](#Eclipse)
[_Modular samples_](#Eclipse-Modular-Samples)
[_Non-modular samples_](#Eclipse-Non-Modular-Samples)
- [Visual Studio Code](#VSCode)
[_Modular samples_](#VSCode-Modular-Samples)
[_Non-modular samples_](#VSCode-Non-Modular-Samples)
* [License](#License)
* [Contributing](#Contributing)
HelloFX samples<a name="HelloFX-Samples" />
---
Contains samples of a simple HelloFX class that can be run from command line, with
or without build tools.
Build Tool | Sample | Description
---------- | ------ | -----------
None | [HelloFX project](HelloFX/CLI) | Simple HelloFX class to run on command line.
Maven | [HelloFX project](HelloFX/Maven) | Simple HelloFX class to run with Maven.
Gradle | [HelloFX project](HelloFX/Gradle) | Simple HelloFX class to run with Gradle.
Command Line<a name="Command-Line" />
---
Contains samples of modular and non-modular projects that can be run from command
line, with or without build tools.
### _Modular samples_<a name="CLI-Modular-Samples" />
Build Tool | Sample | Description
---------- | ------ | -----------
None | [HelloFX project](CommandLine/Modular/CLI) | Modular project to run on command line.
Maven | [HelloFX project](CommandLine/Modular/Maven) | Modular project to run with Maven.
Gradle | [HelloFX project](CommandLine/Modular/Gradle) | Modular project to run with Gradle.
### _Non-modular samples_<a name="CLI-Non-Modular-Samples" />
Build Tool | Sample | Description
---------- | ------ | -----------
None | [HelloFX project](CommandLine/Non-modular/CLI) | Non-modular project to run on command line.
Maven | [HelloFX project](CommandLine/Non-modular/Maven) | Non-modular project to run with Maven.
Gradle | [HelloFX project](CommandLine/Non-modular/Gradle) | Non-modular project to run with Gradle.
IDEs<a name="IDEs" />
---
Contains samples of modular and non-modular projects that can be run from an IDE,
with or without build tools.
### IntelliJ<a name="IntelliJ" />
#### _Modular samples_<a name="IntelliJ-Modular-Samples" />
Build Tool | Sample | Description
---------- | ------ | -----------
Java | [HelloFX project](IDE/IntelliJ/Modular/Java) | Modular project to run from IntelliJ.
Maven | [HelloFX project](IDE/IntelliJ/Modular/Maven) | Modular project to run from IntelliJ, with Maven.
Gradle | [HelloFX project](IDE/IntelliJ/Modular/Gradle) | modular project to run from IntelliJ, with Gradle.
#### _Non-modular samples_<a name="IntelliJ-Non-Modular-Samples" />
Build Tool | Sample | Description
---------- | ------ | -----------
Java | [HelloFX project](IDE/IntelliJ/Non-Modular/Java) | Non-modular project to run from IntelliJ.
Maven | [HelloFX project](IDE/IntelliJ/Non-Modular/Maven) | Non-modular project to run from IntelliJ, with Maven.
Gradle | [HelloFX project](IDE/IntelliJ/Non-Modular/Gradle) | Non-modular project to run from IntelliJ, with Gradle.
### NetBeans<a name="NetBeans" />
#### _Modular samples_<a name="NetBeans-Modular-Samples" />
Build Tool | Sample | Description
---------- | ------ | -----------
Java | [HelloFX project](IDE/NetBeans/Modular/Java) | Modular project to run from NetBeans.
Maven | [HelloFX project](IDE/NetBeans/Modular/Maven) | Modular project to run from NetBeans, with Maven.
Gradle | [HelloFX project](IDE/NetBeans/Modular/Gradle) | Modular project to run from NetBeans, with Gradle.
#### _Non-modular samples_<a name="NetBeans-Non-Modular-Samples" />
Build Tool | Sample | Description
---------- | ------ | -----------
Java | [HelloFX project](IDE/NetBeans/Non-Modular/Java) | Non-modular project to run from NetBeans.
Maven | [HelloFX project](IDE/NetBeans/Non-Modular/Maven) | Non-modular project to run from NetBeans, with Maven.
Gradle | [HelloFX project](IDE/NetBeans/Non-Modular/Gradle) | Non-modular project to run from NetBeans, with Gradle.
### Eclipse<a name="Eclipse" />
#### _Modular samples_<a name="Eclipse-Modular-Samples" />
Build Tool | Sample | Description
---------- | ------ | -----------
Java | [HelloFX project](IDE/Eclipse/Modular/Java) | Modular project to run from Eclipse.
Maven | [HelloFX project](IDE/Eclipse/Modular/Maven) | Modular project to run from Eclipse, with Maven.
Gradle | [HelloFX project](IDE/Eclipse/Modular/Gradle) | Modular project to run from Eclipse, with Gradle.
#### _Non-modular samples_<a name="Eclipse-Non-Modular-Samples" />
Build Tool | Sample | Description
---------- | ------ | -----------
Java | [HelloFX project](IDE/Eclipse/Non-Modular/Java) | Non-modular project to run from Eclipse.
Maven | [HelloFX project](IDE/Eclipse/Non-Modular/Maven) | Non-modular project to run from Eclipse, with Maven.
Gradle | [HelloFX project](IDE/Eclipse/Non-Modular/Gradle) | Non-modular project to run from Eclipse, with Gradle.
### Visual Studio Code<a name="VSCode" />
#### _Modular samples_<a name="VSCode-Modular-Samples" />
Build Tool | Sample | Description
---------- | ------ | -----------
Maven | [HelloFX project](IDE/VSCode/Modular/Maven) | Modular project to run from Visual Studio Code, with Maven.
Gradle | [HelloFX project](IDE/VSCode/Modular/Gradle) | Modular project to run from Visual Studio Code, with Gradle.
#### _Non-modular samples_<a name="VSCode-Non-Modular-Samples" />
Build Tool | Sample | Description
---------- | ------ | -----------
Java | [HelloFX project](IDE/VSCode/Non-Modular/Java) | Non-modular project to run from Visual Studio Code.
Maven | [HelloFX project](IDE/VSCode/Non-Modular/Maven) | Non-modular project to run from Visual Studio Code, with Maven.
Gradle | [HelloFX project](IDE/VSCode/Non-Modular/Gradle) | Non-modular project to run from Visual Studio Code, with Gradle.
License<a name="License" />
---
This project is licensed under [BSD 3-Clause](LICENSE).
Contributing<a name="Contributing" />
---
This project welcomes all types of contributions and suggestions.
We encourage you to report issues, create suggestions and submit
pull requests.
Contributions can be submitted via [pull requests](https://github.com/openjfx/samples/pulls/),
providing you have signed the [Gluon Individual Contributor License Agreement (CLA)](https://docs.google.com/forms/d/16aoFTmzs8lZTfiyrEm8YgMqMYaGQl0J8wA0VJE2LCCY).
Please go through the [list of issues](https://github.com/openjfx/samples/issues)
to make sure that you are not duplicating an issue.
| 1 |
GoogleCloudPlatform/getting-started-java | null | 2015-11-10T19:10:49Z | null | # Getting started on Google Cloud Platform for Java®
[![CircleCI Build Status](https://circleci.com/gh/GoogleCloudPlatform/getting-started-java.svg?style=shield&circle-token=51b789e102291cbeae6817678d02da0f4cf25f1f)](https://circleci.com/gh/GoogleCloudPlatform/getting-started-java)
[![Coverage Status](https://codecov.io/gh/GoogleCloudPlatform/getting-started-java/branch/main/graph/badge.svg)](https://codecov.io/gh/GoogleCloudPlatform/getting-started-java)
The code for the samples is contained in individual folders on this repository.
Follow the instructions at [Getting Started on Google Cloud Platform for Java](https://cloud.google.com/java/) or the README files in each folder for instructions on how to run locally and deploy.
Managed VMs on Google Cloud Platform use the [Java Servlets](http://www.oracle.com/technetwork/java/overview-137084.html) & [Java Server Pages](http://www.oracle.com/technetwork/java/index-jsp-138231.html) on [Jetty](http://www.eclipse.org/jetty/).
1. [Helloworld-servlet](helloworld-servlet) Servlet based Hello World app
1. [HelloWorld-jsp](helloworld-jsp) Java Server Pages based Hello World app
1. [Bookshelf](bookshelf) A full featured app that demonstrates Authentication and CRUD operations for [Cloud Datastore](https://cloud.google.com/datastore/docs/concepts/overview?hl=en) and [Cloud SQL](https://cloud.google.com/sql/docs/introduction).
## Google Cloud Samples
To browse ready to use code samples check [Google Cloud samples](https://cloud.google.com/docs/samples).
## Contributing changes
* See [CONTRIBUTING.md](CONTRIBUTING.md)
## Licensing
* See [LICENSE](LICENSE)
Java is a registered trademark of Oracle Corporation and/or its affiliates.
| 0 |
mybatis/jpetstore-6 | A web application built on top of MyBatis 3, Spring 3 and Stripes | 2013-02-10T11:13:55Z | null | MyBatis JPetStore
=================
[![Java CI](https://github.com/mybatis/jpetstore-6/actions/workflows/ci.yaml/badge.svg)](https://github.com/mybatis/jpetstore-6/actions/workflows/ci.yaml)
[![Container Support](https://github.com/mybatis/jpetstore-6/actions/workflows/support.yaml/badge.svg)](https://github.com/mybatis/jpetstore-6/actions/workflows/support.yaml)
[![Coverage Status](https://coveralls.io/repos/github/mybatis/jpetstore-6/badge.svg?branch=master)](https://coveralls.io/github/mybatis/jpetstore-6?branch=master)
[![License](https://img.shields.io/:license-apache-brightgreen.svg)](https://www.apache.org/licenses/LICENSE-2.0.html)
![mybatis-jpetstore](https://mybatis.org/images/mybatis-logo.png)
JPetStore 6 is a full web application built on top of MyBatis 3, Spring 5 and Stripes.
Essentials
----------
* [See the docs](http://www.mybatis.org/jpetstore-6)
## Other versions that you may want to know about
- JPetstore on top of Spring, Spring MVC, MyBatis 3, and Spring Security https://github.com/making/spring-jpetstore
- JPetstore with Vaadin and Spring Boot with Java Config https://github.com/igor-baiborodine/jpetstore-6-vaadin-spring-boot
- JPetstore on MyBatis Spring Boot Starter https://github.com/kazuki43zoo/mybatis-spring-boot-jpetstore
## Run on Application Server
Running JPetStore sample under Tomcat (using the [cargo-maven2-plugin](https://codehaus-cargo.github.io/cargo/Maven2+plugin.html)).
- Clone this repository
```
$ git clone https://github.com/mybatis/jpetstore-6.git
```
- Build war file
```
$ cd jpetstore-6
$ ./mvnw clean package
```
- Startup the Tomcat server and deploy web application
```
$ ./mvnw cargo:run -P tomcat90
```
> Note:
>
> We provide maven profiles per application server as follow:
>
> | Profile | Description |
> | -------------- | ----------- |
> | tomcat90 | Running under the Tomcat 9.0 |
> | tomcat85 | Running under the Tomcat 8.5 |
> | tomee80 | Running under the TomEE 8.0(Java EE 8) |
> | tomee71 | Running under the TomEE 7.1(Java EE 7) |
> | wildfly26 | Running under the WildFly 26(Java EE 8) |
> | wildfly13 | Running under the WildFly 13(Java EE 7) |
> | liberty-ee8 | Running under the WebSphere Liberty(Java EE 8) |
> | liberty-ee7 | Running under the WebSphere Liberty(Java EE 7) |
> | jetty | Running under the Jetty 9 |
> | glassfish5 | Running under the GlassFish 5(Java EE 8) |
> | glassfish4 | Running under the GlassFish 4(Java EE 7) |
> | resin | Running under the Resin 4 |
- Run application in browser http://localhost:8080/jpetstore/
- Press Ctrl-C to stop the server.
## Run on Docker
```
docker build . -t jpetstore
docker run -p 8080:8080 jpetstore
```
or with Docker Compose:
```
docker compose up -d
```
## Try integration tests
Perform integration tests for screen transition.
```
$ ./mvnw clean verify -P tomcat90
```
| 0 |
android/testing-samples | A collection of samples demonstrating different frameworks and techniques for automated testing | 2014-10-11T03:51:27Z | null | Android testing samples
===================================
A collection of samples demonstrating different frameworks and techniques for automated testing.
### Espresso Samples
**[BasicSample](https://github.com/googlesamples/android-testing/blob/main/ui/espresso/BasicSample)** - Basic Espresso sample
**[CustomMatcherSample](https://github.com/googlesamples/android-testing/blob/main/ui/espresso/CustomMatcherSample)** - Shows how to extend Espresso to match the *hint* property of an EditText
**[DataAdapterSample](https://github.com/googlesamples/android-testing/blob/main/ui/espresso/DataAdapterSample)** - Showcases the `onData()` entry point for Espresso, for lists and AdapterViews
**[FragmentScenarioSample](https://github.com/googlesamples/android-testing/blob/main/ui/espresso/FragmentScenarioSample)** - Basic usage of `FragmentScenario` with Espresso.
**[IdlingResourceSample](https://github.com/googlesamples/android-testing/blob/main/ui/espresso/IdlingResourceSample)** - Synchronization with background jobs
**[IntentsBasicSample](https://github.com/googlesamples/android-testing/blob/main/ui/espresso/IntentsBasicSample)** - Basic usage of `intended()` and `intending()`
**[IntentsAdvancedSample](https://github.com/googlesamples/android-testing/blob/main/ui/espresso/IntentsAdvancedSample)** - Simulates a user fetching a bitmap using the camera
**[MultiWindowSample](https://github.com/googlesamples/android-testing/blob/main/ui/espresso/MultiWindowSample)** - Shows how to point Espresso to different windows
**[RecyclerViewSample](https://github.com/googlesamples/android-testing/blob/main/ui/espresso/RecyclerViewSample)** - RecyclerView actions for Espresso
**[ScreenshotSample](https://github.com/googlesamples/android-testing/blob/main/ui/espresso/ScreenshotSample)** - Screenshot capturing and saving using Espresso and androidx.test.core APIs
**[WebBasicSample](https://github.com/googlesamples/android-testing/blob/main/ui/espresso/WebBasicSample)** - Use Espresso-web to interact with WebViews
**[BasicSampleBundled](https://github.com/googlesamples/android-testing/blob/main/ui/espresso/BasicSampleBundled)** - Basic sample for Eclipse and other IDEs
**[MultiProcessSample](https://github.com/googlesamples/android-testing/blob/main/ui/espresso/MultiProcessSample)** - Showcases how to use multiprocess Espresso.
### UiAutomator Sample
**[BasicSample](https://github.com/googlesamples/android-testing/tree/main/ui/uiautomator/BasicSample)** - Basic UI Automator sample
### AndroidJUnitRunner Sample
**[AndroidJunitRunnerSample](https://github.com/googlesamples/android-testing/tree/main/runner/AndroidJunitRunnerSample)** - Showcases test annotations, parameterized tests and testsuite creation
### JUnit4 Rules Sample
**All previous samples use ActivityTestRule or IntentsTestRule but there's one specific to ServiceTestRule:
**[BasicSample](https://github.com/googlesamples/android-testing/blob/main/ui/espresso/BasicSample)** - Simple usage of `ActivityTestRule`
**[IntentsBasicSample](https://github.com/googlesamples/android-testing/blob/main/ui/espresso/IntentsBasicSample)** - Simple usage of `IntentsTestRule`
**[ServiceTestRuleSample](https://github.com/googlesamples/android-testing/tree/main/integration/ServiceTestRuleSample)** - Simple usage of `ServiceTestRule`
Prerequisites
--------------
- Android SDK v28
- Android Build Tools v28.03
Getting Started
---------------
These samples use the Gradle build system. To build a project, enter the project directory and use the `./gradlew assemble` command or use "Import Project" in Android Studio.
- Use `./gradlew connectedAndroidTest` to run the tests on a connected emulator or device.
- Use `./gradlew test` to run the unit test on your local host.
There is a top-level `build.gradle` file if you want to build and test all samples from the root directory. This is mostly helpful to build on a CI (Continuous Integration) server.
AndroidX Test Library
---------------
Many of these samples use the AndroidX Test Library. Visit the [Testing site on developer.android.com](https://developer.android.com/training/testing) for more information.
Experimental Bazel Support
--------------------------
[![Build status](https://badge.buildkite.com/18dda320b265e9a8f20cb6141b1e80ca58fb62bdb443e527be.svg)](https://buildkite.com/bazel/android-testing)
Some of these samples can be tested with [Bazel](https://bazel.build) on Linux. These samples contain a `BUILD.bazel` file, which is similar to a `build.gradle` file. The external dependencies are defined in the top level `WORKSPACE` file.
This is __experimental__ feature. To run the tests, please install the latest version of Bazel (0.12.0 or later) by following the [instructions on the Bazel website](https://docs.bazel.build/versions/master/install-ubuntu.html).
### Bazel commands
```
# Clone the repository if you haven't.
$ git clone https://github.com/google/android-testing
$ cd android-testing
# Edit the path to your local SDK at the top of the WORKSPACE file
$ $EDITOR WORKSPACE
# Test everything in a headless mode (no graphical display)
$ bazel test //... --config=headless
# Test a single test, e.g. ui/espresso/BasicSample/BUILD.bazel
$ bazel test //ui/uiautomator/BasicSample:BasicSampleInstrumentationTest_21_x86 --config=headless
# Query for all android_instrumentation_test targets
$ bazel query 'kind(android_instrumentation_test, //...)'
//ui/uiautomator/BasicSample:BasicSampleInstrumentationTest_23_x86
//ui/uiautomator/BasicSample:BasicSampleInstrumentationTest_22_x86
//ui/uiautomator/BasicSample:BasicSampleInstrumentationTest_21_x86
//ui/uiautomator/BasicSample:BasicSampleInstrumentationTest_19_x86
//ui/espresso/RecyclerViewSample:RecyclerViewSampleInstrumentationTest_23_x86
//ui/espresso/RecyclerViewSample:RecyclerViewSampleInstrumentationTest_22_x86
//ui/espresso/RecyclerViewSample:RecyclerViewSampleInstrumentationTest_21_x86
//ui/espresso/RecyclerViewSample:RecyclerViewSampleInstrumentationTest_19_x86
//ui/espresso/MultiWindowSample:MultiWindowSampleInstrumentationTest_23_x86
//ui/espresso/MultiWindowSample:MultiWindowSampleInstrumentationTest_22_x86
...
# Test everything with GUI enabled
$ bazel test //... --config=gui
# Test with a local device or emulator. Ensure that `adb devices` lists the device.
$ bazel test //... --config=local_device
# If multiple devices are connected, add --device_serial_number=$identifier where $identifier is the name of the device in `adb devices`
$ bazel test //... --config=local_device --test_arg=--device_serial_number=$identifier
```
For more information, check out the documentation for [Android Instrumentation Tests in Bazel](https://docs.bazel.build/versions/master/android-instrumentation-test.html). You may also want to check out [Building an Android App with Bazel](https://docs.bazel.build/versions/master/tutorial/android-app.html), and the list of [Android Rules](https://docs.bazel.build/versions/master/be/android.html) in the Bazel Build Encyclopedia.
Known issues:
* Building of APKs is supported on Linux, Mac and Windows, but testing is only supported on Linux.
* `android_instrumentation_test.target_device` attribute still needs to be specified even if `--config=local_device` is used.
* If using a local device or emulator, the APKs are not uninstalled automatically after the test. Use this command to
remove the packages:
* `adb shell pm list packages com.example.android.testing | cut -d ':' -f 2 | tr -d '\r' | xargs -L1 -t adb uninstall`
Please file Bazel related issues against the [Bazel](https://github.com/bazelbuild/bazel) repository instead of this repository.
Support
-------
- Google+ Community: https://plus.google.com/communities/105153134372062985968
- Stack Overflow: http://stackoverflow.com/questions/tagged/android-testing
If you've found an error in this sample, please file an issue:
https://github.com/googlesamples/android-testing
Patches are encouraged, and may be submitted by forking this project and
submitting a pull request through GitHub. Please see CONTRIBUTING.md for more details.
License
-------
Copyright 2015 The Android Open Source Project, Inc.
Licensed to the Apache Software Foundation (ASF) under one or more contributor
license agreements. See the NOTICE file distributed with this work for
additional information regarding copyright ownership. The ASF licenses this
file to you under the Apache License, Version 2.0 (the "License"); you may not
use this file except in compliance with the License. You may obtain a copy of
the License at
http://www.apache.org/licenses/LICENSE-2.0
Unless required by applicable law or agreed to in writing, software
distributed under the License is distributed on an "AS IS" BASIS, WITHOUT
WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. See the
License for the specific language governing permissions and limitations under
the License.
| 1 |
ihrupin/samples | samples | 2013-01-23T16:32:59Z | null | ###This repo contains sample source code for my blog
[WWW.HRUPIN.COM](http://www.hrupin.com) | 1 |
netgloo/spring-boot-samples | Spring Boot samples by Netgloo | 2014-05-22T19:05:50Z | null | null | 1 |
GoogleCloudPlatform/cloud-bigtable-examples | Examples of how to use Cloud Bigtable both with GCE map/reduce as well as stand alone applications. | 2014-12-05T12:59:52Z | null | # Google Cloud Bigtable examples
[![Travis CI status][travis-shield]][travis-link]
[![Stack Overflow][stackoverflow-shield]][stackoverflow-link]
Bigger than a data warehouse, fast enough for real-time access, and less expensive than running virtual machines. The world-renowned database that powers Google is now available to you worldwide.
## Overview
[Google Cloud Bigtable](https://cloud.google.com/bigtable/) offers you a fast, fully managed, almost infinitely scalable NoSQL database service that's ideal for web, mobile, and IoT applications requiring terabytes to petabytes of data. Unlike comparable market offerings, Cloud Bigtable doesn't require you to sacrifice speed, scale, or cost efficiency when your applications grow. The Bigtable service that Cloud Bigtable relies upon has been battle-tested at Google for more than 10 years—it's the database driving major applications such as Search, Analytics, Maps and Gmail.
## Quickstart
[Quickstart/HBase](quickstart) - Create a Cloud Bigtable Cluster and the hbase shell from within a docker container on your local machine
## Java
* [Hello World](java/hello-world) - This sample has been migrated to: https://github.com/GoogleCloudPlatform/java-docs-samples/blob/main/bigtable/hbase/snippets/src/main/java/com/example/bigtable/HelloWorld.java
* [Import HBase Sequence files](java/dataflow-import-examples) Import HBase sequence files directly to Cloud Bigtable using Dataflow.
* [Dataproc Wordcount using Map/Reduce](java/dataproc-wordcount) - How to load data to Cloud Bigtable using Dataproc on GCE
* [GAE J8 Std-Hello World](https://github.com/googlecloudplatform/java-docs-samples/tree/master/appengine-java8/bigtable) - Accessing Cloud Bigtable from App Engine standard
## Dataflow
* [Connector-Examples](java/dataflow-connector-examples) - Using the cloud dataflow connector for Bigtable, do write Hello World to two rows, Use Cloud Pub / Sub to count Shakespeare, count the number of rows in a Table, and copy records from BigQuery to BigTable.
* [Pardo-HelloWorld](java/dataflow-pardo-helloworld) - example of using Cloud Dataflow without the connector.
## Go
* [cbt](https://github.com/GoogleCloudPlatform/gcloud-golang/tree/master/bigtable/cmd/cbt) [doc](https://godoc.org/google.golang.org/cloud/bigtable/cmd/cbt) Basic command line interactions with Cloud Bigtable - A really great place to start learning the Go Client.
* [helloworld](https://github.com/GoogleCloudPlatform/golang-samples/tree/master/bigtable/helloworld) - Basic Hello world example application demonstrating how to read and write to a Cloud Bigtable instance.
* [usercounter](https://github.com/GoogleCloudPlatform/golang-samples/tree/master/bigtable/usercounter) - Accessing Cloud Bigtable from App Engine Flexible
* [search](https://github.com/GoogleCloudPlatform/golang-samples/tree/master/bigtable/search) - Create and search a Cloud Bigtable.
## Python
* [Hello
World](https://github.com/GoogleCloudPlatform/python-docs-samples/tree/master/bigtable/hello)
A minimal application that demonstrates using the Googe Cloud Client
libraries to create a temporary table, write some rows, read them back and
clean up.
* [Hello World
(Happybase)](https://github.com/GoogleCloudPlatform/python-docs-samples/tree/master/bigtable/hello_happybase)
A minimal application that demonstrates using the Happybase API create a
temporary table, write some rows, read them back and clean up.
## Questions and discussions
If you have questions or run into issues with Google Cloud Bigtable or the
client libraries, you can use any of the following forums:
* Stack Overflow: tag questions with [`google-cloud-bigtable`][stackoverflow-link]
* Mailing list: [google-cloud-bigtable-discuss@][google-cloud-bigtable-discuss]
You can also subscribe to
[google-cloud-bigtable-announce@][google-cloud-bigtable-announce] list to receive
infrequent product and client library announcements.
## Contributing changes
See [CONTRIBUTING.md](CONTRIBUTING.md) for more information on how to contribute
to this project.
## More examples
More Google Cloud Bigtable examples are available in the following languages:
* [Java](https://github.com/GoogleCloudPlatform/java-docs-samples/tree/master/bigtable)
* [Python](https://github.com/GoogleCloudPlatform/python-docs-samples/tree/master/bigtable)
* [Node](https://github.com/googleapis/nodejs-bigtable/tree/master/samples)
* [Go](https://github.com/GoogleCloudPlatform/golang-samples/tree/master/bigtable)
* [Dotnet](https://github.com/GoogleCloudPlatform/dotnet-docs-samples/tree/master/bigtable/api)
* [C++](https://github.com/googleapis/google-cloud-cpp/tree/master/google/cloud/bigtable/examples)
* [Ruby](https://github.com/GoogleCloudPlatform/ruby-docs-samples/tree/master/bigtable)
* [PHP](https://github.com/GoogleCloudPlatform/php-docs-samples/tree/master/bigtable)
## License
Apache 2.0; see [LICENSE](LICENSE) for details.
<!-- references -->
[travis-shield]: https://travis-ci.org/GoogleCloudPlatform/cloud-bigtable-examples.svg
[travis-link]: https://travis-ci.org/GoogleCloudPlatform/cloud-bigtable-examples/builds
[stackoverflow-shield]: https://img.shields.io/badge/stackoverflow-google--cloud--bigtable-blue.svg
[nodejs-bigtable]: https://github.com/googleapis/nodejs-bigtable
[stackoverflow-link]: http://stackoverflow.com/search?q=[google-cloud-bigtable]
[google-cloud-bigtable-discuss]: https://groups.google.com/group/google-cloud-bigtable-discuss
[google-cloud-bigtable-announce]: https://groups.google.com/group/google-cloud-bigtable-announce
| 1 |
youtube/api-samples | Code samples for YouTube APIs, including the YouTube Data API, YouTube Analytics API, and YouTube Live Streaming API. The repo contains language-specific directories that contain the samples. | 2013-12-09T18:41:41Z | null | api-samples
===========
Code samples for YouTube APIs, including the YouTube Data API, YouTube Analytics API, and YouTube Live Streaming API. The repo contains language-specific directories that contain the samples.
| 1 |
apache/dubbo-samples | samples for Apache Dubbo | 2018-04-28T09:25:29Z | null | # Dubbo Samples
Samples for Apache Dubbo.
![Build Status](https://github.com/apache/dubbo-samples/workflows/Dubbo%202/badge.svg)
![license](https://img.shields.io/github/license/apache/dubbo-samples.svg)
This repository contains a number of projects to illustrate various usages of Dubbo from basic to advanced, pls. check README in each individual sub projects. It is also helpful to cross reference to [Dubbo User Manual](https://dubbo.apache.org/zh-cn/overview/tasks/) to understand the features demoed in this project.
What's more, [dubbo-go](https://github.com/apache/dubbo-go) samples are moved to [dubbo-go-samples](https://github.com/apache/dubbo-go-samples).
## Build and Run Samples
To compile all samples, run the following command in the top directory of this project, or step into the sub directories to compile one single sample:
**It is highly not recommend to build the entire project from the root directory, as building the entire samples can take a long time. Each module in Samples is designed independently so you can first go to the demo directory you care about, then execute the build and run the demo.**
For example,
```bash
$ cd 1-basic/dubbo-samples-spring-boot
$ mvn clean package
```
You may need to read each individual README under the sub directories if you have to understand how to build and run.
## Integration Test
This project is also used for integration tests for dubbo. If you are just learning how to use Dubbo you don't have to care about this part.
**How to build and run a integration test**
Dubbo integration test base on docker container, and relies on an image used to run the provider application and test cases.
Integration test leverages [docker](https://docs.docker.com/get-started/) to setup test environment, more accurately, to start dubbo provider instance, and any other supporting systems like registry center if necessary, in docker.
Please install `docker` and `docker-compose` first, then build the test image `dubbo/sample-test`.
```bash
cd dubbo-samples
./test/build-test-image.sh
```
Use a debian mirror through env `DEBIAN_MIRROR` if apt download files slowly,
the following example uses aliyun mirror server [http://mirrors.aliyun.com/ubuntu/](http://mirrors.aliyun.com/ubuntu/) :
```bash
cd dubbo-samples
DEBIAN_MIRROR=http://mirrors.aliyun.com ./test/build-test-image.sh
```
Then we use the `run-tests.sh` script to run the test cases.
* Run single test case
```bash
cd dubbo-samples
./test/run-tests.sh <project.basedir>
```
For example, run the `dubbo-samples-annotation` test case:
```
./test/run-tests.sh 2-advanced/dubbo-samples-annotation
```
* Run all test cases
```bash
cd dubbo-samples
./test/run-tests.sh
```
If docker container fails to startup successfully in any case, you can check log files in directory `${project.basedir}/target/logs` to understand what happens.
Pls. note integration tests rely on a Docker environment, make sure the docker environment is available before running them.
**How to add more integration test**
If you are interested in contributing more integration test for dubbo, pls. read further to understand how to enable integration test for one particular sample from the scratch.
Please follow the steps below:
1. Add a file named `case-configuration.yml` to test project.
This file is used to configure the test modules and environment, including dubbo provider / test services,
dependent third-party services.
2. Add a file named `case-versions.conf` to test project.
This file is used to configure the supported component version rules to support multi-version testing.
**Details of `case-configuration.yml`:**
Take the case `dubbo-samples-annotation` as an example:
```yaml
services:
dubbo-samples-annotation:
type: app
basedir: .
mainClass: org.apache.dubbo.samples.annotation.AnnotationProviderBootstrap
dubbo-samples-annotation-test:
type: test
basedir: .
tests:
- "**/*IT.class"
systemProps:
- zookeeper.address=dubbo-samples-annotation
- zookeeper.port=2181
- dubbo.address=dubbo-samples-annotation
- dubbo.port=20880
waitPortsBeforeRun:
- dubbo-samples-annotation:2181
- dubbo-samples-annotation:20880
depends_on:
- dubbo-samples-annotation
```
The project contains a dubbo provider `AnnotationProviderBootstrap` and an embedded zookeeper server,
as well as a test class `AnnotationServicesIT`.
Therefore, we have to define two services, one service runs `AnnotationProviderBootstrap`,
and the other service runs test classes.
The service `type` of running dubbo provider is `app`, and the service `type` of running test is `test`.
The project directory is the same as the case configuration directory, so `basedir` is `.` .
Use hostname to access between containers, the default `hostname` of the container is the same as serviceName.
So through `dubbo-samples-annotation:2181`, the embedded zookeeper server can be accessed from the test container.
There are many test cases similar to this example, only need to modify the `mainClass` and hostname.
Extract the changed as variables, and the unchanged content as templates.
When using the template, you only need to modify the variable value, which makes the case configuration easier.
The above example can use a template `app-builtin-zookeeper.yml`, use `from` to reference it and override the variable value in `props`:
```yaml
from: app-builtin-zookeeper.yml
props:
project_name: dubbo-samples-annotation
main_class: org.apache.dubbo.samples.annotation.AnnotationProviderBootstrap
zookeeper_port: 2181
dubbo_port: 20880
```
Another template is `app-external-zookeeper.yml`, which supports an external zookeeper service.
you can find all the templates in the directory `test/dubbo-scenario-builder/src/main/resources/configs`.
**Details of `case-versions.conf`:**
Version rules for spring app:
```
# Spring app
dubbo.version=2.7*, 3.*
spring.version=4.*, 5.*
```
Version rules for spring-boot 1.x app:
```
# SpringBoot app
dubbo.version=2.7*, 3.*
spring-boot.version=1.*
```
Version rules for spring-boot 2.x app:
```
# SpringBoot app
dubbo.version=2.7*, 3.*
spring-boot.version=2.*
```
For more details, please refer to the following case configurations:
* [dubbo-samples-annotation](dubbo-samples-annotation/case-configuration.yml) : A simple provider service with builtin zookeeper.
* [dubbo-samples-api](dubbo-samples-api/case-configuration.yml) : A simple provider service with external zookeeper.
* [dubbo-samples-chain](dubbo-samples-chain/case-configuration.yml) : A multiple services with external zookeeper.
* [dubbo-samples-migration](dubbo-samples-migration/README.md) : A compatibility test with the provider and consumer have different dubbo verison.
That's it, then feel free to add more integration test for the Dubbo project, have fun.
| 1 |
spring-projects/spring-integration-samples | You are looking for examples, code snippets, sample applications for Spring Integration? This is the place. | 2011-08-10T04:40:02Z | null | Spring Integration Samples
==========================
[![Revved up by Develocity](https://img.shields.io/badge/Revved%20up%20by-Develocity-06A0CE?logo=Gradle&labelColor=02303A)](https://ge.spring.io/scans?search.rootProjectNames=spring-integration-samples)
Welcome to the **Spring Integration Samples** repository which provides **50+ samples** to help you learn [Spring Integration][]. To simplify your experience, the *Spring Integration* samples are split into 4 distinct categories:
* Basic
* Intermediate
* Advanced
* Applications
* DSL
Inside of each category you'll find a **README.md** file, which will contain a more detailed description of that category. Each sample also comes with its own **README.md** file explaining further details, e.g. how to run the respective sample.
| For additional samples, please also checkout the [Spring Integration Extensions][] project as it also provides numerous samples.
*Happy Integration!*
# Note
This (main) branch requires Spring Integration 6.0 or above.
For samples running against earlier versions of Spring Integration, use the __5.5.x__ and other branches.
The project requires now Java 17 or above.
To open the project in the IDE, use its `import` option against a `build.gradle` file from the root project directory.
## Related GitHub projects
* [Spring Integration][]
* [Spring Integration Extensions][]
## Community Sample Projects
* [Xavier Padró][]
# Categories
Below is a short description of each category.
## DSL
This directory holds demos/samples for Spring Integration 4.0 Java Configuration as well as the Java DSL Extension.
## Basic
This is a good place to get started. The samples here are technically motivated and demonstrate the bare minimum with regard to configuration and code to help you to get introduced to the basic concepts, API and configuration of Spring Integration. For example, if you are looking for an answer on how to wire a **Service Activator** to a **Channel** or how to apply a **Gateway** to your message exchange or how to get started with using the **MAIL** or **XML** module, this would be the right place to find a relevant sample. The bottom line is that this is a good starting point.
* **amqp** - Demonstrates the functionality of the various **AMQP Adapters**
* **barrier** - Shows how to suspend a thread until some asynchronous event occurs
* **control-bus** - Demonstrates the functionality of the **Control Bus**
* **enricher** - This sample demonstrates how the Enricher components can be used
* **feed** - Demonstrates the functionality of the **Feed Adapter** (RSS/ATOM)
* **file** - Demonstrates aspects of the various File Adapters (e.g. **File Inbound/Outbound Channel Adapters**, file **polling**)
* **ftp** - Demonstrates the **FTP support** available with Spring Integration
* **helloworld** - Very simple starting example illustrating a basic message flow (using **Channel**, **ServiceActivator**, **QueueChannel**)
* **http** - Demonstrates request/reply communication when using a pair of **HTTP Inbound/Outbound gateways**
* **jdbc** - Illustrates the usage of the Jdbc Adapters, including object persistence and retrieval
* **jms** - Demonstrates **JMS** support available with Spring Integration
* **jmx** - Demonstrates **JMX** support using a **JMX Attribute Polling Channel** and **JMX Operation Invoking Channel Adapter**
* **jpa** - Shows the usage of the JPA Components
* **mail** - Example showing **IMAP** and **POP3** support
* **mqtt** - Demonstrates the functionality of inbound and outbound **MQTT Adapters**
* **mongodb** - Shows how to persist a Message payload to a **MongoDb** document store and how to read documents from **MongoDb**
* **oddeven** - Example combining the functionality of **Inbound Channel Adapter**, **Filter**, **Router** and **Poller**
* **quote** - Example demoing core EIP support using **Channel Adapter (Inbound and Stdout)**, **Poller** with Interval Triggers, **Service Activator**
* **sftp** - Demonstrating SFTP support using **SFTP Inbound / Outbound Channel Adapters**
* **tcp-amqp** - Demonstrates basic functionality of bridging the **Spring Integration TCP Adapters** with **Spring Integration AMQP Adapters**
* **tcp-broadcast** - Demonstrates broadcasting a message to multiple connected TCP clients.
* **tcp-client-server** - Demonstrates socket communication using **TcpOutboundGateway**, **TcpInboundGateway** and also uses a **Gateway** and a **Service Activator**
* **tcp-with-headers** - Demonstrates sending headers along with the payload over TCP using JSON.
* **testing-examples** - A series of test cases that show techniques to **test** Spring Integration applications.
* **twitter** - Illustrates Twitter support using the **Twitter Inbound Channel Adapter**, **Twitter Inbound Search Channel Adapter**, **Twitter Outbound Channel Adapter**
* **ws-inbound-gateway** - Example showing basic functionality of the **Web Service Gateway**
* **ws-outbound-gateway** - Shows outbound web services support using the **Web Service Outbound Gateway**, **Content Enricher**, Composed Message Processor (**Chain**)
* **xml** - Example demonstrates various aspects of the **Xml** support using an **XPath Splitter**, **XPath Router**, **XSLT Transformer** as well as **XPath Expression** support
* **xmpp** - Show the support for [**XMPP**](https://en.wikipedia.org/wiki/Extensible_Messaging_and_Presence_Protocol) (formerly known as Jabber) using e.g. GoogleTalk
## Intermediate
This category targets developers who are already more familiar with the Spring Integration framework (past getting started), but need some more guidance while resolving more advanced technical problems that you have to deal with when switching to a Messaging architecture. For example, if you are looking for an answer on how to handle errors in various scenarios, or how to properly configure an **Aggregator** for the situations where some messages might not ever arrive for aggregation, or any other issue that goes beyond a basic understanding and configuration of a particular component to address "what else you can do?" types of problems, this would be the right place to find relevant examples.
* **async-gateway** - Usage example of an asynchronous **Gateway**
* **dynamic-poller** - Example shows usage of a **Poller** with a custom **Trigger** to change polling periods at runtime
* **async-gateway** - Example shows usage of an **Asynchronous Gateway**
* **errorhandling** - Demonstrates basic **Error Handling** capabilities of Spring Integration
* **file-processing** - Sample demonstrates how to wire a message flow to process files either sequentially (maintain the order) or concurrently (no order).
* **mail-attachments** - Demonstrates the processing of email attachments
* **monitoring** The project used in the *[Spring Integration Management and Monitoring Webinar](https://www.springsource.org/node/3598)* Also available on the *[SpringSourceDev YouTube Channel](https://www.youtube.com/SpringSourceDev)*
* **multipart-http** - Demonstrates the sending of HTTP multipart requests using Spring's **RestTemplate** and a Spring Integration **Http Outbound Gateway**
* **rest-http** - This sample demonstrates how to send an HTTP request to a Spring Integration's HTTP service while utilizing Spring Integration's new HTTP Path usage. This sample also uses Spring Security for HTTP Basic authentication. With HTTP Path facility, the client program can send requests with URL Variables.
* **retry-and-more** Provides samples showing the application of MessageHandler Advice Chains to endpoints - retry, circuit breaker, expression evaluating
* **splitter-aggregator-reaper** A demonstration of implementing the Splitter and Aggregator *Enterprise Integration Patterns* (EIP) together. This sample also provides a concrete example of a [message store reaper][] in action.
* **stored-procedures-derby** Provides an example of the stored procedure Outbound Gateway using *[Apache Derby](https://db.apache.org/derby/)*
* **stored-procedures-ms** Provides an example of the stored procedure Outbound Gateway using *Microsoft SQL Server*
* **stored-procedures-oracle** Provides an example of the stored procedure Outbound Gateway using *ORACLE XE*
* **stored-procedures-postgresql** Provides an example of the stored procedure Outbound Gateway using *[PostgreSQL](https://www.postgresql.org/)*
* **tcp-async-bi-directional** - Demonstrates the use of *Collaborating Channel Adapters* for arbitrary async messaging (not request/reply) between peers.
* **tcp-client-server-multiplex** - Demonstrates the use of *Collaborating Channel Adapters* with multiple in-flight requests/responses over a single connection.
* **travel** - More sophisticated example showing the retrieval of weather (SOAP Web Service) and traffic (HTTP Service) reports using real services
* **tx-synch** Provides a sample demonstrating the use of transaction synchronization, renaming an input file to a different filename, depending on whether the transaction commits, or rolls back.
## Advanced
This category targets advanced developers who are quite familiar with Spring Integration but are looking to address a specific custom need by extending the Spring Integration public API. For example, if you are looking for samples showing how to implement a custom **Channel** or **Consumer** (event-based or polling-based), or you are trying to figure out what is the most appropriate way to implement a custom **BeanParser** on top of the Spring Integration BeanParser hierarchy when implementing a custom namespace, this would be the right place to look. Here you can also find samples that will help you with adapter development. Spring Integration comes with an extensive library of adapters that allow you to connect remote systems with the Spring Integration messaging framework. However you might have a need to integrate with a system for which the core framework does not provide an adapter, so you have to implement your own. This category would include samples showing you how to implement various adapters.
* **advanced-testing-examples** - Example test cases that show advanced techniques to test Spring Integration applications
* **dynamic-ftp** - Demonstrates one technique for sending files to dynamic destinations.
* **dynamic-tcp-client** - Demonstrates a technique for dynamically creating TCP clients.
## Applications
This category targets developers and architects who have a good understanding of Message-Driven architecture and Enterprise Integration Patterns, and have an above average understanding of Spring and Spring integration and who are looking for samples that address a particular business problem. In other words, the emphasis of samples in this category is '**business use cases**' and how they can be solved via a Messaging architecture and Spring Integration in particular. For example, if you are interested to see how a Loan Broker process or Travel Agent process could be implemented and automated via Spring Integration, this would be the right place to find these types of samples.
* **cafe** - Emulates a simple operation of a coffee shop combining various Spring Integration adapters (Including **Router** and **Splitter**) see [Appendix A of the reference documentation](https://docs.spring.io/spring-integration/docs/current/reference/html/#samples) for more details. Implementations are provided for:
- AMQP
- JMS
- In memory channels
* **cafe-scripted** - Scripted implementation of the classic **cafe** sample application. Supports **JavaScript**, **Groovy**, **Ruby**, and **Python**.
* **loan-broker** - Simulates a simple banking application (Uses **Gateway**, **Chain**, **Header Enricher**, **Recipient List Router**, **Aggregator**) see [Appendix A of the reference documentation](https://docs.spring.io/spring-integration/docs/current/reference/html/#samples) for more details
* **loanshark** This extension to the loan broker sample shows how to exchange messages between Spring Integration applications (and other technologies) using **UDP**.
**file-split-ftp** - Reads a file; splits into 3 based on contents; sends files over ftp; sends email with results.
# Contributing
See the [Spring Integration Contributor Guidelines](https://github.com/spring-projects/spring-integration/blob/master/CONTRIBUTING.adoc) for information about how to contribute to this repository.
# Resources
For more information, please visit the Spring Integration website at: [https://projects.spring.io/spring-integration/](https://projects.spring.io/spring-integration/)
[Spring Integration]: https://github.com/spring-projects/spring-integration
[Spring Integration Extensions]: https://github.com/spring-projects/spring-integration-extensions
[message store reaper]: https://docs.spring.io/spring-integration/api/org/springframework/integration/store/MessageGroupStoreReaper.html
[Xavier Padró]: https://github.com/xpadro/spring-integration
| 1 |
GoogleCloudPlatform/java-docs-samples | Java and Kotlin Code samples used on cloud.google.com | 2015-03-25T22:48:38Z | null | # Google Cloud Platform Java Samples
[![Build Status][java-11-badge]][java-11-link] [![Build
Status][java-17-badge]][java-17-link] [![Build Status][java-21-badge]][java-21-link]
<a href="https://console.cloud.google.com/cloudshell/open?git_repo=https://github.com/GoogleCloudPlatform/java-docs-samples&page=editor&open_in_editor=README.md">
<img alt="Open in Cloud Shell" src ="http://gstatic.com/cloudssh/images/open-btn.png"></a>
This repository holds sample code written in Java that demonstrates the
[Google Cloud Platform](https://cloud.google.com/docs/).
Some samples have accompanying guides on <cloud.google.com>. See respective
README files for details.
## Google Cloud Samples
To browse ready to use code samples check [Google Cloud Samples](https://cloud.google.com/docs/samples?l=java).
## Set Up
1. [Set up your Java Development Environment](https://cloud.google.com/java/docs/setup)
1. Clone this repository:
git clone https://github.com/GoogleCloudPlatform/java-docs-samples.git
1. Obtain authentication credentials.
Create local credentials by running the following command and following the
oauth2 flow (read more about the command [here][auth_command]):
gcloud auth application-default login
Or manually set the `GOOGLE_APPLICATION_CREDENTIALS` environment variable
to point to a service account key JSON file path.
Learn more at [Setting Up Authentication for Server to Server Production Applications][ADC].
*Note:* Application Default Credentials is able to implicitly find the credentials as long as the application is running on Compute Engine, Kubernetes Engine, App Engine, or Cloud Functions.
## Contributing
* See the [Contributing Guide](CONTRIBUTING.md)
## Licensing
* See [LICENSE](LICENSE)
## Supported Java runtimes
Every submitted change has to pass all checks that run on the testing environments with Java 11 and Java 17 runtimes before merging the change to the main branch.
We run periodic checks on the environments with Java 8 and Java 21 runtimes but we don't enforce passing these tests at the moment.
Because Java 8 is a [supported Java runtime][supported_runtimes] in Google Cloud, please configure to build your code sample with Java 8.
In exceptional cases, configure to build your code sample using Java 11.
[supported_runtimes]: https://cloud.google.com/java/docs/supported-java-versions
## Source Code Headers
Every file containing source code must include copyright and license
information. This includes any JS/CSS files that you might be serving out to
browsers. (This is to help well-intentioned people avoid accidental copying that
doesn't comply with the license.)
Apache header:
Copyright 2022 Google LLC
Licensed under the Apache License, Version 2.0 (the "License");
you may not use this file except in compliance with the License.
You may obtain a copy of the License at
https://www.apache.org/licenses/LICENSE-2.0
Unless required by applicable law or agreed to in writing, software
distributed under the License is distributed on an "AS IS" BASIS,
WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
See the License for the specific language governing permissions and
limitations under the License.
[ADC]: https://developers.google.com/identity/protocols/application-default-credentials
[auth_command]: https://cloud.google.com/sdk/gcloud/reference/beta/auth/application-default/login
[java-11-badge]:
https://storage.googleapis.com/cloud-devrel-kokoro-resources/java/badges/java-docs-samples-11.svg
[java-11-link]:
https://storage.googleapis.com/cloud-devrel-kokoro-resources/java/badges/java-docs-samples-11.html
[java-17-badge]:
https://storage.googleapis.com/cloud-devrel-kokoro-resources/java/badges/java-docs-samples-17.svg
[java-17-link]:
https://storage.googleapis.com/cloud-devrel-kokoro-resources/java/badges/java-docs-samples-17.html
[java-21-badge]:
https://storage.googleapis.com/cloud-devrel-kokoro-resources/java/badges/java-docs-samples-21.svg
[java-21-link]:
https://storage.googleapis.com/cloud-devrel-kokoro-resources/java/badges/java-docs-samples-21.html
Java is a registered trademark of Oracle and/or its affiliates.
| 1 |
baomidou/mybatis-plus-samples | MyBatis-Plus Samples | 2018-07-23T02:32:11Z | null | # MyBatis-Plus Samples
[贡献代码](https://github.com/baomidou/mybatis-plus-samples)
[企业版 Mybatis-Mate 高级特性](https://gitee.com/baomidou/mybatis-mate-examples)
本工程为 MyBatis-Plus 的官方示例,项目结构如下:
- mybatis-plus-sample-quickstart: 快速开始示例
- mybatis-plus-sample-quickstart-springmvc: 快速开始示例(Spring MVC版本)
- mybatis-plus-sample-reduce-springmvc: 简化掉默认mapper类示例(Spring MVC版本)
- mybatis-plus-sample-generator: 代码生成器示例
- mybatis-plus-sample-crud: 完整 CRUD 示例
- mybatis-plus-sample-ddl-mysql: SQL 脚本自动维护 示例
- mybatis-plus-sample-wrapper: 条件构造器示例
- mybatis-plus-sample-pagination: 分页功能示例
- mybatis-plus-sample-active-record: ActiveRecord示例
- mybatis-plus-sample-sequence: Sequence示例
- mybatis-plus-sample-execution-analysis: Sql执行分析示例
- mybatis-plus-sample-performance-analysis: 性能分析示例
- mybatis-plus-sample-optimistic-locker: 乐观锁示例
- mybatis-plus-sample-sql-injector: 自定义全局操作示例
- mybatis-plus-sample-auto-fill-metainfo: 公共字段填充示例
- mybatis-plus-sample-logic-delete: 逻辑删除示例
- mybatis-plus-sample-multi-datasource: 多数据源示例
- mybatis-plus-sample-enum: 枚举注入示例
- mybatis-plus-sample-dynamic-tablename: 动态表名示例
- mybatis-plus-sample-tenant: 多租户示例
- mybatis-plus-sample-typehandler: 类型处理器示例,例如 json 字段对象转换
- mybatis-plus-sample-deluxe: 完整示例(包含 分页、逻辑删除、自定义全局操作 等绝大部分常用功能的使用示例,相当于大整合的完整示例)
- mybatis-plus-sample-assembly: 分离打包示例
- mybatis-plus-sample-resultmap: 使用 resultMap 示例
- mybatis-plus-sample-id-generator: 自定义ID生成示例
- mybatis-plus-sample-id-string: 字符串ID生成示例
- mybatis-plus-sample-no-spring: 不使用spring下的示例
- mybatis-plus-sample-pagehelper: 使用pagehelper进行分页
- mybatis-plus-sample-association: 联表查询示例
- mybatis-plus-sample-jsonb: 数据库 postgres 字段 jsonb 示例
- mybatis-plus-startup-analysis : 启动性能测试示例
![微信 wx153666](https://images.gitee.com/uploads/images/2021/0903/235825_2d017339_12260.jpeg)
- 可加作者,进入微信群
| 1 |
apache/incubator-seata-samples | Apache Seata(incubating) Samples for Java | 2019-01-29T16:01:42Z | null | # samples code specification
## Directory Structure
The first and second levels are more of a directory
Top level: seata-samples
Second layer: at-sample, tcc-sample, saga-sample, xa-sample
Third floor, The third layer is the specific sample and the naming convention is as follows:
## naming
naming with framework: spring-nacos-seata, springboot-naocs-zk-seata ...
## dependency
pom: The dependencies of each sample should be independent and should not depend on the dependencies of the parent pom of seata samples.
# samples transaction model
https://seata.apache.org/docs/user/quickstart/
## start sequence
1、account
2、storage
3、order
4、business | 1 |
javaee-samples/javaee7-samples | Java EE 7 Samples | 2013-08-27T18:47:51Z | null | # Java EE 7 Samples #
This workspace consists of Java EE 7 Samples and unit tests. They are categorized in different directories, one for each Technology/JSR.
Some samples/tests have documentation, otherwise read the code. The [Java EE 7 Essentials](http://www.amazon.com/Java-EE-Essentials-Arun-Gupta/dp/1449370179/) book refers to most of these samples and provides an explanation. Feel free to add docs and send a pull request.
## How to run? ##
Samples are tested on Payara, GlassFish, Wildfly and more using the Arquillian ecosystem.
A brief instruction how to clone, build, import and run the samples on your local machine @radcortez provides in this sample video https://www.youtube.com/watch?v=BB4b-Yz9cF0
Only one container profile can be active at a given time otherwise there will be dependency conflicts.
There are 16 available container profiles, for 6 different servers:
* Payara and GlassFish
* ``payara-ci-managed``
This profile will install a Payara server and start up the server per sample.
Useful for CI servers. The Payara version that's used can be set via the ``payara.version`` property.
This is the default profile and does not have to be specified explicitly.
* ``payara-embedded``
This profile uses the Payara embedded server and runs in the same JVM as the TestClass.
Useful for development, but has the downside of server startup per sample.
* ``payara-remote``
This profile requires you to start up a Payara server outside of the build. Each sample will then
reuse this instance to run the tests.
Useful for development to avoid the server start up cost per sample.
This profile supports for some tests to set the location where Payara is installed via the ``glassfishRemote_gfHome``
system property. E.g.
``-DglassfishRemote_gfHome=/opt/payara171``
This is used for sending asadmin commands to create container resources, such as users in an identity store.
* ``glassfish-embedded``
This profile uses the GlassFish embedded server and runs in the same JVM as the TestClass.
Useful for development, but has the downside of server startup per sample.
* ``glassfish-remote``
This profile requires you to start up a GlassFish server outside of the build. Each sample will then
reuse this instance to run the tests.
Useful for development to avoid the server start up cost per sample.
This profile supports for some tests to set the location where GlassFish is installed via the ``glassfishRemote_gfHome``
system property. E.g.
``-DglassfishRemote_gfHome=/opt/glassfish41``
This is used for sending asadmin commands to create container resources, such as users in an identity store.
* WildFly
* ``wildfly-ci-managed``
This profile will install a Wildfly server and start up the server per sample.
Useful for CI servers. The WildFly version that's used can be set via the ``wildfly.version`` property.
* ``wildfly-embedded``
This profile is almost identical to wildfly-ci-managed. It will install the same Wildfly server and start up
that server per sample again, but instead uses the Arquillian embedded connector to run it in the same JVM.
Useful for CI servers. The WildFly version that's used can be set via the ``wildfly.version`` property.
* ``wildfly-remote``
This profile requires you to start up a Wildfly server outside of the build. Each sample will then
reuse this instance to run the tests.
Useful for development to avoid the server start up cost per sample.
* ``wildfly-swarm``
This profile uses WildFly Swarm, which allows building uberjars that contain just enough of the WildFly
application server. Here, the parts of WildFly that are included are selected based on inspecting the application
and looking for the Java EE APIs that are actually used. The WildFly Swarm version that's used can be set via
the ``wildfly.swarm.version`` property.
* TomEE
* ``tomee-ci-managed``
This profile will install a TomEE server and start up that server per sample.
Useful for CI servers. This profile cannot connect to a running server.
Note that the version of TomEE to be used has to be present in an
available maven repository. The defaults in this profile assume that the arquillian adapter and
the TomEE server have the same version. E.g both 7.0.0.
To use a TomEE server that's not available in maven central, one way to use it for the samples is to
install it in a local .m2 as follows:
Clone TomEE repo:
``git clone https://github.com/apache/tomee``
``cd tomee``
Switch to the desired version if needed, then build and install in .m2:
``mvn clean install -pl tomee/apache-tomee -am -Dmaven.test.skip=true``
``mvn clean install -pl arquillian -amd -Dmaven.test.skip=true``
Make sure the version that's installed (see pom.xml in TomEE project) matches the ``tomee.version`` in the
properties section in the root pom.xml of the samples project.
* ``tomee-embedded``
This profile uses the TomEE embedded server and runs in the same JVM as the TestClass.
* Liberty
* ``liberty-managed``
This profile will start up the Liberty server per sample, and optionally connects to a running server that you
can start up outside of the build (with the restriction that this server has to run on the host as where
the tests are run using the same user).
To connect to a running server the ``org.jboss.arquillian.container.was.wlp_managed_8_5.allowConnectingToRunningServer``
system property has to be set to true. E.g.
``-Dorg.jboss.arquillian.container.was.wlp_managed_8_5.allowConnectingToRunningServer=true``
This profile requires you to set the location where Liberty is installed via the ``libertyManagedArquillian_wlpHome``
system property. E.g.
``-DlibertyManagedArquillian_wlpHome=/opt/wlp``
This profile also requires the localConnector feature to be configured in server.xml, and if all tests are to be run the
javaee-7.0 feature E.g.
```xml
<featureManager>
<feature>javaee-7.0</feature>
<feature>localConnector-1.0</feature>
</featureManager>
```
For older versions of Liberty (pre 16.0.0.0) for the JASPIC tests to even be attempted to be executed a cheat is needed that creates a group in Liberty's internal user registry:
```xml
<basicRegistry id="basic">
<group name="architect"/>
</basicRegistry>
```
This cheat is not needed for the latest versions of Liberty (16.0.0.0/2016.7 and later)
* ``liberty-ci-managed``
This profile will download and install a Liberty server and start up the server per sample.
Useful for CI servers. Note, this is not a real embedded server, but a regular server. It's now
called "embedded" because no separate install is needed as it's downloaded automatically.
* Weblogic
* ``weblogic-remote``
This profile requires you to start up a WebLogic server outside of the build. Each sample will then
reuse this instance to run the tests.
This profile requires you to set the location where WebLogic is installed via the ``weblogicRemoteArquillian_wlHome``
system property. E.g.
``-DweblogicRemoteArquillian_wlHome=/opt/wls12210``
The default username/password are assumed to be "admin" and "admin007" respectively. This can be changed using the
``weblogicRemoteArquillian_adminUserName`` and ``weblogicRemoteArquillian_adminPassword`` system properties. E.g.
``-DweblogicRemoteArquillian_adminUserName=myuser``
``-DweblogicRemoteArquillian_adminPassword=mypassword``
* Tomcat
* ``tomcat-remote``
This profile requires you to start up a plain Tomcat (8.5 or 9) server outside of the build. Each sample will then
reuse this instance to run the tests.
Tomcat supports samples that make use of Servlet, JSP, Expression Language (EL), WebSocket and JASPIC.
This profile requires you to enable JMX in Tomcat. This can be done by adding the following to ``[tomcat home]/bin/catalina.sh``:
```
JAVA_OPTS="$JAVA_OPTS -Dcom.sun.management.jmxremote.port=8089 -Dcom.sun.management.jmxremote=true "
JAVA_OPTS="$JAVA_OPTS -Dcom.sun.management.jmxremote.ssl=false "
JAVA_OPTS="$JAVA_OPTS -Dcom.sun.management.jmxremote.authenticate=false"
JAVA_OPTS="$JAVA_OPTS -Djava.rmi.server.hostname=localhost "
```
This profile also requires you to set a username (``tomcat``) and password (``manager``) for the management application in
``tomcat-users.xml``. See the file ``test-utils/src/main/resources/tomcat-users.xml`` in this repository for a full example.
Be aware that this should *only* be done for a Tomcat instance that's used exclusively for testing, as the above will make
the Tomcat installation **totally insecure!**
* ``tomcat-ci-managed``
This profile will install a Tomcat server and start up the server per sample.
Useful for CI servers. The Tomcat version that's used can be set via the ``tomcat.version`` property.
The containers that download and install a server (the \*-ci-managed profiles) allow you to override the version used, e.g.:
* `-Dpayara.version=4.1.1.163`
This will change the version from the current one (e.g 4.1.1.171.1) to 4.1.1.163 for Payara testing purposes.
* `-Dglassfish.version=4.1`
This will change the version from the current one (e.g 4.1.1) to 4.1 for GlassFish testing purposes.
* `-Dwildfly.version=8.1.0.Final`
This will change the version from the current one (e.g. 10.1.0.Final) to 8.1.0.Final for WildFly.
**To run them in the console do**:
1. In the terminal, ``mvn test -fae`` at the top-level directory to start the tests for the default profile.
When developing and runing them from IDE, remember to activate the profile before running the test.
To learn more about Arquillian please refer to the [Arquillian Guides](http://arquillian.org/guides/)
**To run only a subset of the tests do at the top-level directory**:
1. Install top level dependencies: ``mvn clean install -pl "test-utils,util" -am``
1. cd into desired module, e.g.: ``cd jaspic``
1. Run tests against desired server, e.g.: ``mvn clean test -P liberty-ci-managed``
## How to contribute ##
With your help we can improve this set of samples, learn from each other and grow the community full of passionate people who care about the technology, innovation and code quality. Every contribution matters!
There is just a bunch of things you should keep in mind before sending a pull request, so we can easily get all the new things incorporated into the master branch.
Standard tests are jUnit based - for example [this commit](servlet/servlet-filters/src/test/java/org/javaee7/servlet/filters/FilterServletTest.java). Test classes naming must comply with surefire naming standards `**/*Test.java`, `**/*Test*.java` or `**/*TestCase.java`.
For the sake of clarity and consistency, and to minimize the upfront complexity, we prefer standard jUnit tests using Java, with as additional helpers HtmlUnit, Hamcrest and of course Arquillian. Please don't use alternatives for these technologies. If any new dependency has to be introduced into this project it should provide something that's not covered by these existing dependencies.
### Some coding principles ###
* When creating new source file do not put (or copy) any license header, as we use top-level license (MIT) for each and every file in this repository.
* Please follow JBoss Community code formatting profile as defined in the [jboss/ide-config](https://github.com/jboss/ide-config#readme) repository. The details are explained there, as well as configurations for Eclipse, IntelliJ and NetBeans.
### Small Git tips ###
* Make sure your [fork](https://help.github.com/articles/fork-a-repo) is always up-to-date. Simply run ``git pull upstream master`` and you are ready to hack.
* When developing new features please create a feature branch so that we incorporate your changes smoothly. It's also convenient for you as you could work on few things in parallel ;) In order to create a feature branch and switch to it in one swoop you can use ``git checkout -b my_new_cool_feature``
That's it! Welcome in the community!
## CI Job ##
CI jobs are executed by [Travis](https://travis-ci.org/javaee-samples/javaee7-samples). Note that by the very nature of the samples provided here it's perfectly normal that not all tests pass. This normally would indicate a bug in the server on which the samples are executed. If you think it's really the test that's faulty, then please submit an issue or provide a PR with a fix.
## Run each sample in Docker
* Install Docker client from http://boot2docker.io
* Build the sample that you want to run as
``mvn clean package -DskipTests``
For example:
``mvn -f jaxrs/jaxrs-client/pom.xml clean package -DskipTests``
* Change the second line in ``Dockerfile`` to specify the location of the generated WAR file
* Run boot2docker and give the command
``docker build -it -p 80:8080 javaee7-sample``
* In a different shell, find out the IP address of the running container as:
``boot2docker ip``
* Access the sample as http://IP_ADDRESS:80/jaxrs-client/webresources/persons. The exact URL would differ based upon the sample.
| 1 |
VaughnVernon/IDDD_Samples | These are the sample Bounded Contexts from the book Implementing Domain-Driven Design" by Vaughn Vernon: http://vaughnvernon.co/?page_id=168" | 2013-04-08T22:12:57Z | null | These are the sample Bounded Contexts from the book
"Implementing Domain-Driven Design" by Vaughn Vernon:
http://vaughnvernon.co/?page_id=168
The models and surrounding architectural mechanisms
may be in various states of flux as the are refined
over time. Some tests may be incomplete. The code is
not meant to be a reflection of a production quality
work, but rather as a set of reference projects for
the book.
Points of Interest
==================
The iddd_agilepm project uses a key-value store as
its underlying persistence mechanism, and in particular
is LevelDB. Actually the LevelDB in use is a pure Java
implementation: https://github.com/dain/leveldb
Currently iddd_agilepm doesn't employ a container of
any kind (such as Spring).
The iddd_collaboration project uses Event Sourcing and
CQRS. It purposely avoids the use of an object-relational
mapper, showing that a simple JDBC-based query engine
and DTO matter can be used instead. This technique does
have its limitations, but it is meant to be small and fast
and require no configuration or annotations. It is not
meant to be perfect.
It may be helpful to make one additional mental note on
the iddd_collaboration CQRS implementation. To keep the
example simple it persists the Event Sourced write model
and the CQRS read model in one thread. Since two different
stores are used--LevelDB for the Event Journal and MySQL
for the read model--there may be very slight opportunities
for inconsistency, but not much. The idea was to keep the
two models as close to consistent as possible without
using the same data storage (and transaction) for both.
Two different storage mechanisms were used purposely to
demonstrate that they can be separate.
The iddd_identityaccess project uses object-relational
mapping (Hibernate), but so as not to leave it "boring" it
provides a RESTful client interface and even publishes
Domain-Event notifications via REST (logs) and RabbitMQ.
Finally the iddd_common project provides a number of reusable
components. This is not an attempt to be a framework, but
just leverages reuse to the degree that code copying doesn't
liter each project. This is not a recommendation, but it
did work well and save a considerable amount of work while
producing the samples.
Usage
=====
Requires
--------
- Java 7 (8+ does not work)
- MySQL Client + Server
- RabbitMQ
Setup (with Docker)
-------------------
To make it easy to run the tests and it requirements,
the `startContainers.sh` script is provided. Which
will start a:
- MySQL Server container
- RabbitMQ Server container
- RabbitMQ Management container
If the `mysql` command is available, which is the mysql client,
also the required SQL scripts will be imported into the MySQL
Server.
If you use the `startContainers.sh` script, you don't need
MySQL Server and RabbitMQ installed locally. Instead,
Docker needs to be installed as the script will start
MySQL and RabbitMQ in Docker containers.
Build
------
You can build the project by running:
```
./gradlew build
```
This automatically downloads Gradle and builds the project, including running the tests.
The Gradle build using Maven repositories was provided by
Michael Andrews (Github michaelajr and Twitter @MichaelAJr).
Thanks much!
I hope you benefit from the samples.
Vaughn Vernon
Author: Implementing Domain-Driven Design
Twitter: @VaughnVernon
http://vaughnvernon.co/
| 1 |
microservices-security-in-action/samples | Microservices Security in Action Book Samples | 2018-04-15T22:49:51Z | null | # Microservices Security In Action
**By [Prabath Siriwardena](https://twitter.com/prabath) and [Nuwan Dias](https://twitter.com/nuwandias)**
<img src="cover.jpeg" style="float: left; width: 100%" />
[Amazon](https://www.amazon.com/Microservices-Security-Action-Prabath-Siriwardena/dp/1617295957/) | [Manning](https://www.manning.com/books/microservices-security-in-action) | [YouTube](https://www.youtube.com/channel/UCoEOYnrqEcANUgbcG-BuhSA) | [Slack](https://bit.ly/microservices-security) | [Notes](notes.md) | [Supplementary Readings](supplementary-readings.md)
**NOTE: While writing the book we wanted to mostly focus on the concepts, as the concrete technologies used to implement the concepts are constantly changing and we wanted to keep them as much as simple. So we decided to use Spring Boot to implement the OAuth 2.0 authorization server used in the samples of the book. However in practice you may use Keycloak, Auth0, Okta, WSO2, and so on as your authorization server.**
**Spring Boot has deprecated AuthorizationServerConfigurerAdapter, ClientDetailsServiceConfigurer, and AuthorizationServerSecurityConfigurer classes, which we used to implement the authorization server, which we will surely update in the next edition of the book and will also update the github project even before that. However, we expect this will not distract the readers that much, because we don't expect them to implement an authorization server.**
## PART 1 OVERVIEW
### 1 ■ Microservices security landscape
### 2 ■ [First steps in securing microservices](chapter02)
## PART 2 EDGE SECURITY
### 3 ■ [Securing north/south traffic with an API gateway](chapter03)
### 4 ■ [Accessing a secured microservice via a single-page application](chapter04)
### 5 ■ [Engaging throttling, monitoring, and access control](chapter05)
## PART 3 SERVICE-TO-SERVICE COMMUNICATIONS
### 6 ■ [Securing east/west traffic with certificates ](chapter06)
### 7 ■ [Securing east/west traffic with JWT](chapter07)
### 8 ■ [Securing east/west traffic over gRPC](chapter08)
### 9 ■ [Securing reactive microservices](chapter09)
## PART 4 SECURE DEPLOYMENT
### 10 ■ [Conquering container security with Docker](chapter10)
### 11 ■ [Securing microservices on Kubernetes](chapter11)
### 12 ■ [Securing microservices with Istio service mesh](chapter12)
### PART 5 SECURE DEVELOPMENT
### 13 ■ [Secure coding practices and automation](chaper13)
## APPENDICES
### A ■ OAuth 2.0 and OpenID Connect
### B ■ [JSON Web Token](appendix-b)
### C ■ Single-page application architecture
### D ■ Observability in a microservices deployment
### E ■ [Docker fundamentals](appendix-e)
### F ■ [Open Policy Agent](appendix-f)
### G ■ Creating a certificate authority and related keys with OpenSSL
### H ■ Secure Production Identity Framework for Everyone
### I ■ [gRPC fundamentals](appendix-i)
### J ■ [Kubernetes fundamentals](appendix-j)
### K ■ [Service mesh and Istio fundamentals](appendix-k)
| 1 |
junit-team/junit5-samples | Collection of sample applications using JUnit 5. | 2015-11-13T21:28:16Z | null | # JUnit 5 Samples [![ci-badge]][ci-actions]
Welcome to _JUnit 5 Samples_, a collection of sample applications and extensions
using JUnit Jupiter, JUnit Vintage, and the JUnit Platform on various build systems.
CI builds for sample projects are performed by [GitHub Actions][ci-actions]. Using JDK 11+'s
`jshell` tool, you may build all samples via the `build-all-samples.jsh` script.
## Jupiter Starter Samples
_Basic setups showing how to get started with JUnit Jupiter._
### Jupiter on Ant ![badge-jdk-8] ![badge-tool-ant] ![badge-junit-jupiter]
The [junit5-jupiter-starter-ant] sample demonstrates the bare minimum configuration for
getting started with JUnit Jupiter using the Ant build system.
### Jupiter on Gradle ![badge-jdk-8] ![badge-tool-gradle] ![badge-junit-jupiter]
The [junit5-jupiter-starter-gradle] sample demonstrates the bare minimum configuration for
getting started with JUnit Jupiter using the Gradle build system.
### Jupiter on Gradle using Kotlin ![badge-jdk-8] ![badge-tool-gradle] ![badge-junit-jupiter]
The [junit5-jupiter-starter-gradle-kotlin] sample demonstrates the bare minimum
configuration for getting started with JUnit Jupiter using the Gradle build system and the
Kotlin programming language.
### Jupiter on Gradle using Groovy ![badge-jdk-8] ![badge-tool-gradle] ![badge-junit-jupiter]
The [junit5-jupiter-starter-gradle-groovy] sample demonstrates the bare minimum
configuration for getting started with JUnit Jupiter using the Gradle build system and the
Groovy programming language.
### Jupiter on Maven ![badge-jdk-8] ![badge-tool-maven] ![badge-junit-jupiter]
The [junit5-jupiter-starter-maven] sample demonstrates the bare minimum configuration for
getting started with JUnit Jupiter using the Maven build system.
### Jupiter on Maven using Kotlin ![badge-jdk-8] ![badge-tool-maven] ![badge-junit-jupiter]
The [junit5-jupiter-starter-maven-kotlin] sample demonstrates the bare minimum configuration for
getting started with JUnit Jupiter project using Maven build system and Kotlin programming language.
### Jupiter on Bazel ![badge-jdk-8] ![badge-tool-bazel] ![badge-junit-jupiter]
The [junit5-jupiter-starter-bazel] sample demonstrates the bare minimum configuration for
getting started with JUnit Jupiter using the Bazel build system.
### Jupiter on sbt ![badge-jdk-8] ![badge-tool-sbt] ![badge-junit-jupiter]
The [junit5-jupiter-starter-sbt] sample demonstrates the bare minimum configuration for
getting started with JUnit Jupiter using sbt and the Scala programming language.
## Jupiter Feature Samples
_Extending JUnit Jupiter using its `Extension` API._
### Sample Extensions ![badge-jdk-8] ![badge-tool-gradle] ![badge-junit-jupiter]
The [junit5-jupiter-extensions] sample demonstrates how one can implement custom
JUnit Jupiter extensions and use them in tests.
## Migration Samples
_More complex setups how to integrate various parts of "JUnit 5" including a
possible migration path for JUnit 3 or 4 based projects._
### Gradle Migration ![badge-jdk-8] ![badge-tool-gradle] ![badge-junit-platform] ![badge-junit-jupiter] ![badge-junit-vintage]
The [junit5-migration-gradle] sample demonstrates how to set up a Gradle project
using the JUnit Platform, JUnit Jupiter, and JUnit Vintage.
### Maven Migration ![badge-jdk-8] ![badge-tool-maven] ![badge-junit-platform] ![badge-junit-jupiter] ![badge-junit-vintage]
The [junit5-migration-maven] sample demonstrates how to set up a Maven project
using the JUnit Platform, JUnit Jupiter, and JUnit Vintage.
## Platform Samples
_Showing basic features of the JUnit Platform._
### Multiple Engines ![badge-jdk-11] ![badge-tool-gradle] ![badge-junit-platform] ![badge-junit-jupiter] ![badge-junit-vintage] ...
The [junit5-multiple-engines] sample demonstrates how to set up a Gradle project
using the JUnit Platform with various [TestEngine][guide-custom-engine] implementations.
### Living in the Modular World ![badge-jdk-11] ![badge-tool-console] ![badge-junit-platform]
The [junit5-modular-world] sample demonstrates how to test code organized in modules.
This sample also demonstrates how to implement a custom [TestEngine][guide-custom-engine]
for the JUnit Platform using the Java Platform Module System.
[junit5-jupiter-extensions]: junit5-jupiter-extensions
[junit5-jupiter-starter-ant]: junit5-jupiter-starter-ant
[junit5-jupiter-starter-gradle]: junit5-jupiter-starter-gradle
[junit5-jupiter-starter-gradle-groovy]: junit5-jupiter-starter-gradle-groovy
[junit5-jupiter-starter-gradle-kotlin]: junit5-jupiter-starter-gradle-kotlin
[junit5-jupiter-starter-maven]: junit5-jupiter-starter-maven
[junit5-jupiter-starter-maven-kotlin]: junit5-jupiter-starter-maven-kotlin
[junit5-jupiter-starter-bazel]: junit5-jupiter-starter-bazel
[junit5-jupiter-starter-sbt]: junit5-jupiter-starter-sbt
[junit5-migration-gradle]: junit5-migration-gradle
[junit5-migration-maven]: junit5-migration-maven
[junit5-multiple-engines]: junit5-multiple-engines
[junit5-modular-world]: junit5-modular-world
[badge-jdk-8]: https://img.shields.io/badge/jdk-8-lightgray.svg "JDK-8"
[badge-jdk-11]: https://img.shields.io/badge/jdk-11-red.svg "JDK-11 or higher"
[badge-tool-ant]: https://img.shields.io/badge/tool-ant-10f0f0.svg "Ant"
[badge-tool-gradle]: https://img.shields.io/badge/tool-gradle-blue.svg "Gradle wrapper included"
[badge-tool-maven]: https://img.shields.io/badge/tool-maven-0440af.svg "Maven wrapper included"
[badge-tool-bazel]: https://img.shields.io/badge/tool-bazel-43a047.svg "Bazel"
[badge-tool-sbt]: https://img.shields.io/badge/tool-sbt-43a047.svg "SBT"
[badge-tool-console]: https://img.shields.io/badge/tool-console-022077.svg "Command line tools"
[badge-junit-platform]: https://img.shields.io/badge/junit-platform-brightgreen.svg "JUnit Platform"
[badge-junit-jupiter]: https://img.shields.io/badge/junit-jupiter-green.svg "JUnit Jupiter Engine"
[badge-junit-vintage]: https://img.shields.io/badge/junit-vintage-yellowgreen.svg "JUnit Vintage Engine"
[ci-badge]:https://github.com/junit-team/junit5-samples/workflows/Build%20all%20samples/badge.svg "CI build status"
[ci-actions]: https://github.com/junit-team/junit5-samples/actions
[guide-custom-engine]: http://junit.org/junit5/docs/current/user-guide/#launcher-api-engines-custom "Plugging in Your Own Test Engine"
| 1 |
rengwuxian/RxJavaSamples | RxJava 2 和 Retrofit 结合使用的几个最常见使用方式举例 | 2016-03-24T13:08:10Z | null | 样例代码已正式切换到基于 RxJava 2
================
> 需要旧版 RxJava 1 代码的点[这里](https://github.com/rengwuxian/RxJavaSamples/tree/1.x)
### 项目介绍
RxJava 2 和 Retrofit 结合使用的几个最常见使用方式举例。
1. **基本使用**
实现最基本的网络请求和结果处理。
![screenshot_1](./images/screenshot_1.png)
2. **转换(map)**
把返回的数据转换成更方便处理的格式再交给 Observer。
![screenshot_2](./images/screenshot_2.png)
3. **压合(zip)**
将不同接口并行请求获取到的数据糅合在一起后再处理。
![screenshot_3](./images/screenshot_3.png)
4. **一次性 token**
需要先请求 token 再访问的接口,使用 flatMap() 将 token 的请求和实际数据的请求连贯地串起来,而不必写嵌套的 Callback 结构。
![screenshot_4](./images/screenshot_4.png)
5. **非一次性 token**
对于非一次性的 token (即可重复使用的 token),在获取 token 后将它保存起来反复使用,并通过 retryWhen() 实现 token 失效时的自动重新获取,将 token 获取的流程彻底透明化,简化开发流程。
![screenshot_5](./images/screenshot_5.png)
6. **缓存**
使用 BehaviorSubject 缓存数据。
![screenshot_6](./images/screenshot_6.png)
### apk 下载
[RxJavaSamples_2.0.apk](https://github.com/rengwuxian/RxJavaSamples/releases/download/2.0/RxJavaSamples_2.0.apk) | 0 |
sanaulla123/samples | Samples used in my blog posts | 2017-10-31T17:41:56Z | null | ## Related Blog Posts
- [JDK 12 – JEP 325 Switch Expressions](https://sanaulla.info/2019/04/13/jdk-12-switch-expressions/)
- [How to create a QR Code SVG using Zxing and JFreeSVG in Java?](https://sanaulla.info/2019/04/12/how-to-create-a-qr-code-svg-using-zxing-and-jfreesvg-in-java/)
- [Launch Single-File Source-Code Programs in JDK 11](https://sanaulla.info/2018/07/05/launch-single-file-source-code-programs-in-jdk-11/)
- [Java 10 – JEP 286: Local-Variable Type Inference](https://sanaulla.info/2018/03/04/java-10-jep-286-local-variable-type-inference/)
- [Moving From Mustache.js and jQuery to Vuejs for Client Side View Management Reactively](https://sanaulla.info/2017/12/06/moving-from-mustache-js-to-vuejs-for-client-side-view-management/) | 1 |
pavansolapure/opencodez-samples | The code repository for Opencodez. Here at this git, we are trying to share code for Java, Python, PHP, Oracle and any new technology we try our hands and feel it can add value. | 2016-09-26T06:47:02Z | null | # www.opencodez.com - code samples
This is where we keep all of our code samples. Please feel free to download, try and suggest any changes or enhancements.
I am providing here link for each of the article that is associated with code. This will help you understand and give you a chance to express your thoughts.
# Java
2-way-ssl-authentication https://www.opencodez.com/java/implement-2-way-authentication-using-ssl.htm
actuators https://www.opencodez.com/java/spring-boot-actuators.htm
ad-ldap-demo https://www.opencodez.com/java/configure-ldap-authentication-using-spring-boot.htm
apache-cxf-ws https://www.opencodez.com/java/soap-web-services-with-apache-cxf-spring-boot.htm
currency-conversion https://www.opencodez.com/java/currency-conversion-app-spring-boot-java.htm
device-detection https://www.opencodez.com/java/device-detection-using-spring-mobile.htm
encrypted-mail https://www.opencodez.com/java/send-encrypted-email-using-java.htm
generic-csv-reader https://www.opencodez.com/java/generic-csv-file-reader-in-java.htm
java-deep-learning https://www.opencodez.com/java/deeplearaning4j.htm
kafka-demo https://www.opencodez.com/java/using-apache-kafka-java.htm
mail-demo https://www.opencodez.com/java/java-mail-framework-using-spring-boot.htm
microservices https://www.opencodez.com/java/microservices-action-spring-boot.htm
multi-db https://www.opencodez.com/java/connecting-multiple-databases-spring-data-jpa.htm
quartz-demo https://www.opencodez.com/java/quartz-scheduler-with-spring-boot.htm
restful-demo https://www.opencodez.com/java/building-restful-web-services-using-java.htm
spring-boot-datatable https://www.opencodez.com/java/datatable-with-spring-boot.htm
spring-kafka-demo https://www.opencodez.com/java/how-to-build-message-driven-application-using-kafka-and-spring-boot.htm
web-app-starter https://www.opencodez.com/java/java-web-application-starter-template-using-spring-boot.htm
zip-test https://www.opencodez.com/java/zip-file-using-java.htm
# Python
keras-text-classification https://www.opencodez.com/python/text-classification-using-keras.htm
# Oracle
Oracle https://www.opencodez.com/oracle/oracle-job-scheduler-guide-examples-part-1.htm
| 1 |
spring-projects/spring-security-samples | null | 2020-07-29T17:05:15Z | null | null | 1 |
lenve/javaboy-code-samples | 公众号【江南一点雨】文章案例汇总,技术文章请戳这里-----> | 2019-05-10T11:36:20Z | null | 各位小伙伴大家好!
扫码加微信(微信ID:**a_java_boy2**),备注 SpringBoot,进群讨论。
![微信ID:a_java_boy2](https://user-images.githubusercontent.com/6023444/75459026-ba70d500-59b9-11ea-8cbd-3d5889f356c4.png)
## 仓库简介
松哥长期坚持在微信公众号**江南一点雨**上分享原创技术教程,但是代码一直没有统一管理过,最近有小伙伴提出,希望松哥能把文章的代码整理下,方便大伙参考。于是,松哥创建了这个仓库,用来分享微信公众号**江南一点雨**上文章的案例。小伙伴要是觉得这个仓库有用的话,记得点个 star。
## 代码索引
|code-samples|对应的文章|
|:---|:---|
|spring-boot-starter-custom|[徒手撸一个 Spring Boot 中的 Starter ,解密自动化配置黑魔法!](https://mp.weixin.qq.com/s/tKr_shLQnvcQADr4mvcU3A)|
|api.js|[Spring Boot + Vue 前后端分离开发,前端网络请求封装与配置](https://mp.weixin.qq.com/s/K8ANNmm6ZrP2xMyK6LGZ_g)|
|javassm|[这一次,我连 web.xml 都不要了,纯 Java 搭建 SSM 环境](https://mp.weixin.qq.com/s/NC_0oaeBzRjCB34U_ZWxIQ)|
|properties|[是时候彻底搞清楚 Spring Boot 的配置文件 application.properties 了!](https://mp.weixin.qq.com/s/cUhzpo8zkQq09d8S4WkAsw)|
|redis|[Spring Boot 操作 Redis,三种方案全解析!](https://mp.weixin.qq.com/s/cgDtmjPWTdh44bSlLC0Qsw)|
|sessionshare|[Spring Boot 一个依赖搞定 session 共享,没有比这更简单的方案了!](https://mp.weixin.qq.com/s/xs67SzSkMLz6-HgZVxTDFw)|
|restful|[Spring Boot 中 10 行代码构建 RESTful 风格应用](https://mp.weixin.qq.com/s/7uO87SOu93XH2Y3iWxWicg)|
|shiro|[Spring Boot 整合 Shiro ,两种方式全总结!](https://mp.weixin.qq.com/s/JU_-gn-yZ4VJJXTZvo7nZQ)|
|quartz|[Spring Boot 中实现定时任务的两种方式!](https://mp.weixin.qq.com/s/_20RYBkjKrB4tdpXI3hBOA)|
|ehcache|[另一种缓存,Spring Boot 整合 Ehcache](https://mp.weixin.qq.com/s/i9a3VOf_GMN_UBQ-8tKi3A)|
|thymeleaf|[极简 Spring Boot 整合 Thymeleaf 页面模板](https://mp.weixin.qq.com/s/7tgiuFceyZPHBZcLnPmkfw)|
|exception|[Spring Boot 中关于自定义异常处理的套路!](https://mp.weixin.qq.com/s/w26MvCWQ1RO4CUJrfXi5AA)|
|jdbctemplate|[Spring Boot数据持久化之JdbcTemplate](https://mp.weixin.qq.com/s/X4-e1cf3uZafg8XtMJeo_Q)|
|jdbcmulti|[Spring Boot多数据源配置之JdbcTemplate](https://mp.weixin.qq.com/s/7po83-CAoryo1eglumW42Q)|
|mybatis|[最简单的SpringBoot整合MyBatis教程](https://mp.weixin.qq.com/s/HOnX2XRDWrQ9oOKLo1ueKw)|
|mybatismulti|[极简Spring Boot整合MyBatis多数据源](https://mp.weixin.qq.com/s/9YXwk2-4zIq60WFuy6nXdw)|
|jpa|[是时候了解下Spring Boot整合 Jpa啦](http://www.javaboy.org/2019/0407/springboot-jpa.html)|
|jpamulti|[Spring Boot 整合 Jpa 多数据源](http://www.javaboy.org/2019/0407/springboot-jpa-multi.html)|
|jwt|[干货\|一个案例学会Spring Security 中使用 JWT!](https://mp.weixin.qq.com/s/riyFQSrkQBQBCyomE__fLA)|
|security_json|[SpringSecurity登录使用JSON格式数据](https://mp.weixin.qq.com/s/X1t-VCxzxIcQKOAu-pJrdw)|
|swagger2|[SpringBoot整合Swagger2,再也不用维护接口文档了!](https://mp.weixin.qq.com/s/iTsTqEeqT9K84S091ycdog)|
|cors|[Spring Boot中通过CORS解决跨域问题](https://mp.weixin.qq.com/s/ASEJwiswLu1UCRE-e2twYQ)|
|freemarker|[Spring Boot 整合 Freemarker,50 多行配置是怎么省略掉的?](https://mp.weixin.qq.com/s/zXwAy1dMlITqHOdBNeZEKg)|
|mail|[Spring Boot 邮件发送的 5 种姿势!](https://mp.weixin.qq.com/s/8UiEMpono-hUrRVwvDjUgA)|
|docker|[一键部署 Spring Boot 到远程 Docker 容器,就是这么秀!](https://mp.weixin.qq.com/s/vSCQLvQBYMYoPhdlO2v3XA)|
|https|[Spring Boot 支持 Https 有那么难吗?](https://mp.weixin.qq.com/s/WOmOXN_IK0IMjL0_hlAOFA)|
|jwt-demo|[Spring Security 结合 Jwt 实现无状态登录](https://mp.weixin.qq.com/s/Sn59dxwtsEWoj2wdynQuRQ)|
|docker-jib|[别用 Dockerfile 部署 Spring Boot 啦!松哥教你两步搞定!](https://mp.weixin.qq.com/s/ZqWktjLUOzHNKOGE6BfHRA)|
## 松哥简介
大家好,我是江南一点雨,管理学学士,大学自学 Java 编程,从移动端到前端到后端均有涉猎,现在专注于 Java 微服务,我是 CSDN 博客专家、华为云云享专家、《Spring Boot + Vue全栈开发实战》 作者、运营了一个公众号 **江南一点雨**,专注于 Spring Boot + 微服务以及前后端分离技术分享,欢迎大家关注!关注公众号回复 2TB,领取松哥为大家精心准备的 Java 干货!
### 我的公众号
![](http://www.javaboy.org/images/sb/javaboy.jpg)
### 我的站点
- 独立站点: http://www.javaboy.org
- GitHub: https://github.com/lenve
- CSDN: http://wangsong.blog.csdn.net
- 思否: https://segmentfault.com/u/lenve
- 博客园: https://www.cnblogs.com/lenve
- 掘金: https://juejin.im/user/57d679af0bd1d000585012a7 | 1 |
agoncal/agoncal-sample-jaxrs | Samples about JAX-RS | 2012-11-23T17:14:05Z | null | # Samples - JAX-RS
## Purpose of this sample
Several samples about JAX-RS :
* 01-Testing : Simple integration test
# Licensing
<a rel="license" href="http://creativecommons.org/licenses/by-sa/3.0/"><img alt="Creative Commons License" style="border-width:0" src="http://i.creativecommons.org/l/by-sa/3.0/88x31.png" /></a><br />This work is licensed under a <a rel="license" href="http://creativecommons.org/licenses/by-sa/3.0/">Creative Commons Attribution-ShareAlike 3.0 Unported License</a>.
<div class="footer">
<span class="footerTitle"><span class="uc">a</span>ntonio <span class="uc">g</span>oncalves</span>
</div> | 1 |
habuma/spring-in-action-5-samples | Home for example code from Spring in Action 5. | 2018-08-11T23:29:43Z | null | null | 1 |
mercyblitz/thinking-in-spring-boot-samples | 小马哥书籍《Spring Boot 编程思想》示例工程 | 2018-11-22T13:34:21Z | null | # 《Spring Boot 编程思想》
> 谨以此书纪念已故外婆 - 解厚群
本书全名为《Spring Boot 编程思想》,是以 Spring Boot 2.0 为讨论的主线,讨论的范围将涵盖 Spring Boot 1.x 的所有版本,以及所关联的 Spring Framework 版本,致力于:
- 场景分析:掌握技术选型
- 系统学习:拒绝浅尝辄止
- 重视规范:了解发展趋势
- 源码解读:理解设计思想
- 实战演练:巩固学习成果
## 自序
- [《核心篇》](https://mercyblitz.github.io/books/thinking-in-spring-boot/core/preface/)([预售中…](https://item.jd.com/12570242.html))
- 《运维篇》(即将完稿…)
- 《Web 篇》(编写中…)
## 扉页
- [内容总览](https://mercyblitz.github.io/books/thinking-in-spring-boot/overview/)
- [版本范围](https://mercyblitz.github.io/books/thinking-in-spring-boot/version/)
- [相关约定](https://mercyblitz.github.io/books/thinking-in-spring-boot/conventions/)
- [配套视频](https://mercyblitz.github.io/books/thinking-in-spring-boot/videos/)
- [示例工程](https://mercyblitz.github.io/books/thinking-in-spring-boot/samples/)
- [勘误汇总](https://mercyblitz.github.io/books/thinking-in-spring-boot/revision/)
- [公益资金流向](https://mercyblitz.github.io/books/thinking-in-spring-boot/donate/)
## [关于我](https://mercyblitz.github.io/books/thinking-in-spring-boot/about/)
“我是谁?”,是个不错的哲学问题。
在江湖上,大家亲切地称我 “小马哥“,我做公益,也做生意;在社区中,我又以 `mercyblitz` 的身份出没在众多开源项目,"mercy" 符合我的性格,"blitz" 说明我的风格。
承蒙错爱,不少的朋友对我过去的分享称赞有加,然而“千人之诺诺,不如一士之谔谔”,时常又让自己陷入一种迷思,到底是平台的帮衬,还是个人的确禁得起考验。于是我选择隐匿真名,希望能够听到更为真实的声音。尽管在互联网时代,只要稍作功课,个人信息几乎无处遁形。无可讳言,本人的所属公司以及职业头衔必然会形成“舞台效应”,如此一来,不但违背了写书的初衷,而且模糊了讨论的焦点。所以,本书即不会出现这些信息,又不会搞“个人崇拜”。它的价值应该体现在知识的传播,至于它的优劣则由诸君来评判。
## 交流社区
- 微信公众号:次灵均阁
![微信公众号二维码](https://mercyblitz.github.io/books/thinking-in-spring-boot/assets/my_mp_qrcode.jpg)
- [知识星球](https://t.zsxq.com/72rj2rr):
![小马哥 Java 星球](https://mercyblitz.github.io/books/thinking-in-spring-boot/assets/my_java_planet.png)
- [Github](http://github.com/mercyblitz):[http://github.com/mercyblitz](http://github.com/mercyblitz)
> 更多个人信息,请使用 [Google 搜索 `mercyblitz`](https://www.google.com/search?q=mercyblitz)
| 1 |
hazelcast/hazelcast-code-samples | Hazelcast Code Samples | 2013-07-27T17:31:05Z | null | Hazelcast Code Samples Readme
=============================
The folder **/code-samples** in your package contains an extensive collection of code samples which you can use to learn how to use Hazelcast features. From distributed primitives to Service Provider Interface (SPI), you can see Hazelcast in action readily.
How to run
----------
If the sample has a README file, follow the instructions. A lot of samples have shell scripts like "start.sh", "start-member.sh" or "start-client.sh", use them to run the sample. If none of the previous options apply, use _java -cp target/classes:target/lib/\* <fully qualified name of the main class>_ to run the sample.
Included sample folders
-----------------------
* **/clients** — Includes sample code that shows how to create a Hazelcast client, put a message on a queue by this client and receive that message by a Hazelcast node. Further how to set up client's near cache, deploy user code to member, communicate via REST or populate client statistics to member.
* **/cluster** — cluster state managements and shutdown
* **/cluster-split-brain-protection** — setting up cluster split brain protection programatically
* **/cluster-split-brain-protection-xml** — setting up cluster split brain protection via XML configuration
* **/cluster-state** — managing cluster state to frozen, passive and shutdown.
* **/demo** — You can start multiple nodes and operate usual map operations using the code samples here.
* **/distributed-collections** — Includes Distributed Queue, Bounded Queue, Listeners, Set, List, Queue store, Ringbuffer and Ringbuffer store code samples.
* **/distributed-executor** — examples of distributed task execution e.g. executing on all member, just key owner, only lite nodes only, on specific member. Also examples of usage of futures and scheduled executions.
* **/distributed-map** — An extensive code samples folder that includes many features of the Hazelcast distributed map in action.
* **/distributed-primitives** — Includes Distributed AtomicLong, AtomicReference, CountDownLatch, IdGenerator, FlakeIdGenerator, CardinalityEstimator, Condition, Semaphore and Lock code samples.
* **/distributed-topic** — Code samples to see publish/subscriber messaging model.
* **/enterprise** — Includes socket and security interceptor, CPMap, HD store and hot restart code samples.
* **/hazelcast-integration** — Code samples to show how you can integrate Hazelcast with Hibernate 2nd Level Cache and Spring. It also includes code samples for web session replication and resource adapter implementation.
* **/jcache** — An extensive code samples folder for operations including creating a cache and writing entries to it, creating listeners and clients.
* **/jet** — Code samples to demonstrate building stream and batch processing applications using Hazelcast's Jet engine.
* **/jmx** — example of connecting to Hazelcast member via JMX.
* **/json** — examples of JSON objects stored in Hazelcast.
* **/learning-basics** — Code samples to show some Hazelcast basics like creating, configuring and destroying Hazelcast instances, configuring logging and Hazelcast configuration.
* **/monitoring** — Includes code samples that show how to check if a Hazelcast cluster is safe to be shutdown.
* **/near-cache** — Shows the benefits of Near Caches, local subsets of data that track the master copy in the grid. Further extends the _/clients_ examples.
* **/network-configuration** — Shows what options Hazelcast configuration has regarding to network (e.g. partition grouping, multicast, ports, outbound ports, etc.)
* **/osgi** — Demonstrates how to use Hazelcast's OSGI support
* **/replicated-map** — Code samples to show how to get a replicated map and create an entry listener.
* **/serialization** — Includes code samples that implement various serialization interfaces like DataSerializable, IdentifiedDataSerializable, Externalizable and Portable. It also has code samples to show how to plug a custom serializer using StreamSerializer and ByteArraySerializer interfaces and usage of Kryo and Protobuf serializers.
* **/spi** — Includes code samples that create a simple counter application using Hazelcast’s Service Provider Interface (SPI).
* **/sql** — Examples of using SQL directly, or via JDBC.
* **/transactions** — Code samples showing how to use the TransactionalMap and TransactionalTask interfaces.
Included helper folders
-----------------------
* **/checkstyle** — Java code style configuration
* **/helper** — Shared utility classes and methods for samples | 1 |
spring-cloud/spring-cloud-stream-samples | Samples for Spring Cloud Stream | 2016-02-19T14:32:27Z | null | null | 1 |
googleworkspace/java-samples | ☕ Java samples for Google Workspace APIs. | 2014-05-02T18:11:16Z | null | # Google Workspace Java Samples
A collection of samples that demonstrate how to call Google Workspace APIs in Java.
## APIs
### Admin SDK
- [Alert Center Quickstart](https://developers.google.com/admin-sdk/alertcenter/quickstart/java)
- [Directory Quickstart](https://developers.google.com/admin-sdk/directory/v1/quickstart/java)
- [Reports Quickstart](https://developers.google.com/admin-sdk/reports/v1/quickstart/java)
- [Reseller Quickstart](https://developers.google.com/admin-sdk/reseller/v1/quickstart/java)
### Apps Script
- [Quickstart](https://developers.google.com/apps-script/api/quickstart/java)
### Calendar
- [Quickstart](https://developers.google.com/calendar/quickstart/java)
- [Sync Tokens and Etags](calendar/sync)
- [Command-line sample](https://github.com/google/google-api-java-client-samples/tree/master/calendar-cmdline-sample)
### Classroom
- [Quickstart](https://developers.google.com/classroom/quickstart/java)
### Docs
- [Quickstart](https://developers.google.com/docs/api/quickstart/java)
### Drive V3
- [Quickstart](https://developers.google.com/drive/v3/web/quickstart/java)
- [Command-line sample](https://github.com/google/google-api-java-client-samples/tree/master/drive-cmdline-sample)
### Gmail
- [Quickstart](https://developers.google.com/gmail/api/quickstart/java)
### People
- [Quickstart](https://developers.google.com/people/quickstart/java)
### Sheets
- [Quickstart](https://developers.google.com/sheets/api/quickstart/java)
### Slides
- [Quickstart](https://developers.google.com/slides/quickstart/java)
### Tasks
- [Quickstart](https://developers.google.com/google-apps/tasks/quickstart/java)
### Vault
- [Quickstart](https://developers.google.com/vault/quickstart/java)
| 1 |
udacity/ud862-samples | null | 2015-08-10T22:29:29Z | null | # ud862-samples
This repository holds the code samples written for ud862 - Android Design for Developers.
| 1 |
devunwired/accessory-samples | Talk to Your Toaster Accessory Sample Code | 2012-08-15T20:07:50Z | null | Android Accessory Examples
--------------------------
This repository contains sample applications demonstrating many of the techniques for doing custom accessory development discussed in "Talk to Your Toaster".
Examples include:
- Bluetooth RFCOMM
- Bluetooth Headset Profile
- USB Open Accessory Protocol
- USB Host Protocol
The sample code is licensed under the MIT Open Source License | 1 |
spring-projects/spring-amqp-samples | Samples for Spring AMQP | 2011-03-10T14:40:16Z | null | This project hosts some samples that complement [Spring AMQP](https://github.com/SpringSource/spring-amqp), showing you how to get started with Spring and AMQP.
# Build Instructions #
Install the [RabbitMQ](https://www.rabbitmq.com) broker first (version
2.3.1 or better). Then clone from GIT and then use Maven (2.1.*):
$ git clone ...
$ mvn install
SpringSource ToolSuite users (or Eclipse users with the latest
m2eclipse plugin) can import the projects as existing Maven projects.
The basic HelloWorld sample has two versions (with synchronous and
asynchronous consumers). Both have two Java classes called `Producer`
and `Consumer` with main methods to launch. Run the producer first
and ensure that the broker is already running.
The Stocks sample has a UI that can be launched as a Java main, and a
daemon server process with the same properties. You can run them from
an IDE easily. Run the `Server` and then the `Client` and you should
see a swing client pop up and stock tickers appearing. To run from
the command line you can use the Maven exec plugin:
$ mvn exec:java -Dexec.classpathScope=test -Dexec.mainClass=org.springframework.amqp.rabbit.stocks.Server &
$ mvn exec:java -Dexec.classpathScope=test -Dexec.mainClass=org.springframework.amqp.rabbit.stocks.Client
In the example above we backgrounded the server process, or you could
run it in a different window to make things clearer in the console
logs.
## Web UI
The Stocks sample is also a web application. You should be able to run it in your IDE, e.g. if you imported the project into STS (or Eclipse with Maven support) you can drag it onto a server, or use `Run As...->On Server`. From the command line you can use
$ mvn jetty:run
The web UI is designed like the swing client - it has a ticker table
that updates every second (if there is any new data), and an order
entry form. The `QuoteController` manages the interaction between the
browser and the application and between the application and the AMQP
broker.
## RabbitMQ Tutorials
Spring Boot versions of the [6 standard RabbitMQ tutorials](https://www.rabbitmq.com/getstarted.html) are provided in `rabbitmq-tutorials`.
## Spring Boot Applications
Several Spring Boot applications are also provided, with names `spring-rabbit-...`.
Explore their individual READMEs for more information.
# Contributing to Spring AMQP Samples
Here are some ways for you to get involved in the community:
* Get involved with the Spring community on the Spring Community Forums. Please help out on the [forum](https://forum.spring.io/) by responding to questions and joining the debate.
* Create [JIRA](https://jira.springsource.org/browse/AMQP) tickets for bugs and new features and comment and vote on the ones that you are interested in.
* Github is for social coding: if you want to write code, we encourage contributions through pull requests from [forks of this repository](https://help.github.com/forking/). If you want to contribute code this way, please reference a JIRA ticket as well covering the specific issue you are addressing.
* Watch for upcoming articles on Spring by [subscribing](https://www.springsource.org/node/feed) to springframework.org
Refer to the spring-amqp [Contributor's Guidelines](https://github.com/spring-projects/spring-amqp/blob/master/CONTRIBUTING.adoc) for complete information about the necessary steps.
## Code Conventions and Housekeeping
None of these is essential for a pull request, but they will all help. They can also be added after the original pull request but before a merge.
* Use the Spring Framework code format conventions (import `eclipse-code-formatter.xml` from the root of the project if you are using Eclipse).
* Make sure all new .java files to have a simple Javadoc class comment with at least an @author tag identifying you, and preferably at least a paragraph on what the class is for.
* Add the ASF license header comment to all new .java files (copy from existing files in the project)
* Add yourself as an @author to the .java files that you modify substantially (more than cosmetic changes).
* Add some Javadocs and, if you change the namespace, some XSD doc elements (Spring AMQP is not stellar in this area yet, but it will have to come up to scratch one day, so you will be helping a lot).
* A few unit tests would help a lot as well - someone has to do it.
* If no-one else is using your branch, please rebase it against the current master (or other target branch in the main project).
| 1 |
vinsguru/vinsguru-blog-code-samples | null | 2019-09-01T01:29:19Z | null | vinsguru-blog-code-samples
| 1 |
JetBrains/intellij-sdk-code-samples | Mirror of the IntelliJ SDK Docs Code Samples | 2020-04-02T15:20:51Z | null | # IntelliJ Platform SDK Code Samples
[![official JetBrains project](https://jb.gg/badges/official-flat-square.svg)][jb:github]
[![JetBrains IntelliJ Platform SDK Docs](https://jb.gg/badges/docs.svg?style=flat-square)][jb:docs]
[![X Follow](https://img.shields.io/badge/follow-%40JBPlatform-1DA1F2?logo=x)][jb:x]
[![Build](https://img.shields.io/github/actions/workflow/status/JetBrains/intellij-sdk-docs/code-samples.yml?branch=main&style=flat-square)][gh:workflow-code-samples]
[![Slack](https://img.shields.io/badge/Slack-%23intellij--platform-blue?style=flat-square&logo=Slack)][jb:slack]
Learn how to build plugins using IntelliJ Platform SDK for the [JetBrains products][jb:products] by experimenting with our code samples.
These samples show you how features work and help you jumpstart your plugins.
> [!TIP]
> To start a new plugin project, consider using [IntelliJ Platform Plugin Template][gh:template] which offers a pure boilerplate template to make it easier to create a new plugin project.
>
> The code samples can also be found in the [IntelliJ SDK Code Samples](https://github.com/JetBrains/intellij-sdk-code-samples) mirror repository.
To learn more, browse [available Extension Points][docs:eps], explore Extension Point usages in open-source plugins using [IntelliJ Platform Explorer](https://jb.gg/ipe) and learn how to [Explore the IntelliJ Platform API][docs:explore-api].
## Target Platform
All Code Samples target the latest GA platform release.
Previous releases are made available via [tags](https://github.com/JetBrains/intellij-sdk-code-samples/tags).
## Structure
Code Samples depend on the [IntelliJ Platform SDK][docs] and [Gradle][docs:gradle] as a build system.
The main plugin definition file is stored in the `plugin.xml` file, which is created according to the [Plugin Configuration File documentation][docs:plugin.xml].
It describes definitions of the actions, extensions, or listeners provided by the plugin.
## Code Samples
Please see [Code Samples][docs:code-samples] topic on how to import and run code samples.
In the following table, you may find all available samples provided in the separated directories as stand-alone projects available for running with the Gradle [`runIde`](tools_gradle_intellij_plugin.md#tasks-runide) task.
| Code Sample | Description |
|-----------------------------------------------------------------------------|-------------------------------------------------------------------------------------------------------------------------------------------------------------------|
| [Action Basics](./action_basics) | Action and Action Group patterns implementation, adds entries to the Tools menu. |
| [Comparing References Inspection](./comparing_string_references_inspection) | Local Inspection Tool, adds entries to **Settings | Editor | Inspections | Java | Probable Bugs**. |
| [Conditional Operator Intention](./conditional_operator_intention) | Intention action, suggests converting a ternary operator into an `if` block and adds entry to **Settings | Editor | Intentions | SDK Intentions**. |
| [Editor Basics](./editor_basics) | Basic Editor APIs example with editor popup menu with extra actions. |
| [Framework Basics](./framework_basics) | Basic *SDK Demo Framework* support added to the **File | New | Project | Java** wizard. |
| [Kotlin Demo](./kotlin_demo) | Kotlin example extending the *Main Menu* with a **Greeting** menu group. |
| [Live Templates](./live_templates) | Live templates for Markdown language, adds an entry to the **Settings | Editor | Live Templates** dialog. |
| [Max Opened Projects](./max_opened_projects) | Application services and listeners, shows warning dialog when more than 3 open projects are opened. |
| [Module](./module) | *SDK Demo Module* module type added to the **File | New | Project...** wizard. |
| [Product Specific - PyCharm Sample](./product_specific/pycharm_basics) | Plugin project configuration for the PyCharm IDE. |
| [Project Model](./project_model) | Interacts with the project model, adds menu items to **Tools** and **Editor Context** menus. |
| [Project View Pane](./project_view_pane) | Project View Pane listing only image files. |
| [Project Wizard](./project_wizard) | Project Wizard example with demo steps. |
| [PSI Demo](./psi_demo) | PSI Navigation features presentation. |
| [Run Configuration](./run_configuration) | Run configuration implementation with factory, options and UI. |
| [Settings](./settings) | Custom settings panel, adds a settings panel to the **Settings** panel under **Tools**. |
| [Simple Language Plugin](./simple_language_plugin) | Custom language support, defines a new *Simple language* with syntax highlighting, annotations, code completion, and other features. |
| [Theme Basics](./theme_basics) | Sample *theme* plugin with basic interface modifications. |
| [Tool Window](./tool_window) | Custom Tool Window example plugin. |
| [Tree Structure Provider](./tree_structure_provider) | Tree Structure Provider showing only plain text files. |
[gh:workflow-code-samples]: https://github.com/JetBrains/intellij-sdk-docs/actions/workflows/code-samples.yml
[gh:template]: https://github.com/JetBrains/intellij-platform-plugin-template
[jb:github]: https://github.com/JetBrains/.github/blob/main/profile/README.md
[jb:docs]: https://plugins.jetbrains.com/docs/intellij/
[jb:products]: https://www.jetbrains.com/products.html
[jb:slack]: https://plugins.jetbrains.com/slack
[jb:x]: https://x.com/JBPlatform
[docs]: https://plugins.jetbrains.com/docs/intellij/
[docs:code-samples]: https://plugins.jetbrains.com/docs/intellij/code-samples.html
[docs:eps]: https://plugins.jetbrains.com/docs/intellij/extension-point-list.html
[docs:gradle]: https://plugins.jetbrains.com/docs/intellij/developing-plugins.html
[docs:plugin.xml]: https://plugins.jetbrains.com/docs/intellij/plugin-configuration-file.html
[docs:explore-api]: https://plugins.jetbrains.com/docs/intellij/explore-api.html
| 1 |
IBMStreams/samples | This repository contains open-source sample applications for IBM Streams. | 2013-11-25T23:31:25Z | null | ## README -- IBMStreams samples
This repository contains sample applications for IBM Streams.
### [Search the samples using the samples catalog](http://ibmstreams.github.io/samples)
You can also [Contribute a sample](https://github.com/IBMStreams/samples/wiki/Adding-a-sample-to-the-catalog-and-repo)
To learn more about Streams:
* [IBM Streams on Github](http://ibmstreams.github.io)
* [Streams Community](https://ibm.biz/streams-community)
## About this repository
Each branch in the repo is related and serves a different purpose.
- `main` branch: has the actual code samples organized by feature or task, e.g. Read data, Analyze data, etc.
- `gh-pages` branch has the code for the catalog, ibmstreams.github.io/samples/
- AngularJS code
- `fileserver` branch: This has the code for the file server. The file server is used by the catalog to provide a zip archive of each individual sample.
### Adding a new sample to the catalog
You need to install jekyll.
Background info:
- Each individual sample has a `catalog.json` that describes the sample and is used by the gh-pages branch to display the catalog.
- `extSamples.json` contains information about additional samples that are listed on the website but hosted in other repositories
To add a sample to the catalog:
- If the sample is going to be in this repo,
- add the sample folder to the tree in the appropriate folder, e.g. if it is a Database sample, add it to ReadAndStore data.
- Add a `catalog.json` file to the top level folder of the new sample, use any of the existing `catalog.json` as an example
- If it is going to be hosted in another repo,
- edit the `extSamples.json` file to add the information about the sample.
- Update the categories array in the JSON file is based on the categories listed in categoryKey.txt
- Commit your changes to the main branch.
- Run the updateCatalogDB.sh script. This script will
- run the `generate-catalog.py` script combines the `extSamples.json` file with the entry from each catalog.json in the repo to create a master JSON file listing every entry in the catalog.
- Switch to the `gh-pages` branch and start a local copy of the server at 127.0.0.1:4000/
- 127.0.0.1:4000/ to see the catalog and verify the new sample is listed. Commit and push the changes to the gh-pages branch.
*Note*: Run the data/main.json file through a JSON minimizer before commiting it to remove whitespace.
| 1 |
THEONE10211024/RxJavaSamples | 收集了RxJava常见的使用场景,例子简洁、经典、易懂... | 2015-12-23T09:16:54Z | null | # RxJavaSamples
收集了RxJava常见的使用场景,例子简洁、经典、易懂...samples中的例子我已经在我的博客里介绍了,想进一步了解的同学可以看[这里](http://blog.csdn.net/theone10211024/article/details/50435325)
## (非)著名的库
* [RxJava](https://github.com/ReactiveX/RxJava) 没什么好说的,众多Rx系列的发源地。
* [RxAndroid](https://github.com/ReactiveX/RxAndroid) JakeWharton大神主导,将RxJava带入了Android,例子不多但在活跃地开发中。你可以从[这里](http://blog.csdn.net/lzyzsd/article/details/45033611)略知一二
* [RxBinding](https://github.com/JakeWharton/RxBinding) JakeWharton 大神项目,以RxJava形式实现Android里的OnClickListener 、TextWatcher、ScrollChange等事件绑定,内容相当丰富,关键还支持kotlin语法!
* [RxKotlin](https://github.com/ReactiveX/RxKotlin) Kotlin在取代Java的路上又多了一门神器!
* [RxRelay](https://github.com/JakeWharton/RxRelay) JakeWharton 大神又一力作!
## 项目&&例子
* [RxJava-Android-Samples]( https://github.com/kaushikgopal/RxJava-Android-Samples) 涵盖了* RxJava的一些应用场景。经典、易懂但不是很全,本项目中大部分例子来源于此,表示感谢!
* [Awesome-RxJava]( https://github.com/lzyzsd/Awesome-RxJava) 收集了很多经典博客、教程、译文和App。想要入门?弄明白这里面的文章足矣!
* [RxDocs](https://github.com/mcxiaoke/RxDocs) Rx和RxJava文档中文翻译项目,非常多的学习资料!!
* [RengwuxianRxjava]( https://github.com/androidmalin/RengwuxianRxjava) 扔物线那篇[经典文章](http://gank.io/post/560e15be2dca930e00da1083)中的例子
* [RxBlur]( https://github.com/SmartDengg/RxBlur) 用RxJava处理和操作高斯模糊效果的简单用例。
* [Meizhi](https://github.com/drakeet/Meizhi) 基于RxJava & Retrofit开发的项目
* [RexWeather]( https://github.com/vyshane/rex-weather) 天气预报小应用,基于RxJava & Retrofit开发的项目
* [Android-ReactiveLocation](https://github.com/mcharmas/Android-ReactiveLocation)
* [reark](https://github.com/reark/reark)
* [RxPermissions](https://github.com/tbruyelle/RxPermissions)
* [rxfilewatcher](https://github.com/helmbold/rxfilewatcher)
* [RxLifecycle](https://github.com/trello/RxLifecycle)用来严格控制由于发布了一个订阅后,由于没有及时取消,导致Activity/Fragment无法销毁导致的内存泄露。
* [rxloader](https://github.com/evant/rxloader)
* [ReactiveNetwork](https://github.com/pwittchen/ReactiveNetwork) 使用RxJava来监听网络连接状态和wifi信号强度变化
* [frodo](https://github.com/android10/frodo)
* [rxjava-multiple-sources-sample](https://github.com/dlew/rxjava-multiple-sources-sample) 如何使用RxJava做多级缓存的案例。
* [rx-preferences](https://github.com/f2prateek/rx-preferences) 用RxJava实现Android中的SharedPreferences
* [RxCache](https://github.com/VictorAlbertos/RxCache) 为Android和java开发量身打造的缓存库
## 技术博客
* [给Android开发者的RxJava详解]( http://gank.io/post/560e15be2dca930e00da1083)扔物线力作,RxJava讲的通俗易懂。
* [可能是东半球最全的RxJava使用场景小结]( http://blog.csdn.net/theone10211024/article/details/50435325) 主要针对Android中使用场景的总结。大多数是常见且经典的例子,看看RxJava是如何解决Android开发中的痛点的!
* [深入浅出RxJava]( http://blog.csdn.net/lzyzsd/article/details/41833541) 深入浅出RxJava系列,一共四篇,这是第一篇。翻译得还不错!
* [RxJava大搜集]( http://www.jcodecraeer.com/a/anzhuokaifa/androidkaifa/2015/0430/2815.html)这里有你想要的
* [RxBus]( http://nerds.weddingpartyapp.com/tech/2014/12/24/implementing-an-event-bus-with-rxjava-rxbus/) 无所不能的RxJava也能做EventBus?看看别人是怎么实现的吧!
* [当复仇者联盟遇上Dagger2、RxJava和Retrofit的巧妙结合](http://blog.csdn.net/handsome_926/article/details/49176227) RxJava+Dagger2+Retrofit!教你什么才是一个干净的框架!
* [Advanced RxJava](http://akarnokd.blogspot.com/) 系列博客,[该系列博客的中文翻译](http://blog.piasy.com/AdvancedRxJava/)。
## 网站
* [ReactiveX](http://reactivex.io) ReactiveX官方网站,不知道它的就如同学Android不知道Android Developer
* [RxMarbles]( http://rxmarbles.com) 直观有趣的宝石图!让你对这种编程思想理解得更加透彻!!
##书籍
* [RxJava Essentials(英文版)](http://download.csdn.net/detail/theone10211024/9394367) 讲得比较详细,适合RxJava入门学习。
* [RxJava Essentials(中文版)](http://download.csdn.net/detail/theone10211024/9394379) RxJava Essentials的中文翻译。
##### 最后,我想说的是RxJava目前在国内的使用频率还比较低,希望大家能成为推动RxJava在国普及的一员!如果你有更多好的文章、网站或工程,请发扬程序员最独特的魅力—开源精神,以便让更多的同行看见、学到和参与进来!
| 0 |
graphql-java-kickstart/samples | Samples for using the graphql java kickstart projects | 2018-11-07T16:10:45Z | null | # GraphQL Java Kickstart Samples
[![Discuss on GitHub](https://img.shields.io/badge/GitHub-discuss-orange)](https://github.com/graphql-java-kickstart/samples/discussions)
## We are looking for contributors!
Are you interested in improving our documentation, working on the codebase, reviewing PRs?
[Reach out to us on Discussions](https://github.com/graphql-java-kickstart/samples/discussions)
and join the team!
Samples for using the GraphQL Java Kickstart projects
| 1 |
liferay/liferay-blade-samples | null | 2016-04-07T20:43:30Z | null | null | 1 |
Mike-bel/MDStudySamples | Material Design Widgets Study Samples | 2016-08-04T07:23:43Z | null | # MDStudySamples
Android Material Design 材料设计风格的系统性学习案例
设计规范:
- [Google官网](https://material.google.com/)
- [极客中文翻译](http://wiki.jikexueyuan.com/project/material-design/)
## TabLayout
博客地址:[Android TabLayout 分分钟打造一个滑动标签页](http://www.jianshu.com/p/39a66373498c)
## Snackbar
博客地址:[Android 一文告诉你到底是用Dialog,Snackbar,还是Toast](http://www.jianshu.com/p/9eb3b17b0e77)
## FloatingActionButton
博客地址:[Android FloatingActionButton 重要的操作不要太多,一个就好](http://www.jianshu.com/p/5328b2eee827)
## AppBarLayout & CoordinatorLayout
- [Android 初识AppBarLayout 和 CoordinatorLayout](http://www.jianshu.com/p/ab04627cce58)
- [Android 详细分析AppBarLayout的五种ScrollFlags](http://www.jianshu.com/p/7caa5f4f49bd)
- [Android CoordinatorLayout实战案例学习《一》](http://www.jianshu.com/p/4b0f3c80ebc9)
- [Android CoordinatorLayout 实战案例学习《二》](http://www.jianshu.com/p/360fd368936d)
- [Android 一步一步分析CoordinatorLayout.Behavior](http://www.jianshu.com/p/8396b74de317)
## TODO
MD风格登录页:
- [fanrunqi/MaterialLogin](https://github.com/fanrunqi/MaterialLogin)
- [shem8/MaterialLogin](https://github.com/shem8/MaterialLogin)
BottomNavigation:
- [Ashok-Varma/BottomNavigation](https://github.com/Ashok-Varma/BottomNavigation)
- [aurelhubert/ahbottomnavigation](https://github.com/aurelhubert/ahbottomnavigation)
### 关注我的微信公众号:安卓笔记侠
----
![](http://ocq7gtgqu.bkt.clouddn.com/NiaoTechNiaoTech_QRcode.jpg)
| 1 |
lenve/spring-security-samples | null | 2020-03-23T01:13:22Z | null | ### 跟着松哥学 Spring Security
扫码加微信(微信ID:**a_java_boy2**),备注 SpringSecurity,进群讨论。
![微信ID:a_java_boy2](https://user-images.githubusercontent.com/6023444/75459026-ba70d500-59b9-11ea-8cbd-3d5889f356c4.png)
扫码关注微信公众号【江南一点雨】,回复 **ss** 获取 Spring Security 系列完整文章:
![](https://open.weixin.qq.com/qr/code?username=a_javaboy)
#### 本仓库部分 Demo 有配套视频
视频地址:[https://www.bilibili.com/video/BV1xA411h7o3/](https://www.bilibili.com/video/BV1xA411h7o3/)
欢迎大家在 B 站关注我,以便及时收到最新视频。
#### 本仓库所有 Demo 都有配套文章
|Demo|文章|
|:---|:---|
|form-login|[松哥手把手带你入门 Spring Security,别再问密码怎么解密了](https://mp.weixin.qq.com/s/Q0GkUb1Nt6ynV22LFHuQrQ)|
|form-login-2|[手把手教你定制 Spring Security 中的表单登录](https://mp.weixin.qq.com/s/kHJRKwH-WUx-JEeaQMa7jw)|
|form-login-3|[Spring Security 做前后端分离,咱就别做页面跳转了!统统 JSON 交互](https://mp.weixin.qq.com/s/Xzt9ymff0DCbAQbklHOxpQ)|
|form-login-4|[Spring Security 中的授权操作原来这么简单](https://mp.weixin.qq.com/s/BKAYXMaBBs0VrKZtzorn-w)|
|form-login-5|[Spring Security 如何将用户数据存入数据库?](https://mp.weixin.qq.com/s/EurEXmU0M9AKuUs4Jh_V5g)|
|withjpa|[Spring Security+Spring Data Jpa 强强联手,安全管理只有更简单!](https://mp.weixin.qq.com/s/VWJvINbi1DB3fF-Mcx7mGg)|
|rememberme|[Spring Boot + Spring Security 实现自动登录功能](https://mp.weixin.qq.com/s/aSsGNBSWMTsAEXjn9wQnYQ)|
|rememberme-persis|[Spring Boot 自动登录,安全风险要怎么控制?](https://mp.weixin.qq.com/s/T6_PBRzIADE71af3yoKB6g)|
|verifycode|[SpringSecurity 自定义认证逻辑的两种方式(高级玩法)](https://mp.weixin.qq.com/s/LeiwIJVevaU5C1Fn5nNEeg)|
|verifycode-2|[Spring Security 中如何快速查看登录用户 IP 地址等信息?](https://mp.weixin.qq.com/s/pSX9XnPNQPyLWGc6oWR3hA)|
|session-1|[Spring Security 自动踢掉前一个登录用户,一个配置搞定!](https://mp.weixin.qq.com/s/9f2e4Ua2_fxEd-S9Y7DDtA)|
|session-2|[Spring Boot + Vue 前后端分离项目,如何踢掉已登录用户?](https://mp.weixin.qq.com/s/nfqFDaLDH8UJVx7mqqgHmQ)|
|stricthttpfirewall|[Spring Security 自带防火墙!你都不知道自己的系统有多安全!](https://mp.weixin.qq.com/s/Fuu9rKoOvSyuvCKSyh6dUQ)|
|session-3|[什么是会话固定攻击?Spring Boot 中要如何防御会话固定攻击?](https://mp.weixin.qq.com/s/9SaNvVfiivWUIAe6OZgpZQ)|
|session-4|[集群化部署,Spring Security 要如何处理 session 共享?](https://mp.weixin.qq.com/s/EAacxjaNg8BJRkTkGFLLpQ)|
|csrf-1|[松哥手把手教你在 SpringBoot 中防御 CSRF 攻击!so easy!](https://mp.weixin.qq.com/s/TDm8ljxbHpMqteucfmeccA)|
|csrf-2|[松哥手把手教你在 SpringBoot 中防御 CSRF 攻击!so easy!](https://mp.weixin.qq.com/s/TDm8ljxbHpMqteucfmeccA)|
|csrf-3|[松哥手把手教你在 SpringBoot 中防御 CSRF 攻击!so easy!](https://mp.weixin.qq.com/s/TDm8ljxbHpMqteucfmeccA)|
|-|[要学就学透彻!Spring Security 中 CSRF 防御源码解析](https://mp.weixin.qq.com/s/evyI9wo30JI78_ZYGaKFRg)|
|securitydemo|[Spring Boot 中密码加密的两种姿势!](https://mp.weixin.qq.com/s/jBoU5j4YChDVwyX22SbtgA)|
|-|[Spring Security 要怎么学?为什么一定要成体系的学习?](https://mp.weixin.qq.com/s/6YgV5z3Bbd7wKP5TwI1TQg)|
|-|[Spring Security 两种资源放行策略,千万别用错了!](https://mp.weixin.qq.com/s/He_K-a-1JpQHZBPEUo2uZw)|
|client1、client2|[松哥手把手教你入门 Spring Boot + CAS 单点登录](https://mp.weixin.qq.com/s/BzdCr_rgLttRlq_SWQuG0Q)|
|client1、client2|[Spring Boot 实现单点登录的第三种方案!](https://mp.weixin.qq.com/s/YQMHms9BiVaTgYct4wk2cw)|
|client1、client2|[Spring Boot+CAS 单点登录,如何对接数据库?](https://mp.weixin.qq.com/s/dWwscpe9okkJjkGQMWVYvA)|
|-|[Spring Boot+CAS 默认登录页面太丑了,怎么办?](https://mp.weixin.qq.com/s/uWib5RtH1aEC7p5VK4S1Ig)|
|swagger-jwt|[用 Swagger 测试接口,怎么在请求头中携带 Token?](https://mp.weixin.qq.com/s/LvMOKeX09liTvujZi6XO3Q)|
|cors-1、cors-2|[Spring Boot 中三种跨域场景总结](https://mp.weixin.qq.com/s/FaSfN31z4BlxPI2QOa8t1Q)|
|httpbasic|[Spring Boot 中如何实现 HTTP 认证?](https://mp.weixin.qq.com/s/7T5XA1zxQkhMvffMxHKVvQ)|
|authorize|[Spring Security 中的四种权限控制方式](https://mp.weixin.qq.com/s/7cm99q5ZM4qUkekx0Xa0YQ)|
|authorize-2|[Spring Security 多种加密方案共存,老破旧系统整合利器!](https://mp.weixin.qq.com/s/_iau1jsnc50vs794_ib0IA)|
|-|[神奇!自己 new 出来的对象一样也可以被 Spring 容器管理!](https://mp.weixin.qq.com/s/edtYkmgx_SnYoqsy-yFmsQ)|
|-|[Spring Security 配置中的 and 到底该怎么理解?](https://mp.weixin.qq.com/s/42-rjiZShvZXYM_ULQt0YQ)|
|exception|[一文搞定 Spring Security 异常处理机制!](https://mp.weixin.qq.com/s/f1teXTEuDR7S0j_Ml2qL8g)|
|-|[写了这么多年代码,这样的登录方式还是头一回见!](https://mp.weixin.qq.com/s/dm2SmUzb7vQZA3C0NFp86A)|
|authenticationmanager|[Spring Security 竟然可以同时存在多个过滤器链?](https://mp.weixin.qq.com/s/S_maV7OvvfmYUO53AgCu0g)|
|multiusers|[Spring Security 可以同时对接多个用户表?](https://mp.weixin.qq.com/s/sF4vPZQv7rtBYhBhmONJ5w)|
|-|[在 Spring Security 中,我就想从子线程获取用户登录信息,怎么办?](https://mp.weixin.qq.com/s/4dcQ6lohB3sEcnkAXxdZwg)|
|-|[深入理解 FilterChainProxy【源码篇】](https://mp.weixin.qq.com/s/EZsChg5YG0TBadU4q_CAnA)|
|-|[深入理解 SecurityConfigurer 【源码篇】](https://mp.weixin.qq.com/s/PWIM9jgEB-F-m4Ove470wg)|
|-|[深入理解 HttpSecurity【源码篇】](https://mp.weixin.qq.com/s/Kk5c5pK5_LFcCpcnIr2VrA)|
|-|[深入理解 AuthenticationManagerBuilder 【源码篇】](https://mp.weixin.qq.com/s/kB4m0YJas9LHuNT8JH5ZmQ)|
|authenticationmanager|[花式玩 Spring Security ,这样的用户定义方式你可能没见过!](https://mp.weixin.qq.com/s/LBgZu-mBifPG_-azCG7Lcg)|
|-|[深入理解 WebSecurityConfigurerAdapter【源码篇】](https://mp.weixin.qq.com/s/vP-QGm9GNxMInIeGSZvWwQ)|
|-|[盘点 Spring Security 框架中的八大经典设计模式](https://mp.weixin.qq.com/s/d2o9QpK1EfBMRR8zfHhv2g)|
|-|[Spring Security 初始化流程梳理](https://mp.weixin.qq.com/s/D0weIKPto4lcuwl9DQpmvQ)|
|-|[为什么你使用的 Spring Security OAuth 过期了?松哥来和大家捋一捋!](https://mp.weixin.qq.com/s/0WOefpO6-aYSIRNiNnijyg)|
|-|[一个诡异的登录问题](https://mp.weixin.qq.com/s/-kDQbP1htEfn_8n7ZfKqmA)|
|-|[什么是计时攻击?Spring Boot 中该如何防御?](https://mp.weixin.qq.com/s/9yK32E44UnIep-5iX0s2Ow)|
|voter|[Spring Security 中如何让上级拥有下级的所有权限?](https://mp.weixin.qq.com/s/1ZWyD41R827FhghiCHY-Sw)|
|voter|[Spring Security 权限管理的投票器与表决机制](https://mp.weixin.qq.com/s/sU97RQjQq2-XXQt49LkSeQ)|
|-|[Spring Security 中的 hasRole 和 hasAuthority 有区别吗?](https://mp.weixin.qq.com/s/GTNOa2k9_n_H0w24upClRw)|
|-|[Spring Security 中如何细化权限粒度?](https://mp.weixin.qq.com/s/Q9lfrJ3iioUpYEO9elCtsw)|
|acls|[一个案例演示 Spring Security 中粒度超细的权限控制!](https://mp.weixin.qq.com/s/98CIxDVrhAiE14EXvgf7Vw)|
|-|[Spring Security 中最流行的权限管理模型!](https://mp.weixin.qq.com/s/B03cDEE1i3gT0yDhIxGATw)|
|based_on_url|[我又发现 Spring Security 中一个小秘密!](https://mp.weixin.qq.com/s/FzNpjyjbi6bQEEkUDRsnXA)|
|-|[聊一个 GitHub 上开源的 RBAC 权限管理系统,很6!](https://mp.weixin.qq.com/s/K5YDMBREzObp2yrmLtGdjw)|
|-|[RBAC 案例解读【2】](https://mp.weixin.qq.com/s/obLTxCddhJ0kqTqoVN-Axg)|
| 1 |
g00glen00b/spring-samples | A series of examples used to demonstrate certain features of Spring. | 2015-11-15T18:48:53Z | null | # Example applications using Spring boot
This is a collection of small applications demonstrating certain features of Spring boot. Most of these are covered as well in [my blog posts](https://dimitri.codes/tag/spring-boot/).
## Contents
| Blog post | GitHub |
| ------------------------------------------------------------ | ------------------------------------------------------------ |
| [Writing your first Spring webapp with Spring Boot](https://dimitri.codes/spring-webapp/) | [spring-boot-webapp](https://github.com/g00glen00b/spring-samples/tree/master/spring-boot-webapp) |
| [JPA made easy with Spring data's repositories](https://dimitri.codes/spring-data-jpa/) | [spring-boot-jpa-webapp](https://github.com/g00glen00b/spring-samples/tree/master/spring-boot-jpa-webapp) |
| [Handling errors with Spring MVC](https://dimitri.codes/handling-errors-with-spring-mvc/) | [spring-boot-jpa-error-webapp](https://github.com/g00glen00b/spring-samples/tree/master/spring-boot-jpa-error-webapp) |
| [Using Docker containers for your Spring boot applications](https://dimitri.codes/docker-spring-boot/) | [spring-boot-jpa-docker-webapp](https://github.com/g00glen00b/spring-samples/tree/master/spring-boot-jpa-docker-webapp) |
| [Take your Spring apps to the cloud with Bluemix and Docker](https://dimitri.codes/docker-containers-on-bluemix/) | [sping-boot-jpa-docker-bluemix-webapp](https://github.com/g00glen00b/spring-samples/tree/master/spring-boot-jpa-docker-bluemix-webapp) |
| [Internationalization (i18n) with Spring](https://dimitri.codes/spring-internationalization-i18n/) | [spring-boot-i18n-webapp](https://github.com/g00glen00b/spring-samples/tree/master/spring-boot-i18n-webapp) |
| [Handling forms with Spring Web and JSR-303](https://dimitri.codes/spring-form-validation/) | [spring-boot-form](https://github.com/g00glen00b/spring-samples/tree/master/spring-boot-form) |
| [Producing REST API's with Spring](https://dimitri.codes/producing-rest-apis-with-spring/) | [spring-boot-rest](https://github.com/g00glen00b/spring-samples/tree/master/spring-boot-rest) |
| [Consuming REST API's with Spring](https://dimitri.codes/consuming-rest-apis-with-spring/) | [spring-boot-rest](https://github.com/g00glen00b/spring-samples/tree/master/spring-boot-rest) |
| [Documenting your REST API with Swagger and Springfox](https://dimitri.codes/documenting-rest-api-swagger-springfox/) | [spring-boot-swagger](https://github.com/g00glen00b/spring-samples/tree/master/spring-boot-swagger) |
| [Exploring contract first options with Swagger](https://dimitri.codes/exploring-contract-first-options-swagger/) | [spring-boot-swagger](https://github.com/g00glen00b/spring-samples/tree/master/spring-boot-swagger) |
| [Using Ehcache 3 with Spring boot](https://dimitri.codes/spring-boot-cache-ehcache/) | [spring-boot-ehcache](https://github.com/g00glen00b/spring-samples/tree/master/spring-boot-ehcache) |
| [Using the Netflix stack with Spring boot: Eureka](https://dimitri.codes/using-the-netflix-stack-with-spring-boot-eureka/) | [spring-boot-eureka](https://github.com/g00glen00b/spring-samples/tree/master/spring-boot-eureka) |
| [Using the Netflix stack with Spring boot: Ribbon](https://dimitri.codes/using-netflix-stack-spring-boot-ribbon/) | [spring-boot-eureka](https://github.com/g00glen00b/spring-samples/tree/master/spring-boot-eureka) |
| [Using the Netflix stack with Spring boot: Hystrix](https://dimitri.codes/spring-boot-netflix-hystrix/) | [spring-boot-hystrix](https://github.com/g00glen00b/spring-samples/tree/master/spring-boot-hystrix) |
| [Mapping with Dozer](https://dimitri.codes/mapping-with-dozer/) | [spring-boot-jpa-dozer-webapp](https://github.com/g00glen00b/spring-samples/tree/master/spring-boot-jpa-dozer-webapp) |
| [Mapping beans with MapStruct](https://dimitri.codes/mapstruct/) | [spring-boot-jpa-mapstruct-webapp](https://github.com/g00glen00b/spring-samples/tree/master/spring-boot-jpa-mapstruct-webapp) |
| [Getting started with Spring boot 2.0](https://dimitri.codes/getting-started-spring-boot-2/) | [spring-boot-2-web-crawler](https://github.com/g00glen00b/spring-samples/tree/master/spring-boot-2-web-crawler) |
| [Validating the input of your REST API with Spring](https://dimitri.codes/validating-the-input-of-your-rest-api-with-spring) | [spring-boot-validation](https://github.com/g00glen00b/spring-samples/tree/master/spring-boot-validation) |
| [Working with Spring boot and GraphQL](https://dimitri.codes/graphql-spring-boot) | [spring-boot-graphql](https://github.com/g00glen00b/spring-samples/tree/master/spring-boot-graphql) |
| [Indexing documents with Spring batch](https://github.com/g00glen00b/spring-samples/tree/master/spring-boot-solr-batch) | [spring-boot-solr-batch](https://github.com/g00glen00b/spring-samples/tree/master/spring-boot-solr-batch) |
| [Generating documentation for your REST API with Spring REST Docs](https://dimitri.codes/spring-rest-docs) | [spring-boot-restdocs](https://github.com/g00glen00b/spring-samples/tree/master/spring-boot-restdocs) |
| [Generating documentation for your REST API with Spring and Swagger](https://dimitri.codes/generating-static-documentation-swagger) | [spring-boot-swagger-static-docs](https://github.com/g00glen00b/spring-samples/tree/master/spring-boot-swagger-static-docs) |
| [Reactive relational databases with R2DBC and Spring](https://dimitri.codes/reactive-relational-databases-r2dbc-spring) | [spring-boot-r2dbc](https://github.com/g00glen00b/spring-samples/tree/master/spring-boot-r2dbc) |
| [Reactive streams over the network with RSocket](https://dimitri.codes/reactive-streams-rsocket) | [spring-boot-rsocket](https://github.com/g00glen00b/spring-samples/tree/master/spring-boot-rsocket) |
| [Battle of the Spring REST clients: RestTemplate, WebClient or RestClient?](https://dimitri.codes/resttemplate-or-webclient) | [spring-boot-restclient](https://github.com/g00glen00b/spring-samples/tree/master/spring-boot-restclient)
| [Getting started with htmx and Spring Boot](https://dimitri.codes/spring-boot-htmx-intro) | [spring-boot-htmx](https://github.com/g00glen00b/spring-samples/tree/master/spring-boot-htmx)
| 1 |
kunal-kushwaha/DSA-Bootcamp-Java | This repository consists of the code samples, assignments, and notes for the Java data structures & algorithms + interview preparation bootcamp of WeMakeDevs. | 2021-07-30T12:23:25Z | null | # DSA + Interview preparation bootcamp
- [Join Replit](http://join.replit.com/kunal-kushwaha)
- Subscribe to the [YouTube channel](https://www.youtube.com/KunalKushwaha?sub_confirmation=1)
- [Lectures](https://www.youtube.com/playlist?list=PL9gnSGHSqcnr_DxHsP7AW9ftq0AtAyYqJ)
- [Course website](https://wemakedevs.org/courses/dsa)
- [Assignments](https://github.com/kunal-kushwaha/DSA-Bootcamp-Java/tree/main/assignments) (solutions can be found on LeetCode)
- [Connect with me](http://kunalkushwaha.com)
| 0 |
javaee-samples/javaee8-samples | Java EE 8 Samples | 2014-10-06T16:22:37Z | null | # Java EE 8 Samples #
This workspace consists of Java EE 8 Samples and unit tests. They are categorized in different directories, one for each Technology/JSR.
Some samples/tests have documentation, otherwise read the code.
## How to run? ##
Samples are tested on Payara, GlassFish and Tomcat using Arquillian. Arquillian uses container profiles to start up and deploy tests to individual containers.
Only one container profile can be active at a given time, otherwise there will be dependency conflicts.
These are the available container profiles:
* Payara and GlassFish
* ``payara-ci-managed``
This profile will install a Payara server and start up the server per sample.
Useful for CI servers. The Payara version that's used can be set via the ``payara.version`` property.
This is the default profile and does not have to be specified explicitly.
* ``payara-micro-managed``
This profile will install Payara Micro and start up the jar per sample.
Useful for CI servers. The Payara Micro version that's used can be set via the ``payara.micro.version`` property.
* ``payara-remote``
This profile requires you to start up a Payara server outside of the build. Each sample will then
reuse this instance to run the tests.
Useful for development to avoid the server start up cost per sample.
This profile supports for some tests to set the location where Payara is installed via the ``glassfishRemote_gfHome``
system property. E.g.
``-DglassfishRemote_gfHome=/opt/payara173``
This is used for sending asadmin commands to create container resources, such as users in an identity store.
* ``glassfish-embedded``
This profile uses the GlassFish embedded server and runs in the same JVM as the TestClass.
Useful for development, but has the downside of server startup per sample.
* ``glassfish-remote``
This profile requires you to start up a GlassFish server outside of the build. Each sample will then
reuse this instance to run the tests.
Useful for development to avoid the server start up cost per sample.
This profile supports for some tests to set the location where GlassFish is installed via the ``glassfishRemote_gfHome``
system property. E.g.
``-DglassfishRemote_gfHome=/opt/glassfish50``
This is used for sending asadmin commands to create container resources, such as users in an identity store.
* Tomcat
* ``tomcat-remote``
This profile requires you to start up a plain Tomcat 9 server outside of the build. Each sample will then
reuse this instance to run the tests.
Tomcat supports samples that make use of Servlet, JSP, Expression Language (EL), WebSocket and JASPIC.
This profile requires you to enable JMX in Tomcat. This can be done by adding the following to ``[tomcat home]/bin/catalina.sh``:
```
JAVA_OPTS="$JAVA_OPTS -Dcom.sun.management.jmxremote.port=8089 -Dcom.sun.management.jmxremote=true "
JAVA_OPTS="$JAVA_OPTS -Dcom.sun.management.jmxremote.ssl=false "
JAVA_OPTS="$JAVA_OPTS -Dcom.sun.management.jmxremote.authenticate=false"
JAVA_OPTS="$JAVA_OPTS -Djava.rmi.server.hostname=localhost "
```
This profile also requires you to set a username (``tomcat``) and password (``manager``) for the management application in
``tomcat-users.xml``. See the file ``test-utils/src/main/resources/tomcat-users.xml`` in this repository for a full example.
Be aware that this should *only* be done for a Tomcat instance that's used exclusively for testing, as the above will make
the Tomcat installation **totally insecure!**
* ``tomcat-ci-managed``
This profile will install a Tomcat server and start up the server per sample.
Useful for CI servers. The Tomcat version that's used can be set via the ``tomcat.version`` property.
The containers that download and install a server (the \*-ci-managed profiles) allow you to override the version used, e.g.:
* `-Dpayara.version=5.0.0.174`
This will change the version from the current one (e.g 5.0.0.172) to 5.0.0.173 for Payara testing purposes.
* `-Dglassfish.version=5.0`
This will change the version from the current one (e.g 5.1.1) to 5.0 for GlassFish testing purposes.
**To run them in the console do**:
1. In the terminal, ``mvn test -fae`` at the top-level directory to start the tests for the default profile.
When developing and runing them from IDE, remember to activate the profile before running the test.
To learn more about Arquillian please refer to the [Arquillian Guides](http://arquillian.org/guides/)
**To run only a subset of the tests do at the top-level directory**:
1. Install top level dependencies: ``mvn clean install -pl "test-utils" -am``
1. cd into desired module, e.g.: ``cd cdi``
1. Run tests against desired server, e.g.: ``mvn clean test -P glassfish-ci-managed``
## How to contribute ##
With your help we can improve this set of samples, learn from each other and grow the community full of passionate people who care about the technology, innovation and code quality. Every contribution matters!
There is just a bunch of things you should keep in mind before sending a pull request, so we can easily get all the new things incorporated into the master branch.
Standard tests are jUnit based. Test classes naming must comply with surefire naming standards `**/*Test.java`, `**/*Test*.java` or `**/*TestCase.java`.
For the sake of clarity and consistency, and to minimize the upfront complexity, we prefer standard jUnit tests using Java, with as additional helpers HtmlUnit, Hamcrest and of course Arquillian. Please don't use alternatives for these technologies. If any new dependency has to be introduced into this project it should provide something that's not covered by these existing dependencies.
### Some coding principles ###
* When creating new source file do not put (or copy) any license header, as we use top-level license (MIT) for each and every file in this repository.
* Please follow JBoss Community code formatting profile as defined in the [jboss/ide-config](https://github.com/jboss/ide-config#readme) repository. The details are explained there, as well as configurations for Eclipse, IntelliJ and NetBeans.
### Small Git tips ###
* Make sure your [fork](https://help.github.com/articles/fork-a-repo) is always up-to-date. Simply run ``git pull upstream master`` and you are ready to hack.
* When developing new features please create a feature branch so that we incorporate your changes smoothly. It's also convenient for you as you could work on few things in parallel ;) In order to create a feature branch and switch to it in one swoop you can use ``git checkout -b my_new_cool_feature``
That's it! Welcome in the community!
## CI Job ##
CI jobs are executed by [Travis](https://travis-ci.org/javaee-samples/javaee8-samples). Note that by the very nature of the samples provided here it's perfectly normal that not all tests pass. This normally would indicate a bug in the server on which the samples are executed. If you think it's really the test that's faulty, then please submit an issue or provide a PR with a fix.
## Run each sample in Docker
* Install Docker client from http://boot2docker.io
* Build the sample that you want to run as
``mvn clean package -DskipTests``
For example: (note the exact module doens't exist yet, wip here)
``mvn -f jaxrs/jaxrs-client/pom.xml clean package -DskipTests``
* Change the second line in ``Dockerfile`` to specify the location of the generated WAR file
* Run boot2docker and give the command
``docker build -it -p 80:8080 javaee8-sample``
* In a different shell, find out the IP address of the running container as:
``boot2docker ip``
* Access the sample as http://IP_ADDRESS:80/jaxrs-client/webresources/persons. The exact URL would differ based upon the sample.
| 1 |
gupaoedu-tom/spring5-samples | 《Spring5核心原理与30个类手写实战》随书代码示例工程 | 2019-08-20T02:43:47Z | null | # 《Spring5核心原理与30个类手写实战》
### 4个月销量破万,连续占据畅销榜
### 京东购买链接:[https://item.jd.com/12650902.html](https://item.jd.com/12650902.html?_blank)
### 当当购买链接:[http://product.dangdang.com/27905338.html](http://product.dangdang.com/27905338.html)
倾注十年Spring研究精华与见解
★本书几乎涵盖在Spring应用中可能遇到的所有问题,核心原理(IoC、DI、AOP、MVC)、高仿手写、数据访问等
★深度解析Spring 5的原理与新特性,从环境准备、顶层结构设计、数据访问等方面一步步推导出Spring设计原理
★通过本书你可以:
--看源码不再晕车,轻松找到入口。
--系统学习设计思想,提高解决问题的效率。
--培养架构思维能力,自驱学习能力。
--用30个类提炼出Spring核心的精华思想,并保证功能可用。
--从不一样的角度分析Spring经典高频面试题。
--了解Spring 5 的新特性。
--为深入了解Spring Boot做铺垫。
# 关于我
### 为什么说我来自文艺界?
我自幼爱好书法和美术,长了一双能书会画的手,而且手指又长又白,因此以前的艺名叫“玉手藝人”。中学期间,曾获市级书法竞赛一等奖,校园美术竞赛一等奖,校园征文比赛二等奖。担任过学生会宣传部长,负责校园黑板报、校园刊物的编辑、排版、设计。
2008年参加工作后,做过家具建模、平面设计等工作,亲自设计了咕泡学院的Logo。做讲师之后,给自己起了一个跟姓氏谐音的英文名字“Tom”,江湖人称“编程界写字写得最好的、书法界编程最牛的文艺汤”。
### 我的技术生涯
我的IT技术生涯应该算是从2009年开始的,在此之前做过UI设计,做过前端网页,到2009年才真正开始参与Java后台开发。在这里要感谢所有帮助过我入门编程的同事和老师。从2010年至2014年担任过项目组长、项目经理、架构师、技术总监,对很多的开源框架建立了自己的独特见解。我会习惯性地用形象思维来理解抽象世界。譬如:看到二进制0和1,我会想到《周易》中的两仪——阴和阳;看到颜色值用RGB表示,我会想到美术理论中的太阳光折射三原色;下班回家看到炒菜流程,我会想到模板方法模式;坐公交车看到学生卡、老人卡、爱心卡,我会想到策略模式;等等。大家看到的这本书,很多地方都融入了这种形象思维。
### 为什么写书?
其实一开始我没想过要写书,写书的初衷主要是满足学员的诉求。大家认为我个人的学习方法、思维模式、教学方式通俗易懂,很容易让人接受,但是通过视频形式传播受众有限,学员建议我把这些宝贵的经验以纸质书的形式奉献给大家,这样定会给社会带来更大的价值。
借此机会,特别感谢责任编辑董英及电子社的团队成员为本书审稿纠错;感谢我老婆在无数个加班的夜晚给我默默的支持;感谢咕泡学院的学员给本书内容提出宝贵的修改意见。
# 随书资源下载
1. [一步一步手绘Spring DI运行时序图.jpg](https://github.com/gupaoedu-tom/resouce/blob/master/spring5/%E4%B8%80%E6%AD%A5%E4%B8%80%E6%AD%A5%E6%89%8B%E7%BB%98Spring%20DI%E8%BF%90%E8%A1%8C%E6%97%B6%E5%BA%8F%E5%9B%BE.jpg)
2. [一步一步手绘Spring IOC运行时序图.jpg](https://github.com/gupaoedu-tom/resouce/blob/master/spring5/%E4%B8%80%E6%AD%A5%E4%B8%80%E6%AD%A5%E6%89%8B%E7%BB%98Spring%20IOC%E8%BF%90%E8%A1%8C%E6%97%B6%E5%BA%8F%E5%9B%BE.jpg)
3. [一步一步手绘Spring AOP运行时序图.jpg](https://github.com/gupaoedu-tom/resouce/blob/master/spring5/%E4%B8%80%E6%AD%A5%E4%B8%80%E6%AD%A5%E6%89%8B%E7%BB%98Spring%20AOP%E8%BF%90%E8%A1%8C%E6%97%B6%E5%BA%8F%E5%9B%BE.jpg)
4. [一步一步手绘Spring MVC运行时序图.jpg](https://github.com/gupaoedu-tom/resouce/blob/master/spring5/%E4%B8%80%E6%AD%A5%E4%B8%80%E6%AD%A5%E6%89%8B%E7%BB%98Spring%20MVC%E8%BF%90%E8%A1%8C%E6%97%B6%E5%BA%8F%E5%9B%BE.jpg)
5. [SpringMVC核心组件关系图.png](https://github.com/gupaoedu-tom/resouce/blob/master/spring5/SpringMVC%E6%A0%B8%E5%BF%83%E7%BB%84%E4%BB%B6%E5%85%B3%E7%B3%BB%E5%9B%BE.png)
6. [SpringJDBC异常结构图.png](https://github.com/gupaoedu-tom/resouce/blob/master/spring5/SpringJDBC%E5%BC%82%E5%B8%B8%E7%BB%93%E6%9E%84%E5%9B%BE.png)
# 技术交流
![关注公众号Tom弹架构](https://user-images.githubusercontent.com/54272541/139790847-bbcccc8c-cd5e-4bdc-9b1b-bc923a9d4d99.png)
### 推荐《[Netty 4核心原理与手写RPC框架实战](https://github.com/gupaoedu-tom/netty4-samples)》上架3个月销量突破10000册!
### 推荐《[设计模式就该这样学](https://github.com/gupaoedu-tom/design-samples)》已全面开启预售!!!
| 1 |
apache/servicecomb-samples | Apache servicecomb | 2019-02-21T13:02:49Z | null | # ServiceComb samples
This project is samples for java-chassis 3.x.x. You can switch to other branches to see different samples.
## basic
A sample shows a provider, a consumer and a gateway using java chassis.
## porter_lightweight
A sample shows an application with basic login, download file, delete file functions. Read this [document](https://servicecomb.apache.org/references/java-chassis/zh_CN/featured-topics/application-porter.html) for details.
## porter_springboot
A sample shows an application with basic login, download file, delete file functions. Read this [document](https://servicecomb.apache.org/references/java-chassis/zh_CN/featured-topics/application-porter.html) for details.
## java-chassis-samples
Featured samples for java-chassis modules. Each module contains 10 minutes guides.
## java-chassis-integration-tests
java-chassis integration tests。
## Precondition
Before running the samples,install [service center](https://github.com/apache/servicecomb-service-center) and [kie](https://github.com/apache/servicecomb-kie). Or download [Lightweight Cloud Service Engine](https://support.huaweicloud.com/devg-cse/cse_devg_0036.html) which integrates both service center and kie for ease of use.
# 使用ServiceComb开发微服务的示例项目
这个项目使用java-chassis 2.0.x版本。可以切换分支,查看其他版本的例子。
## basic
该项目展示了Java Chassis开发的一个provider, 一个consumer和一个网关服务。
## porter_lightweight
该项目演示了一个包括网关、文件下载、认证鉴权等功能的简单应用系统,同时演示了ServiceComb推荐的先写接口声明,再写业务代码的软件工程实践。可以阅读[文章](https://servicecomb.apache.org/references/java-chassis/zh_CN/featured-topics/application-porter.html)了解项目的细节。这个例子的运行环境采用vert.x作为HTTP服务器,即 REST
over Vert.x transport。
## porter_springboot
该项目演示了一个包括网关、文件下载、认证鉴权等功能的简单应用系统,同时演示了ServiceComb推荐的先写接口声明,再写业务代码的软件工程实践。可以阅读[文章](https://servicecomb.apache.org/references/java-chassis/zh_CN/featured-topics/application-porter.html)了解项目的细节。这个例子的运行环境采用Spring Boot及其Embeded Tomcat,即
REST over Servlet。
## java-chassis-samples
java-chassis 各个模块功能的例子。每个子项目包含了10分钟可以学习完成的简单示例。
## java-chassis-integration-tests
java-chassis 的集成测试用例。
## 前提条件
运行这些例子之前,需要先安装[注册中心](https://github.com/apache/servicecomb-service-center) 和[配置中心](https://github.com/apache/servicecomb-kie) 。华为云提供一个出色的[本地轻量化微服务引擎](https://support.huaweicloud.com/devg-cse/cse_devg_0036.html) ,可以直接下载安装使用。
| 1 |
spring-cloud-samples/spring-cloud-contract-samples | Samples for Spring Cloud Contract project | 2016-11-09T12:30:56Z | null | null | 1 |
pinguo-zhouwei/MaterialDesignSamples | Material Design 系列控件samples,讲了Material Design 系列新控件的使用方法和一些场景示例,使用详情请看对应博客,持续更新中... | 2016-12-12T10:52:00Z | null | null | 0 |
habuma/spring-in-action-4-samples | null | 2014-11-06T18:32:03Z | null | SpringInActionExamples
======================
These are the examples from Spring in Action, Fourth Edition. | 1 |
gluonhq/gluon-samples | Gluon sample projects | 2016-12-14T12:06:29Z | null | # Gluon Samples
Java, JavaFX and Gluon Mobile samples to run with Java 11+, GraalVM and the GluonFX plugin for [Maven](https://github.com/gluonhq/gluonfx-maven-plugin/).
The following platforms are currently supported:
* Linux
* Mac OS X
* Windows
* iOS
* Android
* Embedded
## Documentation
Before getting started with this samples, read the GluonFX plugin [documentation](https://docs.gluonhq.com/).
## Build and run the samples
Visit each sample's README for further instructions.
## Issues and Contributions ##
Issues can be reported to the [Issue tracker](https://github.com/gluonhq/gluon-samples/issues)
Contributions can be submitted via [Pull requests](https://github.com/gluonhq/gluon-samples/pulls),
providing you have signed the [Gluon Individual Contributor License Agreement (CLA)](https://cla.gluonhq.com).
| 1 |
GoogleCloudPlatform/cloud-code-samples | Code templates to make working with Kubernetes feel like editing and debugging local code. | 2019-03-28T02:06:05Z | null | # Code Templates for Google Cloud Code
## What is Google Cloud Code
Cloud Code brings the power and convenience of IDEs to cloud-native application development. Cloud Code integrates with Google Cloud services like Google Kubernetes Engine, Cloud Run, Cloud APIs and Secret Manager, and makes you feel like you are working with local code.
Cloud Code works with Google’s command-line container tools like skaffold, minikube, and kubectl under the hood, providing local, continuous feedback on your project as you build, edit, run, and deploy your applications locally or in the cloud. Cloud Code also deeply integrates with Cloud SDK to provide a unified authentication experience when you develop with Google Cloud Services.
## What's in this repo
Code templates for easy Getting-Started experience with Google Cloud Code in Python, Java, Nodejs, Go and .NET Core.
We support two IDEs: Visual Studio Code and IntelliJ (and other JetBrains IDEs).
VS Code:
![Create New Application VS Code](https://cloud.google.com/code/docs/vscode/images/create-new-app.gif)
IntelliJ:
![Create New Application IntelliJ](https://cloud.google.com/code/docs/intellij/images/intellij-quickstart-runthrough.gif)
## Useful Links
- [Cloud Code for VS Code](https://marketplace.visualstudio.com/items?itemName=GoogleCloudTools.cloudcode)
- [Cloud Code for IntelliJ](https://plugins.jetbrains.com/plugin/8079-cloud-code)
- [Cloud Code Docs](https://cloud.google.com/code/docs/)
- [Cloud Code for VS Code Repo](https://github.com/GoogleCloudPlatform/cloud-code-vscode)
- [Cloud Code for IntelliJ Repo](https://github.com/GoogleCloudPlatform/cloud-code-intellij)
| 1 |
googleads/googleads-shopping-samples | Samples for the Content API for Shopping and the Manufacturer Center API | 2014-06-05T15:16:46Z | null | # Samples for the Content API for Shopping and Manufacturer Center API
These code samples are organized by platform or language. Each language
directory contains a `README` with more information about how to run the
samples for that particular language. Here, we cover setting up
authentication and the common configuration file used by all the samples.
For more information on the APIs, please refer to the documentation for the
[Content API for Shopping](https://developers.google.com/shopping-content/)
and the
[Manufacturer Center API](https://developers.google.com/manufacturers/).
## Choose Your Method of Authentication
Before getting started, check the Getting Started section of the
[Content API for Shopping documentation](https://developers.google.com/shopping-content/v2/quickstart).
You may want to use
[service accounts](https://developers.google.com/shopping-content/guides/how-tos/service-accounts)
instead to simplify the authentication flow. These samples also support using
[Google Application Default Credentials](https://developers.google.com/identity/protocols/application-default-credentials).
Setting up authentication for the Manufacturer Center API is similar to the
Content API. Just make sure to select the Manufacturer Center API in the API
Console. Both APIs can be selected if you wish to try samples for both APIs.
## Setting up Authentication and Sample Configuration
1. Create the directory `$(HOME)/shopping-samples` to store the
configuration.
If you are unsure where this will be located in your particular setup, then
run the samples (following the language-specific `README`). Errors
from the samples related to either this directory or necessary files not
existing will provide the full path to the expected directory/files.
Within this directory, also create the following subdirectories, depending
on which API you would like to try:
* `content` for the Content API for Shopping
* `manufacturers` for the Manufacturer Center API
Place the files described below in the appropriate subdirectory for the API
you want to try.
2. Set up your desired authentication method.
If you are using Google Application Default Credentials:
* Follow the directions on the [Google Application Default
Credentials](https://developers.google.com/identity/protocols/application-default-credentials)
page.
If you are using a service account:
* Put the JSON file you downloaded when creating the service account to
the file `service-account.json` in the appropriate API configuration
subdirectories.
If you are using an OAuth2 client ID:
* Download your [OAuth2 client
credentials](https://console.developers.google.com/apis/credentials) to
the file `client-secrets.json` in the appropriate API configuration
subdirectories.
**Note:** The samples assume that you are using an OAuth2 client ID that
can use a loopback IP address to retrieve tokens. If you are not or are
unsure that you are, please visit the
[OAuth2.0 for Mobile & Desktop Apps]
(https://developers.google.com/identity/protocols/OAuth2InstalledApp)
page and follow the instructions there to create a new OAuth2 client ID
to use with the samples.
You can set up multiple authentication methods to try out different flows,
but note that the samples will always use the first credentials that can be
loaded, in the order:
1. [Google Application Default
Credentials](https://developers.google.com/identity/protocols/application-default-credentials)
2. [Service
accounts](https://developers.google.com/shopping-content/v2/how-tos/service-accounts)
credentials
3. [OAuth2
client](https://developers.google.com/shopping-content/v2/how-tos/authorizing)
credentials
3. Each set of samples uses a different configuration file. For the Content
API for Shopping, take the example `merchant-info.json` from the repository
root and copy it into `$(HOME)/shopping-samples/content`. Next, change its
contents appropriately. It contains a JSON object with the following fields:
| Field | Type | Description |
|---------------------------|--------|------------------------------------------------|
| `merchantId` | number | The Merchant Center ID to run samples against. |
| `accountSampleUser` | string | If non-empty, the email address for the user to add/remove in samples for the `Accounts` service. |
| `accountSampleAdWordsCID` | number | If non-zero, the AdWords Customer ID to link/unlink in samples for the `Accounts` service. |
For the Manufacturer Center API, take the example `manufacturer-info.json`
from the repository root and copy it into
`$(HOME)/shopping-samples/manufacturers`. Next, change its contents
appropriately. It contains a JSON object with the following fields:
| Field | Type | Description |
|---------------------------|--------|------------------------------------------------|
| `manufacturerId` | number | The Manufacturer Center ID to run samples against. |
| `websiteUrl` | string | The URL (without trailing slash) associated with the Manufacturer Center account. |
If using OAuth2 client credentials, once you have authorized access, your
token details will be stored in the `stored-token.json` file in the samples
configuration directory. If you have any issues authenticating, remove this
file and you will be asked to re-authorize access.
## Try Out the Samples
Now that you've configured both the common sample configuration file and set up
your authentication credentials, it's time to build and run any of the included
samples. As mentioned before, there are language-specific instructions in
the `README`s located in each language subdirectory. Have fun!
## Possible Issues
* When using the Content API for Shopping, if you haven't set up tax settings on
your account, you may get an error when running certain samples. If you
receive a "missing tax settings" error, set your tax settings in the Merchant
Center before trying these samples. Selecting the "Don't charge taxes in the
United States" setting is sufficient.
| 1 |
heibaiying/spring-samples-for-all | spring、spring-boot、spring-cloud 常用整合用例 | 2018-12-18T00:59:53Z | null | # Spring-Samples-For-All
![spring](https://img.shields.io/badge/spring-5.1.3.RELEASE-brightgreen.svg) ![springboot](https://img.shields.io/badge/springboot-2.1.1.RELEASE-brightgreen.svg) ![springcloud](https://img.shields.io/badge/springcloud-Finchley.SR2-brightgreen.svg) ![jdk](https://img.shields.io/badge/jdk->=1.8-blue.svg) ![author](https://img.shields.io/badge/author-heibaiying-orange.svg)
本项目仓库提供 spring、spring-boot、spring-cloud 的常用整合用例。**每个用例都提供详细的图文说明**,并给出官方文档的具体链接作为参考。随着 spring 的迭代,本仓库会持续更新,升级版本和丰富用例。
**版本说明**:
spring: 5.1.3.RELEASE
spring-boot:2.1.1.RELEASE
spring-cloud:Finchley.SR2
<br/>
>:star::star::star:**对大数据技术栈感兴趣的小伙伴可以关注我的新仓库:[大数据入门指南](https://github.com/heibaiying/BigData-Notes)**
## 1. spring samples
所有 spring 的项目我都会提供两个版本的 sample:
- 一个版本是基于 xml 配置,也就是最为常见的配置方式;
- 另一个版本完全基于代码配置(项目以**annotation**结尾),这也是目前 spring 官方推荐的更为灵活配置方法,也方便更好的衔接 spring boot 的配置。
| samples | 描述 | 官方文档 |
| ------------------------------------------------------------ | ------------------------------------------------------------ | ------------------------------------------------------------ |
| [springmvc-base](https://github.com/heibaiying/spring-samples-for-all/tree/master/spring/springmvc-base)<br/>[springmvc-base-annotation](https://github.com/heibaiying/spring-samples-for-all/tree/master/spring/springmvc-base-annotation) | springmvc 基础、参数绑定、格式转换、数据校验、<br/>异常处理、 文件上传下载、视图渲染 | [Spring Mvc ](https://docs.spring.io/spring/docs/5.1.3.RELEASE/spring-framework-reference/web.html#mvc) |
| [spring-aop](https://github.com/heibaiying/spring-samples-for-all/tree/master/spring/spring-aop)<br/>[spring-aop-annotation](https://github.com/heibaiying/spring-samples-for-all/tree/master/spring/spring-aop-annotation) | spring 切面编程 | [Spring AOP](https://docs.spring.io/spring/docs/5.1.3.RELEASE/spring-framework-reference/core.html#aop) |
| [spring-jdbc](https://github.com/heibaiying/spring-samples-for-all/tree/master/spring/spring-jdbc)<br/>[spring-jdbc-annotation](https://github.com/heibaiying/spring-samples-for-all/tree/master/spring/spring-jdbc-annotation) | spring jdbc-template 的使用 | [Using JdbcTemplate](https://docs.spring.io/spring/docs/5.1.3.RELEASE/spring-framework-reference/data-access.html#jdbc-JdbcTemplate) |
| [spring-mybatis](https://github.com/heibaiying/spring-samples-for-all/tree/master/spring/spring-mybatis)<br/>[spring-mybatis-annotation](https://github.com/heibaiying/spring-samples-for-all/tree/master/spring/spring-mybatis-annotation) | spring 整合 mybatis | [Mybatis-Spring](http://www.mybatis.org/spring/zh/index.html) |
| [spring-druid-mybatis](https://github.com/heibaiying/spring-samples-for-all/tree/master/spring/spring-druid-mybatis)<br/>[spring-druid-mybatis-annotation](https://github.com/heibaiying/spring-samples-for-all/tree/master/spring/spring-druid-mybatis-annotation) | spring 整合 druid、mybatis | [Alibaba druid](https://github.com/alibaba/druid/wiki/%E5%B8%B8%E8%A7%81%E9%97%AE%E9%A2%98) |
| [spring-redis](https://github.com/heibaiying/spring-samples-for-all/tree/master/spring/spring-redis)<br/>[spring-redis-annotation](https://github.com/heibaiying/spring-samples-for-all/tree/master/spring/spring-redis-annotation) | spring 整合 redis 单机 + 集群(jedis 客户端)<br/>spring 整合 redis 单机 + 集群(redisson 客户端) | [Redisson](https://github.com/redisson/redisson/wiki/%E7%9B%AE%E5%BD%95) |
| [spring-mongodb](https://github.com/heibaiying/spring-samples-for-all/tree/master/spring/spring-mongodb)<br/>[spring-mongodb-annotation](https://github.com/heibaiying/spring-samples-for-all/tree/master/spring/spring-mongodb-annotation) | spring 整合 mongodb | [Spring Data MongoDB](https://docs.spring.io/spring-data/mongodb/docs/2.1.3.RELEASE/reference/html/#mongo.mongo-db-factory-java) |
| [spring-memcached](https://github.com/heibaiying/spring-samples-for-all/tree/master/spring/spring-memcached)<br/>[spring-memcached-annotation](https://github.com/heibaiying/spring-samples-for-all/tree/master/spring/spring-memcached-annotation) | spring 整合 memcached(单机 + 集群) | [Xmemcached](https://github.com/killme2008/xmemcached/wiki/Xmemcached%20%E4%B8%AD%E6%96%87%E7%94%A8%E6%88%B7%E6%8C%87%E5%8D%97) |
| [spring-rabbitmq](https://github.com/heibaiying/spring-samples-for-all/tree/master/spring/spring-rabbitmq)<br/>[spring-rabbitmq-annotation](https://github.com/heibaiying/spring-samples-for-all/tree/master/spring/spring-rabbitmq-annotation) | spring 整合 rabbitmq、消息序列化与反序列化 | [Rabbitmq](http://www.rabbitmq.com/getstarted.html)<br>[Spring AMQP](https://docs.spring.io/spring-amqp/docs/2.1.3.BUILD-SNAPSHOT/reference/html/) |
| [spring-dubbo](https://github.com/heibaiying/spring-samples-for-all/tree/master/spring/spring-dubbo)<br/>[spring-dubbo-annotation](https://github.com/heibaiying/spring-samples-for-all/tree/master/spring/spring-dubbo-annotation) | spring 整合 dubbo | [Dubbo ](http://dubbo.apache.org/zh-cn/docs/user/quick-start.html) |
| [spring-websocket](https://github.com/heibaiying/spring-samples-for-all/tree/master/spring/spring-websocket)<br/>[spring-websocket-annotation](https://github.com/heibaiying/spring-samples-for-all/tree/master/spring/spring-websocket-annotation) | spring 整合 websocket | [Spring Websocket](https://docs.spring.io/spring/docs/5.1.3.RELEASE/spring-framework-reference/web.html#websocket) |
| [spring-mail](https://github.com/heibaiying/spring-samples-for-all/tree/master/spring/spring-email) <br/>[spring-mail-annotation](https://github.com/heibaiying/spring-samples-for-all/tree/master/spring/spring-email-annotation) | spring 普通文本邮件、附件邮件、模板邮件 | [Spring Email](https://docs.spring.io/spring/docs/5.1.3.RELEASE/spring-framework-reference/integration.html#mail) |
| [spring-scheduling](https://github.com/heibaiying/spring-samples-for-all/tree/master/spring/spring-scheduling)<br/>[spring-scheduling-annotation](https://github.com/heibaiying/spring-samples-for-all/tree/master/spring/spring-scheduling-annotation) | spring 定时任务 | [Task Execution and Scheduling](https://docs.spring.io/spring/docs/5.1.3.RELEASE/spring-framework-reference/integration.html#scheduling) |
<br/>
## 2. spring-boot samples
| samples | 描述 | 官方文档 |
| ------------------------------------------------------------ | ------------------------------------------ | ------------------------------------------------------------ |
| [spring-boot-base](https://github.com/heibaiying/spring-samples-for-all/tree/master/spring-boot/spring-boot-base) | spring-boot 基础 | [spring boot 官方文档](https://docs.spring.io/spring-boot/docs/2.1.1.RELEASE/reference/htmlsingle/)<br>[spring boot 中文官方文档](https://www.breakyizhan.com/springboot/3028.html) |
| [spring-boot-yml-profile](https://github.com/heibaiying/spring-samples-for-all/tree/master/spring-boot/spring-boot-yml-profile) | yml 语法和多配置切换 | [Using YAML Instead of Properties](https://docs.spring.io/spring-boot/docs/2.1.1.RELEASE/reference/htmlsingle/#boot-features-external-config-yaml) |
| [spring-boot-tomcat](https://github.com/heibaiying/spring-samples-for-all/tree/master/spring-boot/spring-boot-tomcat) | spring-boot 整合外部容器(tomcat) | [Use Another Web Server](https://docs.spring.io/spring-boot/docs/2.1.1.RELEASE/reference/htmlsingle/#howto-use-another-web-server) |
| [spring-boot-servlet](https://github.com/heibaiying/spring-samples-for-all/tree/master/spring-boot/spring-boot-servlet) | spring boot 整合 servlet 3.0 | [Embedded Servlet Container Support](https://docs.spring.io/spring-boot/docs/2.1.1.RELEASE/reference/htmlsingle/#boot-features-embedded-container) |
| [spring-boot-jsp](https://github.com/heibaiying/spring-samples-for-all/tree/master/spring-boot/spring-boot-jsp) | spring-boot 整合 jsp(内置容器) | [JSP Limitations](https://docs.spring.io/spring-boot/docs/2.1.1.RELEASE/reference/htmlsingle/#boot-features-jsp-limitations) |
| [spring-boot-data-jpa](https://github.com/heibaiying/spring-samples-for-all/tree/master/spring-boot/spring-boot-data-jpa) | spring-boot data jpa 的使用 | [Spring Data JPA](https://docs.spring.io/spring-data/jpa/docs/2.1.3.RELEASE/reference/html/) |
| [spring-boot-mybatis](https://github.com/heibaiying/spring-samples-for-all/tree/master/spring-boot/spring-boot-mybatis) | spring-boot+HikariDataSources 整合 mybatis | [Mybatis-Spring](http://www.mybatis.org/spring/zh/index.html)<br/>[Mybatis-Spring-Boot-Autoconfigure](http://www.mybatis.org/spring-boot-starter/mybatis-spring-boot-autoconfigure/) |
| [spring-boot-druid-mybtais](https://github.com/heibaiying/spring-samples-for-all/tree/master/spring-boot/spring-boot-druid-mybatis) | spring-boot 整合 druid、mybatis | [Alibaba druid](https://github.com/alibaba/druid/wiki/%E5%B8%B8%E8%A7%81%E9%97%AE%E9%A2%98)<br/>[druid-spring-boot-starter](https://github.com/alibaba/druid/tree/master/druid-spring-boot-starter) |
| [spring-boot-redis](https://github.com/heibaiying/spring-samples-for-all/tree/master/spring-boot/spring-boot-redis) | spring-boot 整合 redis | [Working with NoSQL Technologies](https://docs.spring.io/spring-boot/docs/2.1.1.RELEASE/reference/htmlsingle/#boot-features-nosql) |
| [spring-boot-mongodb](https://github.com/heibaiying/spring-samples-for-all/tree/master/spring-boot/spring-boot-mongodb) | spring-boot 整合 mongodb | [Working with NoSQL Technologies](https://docs.spring.io/spring-boot/docs/2.1.1.RELEASE/reference/htmlsingle/#boot-features-nosql) |
| [spring-boot-memcached](https://github.com/heibaiying/spring-samples-for-all/tree/master/spring-boot/spring-boot-memcached) | spring-boot 整合 memcached | [Xmemcached](https://github.com/killme2008/xmemcached/wiki/Xmemcached%20%E4%B8%AD%E6%96%87%E7%94%A8%E6%88%B7%E6%8C%87%E5%8D%97) |
| [spring-boot-rabbitmq](https://github.com/heibaiying/spring-samples-for-all/tree/master/spring-boot/spring-boot-rabbitmq) | spring-boot 整合 rabbitmq | [RabbitMQ support](https://docs.spring.io/spring-boot/docs/2.1.1.RELEASE/reference/htmlsingle/#boot-features-rabbitmq) |
| [spring-boot-dubbo](https://github.com/heibaiying/spring-samples-for-all/tree/master/spring-boot/spring-boot-dubbo) | spring-boot 整合 dubbo | [Dubbo ](http://dubbo.apache.org/zh-cn/docs/user/quick-start.html) |
| [spring-boot-websocket](https://github.com/heibaiying/spring-samples-for-all/tree/master/spring-boot/spring-boot-websocket) | spring-boot 整合 websocket | [Using @ServerEndpoint](https://docs.spring.io/spring-boot/docs/2.1.1.RELEASE/reference/htmlsingle/#howto-create-websocket-endpoints-using-serverendpoint) |
| [spring-boot-kafka](https://github.com/heibaiying/spring-samples-for-all/tree/master/spring-boot/spring-boot-kafka) | spring-boot 整合 kafka | [Apache Kafka Support](https://docs.spring.io/spring-boot/docs/2.1.1.RELEASE/reference/htmlsingle/#boot-features-kafka) |
| [spring-boot-actuator](https://github.com/heibaiying/spring-samples-for-all/tree/master/spring-boot/spring-boot-actuator) | actuator + Hyperic SIGAR 应用信息监控 | [Spring Boot Actuator](https://docs.spring.io/spring-boot/docs/2.1.1.RELEASE/reference/htmlsingle/#production-ready) |
| [spring-boot-swagger2](https://github.com/heibaiying/spring-samples-for-all/tree/master/spring-boot/spring-boot-swagger2) | spring-boot 集成 Swagger2 打造在线接口文档 | [Springfox Reference Documentation](http://springfox.github.io/springfox/docs/current/) |
<br/>
## 3. spring-cloud samples
| samples | 描述 | 官方文档 |
| ------------------------------------------------------------ | ------------------------------------------------------------ | ------------------------------------------------------------ |
| [spring-cloud-Eureka](https://github.com/heibaiying/spring-samples-for-all/tree/master/spring-cloud/spring-cloud-eureka) | Eureka 服务的注册和发现 | [Service Discovery: Eureka Server](https://cloud.spring.io/spring-cloud-static/Finchley.SR2/multi/multi_spring-cloud-eureka-server.html) |
| [spring-cloud-Eureka-cluster](https://github.com/heibaiying/spring-samples-for-all/tree/master/spring-cloud/spring-cloud-eureka-cluster) | Eureka 高可用集群搭建 | [Service Discovery: Eureka Server](https://cloud.spring.io/spring-cloud-static/Finchley.SR2/multi/multi_spring-cloud-eureka-server.html) |
| [spring-cloud-Ribbon](https://github.com/heibaiying/spring-samples-for-all/tree/master/spring-cloud/spring-cloud-ribbon) | Ribbon 客户端负载均衡<br/>RestTemplate 服务远程调用 | [Client Side Load Balancer: Ribbon](https://cloud.spring.io/spring-cloud-static/Finchley.SR2/multi/multi_spring-cloud-ribbon.html) |
| [spring-cloud-OpenFeign](https://github.com/heibaiying/spring-samples-for-all/tree/master/spring-cloud/spring-cloud-feign) | OpenFeign 声明式服务调用、服务容错处理 | [Declarative REST Client: Feign](https://cloud.spring.io/spring-cloud-static/Finchley.SR2/multi/multi_spring-cloud-feign.html) |
| [spring-cloud-Hystrix](https://github.com/heibaiying/spring-samples-for-all/tree/master/spring-cloud/spring-cloud-hystrix) | Hystix 服务容错保护<br/>hystrix dashboard 断路器监控<br>Turbine 断路器聚合监控 | [Circuit Breaker: Hystrix Clients](https://cloud.spring.io/spring-cloud-static/Finchley.SR2/multi/multi__circuit_breaker_hystrix_clients.html)<br/>[Hystrix metrics aggregation with Turbine](https://cloud.spring.io/spring-cloud-static/Finchley.SR2/multi/multi_spring-cloud-consul-turbine.html) |
| [spring-cloud-Zuul](https://github.com/heibaiying/spring-samples-for-all/tree/master/spring-cloud/spring-cloud-zuul) | Zuul 网关服务 | [Router and Filter: Zuul](https://cloud.spring.io/spring-cloud-static/Finchley.SR2/multi/multi__router_and_filter_zuul.html) |
| [spring-cloud-Sleuth-Zipkin](https://github.com/heibaiying/spring-samples-for-all/tree/master/spring-cloud/spring-cloud-sleuth-zipkin) | Sleuth + Zipkin 服务链路追踪 | [Spring Cloud Sleuth](https://cloud.spring.io/spring-cloud-static/Finchley.SR2/multi/multi__introduction.html#sleuth-adding-project) |
| [spring-cloud-Config-Bus](https://github.com/heibaiying/spring-samples-for-all/tree/master/spring-cloud/spring-cloud-config) | Config 分布式配置中心 <br>集成 Bus 消息总线 实现配置热更新 | [Spring Cloud Config Client](https://cloud.spring.io/spring-cloud-static/Finchley.SR2/multi/multi__spring_cloud_config_client.html) |
<br/>
## 4.spring分布式session和分布式事务
| sample | 描述 | 官方文档 |
| ------------------------------------------------------------ | ------------------------------------------------------------ | ------------------------------------------------------------ |
| [spring-session](https://github.com/heibaiying/spring-samples-for-all/tree/master/distributed-solution/spring-session) | spring 实现分布式 session | [spring session](https://spring.io/projects/spring-session#learn) |
| [spring boot + spring session](https://github.com/heibaiying/spring-samples-for-all/tree/master/distributed-solution/spring-boot-session) | spring boot + spring session 实现分布式 session | [spring session](https://spring.io/projects/spring-session#learn) |
| [springboot-druid-mybatis-atomikos](https://github.com/heibaiying/spring-samples-for-all/tree/master/spring-boot/springboot-druid-mybatis-multi) | spring boot + druid + mybatis + atomikos<BR> 配置多数据源、支持分布式事务 ( JTA 方式实现) | [Distributed Transactions with JTA](https://docs.spring.io/spring-boot/docs/2.1.2.RELEASE/reference/htmlsingle/#boot-features-jta) |
<br/>
## 5.参考资料
相关参考文档放在了仓库的 referenced documents 目录下,文件目录如下:
- Servlet3.1 规范(最终版).pdf
- Thymeleaf 中⽂参考⼿册.pdf
<br>
<div align="center">
<a href = "https://blog.csdn.net/m0_37809146">
<img width="200px" src="https://gitee.com/heibaiying/BigData-Notes/raw/master/pictures/blog-logo.png"/>
</a>
</div>
<div align="center"> <a href = "https://blog.csdn.net/m0_37809146"> 欢迎关注我的博客:https://blog.csdn.net/m0_37809146</a> </div>
| 1 |
bitbar/test-samples | Sample test scripts and applications for Bitbar Cloud | 2014-04-10T20:45:44Z | null | # Bitbar Test Samples
This repository contains Bitbar Cloud sample test scripts and applications.
## Repository Structure
* [apps](apps/) - Prebuilt sample applications that you can use to start testing if you don't have your own
* [samples](samples/) - Test samples for using different testing frameworks and some other examples
## FAQ
### iOS
* [How to package a native iOS app for Bitbar Cloud](http://docs.bitbar.com/testing/xcode/ipa/index.html)
* [How to run XCTests on Bitbar Cloud](http://docs.bitbar.com/testing/xcode/xctest/index.html)
* [How to run XCUITests on Bitbar Cloud](http://docs.bitbar.com/testing/xcode/xcuitest/index.html)
### Android
* [How to run Espresso tests on Bitbar Cloud](http://docs.bitbar.com/testing/espresso/index.html)
### Appium
* [How to run client side Appium tests on Bitbar Cloud](http://docs.bitbar.com/testing/appium/client-side/index.html)
* [How to run server side Appium tests on Bitbar Cloud](http://docs.bitbar.com/testing/appium/server-side/index.html)
### Custom Frameworks
* [How to use a custom testing framework on Bitbar Cloud](http://docs.bitbar.com/testing/scripted-run/index.html)
## License
This project is licensed under the Apache License 2.0 - see the [LICENSE](LICENSE) file for details.
| 1 |
habuma/spring-in-action-6-samples | Sample code from Spring in Action 6 | 2021-01-04T04:41:04Z | null | # Spring in Action, 6th Edition Sample Code
This repo will hold the sample code from [Spring in Action, 6th edition](https://www.manning.com/books/spring-in-action-sixth-edition).
## What are all of the weird comments with "tag::" and "end::" about???
(Note: In the most recent commit, I've removed these comments. But they may come back, so I'll leave this mention of them here.)
The source code will have several weird comments, many starting with "tag::" and some with "end::". There may also be large chunks of code commented out.
The "tag::" and "end::" comments are there for the sake of building the book itself. The code in between those comments are pulled into the manuscript so that (as much as possible) code you see in the book comes straight from code that was built and tested.
Sometimes, though, code evolves throughout the course of a chapter. It's impractical to have multiple copies of the same project just for a few lines that are different. In those cases, the variant code is commented out, but still has the "tag::" and "end::" markers around it. The danger of doing that is that it's entirely possible that the commented out variant isn't correct--after all, it hasn't been compiled or run through a test suite. If you find something out of sorts, please let me know and I'll try to fix it.
## Shouldn't there be a test for ... ?
I'll readily admit that there could be more tests around certain parts of the code. When I find time, I will add these tests. In the meantime, please feel free to open a pull request with any suggested tests you think should be merged in.
| 1 |
ipipman/JavaSpringBootSamples | SpringBoot、Dubbo、SpringCloud的各种集成例子:Atomikos、gRPC、Thrift、Seata、ShardingSphere、Dubbo、Hmily、Nacos、Consul、Ribbon、Jedis、Lettuce、Redisson等框架 | 2020-12-10T01:48:53Z | null | # 目录
### SpringBoot相关实例
- ##### [SpringBoot集成Atomikos框架-实现分布式数据库XA事务;](https://github.com/ipipman/JavaSpringBootSamples/tree/master/springboot-atomikos-xa-sample "SpringBoot集成Atomikos框架,实现分布式数据库XA事务;")
- ##### [SpringBoot集成Seata框架-实现TCC模式柔性事务;](https://github.com/ipipman/JavaSpringBootSamples/tree/master/springboot-seata-tcc-sample "SpringBoot集成Seata框架,实现TCC模式柔性事务;")
- ##### [SpringBoot集成Seata框架-实现AT模式柔性事务;](https://github.com/ipipman/JavaSpringBootSamples/tree/master/springboot-seata-at-sample "SpringBoot集成Seata框架,实现AT模式柔性事务;")
- ##### [SpringBoot集成Sharding-JDBC框架-实现数据库读写分离;](https://github.com/ipipman/JavaSpringBootSamples/tree/master/springboot-shardingsphere-jdbc-sample "SpringBoot集成Sharding-JDBC框架,实现数据库读写分离;")
- ##### [SpringBoot集成gRPC框架-实现RPC服务;](https://github.com/ipipman/JavaSpringBootSamples/tree/master/springboot-rpc-grpc-sample "SpringBoot集成gRPC框架,实现RPC服务;")
- ##### [SpringBoot集成Thrift框架-实现RPC服务;](https://github.com/ipipman/JavaSpringBootSamples/tree/master/springboot-rpc-thrift-sample "SpringBoot集成Thrift框架,实现RPC服务;")
- ##### [SpringBoot集成Nacos框架-实现配置中心;](https://github.com/ipipman/JavaSpringBootSamples/tree/master/springboot-nacos-sample "SpringBoot集成Nacos框架-实现配置中心;")
- ##### [SpringBoot集成Jedis框架-实现Redis调用;](https://github.com/ipipman/JavaSpringBootSamples/tree/master/springboot-jedis-sample "SpringBoot集成Jedis框架-实现Redis调用;")
- ##### [SpringBoot集成Lettuce框架-实现Redis调用;](https://github.com/ipipman/JavaSpringBootSamples/tree/master/springboot-lettuce-sample "SpringBoot集成Lettuce框架-实现Redis调用;")
- ##### [SpringBoot集成Redisson框架-实现Redis调用;](https://github.com/ipipman/JavaSpringBootSamples/tree/master/springboot-redisson-sample "SpringBoot集成Redisson框架-实现Redis调用;")
### Dubbo相关实例
- ##### [分布式服务框架Dubbo-基于注解配置的方式;](https://github.com/ipipman/JavaSpringBootSamples/tree/master/dubbo-annotation-sample "分布式服务框架Dubbo(基于注解配置的方式)")
- ##### [分布式服务框架Dubbo-基于XML配置的方式;](https://github.com/ipipman/JavaSpringBootSamples/tree/master/dubbo-xml-sample "分布式服务框架Dubbo(基于XML配置的方式")
- ##### [分布式服务框架Dubbo-事件通知;](https://github.com/ipipman/JavaSpringBootSamples/tree/master/dubbo-notify-sample "分布式服务框架Dubbo(事件通知);")
- ##### [分布式服务框架Dubbo-异步调用;](https://github.com/ipipman/JavaSpringBootSamples/tree/master/dubbo-async-sample "分布式服务框架Dubbo(异步调用)")
- ##### [分布式服务框架Dubbo-缓存策略;](https://github.com/ipipman/JavaSpringBootSamples/tree/master/dubbo-cache-sample "分布式服务框架Dubbo(缓存策略)")
- ##### [分布式服务框架Dubbo-参数回调;](https://github.com/ipipman/JavaSpringBootSamples/tree/master/dubbo-callback-sample "分布式服务框架Dubbo(参数回调)")
- ##### [分布式服务框架Dubbo-基于HTTP传输协议;](https://github.com/ipipman/JavaSpringBootSamples/tree/master/dubbo-http-sample "分布式服务框架Dubbo(基于HTTP传输协议)")
- ##### [分布式服务框架Dubbo-本地调用;](https://github.com/ipipman/JavaSpringBootSamples/tree/master/dubbo-local-sample "分布式服务框架Dubbo(本地调用)")
- ##### [分布式服务框架Dubbo-隐式参数;](https://github.com/ipipman/JavaSpringBootSamples/tree/master/dubbo-attachment-sample "分布式服务框架Dubbo(隐式参数)")
- ##### [分布式服务框架Dubbo-Mock功能;](https://github.com/ipipman/JavaSpringBootSamples/tree/master/dubbo-mock-sample "分布式服务框架Dubbo(mock功能)")
- ##### [分布式服务框架Dubbo-SPI机制;](https://github.com/ipipman/JavaSpringBootSamples/tree/master/dubbo-spi-sample "分布式服务框架Dubbo(SPI机制)")
- ##### [分布式服务框架Dubbo集成Nacos框架-实现注册中心;](https://github.com/ipipman/JavaSpringBootSamples/tree/master/dubbo-nacos-sample "分布式服务框架Dubbo集成Nacos框架-实现注册中心")
- ##### [分布式服务框架Dubbo集成Consul框架-实现注册中心;](https://github.com/ipipman/JavaSpringBootSamples/tree/master/dubbo-consul-sample "分布式服务框架Dubbo集成Consul框架-实现注册中心")
### SpringCloud相关实例
- ##### [SpringCloud集成Consul框架-实现配置中心;](https://github.com/ipipman/JavaSpringBootSamples/tree/master/springcloud-consul-config-sample "SpringCloud集成Consul框架-实现配置中心")
- ##### [SpringCloud集成Consul框架-实现注册中心;](https://github.com/ipipman/JavaSpringBootSamples/tree/master/springcloud-consul-register-sample "SpringCloud集成Consul框架-实现注册中心")
- ##### [SpringCloud集成Consul+Ribbon框架-实现注册中心和负载均衡;](https://github.com/ipipman/JavaSpringBootSamples/tree/master/springcloud-consul-ribbon-sample "SpringCloud集成Consul+Ribbon框架-实现注册中心和负载均衡")
- ##### [SpringCloud集成Nacos框架-实现配置中心;](https://github.com/ipipman/JavaSpringBootSamples/tree/master/springcloud-nacos-config-sample "SpringCloud集成Nacos框架-实现配置中心")
- ##### [SpringCloud集成Nacos框架-实现注册中心;](https://github.com/ipipman/JavaSpringBootSamples/tree/master/springcloud-nacos-register-sample "SpringCloud集成Nacos框架-实现注册中心")
- ##### [SpringCloud集成Nacos+Ribbon框架-实现注册中心和负载均衡;](https://github.com/ipipman/JavaSpringBootSamples/tree/master/springcloud-nacos-ribbon-sample "SpringCloud集成Nacos+Ribbon框架-实现注册中心和负载均衡")
### 关于作者
| 0 |
dynamic-datasource/dynamic-datasource-samples | null | 2020-09-23T06:04:42Z | null | # 演示例子
大部分数据库连接为 H2Database,仅供测试。
除开 `com.baomidou:springboot3-sample`, 其他子模块均可在 [OpenJDK 8, OpenJDK 21] 的 JDK 范围及其下游发行版下执行单元测试。
所有单元测试在 Github Actions 完成验证。你可能希望参考 [位于 Github Actions 的 CI 文件](./.github/workflows/ci.yml)。
- add-remove-datasource 动态添加删除数据源的使用示例
- all-datasource-sample 所有不同连接池使用示例(大乱炖,实际不建议)
- druid-sample 集成mybatis和druid的使用示例
- jdbc-template-sample 集成原生jdbcTemplate的使用示例
- load-datasource-from-jdbc 通过数据库配置来启动数据源示例
- mybatis-sample 集成原生mybatis的使用示例
- mybatisplus2-sample 集成mybatisPlus2的使用示例
- mybatisplus3-sample 集成mybatisPlus3的使用示例
- name-pattern-sample 自定义切面的使用示例
- nest-sample 嵌套切换数据源使用示例
- quartz-sample 多数据源集成quartz示例
- shardingsphere-jdbc-4.x-spring-sample 集成 ShardingSphere JDBC Spring Boot Starter 4.1.1 使用示例, 不再维护,
参考 https://github.com/apache/shardingsphere/releases/tag/5.0.0-alpha
- shardingsphere-jdbc-5.x-core-sample 集成 ShardingSphere JDBC Driver 5.4.1 使用示例
- shardingsphere-jdbc-5.x-spring-sample 集成 ShardingSphere JDBC Spring Boot Starter 5.2.1 使用示例, 不再维护,
参考 https://github.com/apache/shardingsphere/issues/22469
- spel-sample 动态从外部参数spel来切换数据源的使用示例
- tx-local-sample 本地事务示例项目★★★★★★必看★★★★★★
- tx-seata-sample 基于seata的分布式事务集成使用示例
## Contributing
我们欢迎社区的贡献。围绕此 git 的讨论与协作应通过 https://github.com/baomidou/dynamic-datasource/issues 进行。
针对 IDE,项目的语言级别应设置为 JDK 8,对于单独的 `com.baomidou:springboot3-sample` 子模块,语言级别应设置为 JDK 17 。
在提交 Pull Request 之前, 请在本地通过 [OpenJDK 17, OpenJDK 21] 的 JDK 范围下完成此命令的验证。
我们鼓励通过 `SDKMAN!` 切换到 `21.0.2-graalce` 来验证。
```shell
sdk install java 21.0.2-graalce
sdk use java 21.0.2-graalce
git clone git@github.com:dynamic-datasource/dynamic-datasource-samples.git
cd ./dynamic-datasource-samples/
./mvnw -T1C -e clean test
```
| 1 |
thingsboard/samples | Thingboard sample applications | 2016-12-21T14:13:08Z | null | # samples
Thingboard sample applications
| 1 |
Adobe-Consulting-Services/acs-aem-samples | AEM Code Samples repository | 2015-01-07T02:40:07Z | null | # ACS AEM Samples
#### Samples index: [http://adobe-consulting-services.github.io/acs-aem-samples/#samples](http://adobe-consulting-services.github.io/acs-aem-samples/#samples)
This project is a collection of sample implementation of the various, common building blocks for AEM-based applications.
The samples in this project are not intended and should never be installed on AEM instance directly and only used for
reference purposes.
These samples have not been tested for functionality; please report and bugs/incorrectness to the ACS AEM Samples
GitHub Issues project.
| 1 |
GoogleCloudPlatform/point-of-sale | Anthos Edge Use Cases for bringing apps and computation closer to the location where the action is, to improve response times and save bandwidth. | 2021-09-01T17:24:52Z | null | # Point of Sale (PoS)
**Point of Sale** is a sample application that simulates a retail store kiosk
used to submit and track orders and payments.
This application is used by Google to demonstrate use cases where
[Anthos](https://cloud.google.com/anthos) clusters are installed and run outside
of Google Cloud Platform _(i.e. on premise bare metal infrastructure)_. The
application is representative of **edge deployments** like that of retail
store-front devices.
This repository also hosts a collection of samples and walkthroughs that enables
learning and experimenting with [Anthos](https://cloud.google.com/anthos) for
edge use cases. All of the samples and walkthroughs are built around the
**Point of Sale** application.
> 👓 **Note:** Anthos clusters means Kubernetes clusters that are managed by Anthos.
If you’re using this app, please ★Star the repository to show your interest!
> 👓 **Note to Googlers:** Please fill out the form at [go/using-pos](http://go/using-pos) if you are using this application.
<p align="center">
<img src="docs/images/pos.png">
</p>
### Play with it:
- Latest release: [point-of-sale.retail.cymbal.dev](http://point-of-sale.retail.cymbal.dev)
- Build from **main** branch: [staging.point-of-sale.retail.cymbal.dev](http://staging.point-of-sale.retail.cymbal.dev)
---
### Edge computing
Edge computing is a distributed computing paradigm that brings computation and
data storage closer to the location where the action is, to improve response
times and save bandwidth. Multiple industries _(e.g. Retail, Telecommunication,
Manufacturing and Energy)_ are facing a growing demand to provide localized,
consistent, low latency services that expose compute services. Workloads range
from order management, ML for images/traffic analysis/safety, device management
like refrigeration, fryers, etc. [Anthos clusters on Bare Metal](https://cloud.google.com/anthos/clusters/docs/bare-metal) and [Anthos cluster on VMware](https://cloud.google.com/anthos/clusters/docs/on-prem)
are unique solutions for deploying and managing workloads on clusters
distributed across customer data centers and device fleets.
---
### Resources
- _(Quickstart)_ [Deploy this application to a cluster](/docs/quickstart.md)
- _(Anthos VMRuntime)_ [Run the entire application in a VM](/extras/anthos-vmruntime)
#### External use cases of this application
- _(Solution guide)_ [VM based PoS deployed in an Anthos cluster using Anthos VMRuntime](https://github.com/GoogleCloudPlatform/anthos-samples/tree/main/anthos-vmruntime)
- _(Solution guide)_ [Edge deployment of PoS using Anthos on bare metal](https://cloud.google.com/anthos/clusters/docs/bare-metal/latest/installing/install-edge-profile)
- _(Tutorial)_ [PoS deployed in an Anthos bare metal cluster inside Openstack](https://cloud.google.com/anthos/clusters/docs/bare-metal/latest/installing/openstack-abm-install)
---
### Development and Contributing
- Read the [CONTRIBUTING guide](/CONTRIBUTING.md) for instructions on how to contribute
- Follow the [local development guide](/docs/local-dev.md) to learn how to run and develop this app locally
---
### Releases
This repository follows [semantic-versioning](https://semver.org/) to version
its files. Please read [`Releasing a new version of the Point of Sale Application`](/docs/release.md)
for detailed explanation on how to cut a release for this repository.
See the [domain mapping](/docs/domain-mapping.md) guide for information on how
to expose the application using a public domain.
| 0 |
lenve/javaboy-video-samples | null | 2019-08-21T13:39:14Z | null | ## Spring Boot 实战系列视频教程,配套案例
扫码加微信(微信ID:**a_java_boy2**),备注 SpringBoot,进群讨论。
![微信ID:a_java_boy2](https://user-images.githubusercontent.com/6023444/75459026-ba70d500-59b9-11ea-8cbd-3d5889f356c4.png)
本仓库是 Spring Boot 实战系列视频教程官方配套案例,有用的话,欢迎给个 star。(*^_^*)。
案例对应的视频下载地址(付费):链接:https://pan.baidu.com/s/1wbZ4JreJq_D0t29TwDm-1Q 提取码:e5wu
<!--扫码关注公众号【江南一点雨】,回复 Java 获取更多教程。-->
<!--![](https://www.javaboy.org/images/sb/javaboy.jpg)--> | 1 |
gupaoedu-tom/netty4-samples | 《Netty4核心原理与手写RPC框架实战》随书代码示例工程 | 2019-10-26T07:48:17Z | null | # 《Netty4核心原理与手写RPC框架实战》
### 京东购买链接:[https://item.jd.com/12829724.html](https://item.jd.com/12829724.html)
### 当当购买链接:[http://product.dangdang.com/28528192.html](http://product.dangdang.com/28528192.html)
在互联网分布式系统的推动下,Netty是作为一个能够支撑高性能高并发的底层网络通信框架而存在。Netty底层是基于Java NIO来实现的,对NIO进行了非常多的优化,因此深受广大开发者尤其是一线大厂开发者的青睐。
作为一个Java开发人员,如果没有研究过Netty,那么你对Java语言的使用和理解仅仅停留在表面,会点SSH,写几个MVC,访问数据库和缓存,这些只是初级Java程序员干的事。如果你要进阶,想了解Java服务器的深层高阶知识,Netty是一个必须要跨越的门槛。学会了Netty,你可以实现自己的HTTP服务器、FTP服务器、UDP服务器、RPC服务器、WebSocket服务器、Redis的Proxy服务器、MySQL的Proxy服务器等。
★如果你想知道Nginx是怎么写出来的,
★如果你想知道Tomcat和Jetty是如何实现的,
★如果你也想实现一个简单的Redis服务器,
......
那都应该好好研究一下Netty,它们高性能的原理都是类似的。
因为Netty5.x版本已被官方弃用,本书内容基于Netty 4版本来分析其核心原理,培养高级程序员自己造轮子的能力。全书不仅讲述理论知识,并且围绕能够落地的实战场景,开创手写源码的学习方式,使读者学习源码更加高效。本书主要特色是首次提供了基于Netty手写RPC框架,基于Netty手写消息推送系统等实战案例。
# 关于我
### 为什么说我来自文艺界?
我自幼爱好书法和美术,长了一双能书会画的手,而且手指又长又白,因此以前的艺名叫“玉手藝人”。中学期间,曾获市级书法竞赛一等奖,校园美术竞赛一等奖,校园征文比赛二等奖。担任过学生会宣传部长,负责校园黑板报、校园刊物的编辑、排版、设计。
2008年参加工作后,做过家具建模、平面设计等工作,亲自设计了咕泡学院的Logo。做讲师之后,给自己起了一个跟姓氏谐音的英文名字“Tom”,江湖人称“编程界写字写得最好的、书法界编程最牛的文艺汤”。
### 我的技术生涯
我的IT技术生涯应该算是从2009年开始的,在此之前做过UI设计,做过前端网页,到2009年才真正开始参与Java后台开发。在这里要感谢所有帮助过我入门编程的同事和老师。从2010年至2014年担任过项目组长、项目经理、架构师、技术总监,对很多的开源框架建立了自己的独特见解。我会习惯性地用形象思维来理解抽象世界。譬如:看到二进制0和1,我会想到《周易》中的两仪——阴和阳;看到颜色值用RGB表示,我会想到美术理论中的太阳光折射三原色;下班回家看到炒菜流程,我会想到模板方法模式;坐公交车看到学生卡、老人卡、爱心卡,我会想到策略模式;等等。大家看到的这本书,很多地方都融入了这种形象思维。
### 为什么写书?
自2019年《Spring 5核心原理与30个类手写实战》出版以来,深受广大读者喜爱,有些学员将此书作为学习的参考教材。为继续满足大家对技术的追求,借此机会将本人多年对Netty的研究笔记整理成书奉献给各位“汤粉”。
在此,特别感谢责任编辑董英、李秀英及电子社的团队成员的付出,尤其在疫情期间,即使是远程办公也同样坚守岗位审稿至深夜。
# 技术交流
![关注公众号Tom弹架构](https://user-images.githubusercontent.com/54272541/139790847-bbcccc8c-cd5e-4bdc-9b1b-bc923a9d4d99.png)
### 推荐《[Spring5核心原理与30个类手写实战](https://github.com/gupaoedu-tom/spring5-samples)》,4个月销量破万,连续占据畅销榜。
### 推荐《[设计模式就该这样学](https://github.com/gupaoedu-tom/design-samples)》已全面开启预售!!!
| 1 |
PerfectoCode/Samples | Product Samples | 2016-03-20T11:22:24Z | null | ![Perfecto](http://www.perfectomobile.com/sites/all/themes/perfecto/img/logo.png)
# Product Samples
This repository contains official product and code samples for consuming Perfecto services from different supported languages and frameworks.
The following examples are included:
| Sample | Description | Perfecto Documentation |
|----------------|------------------|---------------------|
|Appium |Appium Driver code samples for native applications |[Appium at Perfecto Documentation](http://developers.perfectomobile.com/display/PD/Appium) |
|Cross-Platform |How to test Native applications and Web using Selenium and Appium drivers |[Cross-Platform at Perfecto Documentation](http://developers.perfectomobile.com/display/PD/Cross+Platform+Testing) |
|Methods |Commonly used methods of Selenium and Appium drivers|[Sample method Drag and Drop at our community ](https://community.perfectomobile.com/posts/1160587-drag-and-drop-on-a-desktop-browser) |
|Reporting | Perfecto Reporting - a multiple execution digital report |[Perfecto Reporting](http://developers.perfectomobile.com/display/PD/Reporting) |
|Selenium | Selenium WebDriver code samples for Desktop and Mobile |[Selenium series](http://developers.perfectomobile.com/display/PD/Selenium) |
|Visual-Analysis | Perfecto Visual Analysis - a unique Perfecto functionality for Desktop and Mobile |[Visual Analysis for Desktop at Perfecto Documentation](http://developers.perfectomobile.com/display/PD/Visual+Analysis+for+desktop+Web+testing) |
|Wind Tunnel | Perfecto Wind Tunnel - brings real end-users to the CQ Lab by simulating real end-user scenarios. |[Perfecto Documentation series about Wind Tunnel](http://developers.perfectomobile.com/display/PD/Wind+Tunnel) |
|Windows10 | Perfecto support Microsoft WinAppDriver | [Testing Windows 10 with Perfecto](http://developers.perfectomobile.com/display/PD/Windows+10)
Go to the [PerfectoCode Documentation Portal](http://developers.perfectomobile.com/display/PD/Documentation) for a complete overview of available functionalities.
Visit the [Perfecto Community](https://community.perfectomobile.com/) for an interactive place where you can ask questions, get training materials and more.
| 1 |
kunny/blog_samples | Sample projects provided on blog article | 2013-05-22T01:33:24Z | null | # Blog samples [![Build Status](https://travis-ci.org/kunny/blog_samples.svg?branch=master)](https://travis-ci.org/kunny/blog_samples)
블로그 [커니의 안드로이드 이야기](http://androidhuman.com)에 게재되는 포스트에서 사용한 예제를 제공합니다.
## 예제 프로젝트를 다운로드 하려면?
### git을 사용하여 전체 저장소 다운로드
`Github` 애플리케이션을 사용거나, 터미널에서 다음 명령어를 사용하면 전체 저장소를 다운로드 할 수 있습니다.
$ git clone https://github.com/kunny/blog_samples
### 개별 프로젝트 다운로드
[파이썬 스크립트](https://raw.githubusercontent.com/kunny/blog_samples/master/Android/get_project.py)를 사용하면 일부 프로젝트만 선택하여 다운로드 할 수 있습니다. 스크립트 사용을 위해 미리 설치되어 있어야 하는 구성요소는 다음과 같습니다.
- Python 2.7.5 이상
- Subversion
#### 다운로드 가능한 프로젝트 조회
`python get_project.py` 를 실행하면 스크립트 사용 방법과 함께 다운로드 가능한 프로젝트 정보가 표시됩니다.
$ python get_project.py
Usage : python get_project.py [projectName ...]
Example :
$ python get_project.py HelloWorld // Download one project
$ python get_project.py HelloWorld StudioTesting // Download multiple project
Available projects :
Name Post URL
-----------------------------------------------------------
HelloWorld None
NavigationDrawerExample_Studio http://androidhuman.com/524
AndroidStudioLibApp http://androidhuman.com/530
StudioTesting http://androidhuman.com/536
SigningWithStudio http://androidhuman.com/544
BasicFragments http://androidhuman.com/546
BasicFragments_withActionItem http://androidhuman.com/547
BasicFragments_PersistState http://androidhuman.com/549
#### 프로젝트 다운로드
원하는 프로젝트를 한 개 혹은 여러 개 동시에 다운로드 할 수 있습니다. 한 개의 프로젝트를 다운로드하려면 다음과 같이 프로젝트 이름을 인자로 적어주면 됩니다.
$ python get_project.py HelloWorld
여러 프로젝트를 동시에 다운로드 하려는 경우, 인자에 프로젝트 이름들을 연달아 입력하면 됩니다.
아래는 `HelloWorld` 예제와 `BasicFragments` 예제를 다운로드 하는 예를 보여줍니다.
$ python get_project.py HelloWorld BasicFragments
| 1 |
eclipse-edc/Samples | null | 2022-11-10T12:58:34Z | null | # EDC Samples
This repository provides samples for the Eclipse Dataspace Components (EDC) project, that aim to support the
onboarding process for new community members. The samples are sorted by scope for easy navigation and serve as a
step-by-step guide for getting familiar with the project. The code and a detailed documentation for each sample reside
in the respective module.
## Prerequisites
The samples assume a working knowledge of the **EDC nomenclature**. If you do not know about the EDC nomenclature we
strongly advise reading the [documentation](https://eclipse-edc.github.io/docs/#/) and/or watching the
[introductory videos](https://www.youtube.com/@eclipsedataspaceconnector9622/featured).
Also, a working knowledge of **Git**, **Gradle**, **Java** and **HTTP** is presumed.
We'll assume that you've just checked out the samples code base and have **Java 17+** installed on your development
machine. If not, please download and install JDK 17+ for your OS.
Command examples in this document will use the `bash` syntax and use Unix-style paths, but any other shell should be
fine as well. If you're using Windows you either need to adapt the paths or use WSL2.
## Scopes
The samples are separated by scope, where each scope has a different focus. Depending on what you want to learn more
about, you can choose the scope to look at. More scopes may be added in the future, so be sure to check back regularly.
> **If you are new to the project, it is advisable to start with the `basic` scope. The samples in this scope teach the
> very basics about using the EDC framework, which are presupposed in all other scopes!**
### [Basic](./basic/README.md)
The samples in this scope teach you how to get started with the EDC framework. You will e.g. learn how to set up and run
a connector and how to create your own extensions. What you learn here will be used in all other samples. Click the
link above to learn about the basic samples in more detail.
All basic samples are located in the `basic` directory.
### [Transfer](./transfer/README.md)
This scope revolves around the topic of data transfer. In these samples you will learn how a data transfer works in the
EDC and run different transfer scenarios. Click the link above to learn about the transfer samples in more detail.
All transfer samples are located in the `transfer` directory.
### [Advanced](./advanced/README.md)
Collection of advanced topics regarding the EDC framework.
Click the link above to learn about the transfer samples in more detail.
All transfer samples are located in the `advanced` directory.
### [Policy](./policy/README.md)
These samples deal with the topic of policies and their evaluation and enforcement. They will teach you what
configurations you need to make to enable the evaluation of specific policy rules and constraint and how to provide
custom code for their enforcement.
All policy samples are located in the `policy` directory.
## Contributing
See [how to contribute](https://github.com/eclipse-edc/docs/blob/main/CONTRIBUTING.md).
## License
This project is licensed under the Apache License 2.0 - see [here](LICENSE) for details.
| 0 |
spring-cloud/spring-cloud-dataflow-samples | Sample starter applications and code for use with the Spring Cloud Data Flow project | 2015-12-09T17:48:43Z | null | null | 1 |
temporalio/samples-java | Temporal Java SDK samples | 2019-10-17T16:45:18Z | null | # Temporal Java SDK Samples
This repository contains samples that demonstrate various capabilities of
Temporal using the [Java SDK](https://github.com/temporalio/sdk-java).
It contains two modules:
* [Core](/core): showcases many different SDK features.
* [SpringBoot](/springboot): showcases SpringBoot autoconfig integration.
* [SpringBoot Basic](/springboot-basic): Minimal sample showing SpringBoot autoconfig integration without any extra external dependencies.
## Learn more about Temporal and Java SDK
- [Temporal Server repo](https://github.com/temporalio/temporal)
- [Java SDK repo](https://github.com/temporalio/sdk-java)
- [Java SDK Guide](https://docs.temporal.io/dev-guide/java)
## Requirements
- Java 1.8+ for build and runtime of core samples
- Java 1.8+ for build and runtime of SpringBoot samples when using SpringBoot 2
- Java 1.17+ for build and runtime of Spring Boot samples when using SpringBoot 3
- Local Temporal Server, easiest to get started would be using [Temporal CLI](https://github.com/temporalio/cli).
For more options see docs [here](https://docs.temporal.io/kb/all-the-ways-to-run-a-cluster).
## Build and run tests
1. Clone this repository:
git clone https://github.com/temporalio/samples-java
cd samples-java
2. Build and run Tests
./gradlew build
## Running Samples:
You can run both "Core" and "SpringBoot" samples from the main samples project directory.
Details on how to run each sample can be found in following two sections.
To skip to SpringBoot samples click [here](#Running-SpringBoot-Samples).
### Running "Core" samples
See the README.md file in each main sample directory for cut/paste Gradle command to run specific example.
<!-- @@@SNIPSTART samples-java-readme-samples-directory -->
#### Hello samples
- [**Hello**](/core/src/main/java/io/temporal/samples/hello): This sample includes a number of individual Workflows that can be executed independently. Each one demonstrates something specific.
- [**HelloActivity**](/core/src/main/java/io/temporal/samples/hello/HelloActivity.java): Demonstrates a Workflow Definition that executes a single Activity.
- [**HelloActivityRetry**](/core/src/main/java/io/temporal/samples/hello/HelloActivityRetry.java): Demonstrates how to Retry an Activity Execution.
- [**HelloActivityExclusiveChoice**](/core/src/main/java/io/temporal/samples/hello/HelloActivityExclusiveChoice.java): Demonstrates how to execute Activities based on dynamic input.
- [**HelloAsync**](/core/src/main/java/io/temporal/samples/hello/HelloAsync.java): Demonstrates how to execute Activities asynchronously and wait for them using Promises.
- [**HelloAwait**](/core/src/main/java/io/temporal/samples/hello/HelloAwait.java): Demonstrates how to use Await statement to wait for a condition.
- [**HelloParallelActivity**](/core/src/main/java/io/temporal/samples/hello/HelloParallelActivity.java): Demonstrates how to execute multiple Activities in parallel, asynchronously, and wait for them using `Promise.allOf`.
- [**HelloAsyncActivityCompletion**](/core/src/main/java/io/temporal/samples/hello/HelloAsyncActivityCompletion.java): Demonstrates how to complete an Activity Execution asynchronously.
- [**HelloAsyncLambda**](/core/src/main/java/io/temporal/samples/hello/HelloAsyncLambda.java): Demonstrates how to execute part of a Workflow asynchronously in a separate task (thread).
- [**HelloCancellationScope**](/core/src/main/java/io/temporal/samples/hello/HelloCancellationScope.java): Demonstrates how to explicitly cancel parts of a Workflow Execution.
- [**HelloCancellationScopeWithTimer**](/core/src/main/java/io/temporal/samples/hello/HelloCancellationScopeWithTimer.java): Demonstrates how to cancel activity when workflow timer fires and complete execution. This can prefered over using workflow run/execution timeouts.
- [**HelloDetachedCancellationScope**](/core/src/main/java/io/temporal/samples/hello/HelloDetachedCancellationScope.java): Demonstrates how to execute cleanup code after a Workflow Execution has been explicitly cancelled.
- [**HelloChild**](/core/src/main/java/io/temporal/samples/hello/HelloChild.java): Demonstrates how to execute a simple Child Workflow.
- [**HelloCron**](/core/src/main/java/io/temporal/samples/hello/HelloCron.java): Demonstrates how to execute a Workflow according to a cron schedule.
- [**HelloDynamic**](/core/src/main/java/io/temporal/samples/hello/HelloDynamic.java): Demonstrates how to use `DynamicWorkflow` and `DynamicActivity` interfaces.
- [**HelloPeriodic**](/core/src/main/java/io/temporal/samples/hello/HelloPeriodic.java): Demonstrates the use of the Continue-As-New feature.
- [**HelloException**](/core/src/main/java/io/temporal/samples/hello/HelloException.java): Demonstrates how to handle exception propagation and wrapping.
- [**HelloLocalActivity**](/core/src/main/java/io/temporal/samples/hello/HelloLocalActivity.java): Demonstrates the use of a [Local Activity](https://docs.temporal.io/docs/jargon/mesh/#local-activity).
- [**HelloPolymorphicActivity**](/core/src/main/java/io/temporal/samples/hello/HelloPolymorphicActivity.java): Demonstrates Activity Definitions that extend a common interface.
- [**HelloQuery**](/core/src/main/java/io/temporal/samples/hello/HelloQuery.java): Demonstrates how to Query the state of a Workflow Execution.
- [**HelloSchedules**](/core/src/main/java/io/temporal/samples/hello/HelloSchedules.java): Demonstrates how to create and interact with a Schedule.
- [**HelloSignal**](/core/src/main/java/io/temporal/samples/hello/HelloSignal.java): Demonstrates how to send and handle a Signal.
- [**HelloSaga**](/core/src/main/java/io/temporal/samples/hello/HelloSaga.java): Demonstrates how to use the SAGA feature.
- [**HelloSearchAttributes**](/core/src/main/java/io/temporal/samples/hello/HelloSearchAttributes.java): Demonstrates how to add custom Search Attributes to Workflow Executions.
- [**HelloSideEffect**](/core/src/main/java/io/temporal/samples/hello/HelloSideEffect.java)**: Demonstrates how to implement a Side Effect.
- [**HelloUpdate**](/core/src/main/java/io/temporal/samples/hello/HelloUpdate.java): Demonstrates how to create and interact with an Update.
- [**HelloDelayedStart**](/core/src/main/java/io/temporal/samples/hello/HelloDelayedStart.java): Demonstrates how to use delayed start config option when starting a Workflow Executions.
- [**HelloSignalWithTimer**](/core/src/main/java/io/temporal/samples/hello/HelloSignalWithTimer.java): Demonstrates how to use collect signals for certain amount of time and then process last one.
#### Scenario-based samples
- [**File Processing Sample**](/core/src/main/java/io/temporal/samples/fileprocessing): Demonstrates how to route tasks to specific Workers. This sample has a set of Activities that download a file, processes it, and uploads the result to a destination. Any Worker can execute the first Activity. However, the second and third Activities must be executed on the same host as the first one.
- [**Booking SAGA**](/core/src/main/java/io/temporal/samples/bookingsaga): Demonstrates Temporals take on the Camunda BPMN "trip booking" example.
- [**Money Transfer**](/core/src/main/java/io/temporal/samples/moneytransfer): Demonstrates the use of a dedicated Activity Worker.
- [**Money Batch**](/core/src/main/java/io/temporal/samples/moneybatch): Demonstrates a situation where a single deposit should be initiated for multiple withdrawals. For example, a seller might want to be paid once per fixed number of transactions. This sample can be easily extended to perform a payment based on more complex criteria, such as at a specific time or an accumulated amount. The sample also demonstrates how to Signal the Workflow when it executes (*Signal with start*). If the Workflow is already executing, it just receives the Signal. If it is not executing, then the Workflow executes first, and then the Signal is delivered to it. *Signal with start* is a "lazy" way to execute Workflows when Signaling them.
- [**Customer Application Approval DSL**](/core/src/main/java/io/temporal/samples/dsl): Demonstrates execution of a customer application approval workflow defined in a DSL (like JSON or YAML)
- [**Polling Services**](/core/src/main/java/io/temporal/samples/polling): Recommended implementation of an activity that needs to periodically poll an external resource waiting its successful completion
- [**Heartbeating Activity Batch**](/core/src/main/java/io/temporal/samples/batch/heartbeatingactivity): Batch job implementation using a heartbeating activity.
- [**Iterator Batch**](/core/src/main/java/io/temporal/samples/batch/iterator): Batch job implementation using the workflow iterator pattern.
- [**Sliding Window Batch**](/core/src/main/java/io/temporal/samples/batch/slidingwindow): A batch implementation that maintains a configured number of child workflows during processing.
#### API demonstrations
- [**Async Untyped Child Workflow**](/core/src/main/java/io/temporal/samples/asyncuntypedchild): Demonstrates how to invoke an untyped child workflow async, that can complete after parent workflow is already completed.
- [**Updatable Timer**](/core/src/main/java/io/temporal/samples/updatabletimer): Demonstrates the use of a helper class which relies on `Workflow.await` to implement a blocking sleep that can be updated at any moment.
- [**Workflow Count Interceptor**](/core/src/main/java/io/temporal/samples/countinterceptor): Demonstrates how to create and register a simple Workflow Count Interceptor.
-
- [**Workflow Retry On Signal Interceptor**](/core/src/main/java/io/temporal/samples/retryonsignalinterceptor): Demonstrates how to create and register an interceptor that retries an activity on a signal.
- [**List Workflows**](/core/src/main/java/io/temporal/samples/listworkflows): Demonstrates the use of custom search attributes and ListWorkflowExecutionsRequest with custom queries.
- [**Payload Converter - CloudEvents**](/core/src/main/java/io/temporal/samples/payloadconverter/cloudevents): Demonstrates the use of a custom payload converter for CloudEvents.
- [**Payload Converter - Crypto**](/core/src/main/java/io/temporal/samples/payloadconverter/crypto): Demonstrates the use of a custom payload converter using jackson-json-crypto.
- [**Async Child Workflow**](/core/src/main/java/io/temporal/samples/asyncchild): Demonstrates how to invoke a child workflow async, that can complete after parent workflow is already completed.
- [**Terminate Workflow**](/core/src/main/java/io/temporal/samples/terminateworkflow): Demonstrates how to terminate a workflow using client API.
- [**Get Workflow Results Async**](/core/src/main/java/io/temporal/samples/getresultsasync): Demonstrates how to start and get workflow results in async manner.
- [**Per Activity Type Options**](/core/src/main/java/io/temporal/samples/peractivityoptions): Demonstrates how to set per Activity type options.
- [**Configure WorkflowClient to use mTLS**](/core/src/main/java/io/temporal/samples/ssl): Demonstrates how to configure WorkflowClient when using mTLS.
- [**Payload Codec**](/core/src/main/java/io/temporal/samples/encodefailures): Demonstrates how to use simple codec to encode/decode failure messages.
#### SDK Metrics
- [**Set up SDK metrics**](/core/src/main/java/io/temporal/samples/metrics): Demonstrates how to set up and scrape SDK metrics.
#### Tracing Support
- [**Set up OpenTracing and/or OpenTelemetry with Jaeger**](/core/src/main/java/io/temporal/samples/tracing): Demonstrates how to set up OpenTracing and/or OpenTelemetry and view traces using Jaeger.
<!-- @@@SNIPEND -->
### Running SpringBoot Samples
These samples use SpringBoot 2 by default. To switch to using SpringBoot 3 look at the [gradle.properties](gradle.properties) file
and follow simple instructions there.
1. Start SpringBoot from main repo dir:
./gradlew :springboot:bootRun
To run the basic sample run
./gradlew :springboot-basic:bootRun
2. Navigate to [localhost:3030](http://localhost:3030)
3. Select which sample you want to run
More info on each sample:
- [**Hello**](/springboot/src/main/java/io/temporal/samples/springboot/hello): Invoke simple "Hello" workflow from a GET endpoint
- [**SDK Metrics**](/springboot/src/main/java/io/temporal/samples/springboot/metrics): Learn how to set up SDK Metrics
- [**Synchronous Update**](/springboot/src/main/java/io/temporal/samples/springboot/update): Learn how to use Synchronous Update feature with this purchase sample
- [**Kafka Request / Reply**](/springboot/src/main/java/io/temporal/samples/springboot/kafka): Sample showing possible integration with event streaming platforms such as Kafka
- [**Customize Options**](/springboot/src/main/java/io/temporal/samples/springboot/customize): Sample showing how to customize options such as WorkerOptions, WorkerFactoryOptions, etc (see options config [here](springboot/src/main/java/io/temporal/samples/springboot/customize/TemporalOptionsConfig.java))
- [**Apache Camel Route**](/springboot/src/main/java/io/temporal/samples/springboot/camel): Sample showing how to start Workflow execution from a Camel Route
#### Temporal Cloud
To run any of the SpringBoot samples in your Temporal Cloud namespace:
1. Edit the [application-tc.yaml](/springboot/src/main/resources/application-tc.yaml) to set your namespace and client certificates.
2. Start SpringBoot from main repo dir with the `tc` profile:
./gradlew bootRun --args='--spring.profiles.active=tc'
3. Follow the previous section from step 2
| 1 |
Coder-EdisonZhou/EDT.SpringCloud.Samples | Spring Cloud作为第二代微服务的代表性框架,已经在国内众多大中小型的公司有实际应用案例。许多公司的业务线全部拥抱Spring Cloud,部分公司选择部分拥抱Spring Cloud。此示例基于Spring Boot 1.5.x编写,展示了Spring Cloud的核心组件的基本使用方式,在学习Spring Cloud时可以参考本示例。 | 2018-08-27T06:12:40Z | null | # EDC.SpringCloud.Samples
## 温馨提示
本示例基于Spring Boot 1.5.x实现,如对Spring Boot不熟悉,可以先学习我的这一篇:《[Spring Boot 1.5.x 基础学习示例](https://www.cnblogs.com/edisonchou/p/java_spring_boot_foundation_demos.html)》。关于微服务基本概念不了解的童鞋,可以先阅读下始祖Martin Fowler的《[Microservice](https://mp.weixin.qq.com/s/fzk-kENu0I22P3F2Vu7KBA)》,本文不做介绍和描述。
本示例配套介绍博文请[点击这里](https://www.cnblogs.com/edisonchou/p/java_spring_cloud_foundation_sample_list.html)。
## Spring Cloud基本介绍
<img src="https://images2018.cnblogs.com/blog/381412/201808/381412-20180822202553841-1217264857.jpg" style="border: 1px solid #ddd; border-radius: 5px;" alt="Spring Cloud微服务实战"/>
首先,尽管Spring Cloud带有“Cloud”这个单词,但它并不是云计算解决方案,而是在Spring Boot基础之上构建的,用于快速构建分布式系统的通用模式的工具集。<br/>
其次,使用Spring Cloud开发的应用程序非常适合在Docker和PaaS(比如Pivotal Cloud Foundry)上部署,所以又叫做云原生应用(Cloud Native Application)。云原生可以简单地理解为面向云环境的软件架构。<br/>
总结,***Spring Cloud是一个基于Spring Boot实现的云原生应用开发工具,它为基于JVM的云原生应用开发中涉及的配置管理、服务发现、熔断器、智能路由、微代理、控制总线、分布式会话和集群状态管理等操作提供了一种简单的开发方式***。
## Spring Cloud核心子项目
- Spring Cloud Netflix:核心组件,可以对多个Netflix OSS开源套件进行整合,包括以下几个组件:
- Eureka:服务治理组件,包含服务注册与发现
- Hystrix:容错管理组件,实现了熔断器
- Ribbon:客户端负载均衡的服务调用组件
- Feign:基于Ribbon和Hystrix的声明式服务调用组件
- Zuul:网关组件,提供智能路由、访问过滤等功能
- Archaius:外部化配置组件
- Spring Cloud Config:配置管理工具,实现应用配置的外部化存储,支持客户端配置信息刷新、加密/解密配置内容等。
- Spring Cloud Bus:事件、消息总线,用于传播集群中的状态变化或事件,以及触发后续的处理
- Spring Cloud Security:基于spring security的安全工具包,为我们的应用程序添加安全控制
- Spring Cloud Consul : 封装了Consul操作,Consul是一个服务发现与配置工具(与Eureka作用类似),与Docker容器可以无缝集成
- ......
## 示例环境版本
- **Java** : JDK & JRE 1.8 8u151
- **Spring Boot** : 1.5.15.RELEASE
- **Spring Cloud** : Edgware.SR3 (`PS`:Spring Cloud的版本命名是以伦敦地铁站的名字来命名的)
## 示例简要说明
- 服务注册与发现(基于Eureka) :
[part1_service-register-discovery](https://github.com/EdisonChou/EDC.SpringCloud.Samples/tree/master/src/part1_service-register-discovery)
- 客户端负载均衡(基于Ribbon) :
[part2_client-load-balance](https://github.com/EdisonChou/EDC.SpringCloud.Samples/tree/master/src/part2_client-load-balance)
- 声明式REST调用(基于Feign) :
[part3_feign](https://github.com/EdisonChou/EDC.SpringCloud.Samples/tree/master/src/part3_feign)
- 容错处理(基于Hystrix) :
[part4_hystrix](https://github.com/EdisonChou/EDC.SpringCloud.Samples/tree/master/src/part4_hystrix)
- API网关(基于Zuul) :
[part5_zuul](https://github.com/EdisonChou/EDC.SpringCloud.Samples/tree/master/src/part5_zuul)
- 统一配置管理(基于Spring Cloud Config) :
[part6_config](https://github.com/EdisonChou/EDC.SpringCloud.Samples/tree/master/src/part6_config)
- 微服务跟踪(基于Spring Cloud Sleuth) :
[part7_sleuth](https://github.com/EdisonChou/EDC.SpringCloud.Samples/tree/master/src/part7_sleuth)
- Spring Cloud on Docker与Docker Compose编排微服务 :
[Java微服务之Spring Boot on Docker(Docker Compose编排Spring Cloud微服务)](https://www.cnblogs.com/edisonchou/p/springboot_on_docker_foundation.html)
## 推荐学习资料
`PS`:下面资料都是我们项目组新同事以及老同事(.Net技术背景)所采用的学习资料,并不保证适合于所有人。本示例主要也主要是基于下面的资料而写的sample code。<br/>
<img src="https://www.cnblogs.com/images/cnblogs_com/edisonchou/1288702/o_eBook2.jpg" style="border: 1px solid #ddd; border-radius: 5px;" alt="Spring Cloud与Docker微服务架构实战"/>
<img src="https://www.cnblogs.com/images/cnblogs_com/edisonchou/1288702/o_eBook1.jpg" style="border: 1px solid #ddd; border-radius: 5px;" alt="Spring Cloud微服务实战"/>
> 周立 Spring Cloud与Docker微服务架构实战:https://book.douban.com/subject/30278673/<br/>
> 程序猿DD SpringCloud基础教程(Dalston版本),Spring Cloud微服务实战:http://blog.didispace.com/Spring-Cloud%E5%9F%BA%E7%A1%80%E6%95%99%E7%A8%8B/<br/>
> 纯洁的微笑 SpringCloud系列教程:http://www.ityouknow.com/spring-cloud
## 推荐开发环境
<img src="https://timgsa.baidu.com/timg?image&quality=80&size=b9999_10000&sec=1533644040260&di=f5ef1cf27c43f744cc8fbac384bfd0e9&imgtype=0&src=http%3A%2F%2Fimage.bubuko.com%2Finfo%2F201808%2F20180801214347937731.png" style="border: 1px solid #ddd; border-radius: 5px;" alt="Intellij Idea 2018"/>
> Intellij Idea Community 2018版本<br/>
<br/>
<img src="https://www.cnblogs.com/images/cnblogs_com/edisonchou/1288702/o_alibaba_plugin.jpg" style="border: 1px solid #ddd; border-radius: 5px;" alt="阿里巴巴代码规约"/>
> 阿里巴巴代码规约插件<br/>
## 参考博文
[Spring Cloud微服务架构基础学习与示例](https://www.cnblogs.com/edisonchou/p/java_spring_cloud_foundation_sample_list.html)<br/>
[Java微服务之Spring Boot on Docker(Docker Compose编排Spring Cloud微服务)](https://www.cnblogs.com/edisonchou/p/springboot_on_docker_foundation.html)
| 0 |