ããã°ãã¯ãä¸å°¾ã§ãã ãç¦å²¡ãªãã©ã¤ã³éå¬ãJJUG CCC 2023 Springå ±åä¼ã«åå ãã¦ãã¾ããã javaq.connpass.com å ´æã¯ã¨ã³ã¸ãã¢ã«ãã§ã§ãã æé å 容 ç»å£è 18:40 ~ 19:00 éå ´ã»åä»éå§ 19:00 ~ 19:05 éå§æ¨æ¶ 19:05 ~ 19:25 JJUGã«ã¤ãã¦ãJaâ¦
ããã°ãã¯ãæè¿ç»å£è¸äººã«ãªã£ã¦ããä¸å°¾ã§ãã ã¨ããµã¤ãããã°ã®å·æ°ã®è©±ãããã¦ãªãã§ããã neuet à LINE Fukuoka Engineer Meetupã«åå ãã¦ãã¾ããã å ´æã¯FGN(Fukuoka Growth Next)ã§ããã¹ã¿ã¼ãã¢ããä¼æ¥ãæ¯æ´ããç¦å²¡å¸ã®æ½è¨ã§ããæåãªâ¦
ã¨ããµã¤ãæ ªå¼ä¼ç¤¾ã®ä¸å°¾ã§ãã Embulkã使ã£ã¦ãS3ã®ã¢ã¯ã»ã¹ãã°ãéè¨ãã¦ãã¼ã¿ãã¼ã¹ã«æ¿å ¥ããæ¹æ³ã説æãã¾ãã ä¾ãã°ã¢ã¯ã»ã¹ãã°ããæé帯å¥ã®ã¢ã¯ã»ã¹ãã°ã®çµæãDBã«ä¿åããããããã¨ãããã¨æãã¾ãã åææ¡ä»¶ã¯ä»¥ä¸ã®éãã§ãã AWS Aâ¦
ã¨ããµã¤ãæ ªå¼ä¼ç¤¾ã®ä¸å°¾ã§ãã JJUG CCC 2023 Spring ã«ç»å£ãã¦ãã¾ããã ã¨ããµã¤ãããã°ã®ãªãã«ãã®è©³ç´°ã¯ããã°ã«è¨è¼ããã¦ããéãã§ãã tech.excite.co.jp JJUG ã§ã¯ ãªãã«ãã®è©±ãä¸å¿ã«ãã¾ãããã質åã§ãã¼ã¿ç§»è¡ã®è©±ãå¤ãã£ãã®ã§ããâ¦
ããã°ãã¯ã ã¨ããµã¤ãæ ªå¼ä¼ç¤¾ã®ä¸å°¾ã§ãã Javaã®Optionalã使ã£ã¦nullå¤å®ã®ifåå²ã極åæ¸ããæ¹æ³ããç´¹ä»ãã¾ãã ifåå²ãæ¸ããä¸ã¤ã®æ¹æ³ã¨ãã¦ã mapã使ã (æ»ãå¤æã) ifPresentOrElseã使ã (æ»ãå¤ãªã) ã®2種é¡ãããã¾ãã 以ä¸ãã³ã¼ãâ¦
ãä¹ ãã¶ãã§ããä¸å°¾ã§ãã é·ããã¨ããã°ãæ¸ãã¦ãã¾ããã§ããããå°ããã¤æ¸ããã¨æãã¾ãã ä»å㯠MyBatis Generatorã§åºåããããã¡ã¤ã³ãªãã¸ã§ã¯ãåã«suffixãã¤ãã¦ã¿ã¾ãã MyBatis Generatorã¯Tableãããã¡ã¤ã³ãªãã¸ã§ã¯ããä½æããæ©è½â¦
ããã°ãã¯ãã¨ããµã¤ãã®ä¸å°¾ã§ãã apacheã®.htaccessã§è¤æ°ã®ç°å¢ãã¾ã¨ããæ¹æ³ããç´¹ä»ãã¾ãã ç¾å¨ã¯nginxã人æ°ã§ãããã¾ã ã¾ã apacheã使ã£ã¦ããã¨ãããããã¨æãã¾ããããã£ããåèã«ãã¦ãã ããã ã¨ãã£ã¦ãè¨å®ã¯ç°¡åã§ããã¨ãã°ç°å¢ãâ¦
ããã°ãã¯ãã¨ããµã¤ãä¸å°¾ã§ãã nginxã§ç¹å®ã®URLã®ã¢ã¯ã»ã¹ãã°ãåºããªãæ¹æ³ã説æãã¾ãã é·ç§»å ããã£ã³ãã¼ã³çµäºãªã©ã§å°ç·ããªããªã£ãã®ã«ãbotãªã©ã§ã¢ã¯ã»ã¹ããç¶ãã¦ãã¾ã£ãå ´åã«æå¹ã§ãã å°ç·ããªããªã£ãURLã®ã¢ã¯ã»ã¹ãã°ã貯ã¾ãã¨â¦
ããã°ãã¯ãã¨ããµã¤ãä¸å°¾ã§ãã PHPã®guzzleã使ã£ã並åå¦çãç°¡åã«èª¬æãã¾ãã åç´ã«ä¸¦åå¦çããã·ã³ãã«ãªå®è£ ã ã¨æãã¾ãã "https://google.com", 'yahoo' => "https://yahoo.co.jp", 'excite' => "https://excite.co.jp", 'hogehoge' => "httâ¦
ã¯ããã¾ãã¦ãã¨ããµã¤ãæ ªå¼ä¼ç¤¾ã®ä¸å°¾ã§ãã ä»åã¯MemcachedããRedisã«ç§»è¡ãã話ããã¾ãã åå¹´ã»ã©ãããã¾ãããããããªãã¨ãããã¾ãããã(æéããããããªã®ã¯ç³ã訳ãããã¾ãã) ã¯ããã« ã¾ãã¯cacheã®ä¸èº«ãç²¾æ»ããã apiãµã¼ãã¼ã®cachâ¦
ãã¯ãããããã¾ããã¨ããµã¤ãæ ªå¼ä¼ç¤¾ã®ä¸å°¾ã§ãã intellijã®ä¾¿å©ãªã·ã§ã¼ãã«ãããpvsmã¨souXXã«ã¤ãã¦ç´¹ä»ãã¾ãã psvm ã¨ã¨ãã£ã¿ã¼ä¸ã§æã¤ã¨ããããªã㨠ä¸çºã§ã以ä¸ãè£å®ããã¾ãã ã¡ãã£ã¨åããã¦ã¿ããã¨ãã§ããã¡ãã¡ä»¥ä¸ãã¿ã¤ãã³ã°â¦
ããã°ãã¯ãã¨ããµã¤ãæ ªå¼ä¼ç¤¾ã®ä¸å°¾ã§ãã laravelã§è¤æ°ã®webãµã¼ãã¹ã1ãªãã¸ããªã«è¼ããæ¹æ³ãããã¾ãã apacheã§ä¾ãè¨è¼ãã¾ãã laravelã®é ä¸ã«ã¯ public/index.php ãããã¾ãããããã¯ä¸ã¤ãããªãã¦ãè¯ãã®ã§ããããããå¢ããã°è¯ãã®ã§â¦
ããã°ãã¯ãã¨ããµã¤ãæ ªå¼ä¼ç¤¾ã®ä¸å°¾ã§ãã ä»åã¯è¡¨é¡ã®éããredisã§ä¸åº¦ã«ä¿åãããã£ãã·ã¥ãµã¤ãº(value)ã¯100kb以ä¸ãè¯ãç¹ã«ã¤ãã¦èª¬æãã¾ãã ã£ã¨è¨ã£ã¦ããmemcacheã§ãåãã§ãã 詳ãã説æã¯ãã¡ãã®ãªã³ã¯ãåèã«ãã¦ãã ããã docs.micâ¦
ããã°ãã¯ãä¸å°¾ã§ãã ä»åã¯æè¡çãªè©±ãããªãã¦ããªã«ã¿ã¼ãã¼ã¹ããã®ã¤ãã³ãã§ç»å£ããã話ãè¨è¼ãã¾ãã alterbooth.connpass.com G's ACADEMY Fukuoka ã¯ããã°ã©ãã³ã°ã¹ã¯ã¼ã«ãªã®ã§ãã¹ã¯ã¼ã«ã§ã¯æãã¦ãããªããããªå 容ã§çºè¡¨ããã¾ããã â¦
ããã°ãã¯ãã¨ããµã¤ãæ ªå¼ä¼ç¤¾ã®ä¸å°¾ã§ãã ä»åã¯ãM1 MacBookã使ã£ã¦ãAzure SQL Databaseãåããæ¹æ³ã説æãã¾ãã ã¾ããåææ¡ä»¶ã¨ãã¦ãM1 MacBookã§Azure SQL Serverã®docker image( mcr.microsoft.com/mssql/server )ã¯ä½¿ãã¾ããããã£ã¦ãAzuâ¦
ã¨ããµã¤ãæ ªå¼ä¼ç¤¾ã®ä¸å°¾ã§ãã æè¿ç¦å²¡ã®ã¨ã³ã¸ãã¢ã«ãã§ã§2åLTã¨ã1åã¹ã¿ãã(ãã©ã³ãã£ã¢)ã¨ãã¦åå ããã®ã§ãã®æã®ãã¨ãè¨è¼ãã¾ãï¼ãããªå¤§ããLTã§ã¯ãªãã®ã§ããããã åå ããLTã¯ä»¥ä¸ã§ã engineercafe.connpass.com engineercafe.connpâ¦
ããã°ãã¯ãã¨ããµã¤ãæ ªå¼ä¼ç¤¾ã®ä¸å°¾ã§ãã ä»åã¯Thymeleafã使ã£ãheaderã¨headã®å ±éåã説æãã¾ãã å ¬å¼documentã«æ¸ãã¦ããéãã§ãããè¨è¼ãã¾ãã www.thymeleaf.org ã¾ããgradleã«ä»¥ä¸ãimplementationãã¾ãã implementation 'org.springfrâ¦
ããã°ãã¯ãã¨ããµã¤ãæ ªå¼ä¼ç¤¾ã®ä¸å°¾ã§ãã quarkusã使ã(ã³ã³ãã¤ã«ç·¨) - ã¨ããµã¤ã TechBlog. ã§compileã§ããªãã£ãã¨ããããªãã¨compileã§ããããã«ãªã£ã¦ãã¾ããï¼ ã©ãããissueãè¦ãã¨GraalVM 22.1 ã使ãããã«ãªã£ãã®ã§ããããã§ããã¿ãâ¦
ããã°ãã¯ãã¨ããµã¤ãæ ªå¼ä¼ç¤¾ã®ä¸å°¾ã§ãã eclipseã§ä¾å¤ãã¬ã¼ã¯ãã¤ã³ãã便å©ã ã£ãã®ã§ãinteljã§ã§ããªããã¨æ¢ãããæå¤ã«ããã«åºã¦ãã¾ããã æ®éã«ãã¬ã¼ã¯ãã¤ã³ããä»è¾¼ã¿ããã¬ã¼ã¯ãã¤ã³ãã§å³ã¯ãªãã¯ããã¨ä»¥ä¸ã®ã¡ãã¥ã¼ãåºã¦ãã¾ããâ¦
ããã°ãã¯ãã¨ããµã¤ãæ ªå¼ä¼ç¤¾ã®ä¸å°¾ã§ãã ãã¾ãéè¦ããªããããããªãã§ãããControllerã§ãinterfaceãimplementsãããã¨ãã§ãã¾ãã ãã æ®éã«implementsãããã¨ã¯ãã©ããªã¯ã©ã¹ã§ãã§ãã¾ããã@RequestMappingã@GetMapping()ã@RequestParaâ¦
å¤é ãããããã°ãã¯ãã¨ããµã¤ãæ ªå¼ä¼ç¤¾ä¸å°¾ã§ãã quarkusã®éçºã«æ £ãã¦ããã®ã§ããããã¾ãã¡debugå¨ããè¦ããªãã£ãã®ã§ãdebugãã°ãå ¨é¨åºããã¨ã«ãã¾ããã https://quarkus.io/guides/logging 詳ããè¨å®ã¯ãã¡ãã«è¨è¼ãã¦ããã®ã§ãããç°¡åâ¦
ããã°ãã¯ãã¨ããµã¤ãæ ªå¼ä¼ç¤¾ä¸å°¾ã§ãã ä»åã¯ãã³ãã¬ã¼ãã¨ã³ã¸ã³ã«ã¤ãã¦èª¬æãã¾ãã quarkusã«ã¯QUTEãããã¾ãã ja.quarkus.io ç¹å¾´ã¨ã㦠ãã¤ãã£ããã«ãã«å¯¾å¿(ééã£ã¦ãããããããªã) ãã³ãã¬ã¼ããã¡ã¤ã«ãå¤ãããããªãã¼ãããã°åâ¦
ããã°ã㯠ãä¹ ãã¶ãã§ããã¨ããµã¤ãæ ªå¼ä¼ç¤¾ ä¸å°¾ã§ãã æè¿ã¯è¶£å³ã§Quarkusã使ã£ã¦ãã¾ãã æ¬è¨äºã§ã¯Quarkusã®ä¾å¤å¦çã«ã¤ãã¦ç´¹ä»ãã¾ãã Red Hatã®çæ§ãã³ã¡ã³ããã ãããDMå¾ ã£ã¦ãã¾ãã ä»åã¯ã¨ã©ã¼ã®ãã³ããªã³ã°ã¨ãããã¨ã§ãexceptioâ¦
ããã°ãã¯ãã¨ããµã¤ãæ ªå¼ä¼ç¤¾ã®ä¸å°¾ã§ãã quarkusã¨ããã°ãnative compileã§ãããã ã¾ãã¯jvmã§ã shogo.nakao@localhost:(main*) $ docker build -f src/main/docker/Dockerfile.jvm -t quarkus/hobby-jvm . [+] Building 100.3s (11/11) FINISHED =â¦
ããã«ã¡ã¯ãã¨ããµã¤ãæ ªå¼ä¼ç¤¾ã®ä¸å°¾ã§ãã åºè½ã¡ã¿ãããªã¿ã¤ãã«ãªã®ã§ãããã¿ãªããã¯ãã¼ãã«è¨è¨ã®æãã«ã©ã åã¯ã©ã®ããã«ãã¦ãã¾ããï¼ åºæ¬ã¯ - åè§è±åã®ã¿ - 極åæ£å¼å称ãã«ã©ã åã«ãå¦ãªçç¥ã¯ããªã - packageãclassãªã©ç¹å®ã®è¨èªã®â¦
ããã°ãã¯ãã¨ããµã¤ãæ ªå¼ä¼ç¤¾ã®ä¸å°¾ã§ãã ååã®ç¶ãã§ãã mybatisãå ¥ãã¦ããã¾ãã mybatisã«ã¯serviceã¨åæ§@Singletonãã¤ãã¦ã@Injectã§å¼ã³åºãã¾ãã ãã®éãrepositoryãéã«æã¿ã¾ãã ã¾ããå¿ è¦ãªextentionãgradleã«è¿½å ãã¾ãã implemâ¦
ããã°ãã¯ãã¨ããµã¤ãæ ªå¼ä¼ç¤¾ã®ä¸å°¾ã§ãã ååã®ç¶ãã§ãã serviceãå ¥ãã¦ããã¾ãã serviceã«ã¯@Singletonãã¤ãã¦ã@Injectã§å¼ã³åºãã¾ãã â»ãµã³ãã«ã§ãã interface package org.my.hobby.service; import org.my.hobby.core.Book; public inteâ¦
ããã°ãã¯ãã¨ããµã¤ãæ ªå¼ä¼ç¤¾ã®ä¸å°¾ã§ãã ååã®ç¶ãã§ãã å¿ è¦ãããªãã¼ã«ãå ¥ãã¦ããã¾ãã ã¾ããããªãã¼ã·ã§ã³ã追å ãã¾ãã gradleã«ä»¥ä¸ã追å implementation 'io.quarkus:quarkus-hibernate-validator' ã¢ããã¼ã·ã§ã³ ã§ããªãã¼ã·ã§ã³è¨â¦
åãã¾ãã¦ãRed Hat大好ãã¨ããµã¤ãæ ªå¼ä¼ç¤¾ã®ä¸å°¾ã§ãã 趣å³ã§quarkusã使ã£ã¦ãããã¨æãã®ã§ããã®è¨é²ãæ®ããã¨æãã¾ãã quarkus cliã¯ä½¿ãã¾ããã ã¾ãã¯ç°å¢ä½ãã§ãã quarkusã§buildãã¼ã«gradleã使ããã¨æãã¾ãã mvnãããgradleã®ã»ãâ¦
ã¨ããµã¤ãæ ªå¼ä¼ç¤¾ã®ä¸å°¾ã§ãã RestControllerAdviceã§æ¾ããªãä¾å¤å¦çãæ¾ãæ¹æ³ãè¨è¼ãã¾ãã ããããæ¹æ³ã¯ãExceptionHandlerã§å ¨ã¦catchããæ¹æ³ã ã¨æãã¾ãã @ExceptionHandler @ResponseStatus(HttpStatus.INTERNAL_SERVER_ERROR) public Striâ¦