spring-boot-patterns
БесплатноБез исполняемых скриптовНе проверенSpring Boot patterns for Xeres including constructor injection, @Transactional boundaries, REST controllers with OpenAPI annotations, and reactive WebClient…
от zapek★ 224 звезды на GitHubОб этом скилле
Spring Boot Patterns for Xeres
Application Entry Point
@SpringBootApplication(scanBasePackageClasses = {
io.xeres.app.XeresApplication.class,
io.xeres.ui.UiStarter.class
})
public class XeresApplication
{
}
Service Patterns
Constructor Injection
Always use constructor injection. Dependencies are final.
@Service
public class ContactService
{
private final ProfileService profileService;
private final LocationService locationService;
public ContactService(ProfileService profileService, LocationService locationService)
{
this.profileService = profileService;
this.locationService = locationService;
}
}
Transactional Boundaries
@Transactional(readOnly = true)
public List<Contact> getContacts()
{
}
@Transactional
public void saveContact(Contact contact)
{
}
Circular Dependencies
Use @Lazy annotation, but avoid them if possible:
public ContactService(@Lazy ProfileService profileService)
{
}
REST Controllers
OpenAPI Annotations
@RestController
@Tag(name = "Profiles", description = "Profile management")
public class ProfileController
{
@GetMapping("/{id}")
@Operation(summary = "Get profile by ID")
@ApiResponse(responseCode = "200", description = "Profile found")
public ResponseEntity<ProfileDTO> getProfile(@PathVariable long id)
{
}
}
Exception Handling
Use custom exceptions with appropriate HTTP status codes.
Reactive WebClient Clients (UI Module)
@Component
public class ProfileClient
{
private WebClient webClient;
@EventListener
public void init(StartupEvent event)
{
webClient = webClientBuilder.clone()
.baseUrl(RemoteUtils.getControlUrl() + PROFILES_PATH)
.build();
}
public Mono<Profile> findById(long id)
{
return webClient.get()
.uri("/{id}", id)
.retrieve()
.bodyToMono(Profile.class);
}
}
Configuration Classes
Use @Configuration for feature-specific beans. Keep @Bean methods small and focused.
Testing Services
See junit-testing skill for testing patterns with mocks.
Установить spring-boot-patterns в Claude Code и Claude Desktop
Зарегайся, чтобы установить скилл
Создай бесплатный аккаунт, чтобы открыть команду установки и сохранить скилл в библиотеку.
- Открой команду установки в одну строку
- Сохраняй скиллы в синхронизируемую библиотеку
- Уведомления, когда скиллы обновляются
Разрешённые инструменты
Инструменты, которые скиллу разрешено вызывать.
Без ограничений — скилл может использовать любой инструмент.
FAQ
Что делает скилл spring-boot-patterns?
Spring Boot patterns for Xeres including constructor injection, @Transactional boundaries, REST controllers with OpenAPI annotations, and reactive WebClient usage in the UI module.
Как установить скилл spring-boot-patterns?
Скопируй папку скилла в ~/.claude/skills (вкладка Claude Code выше делает это одной командой), либо поставь как плагин.
Скилл spring-boot-patterns запускает скрипты?
Нет, скилл состоит только из инструкций (SKILL.md), без исполняемых скриптов.
Похожие скиллы
frontend-design
Guidance for distinctive, intentional visual design when building new UI or reshaping an existing one. Helps with aesthetic direction, typography, and making…
от Anthropicwebapp-testing
Toolkit for interacting with and testing local web applications using Playwright. Supports verifying frontend functionality, debugging UI behavior, capturing…
от Anthropicbrand-guidelines
Applies Anthropic's official brand colors and typography to any sort of artifact that may benefit from having Anthropic's look-and-feel. Use it when brand…
от Anthropicweb-artifacts-builder
Suite of tools for creating elaborate, multi-component claude.ai HTML artifacts using modern frontend web technologies (React, Tailwind CSS, shadcn/ui). Use…
от Anthropic