묻고 답해요
158만명의 커뮤니티!! 함께 토론해봐요.
인프런 TOP Writers
-
미해결STM32 FFT 구현
STM32F103R8T6으로 구현 시 문제
강의 자료 38페이지의 코드작성 까지 완료하고 디버깅했는데 다음과 같은 에러가 발생합니다. STM32F103R8T6모델로는 구현이 안되는 것 일까요?
-
미해결[핵집] 2025 빅데이터 분석기사(필기)_과목 1~2
수업자료 통합본 요청드립니다.
빅분기 1~2 통합본 요청드립니다.withshort@gmail.com 감사합니다.
-
미해결
안드로이드 시리얼 Rx 안 받아짐
안드로이드 스튜디오 자바 언어로 Rx 데이터를 받고 싶은데.. 자꾸 사이즈만 받아지고 데이터는 안받아지네요아시는 분 알려주세요
-
미해결스프링 DB 1편 - 데이터 접근 핵심 원리
Mybatis에서 Connection의 생명주기 및 Pooling Proxy객체
[질문 템플릿]1. 강의 내용과 관련된 질문인가요? (예)2. 인프런의 질문 게시판과 자주 하는 질문에 없는 내용인가요? (예)3. 질문 잘하기 메뉴얼을 읽어보셨나요? (예)[질문 내용]제목과 같습니다.Mybatis에서의 Connection 생명주기와커넥션풀을 연동했을때의 Connection 생명주기가 궁금합니다.Mybatis에서 커넥션풀을 적용한다고 가정합니다.만약 하나의 기능 즉, 하나의 쓰레드 단위로 쿼리를 호출하는 매퍼 메소드를 4번 호출한다면 이때 커넥션은 Mapper를 통해 호출하는 DAO 메소드 단위로 Pool에서 4번 꺼내는것인지?만약 그렇다면, 4번 꺼내는 객체들이 앞서 배운 내용처럼 처음 Pool에서 꺼내서 사용하고 반환한 동일한 Connection 객체를 다시 꺼내어 재사용 하는건지 궁금합니다!또한 Transcation Rollback 되는것도 동일한 Connection, 동일한 Session에 의한것과 연관성이 있는건지도 궁금합니다.제가 이해한 부분은 아래와 같습니다.커넥션풀을 사용하면 커넥션풀에 각각 다른 커넥션이 생성됨(10개)하나의 커넥션당 하나의 세션이 생성되며, 커넥션의 생명주기에 종속되어 있다.세션은 트랜잭션을 시작하고 커밋을 관리한다.커넥션 풀을 사용하면 하나의 스레드내에 각각의 쿼리에 대한 작업 단위가 동일한 커넥션을 반환받는다.커넥션이 동일하다면 세션도 동일하므로 하나의 트랜잭션으로 관리된다?이게 맞을까요?
-
해결됨Next + React Query로 SNS 서비스 만들기
error.tsx를 활용한 에러 처리 관련 질문입니다.
안녕하세요 해당 영상을 통해 학습하고 따로 프로젝트를 진행하는 중에 서버 컴포넌트에서 data를 fetch하고 api 상태코드에 따라서 next에서 제공하는 error.tsx에서 해당 에러 상태에 따라 모달에 메세지를 띄우는 작업을 하고 있습니다.로컬 환경에서 실행시켰을때는 정상적으로 error status가 523이 발생했을때 정상적인 메세지를 받아서 error.tsx 화면에서 해당 에러 메세지를 모달에 띄우나 빌드 후 실행시켰을 때에는 An error occurred in the Server Components render. The specific message is omitted in production builds to avoid leaking sensitive details. A digest property is included on this error instance which may provide additional details about the nature of the error.모달안의 메세지에 이러한 문구가 뜹니다. 아무리 찾아봐도 정확한 원인을 모르겠는데 혹시 해결방법을 아실까요?다국어 처리 라이브러리는 next-intl를 사용하였습니다./note/page.tsxasync function fetchSharedNote(guid: string) { try { const res = await fetch( `${process.env.API_SERVER_URL}/v1/...`, { method: "POST", headers: { "Content-Type": "application/json", }, body: JSON.stringify(guid), } ); if (res.ok) { return res.json(); } else { const errorData = await res.json(); throw errorData; } } catch (err: any) { const t = await getTranslations("Index"); if (err.status === RestApiErrorType.notExistResourceException) { throw new Error(t("error523")); } throw new Error(err.message); } } /note/error.tsx "use client"; // Error components must be Client Components import CommonDialog from "@/app/_components/CommonDialog/index"; import { useState } from "react"; export default function Error({ error, }: { error: Error & { digest?: string }; reset: () => void; }) { const [showDialog, setShowDialog] = useState(!!error.message); return ( <CommonDialog isShow={showDialog} contents={error.message} onClick={() => { setShowDialog(false); }} /> ); }
-
미해결[핵집] 2025 빅데이터 분석기사(필기)_과목 3~4
통합본 자료 요청
안녕하세요 통합본 자료 부탁드립니다1~2,3~4모두 수강중입니다. sinisiro@naver.com감사합니다.
-
미해결카프카 완벽 가이드 - 커넥트(Connect) 편
스키마 호환성 질문
안녕하세요https://www.inflearn.com/questions/1207899/%EC%8A%A4%ED%82%A4%EB%A7%88-%ED%98%B8%ED%99%98%EC%84%B1-%EC%A7%88%EB%AC%B8%EC%9E%88%EC%8A%B5%EB%8B%88%EB%8B%A4이 질문에 대한 추가 질문이 있습니다. BACKWARD에 대해 지원하는 신규 스키마 변경에서기존 필드 삭제, 기본 값 가진 신규 필드 추가이 부분은 sink쪽 스키마에서의 변경에 대한 내용인 것은 맞는건가요? 예를 들어 스키마 호환성 체크에서새로 추가되는 컬럼이 기본 값을 가지고 있지 않으면 하위 호환성 오류다. 라는 문장이 있다면"sink 쪽에서" 새로 추가되는 컬럼이 기본 값을 가지고 있지 않으면 하위 호환성 오류다. 라고 해석하는 것이 맞는지 질문드립니다.
-
해결됨AWS Certified Solutions Architect - Associate 자격증 준비하기
수업기간 연장 가능할까요??
안녕하세요.회사 업무로 바빠 4월에 시험 신청을 했습니다. 혹시 수업 기간 연장 가능할까요??
-
미해결스프링 시큐리티
error , exception 이 잘 안됩니다.
강사님 소스와 똑같이 했는데도 안되는데요 ....로그인 실패해도 에러 문구가 안뜹니다. 디버깅하면 Controller 값이 null 로 들어오는데 왜그런걸까요 ?? security 설정에 /login?* 설정도 해줬습니다. @Controllerpublic class LoginController { // 에러가 있을때만 선택적으로 받는다.@RequestMapping(value={"/login"})public String login(@RequestParam(value = "error", required = false) String error,@RequestParam(value = "exception", required = false) String exception, Model model){model.addAttribute("error",error);model.addAttribute("exception",exception);return "login";} @GetMapping("/logout")public String logout(HttpServletRequest request, HttpServletResponse response) { Authentication authentiation = SecurityContextHolder.getContext().getAuthentication(); if (authentiation != null) {new SecurityContextLogoutHandler().logout(request, response, authentiation);} return "redirect:/login"; }} package com.eazybytes.springsecsection3.security.handler; import java.io.IOException; import org.springframework.security.authentication.BadCredentialsException;import org.springframework.security.authentication.InsufficientAuthenticationException;import org.springframework.security.core.AuthenticationException;import org.springframework.security.web.authentication.SimpleUrlAuthenticationFailureHandler;import org.springframework.stereotype.Component; import jakarta.servlet.ServletException;import jakarta.servlet.http.HttpServletRequest;import jakarta.servlet.http.HttpServletResponse; // 인증 검증시 실패할때 인증 예외 발생@Componentpublic class CustomAuthenticationFailureHandle extends SimpleUrlAuthenticationFailureHandler { @Overridepublic void onAuthenticationFailure(final HttpServletRequest request, final HttpServletResponse response, final AuthenticationException exception) throws IOException, ServletException { String errorMessage = "Invalid Username or Password"; if(exception instanceof BadCredentialsException) {errorMessage = "Invalid Username or Password"; }else if(exception instanceof InsufficientAuthenticationException) {errorMessage = "Invalid Secret";} setDefaultFailureUrl("/login?error=true&exception=" + errorMessage); super.onAuthenticationFailure(request, response, exception); }}package com.eazybytes.springsecsection3.security.config;import org.springframework.beans.factory.annotation.Autowired;import org.springframework.boot.autoconfigure.security.servlet.PathRequest;import org.springframework.context.annotation.Bean;import org.springframework.context.annotation.Configuration;import org.springframework.security.authentication.AuthenticationDetailsSource;import org.springframework.security.authentication.AuthenticationProvider;import org.springframework.security.config.annotation.authentication.builders.AuthenticationManagerBuilder;import org.springframework.security.config.annotation.web.builders.HttpSecurity;import org.springframework.security.config.annotation.web.configuration.WebSecurityCustomizer;import org.springframework.security.config.annotation.web.configurers.AbstractHttpConfigurer;import org.springframework.security.crypto.bcrypt.BCryptPasswordEncoder;import org.springframework.security.crypto.password.PasswordEncoder;import org.springframework.security.web.SecurityFilterChain;import org.springframework.security.web.authentication.AuthenticationFailureHandler;import org.springframework.security.web.authentication.AuthenticationSuccessHandler;import com.eazybytes.springsecsection3.security.provider.CustomAuthenticationProvider;import com.eazybytes.springsecsection3.security.service.CustomUserDetailsService;import jakarta.servlet.DispatcherType;@Configurationpublic class SecurityConfig { @Autowiredprivate AuthenticationSuccessHandler customerauthenticationSuccessHandler; // 인증 성공후 핸들링 처리 @Autowiredprivate AuthenticationFailureHandler authenticationFailureHandlerl; // 인증 실패후 핸들링 처리 @Autowiredprivate AuthenticationDetailsSource authenticationDetailsSource; // FormWebAuthenticationDetails 을 security 가 사용할 수 있도록 등록 @Autowiredprivate CustomUserDetailsService userDetailsService; // 개발자가 만든 userDetailsService 를 사용 protected void configure (AuthenticationManagerBuilder auth) throws Exception{ // CustomAuthenticationProvider 를 seruciry 가 사용할 수 있도록 등록auth.authenticationProvider(authenticationProvider());} @Beanpublic AuthenticationProvider authenticationProvider() {return new CustomAuthenticationProvider();} @BeanSecurityFilterChain defaultSecurityFilterChain(HttpSecurity http) throws Exception {http.csrf(AbstractHttpConfigurer::disable); http.authorizeHttpRequests((auth) ->auth.dispatcherTypeMatchers(DispatcherType.FORWARD).permitAll().requestMatchers("/","/users","/users/login/**, /login*").permitAll() /* /login* /login?error=true&exception 접근 허용 */.requestMatchers("/mypage").hasRole("USER").requestMatchers("/message").hasRole("MANAGER").requestMatchers("/config").hasRole("ADMIN").anyRequest().authenticated()); http.formLogin((form) ->form.loginPage("/login").loginProcessingUrl("/login_proc").defaultSuccessUrl("/").authenticationDetailsSource(authenticationDetailsSource).successHandler(customerauthenticationSuccessHandler ) // 인증이 성공한 후 핸들링 처리.failureHandler(authenticationFailureHandlerl) // 인증이 실패후 후 핸들링 처리.permitAll());return http.build();} @Beanpublic PasswordEncoder passwordEncoder() {return new BCryptPasswordEncoder();} @Beanpublic WebSecurityCustomizer webSecurityCustomizer() {// 정적 리소스 spring security 대상에서 제외return (web) ->web.ignoring().requestMatchers(PathRequest.toStaticResources().atCommonLocations());}} --------------------- <!DOCTYPE html><html xmlns:th="http://www.thymeleaf.org"><head th:replace="layout/header::userHead"></head><body><div th:replace="layout/top::header"></div><div class="container text-center"><div class="login-form d-flex justify-content-center"><div class="col-sm-5" style="margin-top: 30px;"><div class="panel"><p>아이디와 비밀번호를 입력해주세요</p></div><div th:if="${param.error}" class="form-group"><span th:text="${exception}" class="alert alert-danger">잘못된 아이디나 암호입니다</span></div><form th:action="@{/login_proc}" class="form-signin" method="post"><input type="hidden" th:value="secret" name="secret_key" /><div class="form-group"><input type="text" class="form-control" name="username" placeholder="아이디" required="required" autofocus="autofocus"></div><div class="form-group"><input type="password" class="form-control" name="password" placeholder="비밀번호" required="required"></div><button type="submit" class="btn btn-lg btn-primary btn-block">로그인</button></form></div></div></div></body></html>
-
미해결[C#과 유니티로 만드는 MMORPG 게임 개발 시리즈] Part4: 게임 서버
RecvBuffer 질문
안녕하세요. Session에서 _recvArgs.SetBuffer() 하는 부분에서 궁금증이 생겼습니다. _recvBuffer.WriteSegment는 다음에 올 패킷 사이즈가 어느 정도인지 모르니버퍼의 offset + writePos부터 여유공간 끝까지(FreeSize)를 뭉탱이로 가리켜서 주는걸로 이해했습니다.그리고 _recvArgs는 WriteSegment가 가리키는 공간을 자신의 버퍼로 사용합니다. 만약, 실제로 보내고자 했던 패킷의 사이즈가 10인데, _recvArgs의 FreeSize가 5라면,소켓은 일단 5만큼만 버퍼에 넣은 다음에 버리고, 나머지 5만큼의 재전송을 요청하는 건가요?아니면 아예 버리고 재전송을 요청하는건가요?그것도 아니라면 물밑(하위 레이어)에서 버퍼가 꽉 찼다는 신호를 서로 주고받아서 혼잡(?)이라 판단하고 애초에 보내지 않고 기다리는건가요? (버퍼가 비어지길 기다리다가 지치면 Disconnect 혹은 Loss?) 그리고 RecvBuffer의 Buffer가TCP 이론을 배울 때 말하는 window size와 직접적으로 연관되는 건가요?아니면 소켓 별도의 버퍼가 또 따로 있는건가요?
-
미해결스프링 시큐리티
thymeleaf tag 질문합니다.
- 학습 관련 질문을 남겨주세요. 상세히 작성하면 더 좋아요! - 먼저 유사한 질문이 있었는지 검색해보세요. - 서로 예의를 지키며 존중하는 문화를 만들어가요. - 잠깐! 인프런 서비스 운영 관련 문의는 1:1 문의하기를 이용해주세요. 로그인 하지 않을 때 isAnonymous() 는 동작하는데 로그인 하고 isAuthenticated() 는 동작 하지 않아서 top 메뉴에 로그아웃이 보이지 않네요 로그인 처리가 잘 안돼서 그런건가요 ??
-
미해결스프링 MVC 2편 - 백엔드 웹 개발 활용 기술
시스템 os locale 과 intellij default locale이 다릅니다.
[질문 템플릿]1. 강의 내용과 관련된 질문인가요? (예)2. 인프런의 질문 게시판과 자주 하는 질문에 없는 내용인가요? (예)3. 질문 잘하기 메뉴얼을 읽어보셨나요? (예)[질문 내용]intellij 에서 로케일 티폴트를 찍으면 en-us라고 나오는데시스템 os locale은 한국입니다.locale.korea 라고 했을 때 messages_kr 파일이 없어 messages.properties(디폴트)를 먼저 찾아 테스트가 동작한다는 설명은 이해했습니다. (locale null 대신 locale.korea로 테스트성공) 하지만 null값으로 주게 되면 시스템 os 를 먼저 찾고(저의 경우 kr) -> messages_kr이 없으니 그대로 messages.properties를 찾을 줄 알았으나 messages_en.properties를 계속해서 참조했습니다. (아래) default값을 찍어보니 맨 위 사진처럼 intellij에서 디폴트값을 us로 인식하고 있었습니다. 혹시 어떻게 해결해야 할까요?
-
미해결10주완성 C++ 코딩테스트 | 알고리즘 코딩테스트
강의 swap 질문
안녕하세요 강사님.c++ 초보 학생입니다.재귀함수로 만드는 순열 강의를 듣는 중에 3:18 전까지는 이해가 되나 3:18에서 코드를 보면 for 문에서 i =depth 즉 0으로 시작하므로 swap(v[0], v[0])이 된 이후에makePermutation(3, 3, 1)이 실행되는 것 아닌가요?강의 설명중 swap이 0,0 후에 1,0 그리고 2,0 까지 일어난다는 것이 코드상 이해되지 않습니다. 어째서일까요??
-
미해결MongoDB를 활용하여, 200억건 이상의 데이터 파이프라인 작성법
upsert를 insert보다 권장하시는 이유는 그냥 편의적인 이유인가요?
안녕하세요?질문 그대로 upsert를 insert보다 권장하시는 이유는 그냥 편의적인 이유인가요?어떤 성능상의 이유가 있는지, 유니크함을 보장하기 위한 수단인건지 등등 단순히 편의적인 이유이상의 무엇인가가 있는지 궁금합니다.(즉, 반대로 편하다는 이유만으로도 사용해도 되는지 궁금하네요)
-
미해결처음 만난 리덕스(Redux)
redux-thunk 실습 오류
Uncaught SyntaxError: The requested module '/node_modules/.vite/deps/redux-thunk.js?v=c406571d' does not provide an export named 'default' (at store.js:3:8)(내용 수정 및 진행상태 업데이트 2023.03.21 am 02:33)비트로 설치한 모듈에서 제공하지 않는 내보내기라길래해결방법 찾아보다가https://github.com/reduxjs/redux-templates여기에 있는 리드미 내용대로yarn add vite-template-redux설치를 하긴 했는데 Vite, with TypeScript 가 아니라 React로 해서 그런지는 모르겠는데그래도 같은 오류가 뜨네요ㅠㅠㅠ 아래는 각각 입력한 코드 내용입니다store.jsimport { applyMiddleware, compose, createStore } from "redux"; import rootReducer from "./reducers"; import thunkMiddleware from "redux-thunk"; // import asyncFunctionMiddleware from "./middlewares/asyncFunctionMiddleware"; const composeEnhancers = window.__REDUX_DEVTOOLS_EXTENSION_COMPOSE__ || compose; const store = createStore( rootReducer, composeEnhancers(applyMiddleware(thunkMiddleware)) ); export default store;addTodoThunks.jsimport { addTodo as addTodoActionCreator, removeTodo as removeTodoActionCreator, } from "../actions/todoAction"; const TODO_MAX_COUNT = 3; function addTodoThunkActionCreator(text) { return async function addTodoThunk(dispatch, getState) { const state = getState(); if (state.todo.length < TODO_MAX_COUNT) { dispatch(addTodoActionCreator("아이템 추가중...")); setTimeout(() => { dispatch(removeTodoActionCreator()); dispatch(addTodoActionCreator(text)); }, 3000); return; } else { dispatch(addTodoActionCreator("최대 개수 초과!")); setTimeout(() => { dispatch(removeTodoActionCreator()); }, 3000); } }; } export default addTodoThunkActionCreator; TodoAppContainer.jsimport { connect } from "react-redux"; // import { // addTodoActionCreator, // removeTodoActionCreator, // removeAllActionCreator, // } from "../actions"; // import { // addTodoActionCreator, // removeTodoActionCreator, // removeAllActionCreator, // } from "../ducks/todoDuck"; import { addTodo as addTodoActionCreator, removeTodo as removeTodoActionCreator, removeAll as removeAllActionCreator, } from "../actions/todoAction"; import addTodoThunkActionCreator from "../thunks/addTodoThunks"; import TodoApp from "../../components/TodoApp"; function mapStateToProps(state, ownProps) { return { todoItems: state.todo, }; } function mapDispatchToProps(dispatch, ownProps) { return { addTodo: (text) => { // dispatch(addTodoActionCreator(text)); dispatch(addTodoThunkActionCreator(text)); }, removeTodo: () => { dispatch(removeTodoActionCreator()); }, removeAll: () => { dispatch(removeAllActionCreator()); }, triggerAsyncFunction: (asyncFunction) => { dispatch(asyncFunction); }, }; } const TodoAppContainer = connect(mapStateToProps, mapDispatchToProps)(TodoApp); export default TodoAppContainer;
-
미해결자바 ORM 표준 JPA 프로그래밍 - 기본편
JPQL 컴파일 오류
JPQL 함수 강의에서 사용자 정의 함수 호출 부분 설명에서 컴파일 오류가 발생헀는데 강사님이랑 코드 작성 똑같이 했는데 함수값이 틀린거 같은데 저 빨간색 코드 부분을 뭐라고 수정을 해야 하나요??
-
미해결[리뉴얼] 파이썬입문과 크롤링기초 부트캠프 [파이썬, 웹, 데이터 이해 기본까지] (업데이트)
공공 데이터 목록 -> 한국환경공단_대기오염정보 이름 변경 문의
오픈 API에 한국환경공단_에어코리아_대기오염정보 은 찾았는데 영상처럼 한국환경공단_대기오염정보는 보이지 않네요..ㅠ시도별 실시간 측정정보 조회도 검색이 안되고 혹시 영상 파일을 공유해 주실 수 있나요? https://www.data.go.kr/data/15073861/openapi.do
-
미해결10주완성 C++ 코딩테스트 | 알고리즘 코딩테스트
1-O 코드 질문입니다.
안녕하세요 큰돌님! 강의 재미있게 잘 듣고 있습니다 ㅎㅎ1-O번을 혼자 풀어서 맞추긴 했는데... 큰돌님 풀이 방식이랑은 좀 다르기도 하고, while문을 중첩해서 쓴 게 시간복잡도 때문에 마음에 걸려서요. - 코드 : http://boj.kr/a5eb7d7c669c408882d3004546fb537d저 같은 경우는 아래와 같은 방식으로 생각하고 구현하였습니다. 1. 입력범위를 먼저 보고 ( 1 <= n <= 10000) 2. 1, 11, 111, 1111을 제외하고는 맨 뒷자리가 1이 나오는 n의 값은 3, 7, 9 밖에 없다는 걸 깨달음 3. 나눗셈을 할때 나머지에 10을 곱해서 다음 자리수에 더해 다시 나눠서 계산하는 방식을 차용. 다시 말해 나눗셈을 할 때, 윗자리부터 몫과 나머지를 구하고, 나머지를 윗자리 몫을 구하고 남은 나누어지는 수에 더해서 다시 나누는 방식을 사용하기로 함. (배수이면 언젠간 나누어 떨어지므로)4. 코드상으로 시간 복잡도는 좋지 않아보이지 않았지만, 주어진 범위내에서는 111...11 자리수가 20이 넘어가더라도 한번의 테스트 케이스에서 대략 20번만 수행하면 되므로 그대로 구현해보았음. 혹시 이런 경우에 테스트 케이스를 맞췄더라도, 시간 복잡도를 고려해서 더 나은 방법을 고민해보는게 좋을까요?
-
해결됨[React / VanillaJS] UI 요소 직접 만들기 Part 1
강의 자료 다운받았는데 06_lazyLoading/4_r 폴더가 없어요
안녕하세요! 알림 보고 바로 수강신청했습니다 ㅎㅎ그런데 강의 자료를 열어보니 06_lazyLoading/4_r 이 쓰여지고는 있는데 폴더가 없네요... const LazyImage = dynamic(() => import('@/components/06_lazyLoading/4_r/lazyImage'), { ssr: false }) 실행도 못해보고 터져버린 앱... ㅠㅠ
-
미해결스프링 DB 2편 - 데이터 접근 활용 기술
KeyHolder 질문
@Override public Item save(Item item) { String sql = "insert into item (item_name, price, quantity) " + "values(:itemName, :price, :quantity)"; SqlParameterSource param = new BeanPropertySqlParameterSource(item); KeyHolder keyHolder = new GeneratedKeyHolder(); template.update(sql, param, keyHolder); long key = keyHolder.getKey().longValue(); item.setId(key); return item; } KeyHolder같은경우 id를 내부에서 직접 구성해줘야하기 때문에 쓰는거라고 알고있는데 서버를 열어서 추가를 해줄때마다 숫자가 증가되는걸 볼수있었습니다. 숫자가 증가되는건 코드에서 자체적으로 해주는건가요?항상 답변감사드립니다.