diff --git a/Writerside/c.list b/Writerside/c.list new file mode 100644 index 0000000..c4c77a2 --- /dev/null +++ b/Writerside/c.list @@ -0,0 +1,6 @@ + + + + + \ No newline at end of file diff --git a/Writerside/cfg/buildprofiles.xml b/Writerside/cfg/buildprofiles.xml new file mode 100644 index 0000000..5f12791 --- /dev/null +++ b/Writerside/cfg/buildprofiles.xml @@ -0,0 +1,17 @@ + + + + + + + + + true + + + + diff --git a/Writerside/images/completion_procedure.png b/Writerside/images/completion_procedure.png new file mode 100644 index 0000000..3535a3f Binary files /dev/null and b/Writerside/images/completion_procedure.png differ diff --git a/Writerside/images/completion_procedure_dark.png b/Writerside/images/completion_procedure_dark.png new file mode 100644 index 0000000..a65beb0 Binary files /dev/null and b/Writerside/images/completion_procedure_dark.png differ diff --git a/Writerside/images/convert_table_to_xml.png b/Writerside/images/convert_table_to_xml.png new file mode 100644 index 0000000..2518a64 Binary files /dev/null and b/Writerside/images/convert_table_to_xml.png differ diff --git a/Writerside/images/convert_table_to_xml_dark.png b/Writerside/images/convert_table_to_xml_dark.png new file mode 100644 index 0000000..4716122 Binary files /dev/null and b/Writerside/images/convert_table_to_xml_dark.png differ diff --git a/Writerside/images/new_topic_options.png b/Writerside/images/new_topic_options.png new file mode 100644 index 0000000..bc6abb6 Binary files /dev/null and b/Writerside/images/new_topic_options.png differ diff --git a/Writerside/images/new_topic_options_dark.png b/Writerside/images/new_topic_options_dark.png new file mode 100644 index 0000000..bf3e48d Binary files /dev/null and b/Writerside/images/new_topic_options_dark.png differ diff --git a/Writerside/sb.tree b/Writerside/sb.tree new file mode 100644 index 0000000..ec29606 --- /dev/null +++ b/Writerside/sb.tree @@ -0,0 +1,32 @@ + + + + + + + + + + + + + + + + + + + + + + + + + + \ No newline at end of file diff --git a/Writerside/sbe.tree b/Writerside/sbe.tree new file mode 100644 index 0000000..231e928 --- /dev/null +++ b/Writerside/sbe.tree @@ -0,0 +1,10 @@ + + + + + + + \ No newline at end of file diff --git a/Writerside/topics/Actuator.md b/Writerside/topics/Actuator.md new file mode 100644 index 0000000..ab0cf93 --- /dev/null +++ b/Writerside/topics/Actuator.md @@ -0,0 +1,3 @@ +# Actuator + +Start typing here... \ No newline at end of file diff --git a/Writerside/topics/Controller.md b/Writerside/topics/Controller.md new file mode 100644 index 0000000..50bc9e5 --- /dev/null +++ b/Writerside/topics/Controller.md @@ -0,0 +1,19 @@ +# Controller + +## URI 맵핑 + +* @Controller +* @RestController +* @RequestMapping +* @GetMapping +* @PostMapping +* @PutMapping +* @DeleteMapping + + +## 매개변수 + +* @PathVariable +* @RequestParam +* @RequestBody + diff --git a/Writerside/topics/Database.md b/Writerside/topics/Database.md new file mode 100644 index 0000000..6355488 --- /dev/null +++ b/Writerside/topics/Database.md @@ -0,0 +1,26 @@ +# Database + +## 설정 + +```yaml +spring: + datasource: + driverClassName: org.mariadb.jdbc.Driver + url: jdbc:mariadb://localhost:3306/mydb + username: root + password: password + jpa: + hibernate: + ddl-auto: create + show-sql: true + properties: + hibernate: + format_sql: true +``` + +### DDL Auto +* create : 애플리케이션이 실행되고, SessionFactory가 실행될 때, 기존의 테이블을 지우고 새로운 테이블을 생성합니다. +* create-drop : 'create'와 유사하지만, 애플리케이션 종료 시점에 테이블을 지웁니다. +* update : SessionFactory가 실행될 때, 객체를 검사한 다음, 변경된 스키마를 갱신합니다. 기존의 데이터는 유지됩니다. +* validate : 'update'와 유사하게 객체를 검사하지만, 스키마를 변경하지 않으며, 테이블 구조가 수정된 경우에는 에러가 발생합니다. +* none : dll-auto 기능을 사용하지 않습니다. \ No newline at end of file diff --git a/Writerside/topics/JPA.md b/Writerside/topics/JPA.md new file mode 100644 index 0000000..1710093 --- /dev/null +++ b/Writerside/topics/JPA.md @@ -0,0 +1,3 @@ +# JPA + +Start typing here... \ No newline at end of file diff --git a/Writerside/topics/JPQL.md b/Writerside/topics/JPQL.md new file mode 100644 index 0000000..679a851 --- /dev/null +++ b/Writerside/topics/JPQL.md @@ -0,0 +1,3 @@ +# JPQL + +JPQL은 맵핑된 엔티티 객체를 대상으로 수행되므로, 쿼리문에는 엔티티의 이름과 필드의 이름을 사용합니다. \ No newline at end of file diff --git a/Writerside/topics/JWT.md b/Writerside/topics/JWT.md new file mode 100644 index 0000000..aff5f6c --- /dev/null +++ b/Writerside/topics/JWT.md @@ -0,0 +1,3 @@ +# JWT + +Start typing here... \ No newline at end of file diff --git a/Writerside/topics/Modeling.md b/Writerside/topics/Modeling.md new file mode 100644 index 0000000..bb8cc47 --- /dev/null +++ b/Writerside/topics/Modeling.md @@ -0,0 +1,32 @@ +# Modeling + +## 어노태이션 + +* @Entity : 해당 클래스가 엔티티임을 명시합니다. +* @Table : 클래스의 이름과 테이블의 이름을 다르게 지정해야 할 경우에 사용합니다. + * name + +* @Id : 테이블의 기본키를 지정합니다. 모든 엔티티는 @Id가 필요합니다. +* @GeneratedValue : 일반적으로 @Id와 함께 사용됩니다. 해당 필드의 값을 자동으로 생성하는 방식을 지정합니다. + * strategy + +* @Column : 테이블의 칼럼으로 맵핑됩니다. + * name : 데이터베이스의 칼럼명을 지정합니다. + * unique : 고유키로 지정합니다. + * nullable : 널 처리 가능여부를 지정합니다. + * insertable + * updatable + * columnDefinition + * table + * length : 데이터의 최대 길이를 지정합니다. + * precision + * scale +* @Transient : 클래스에는 선언되어 있지만, 데이터베이스에는 필요 없는 경우에 지정합니다. + + + +### GenerationType +* AUTO : 사용하는 데이터베이스에 맞게 자동으로 생성합니다. +* IDENTITY : AUTI_INCREMENT를 사용해서, 데이터베이스가 알아서 생성하도록 합니다. +* SEQUENCE : @SequenceGenerator로 지정된 식별자 생성기를 통해서 값을 주입받습니다. +* TABLE : @TableGenerator를 사용해서 별도의 테이블에 값을 저장합니다. \ No newline at end of file diff --git a/Writerside/topics/Paging.md b/Writerside/topics/Paging.md new file mode 100644 index 0000000..f8753fd --- /dev/null +++ b/Writerside/topics/Paging.md @@ -0,0 +1,3 @@ +# Paging + +Start typing here... \ No newline at end of file diff --git a/Writerside/topics/Repository.md b/Writerside/topics/Repository.md new file mode 100644 index 0000000..89800dd --- /dev/null +++ b/Writerside/topics/Repository.md @@ -0,0 +1,33 @@ +# Repository + +JpaRepository > PagingAndSortingRepository > CrudRepository > Repository + +## JpaRepository + +```java +@Repository +public interface MyRepository extends JpaRepository { + +} +``` + + +## 메서드 이름 규칙 + +* findBy, readBy, getBy, queryBu, searchBy, streamBy +* and, or +* isLike, isNotLike +* is, isNot +* startsWith, isStartingWith +* endsWith, isEndingWith +* contains, isContaining +* isNull, isNotNull +* isTrue, isFalse +* before, after +* isLessThan, isGreaterThan +* isBetween +* orderBy +* first, top +* countBy +* existsBy +* deleteBy, removeBy \ No newline at end of file diff --git a/Writerside/topics/Security.md b/Writerside/topics/Security.md new file mode 100644 index 0000000..c2b5e3d --- /dev/null +++ b/Writerside/topics/Security.md @@ -0,0 +1,3 @@ +# Security + +Start typing here... \ No newline at end of file diff --git a/Writerside/topics/Swagger.md b/Writerside/topics/Swagger.md new file mode 100644 index 0000000..13b55f8 --- /dev/null +++ b/Writerside/topics/Swagger.md @@ -0,0 +1,38 @@ +# Swagger + +## 설정 + +### 의존성 추가 +```kotlin +implementation("io.springfox:springfox-swagger2:2.9.2") +implementation("io.springfox:springfox-swagger-ui:2.9.2") + +``` + +### 설정 코드 추가 + +```java +import jdk.javadoc.doclet.Doclet; + +import java.beans.BeanProperty; + +@Configuration +@EnableSwagger2 +public class MyConfiguration { + @Bean + public Doclet api(){ + return new Docket(DocumentationType.SWAGGER_2) + ... + .build(); + } +} +``` + +## 어노태이션 + +* @ApiOperation : 해당 API에 대한 설정을 작성합니다. + * value + * notes +* @ApiParam : 해당 API의 매개변수에 대한 설명 및 설정을 지정합니다. + * value + * required diff --git a/Writerside/topics/Testing.md b/Writerside/topics/Testing.md new file mode 100644 index 0000000..154d01b --- /dev/null +++ b/Writerside/topics/Testing.md @@ -0,0 +1,3 @@ +# Testing + +Start typing here... \ No newline at end of file diff --git a/Writerside/topics/Validation.md b/Writerside/topics/Validation.md new file mode 100644 index 0000000..9142e54 --- /dev/null +++ b/Writerside/topics/Validation.md @@ -0,0 +1,3 @@ +# Validation + +Start typing here... \ No newline at end of file diff --git a/Writerside/topics/starter-topic.md b/Writerside/topics/starter-topic.md new file mode 100644 index 0000000..3d8afee --- /dev/null +++ b/Writerside/topics/starter-topic.md @@ -0,0 +1 @@ +# Spring Boot diff --git a/Writerside/v.list b/Writerside/v.list new file mode 100644 index 0000000..2d12cb3 --- /dev/null +++ b/Writerside/v.list @@ -0,0 +1,5 @@ + + + + + diff --git a/Writerside/writerside.cfg b/Writerside/writerside.cfg new file mode 100644 index 0000000..9ad24bb --- /dev/null +++ b/Writerside/writerside.cfg @@ -0,0 +1,13 @@ + + + + + + + + + + \ No newline at end of file diff --git a/build.gradle.kts b/build.gradle.kts index b709b7d..3770a65 100644 --- a/build.gradle.kts +++ b/build.gradle.kts @@ -12,7 +12,7 @@ buildscript { } } dependencies { - classpath ("com.jaredsburrows:gradle-license-plugin:0.8.90") + classpath ("com.jaredsburrows:gradle-license-plugin:0.9.7") } } plugins { diff --git a/buildSrc/src/main/kotlin/elex-base.gradle.kts b/buildSrc/src/main/kotlin/elex-base.gradle.kts index 3b033ff..1b798df 100644 --- a/buildSrc/src/main/kotlin/elex-base.gradle.kts +++ b/buildSrc/src/main/kotlin/elex-base.gradle.kts @@ -71,6 +71,6 @@ tasks.javadoc { dependencies { - implementation("org.jetbrains:annotations:24.0.0") + implementation("org.jetbrains:annotations:24.1.0") } diff --git a/buildSrc/src/main/kotlin/elex-spring-boot.gradle.kts b/buildSrc/src/main/kotlin/elex-spring-boot.gradle.kts index 7377f79..dbbc3c6 100644 --- a/buildSrc/src/main/kotlin/elex-spring-boot.gradle.kts +++ b/buildSrc/src/main/kotlin/elex-spring-boot.gradle.kts @@ -12,6 +12,6 @@ plugins { } dependencies{ - //implementation("org.jetbrains:annotations:24.0.0") + //implementation("org.jetbrains:annotations:24.1.0") } diff --git a/gradle/wrapper/gradle-wrapper.properties b/gradle/wrapper/gradle-wrapper.properties index 7214b44..92c9322 100644 --- a/gradle/wrapper/gradle-wrapper.properties +++ b/gradle/wrapper/gradle-wrapper.properties @@ -7,6 +7,6 @@ distributionBase=GRADLE_USER_HOME distributionPath=wrapper/dists -distributionUrl=https\://services.gradle.org/distributions/gradle-8.0.1-all.zip +distributionUrl=https\://services.gradle.org/distributions/gradle-8.7-all.zip zipStoreBase=GRADLE_USER_HOME zipStorePath=wrapper/dists \ No newline at end of file diff --git a/security-with-jwt/build.gradle.kts b/security-with-jwt/build.gradle.kts index adfc72c..85f577a 100644 --- a/security-with-jwt/build.gradle.kts +++ b/security-with-jwt/build.gradle.kts @@ -14,11 +14,11 @@ plugins { dependencies { // https://mvnrepository.com/artifact/io.jsonwebtoken/jjwt-api - implementation("io.jsonwebtoken:jjwt-api:0.11.2") + implementation("io.jsonwebtoken:jjwt-api:0.12.5") // https://mvnrepository.com/artifact/io.jsonwebtoken/jjwt-impl - runtimeOnly("io.jsonwebtoken:jjwt-impl:0.11.2") - runtimeOnly("io.jsonwebtoken:jjwt-jackson:0.11.2") + runtimeOnly("io.jsonwebtoken:jjwt-impl:0.12.5") + runtimeOnly("io.jsonwebtoken:jjwt-jackson:0.12.5") implementation("org.springframework.boot:spring-boot-starter-mustache") implementation("org.springframework.boot:spring-boot-starter-web")