feat: 게시글 인라인 이미지 서버 업로드(DB 저장) — base64 대체
CI / build (push) Failing after 15m30s

- board_image 테이블 + BoardImageController/Service/Mapper
  · POST /api/board/images(로그인) → {url:/api/images/{id}}
  · GET  /api/images/{id}(공개, img src 로 로드) — 1년 캐시
- 본문엔 짧은 URL 만 들어가 글이 비대해지지 않음

Co-Authored-By: Claude Opus 4.8 <noreply@anthropic.com>
This commit is contained in:
ByungCheol
2026-06-07 19:17:25 +09:00
parent 2da43b2f77
commit f9abd0c989
6 changed files with 159 additions and 0 deletions
@@ -0,0 +1,18 @@
<?xml version="1.0" encoding="UTF-8"?>
<!DOCTYPE mapper PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN"
"https://mybatis.org/dtd/mybatis-3-mapper.dtd">
<mapper namespace="com.sb.web.board.mapper.BoardImageMapper">
<insert id="insert" parameterType="com.sb.web.board.domain.BoardImage"
useGeneratedKeys="true" keyProperty="id">
INSERT INTO board_image (member_id, content_type, data, byte_size, created_at)
VALUES (#{memberId}, #{contentType}, #{data}, #{byteSize}, NOW())
</insert>
<select id="findById" resultType="com.sb.web.board.domain.BoardImage">
SELECT id, member_id, content_type, data, byte_size, created_at
FROM board_image
WHERE id = #{id}
</select>
</mapper>