package sklep.dodatki;

import io.quarkus.runtime.Startup;
import jakarta.annotation.PostConstruct;
import jakarta.annotation.PreDestroy;
import jakarta.enterprise.context.ApplicationScoped;
import org.slf4j.Logger;
import org.slf4j.LoggerFactory;

@Startup
@ApplicationScoped
public class StartEnd {
    private static final Logger log = LoggerFactory.getLogger(StartEnd.class);

    {
        System.out.println("konstrukcja StartEnd");
    }

    @PostConstruct
    public void start() {
        log.info("StartEnd @PostConstruct");
        System.out.println("startujemy");
    }

    @PreDestroy
    public void end() {
        System.out.println("kończymy");
    }
}
