æè¿ãSpring Bootããã£ã¤ãåå¼·ããæ©ä¼ãããã¾ããã Javaã®è¨èªä»æ§ããã¦ãªãã¨ãããããªã¼ãªã©ã¨æãã¤ã¤ããSpring Bootãã£ã¡ããããªã¼ã好ãã ãªã¼ã¨ãªã£ã¦ã¾ããã Spring Bootã®ä¸ã§ãä¸éç§ã®å¿ãæ´ãã ã®ã¯@Transactionalã§ããã ãããªæãã§ãã©ã³ã¶ã¯ã·ã§ã³ãã§ãã¾ãã @Repository public class UserDao { @Autowired private UserMapper userMapper; @Transactional public List<User> selectAll() { return this.userMapper.selectAll(); } @Transactional public void create(User user) { this.userMapper.create(user)
{{#tags}}- {{label}}
{{/tags}}