메뉴 건너뛰기

Cloudera, BigData, Semantic IoT, Hadoop, NoSQL

Cloudera CDH/CDP 및 Hadoop EcoSystem, Semantic IoT등의 개발/운영 기술을 정리합니다. gooper@gooper.com로 문의 주세요.


2023년 2월 20일 microservice/ftgo_application전체 소스를 다시 받아 build완료후 swagger페이지에 접근하면 다음과 같은 오류가 발생할 수 있다. 

(접근URL : http://dev.gdime.com:8082/swagger-ui/)

이것은 이전 버젼의 swagger를 사용하면서 발생하는 문제인데 이때는 아래와 같이 Configuration Class에 @EnableSwagger2 어노테이션을 붙여준다. 

(ftgo-application프로젝트가 swagger가 swagger2로 변경되면서 발생하는 문제로 보인다 )


--오류내용

Unable to infer base url. This is common when using dynamic servlet registration or when the API is behind an API Gateway. The base url is the root of where all the swagger resources are served


--오류 발생시 조치방법

net.chrisrichardson.eventstore.examples.customersandorders.commonswagger/CommonSwaggerConfiguration.java파일을 다음과 같이 수정한다. 

@Configuration

@EnableSwagger2   <-- 이부분을 추가함

public class CommonSwaggerConfiguration {

번호 제목 날짜 조회 수
53 [gson]mongodb의 api를 이용하여 데이타를 가져올때 "com.google.gson.stream.MalformedJsonException: Unterminated object at line..." 오류발생시 조치사항 2017.12.11 4804
52 Caused by: java.sql.SQLNonTransientConnectionException: Could not read resultset: unexpected end of stream, read 0 bytes from 4 오류시 확인/조치할 내용 2016.10.31 4061
51 List<Map<String, String>>형태의 데이타에서 중복제거 하는 방법 2016.12.23 2041
» [ftgo_application]Unable to infer base url오류 발생시 조치방법 2023.02.20 1823
49 jsoup 사용 예제 2014.06.06 1626
48 마이바티스(MyBatis)쿼리로그 출력및 정렬하기 2015.12.01 1546
47 Mybatis foreach 문법정리(상황에 따른 사용법) 2015.11.10 1454
46 lagom-linux용 build.sbt파일 내용 2017.10.12 1415
45 mybatis와 spring을 org.apache.commons.dbcp2.BasicDataSource의 DataSource로 연동할때 DB설정(참고) 2016.10.31 1073
44 [Mybatis]Spring과 연동하지 않고 Java+Mybatis 형태의 프로그램 샘플소스 2016.09.01 933
43 python test.py실행시 "ImportError: No module named pyspark" 혹은 "ImportError: No module named py4j.protocol"등의 오류 발생시 조치사항 2017.07.04 866
42 [springframework]Caused by: org.mariadb.jdbc.internal.util.dao.QueryException: Could not read resultset: unexpected end of stream, read 0 bytes from 4 오류 발생시 조치사항 2017.01.23 834
41 AIX 7.1에 Python 2.7.11설치하기 2016.10.06 824
40 초기 오류(java.lang.NoSuchMethodError)에 따른 후속 작업에서 오류(java.lang.NoClassDefFoundError)가 발생되는 상황(quartz에서 주기적으로 작업시) 2016.08.29 669
39 python2.7.4에서 Oracle DB(11.2)를 사용하기 위한 설정(RPM을 이용하여 RHEL 7.4에 설치) 2021.11.26 587
38 Eclipse실행시 Java was started but returned exit code=1이라는 오류가 발생할때 조치방법 2016.11.07 575
37 servlet-api를 jar형태로 build할때 포함하지 말고 java 설치 위치의 jre/lib/ext에 복사하여 사용하는것이 좋다. 2016.08.10 537
36 lagom에서 제공하는 초기 생성기능을 이용하여 생성한 프로젝트의 소스 파악 2018.01.16 536
35 VisualVM 1.3.9을 이용한 JVM 모니터링 file 2016.10.27 480
34 [tomcat] logrotate를 이용하여 catalina.out로그파일 일별로 로테이션 저장하기 file 2017.01.18 480
위로