spring:
application:
name: book-metadata-service
datasource:
url: jdbc:postgresql://localhost:5439/bookmetadb?reWriteBatchedInserts=true
username: postgres
password: postgres
driver-class-name: org.postgresql.Driver
hikari:
maximum-pool-size: 20
minimum-idle: 5
connection-timeout: 30000
idle-timeout: 600000
max-lifetime: 1800000
jpa:
properties:
hibernate:
jdbc:
batch_size: 1000
batch_versioned_data: true
order_inserts: true
order_updates: true
generate_statistics: false
flyway:
enabled: true
locations: classpath:db/migration
baseline-on-migrate: true
thymeleaf:
cache: false
book:
pivot:
default-org-id: 1
api:
# Временный статичный ключ на старте. Позже заменить на таблицу api_keys.
static-api-key: dev-local-key-change-me
google:
books:
# Получить бесплатно: console.cloud.google.com -> New Project ->
# APIs & Services -> Library -> найти "Books API" -> Enable ->
# Credentials -> Create Credentials -> API Key. Карта не требуется.
api-key:
libgen:
enabled: false # осознанный opt-in — юридически серая зона, включайте сами
base-url: https://libgen.li/json.php
management:
endpoints:
web:
exposure:
include: health,info,metrics
logging:
level:
root: INFO
ru.mcs.metadatabook: DEBUG
org.hibernate.SQL: WARN
springdoc:
api-docs:
path: /api-docs
swagger-ui:
path: /swagger-ui.html
tags-sorter: alpha
operations-sorter: method
default-produces-media-type: application/json