# @Configuration

A class annotated with the `@Configuration` annotation can contain bean definition methods annotated with [the `@Bean` annotation](https://flinn-burgess.gitbook.io/flinn-s-knowledge-base/tech/java/spring/bean). This marks it to be processed by Spring to generate bean definitions and service requests for those beans at runtime.

```
@Configuration
public class AppConfig {

    @Bean
    public MyBean myBean() {
        // instantiate, configure and return bean ...
    }
}
```
