1
나는 두 가지 유형 (Country and Rate
) 다음 CrudRepository
을 확장하고 findAll
봄 데이터 카우치베이스 주식회사 findall은 속도
public interface CountryRepository extends CrudRepository<Country, String> {
}
를 사용하여 한 가지 유형의 국가를 검색하기 위해 노력하는 카우치베이스 주식회사 900 문서 주위에 추가했다.
public interface RateRepository extends CrudRepository<Rate, String> {
List<Rate> findByTopTrue();
List<Rate> findByCountryStartingWith(String country);
List<Rate> findByCountryIsoCode(String isoCode);
}
내가 요청한 모든으로보기를 만들었지 만 결과는 약 10 초 걸리는이 정상입니다, 내가 RateRepository에 다른 방법을 사용하는 경우가 매우 빠르다 있습니다.
Rate에서 최고 필드에 대한 기본 색인 및 GSI도 만들었습니다.
속도 문제가 couchbase 또는 스프링 데이터와 관련이 있는지 확인하려면 어떻게합니까?
대신
findAllCountries
을 사용하다 2.2.0-SNAPSHOT을 사용하여 성능 문제를 해결하십시오. https://forums.couchbase.com/t/spring-data-couchbase/8543 https://jira.spring.io/browse/DATACOUCH-228 – Shahbour