Feature/parsing-service intermediate commit, not final migration + run config

This commit is contained in:
danil 2024-10-02 11:51:30 +04:00
parent a24bf08f52
commit 30ca5acc34
2 changed files with 34 additions and 1 deletions

View File

@ -7,7 +7,7 @@
<env name="JDBC_URL" value="localhost:5432/parsed_data" /> <env name="JDBC_URL" value="localhost:5432/parsed_data" />
<env name="SERVER_PORT" value="8080" /> <env name="SERVER_PORT" value="8080" />
</envs> </envs>
<module name="pricepulse.parsingservice.main" /> <module name="parsing-service.main" />
<option name="SPRING_BOOT_MAIN_CLASS" value="ru.pricepulse.parsingservice.ParsingServiceApplication" /> <option name="SPRING_BOOT_MAIN_CLASS" value="ru.pricepulse.parsingservice.ParsingServiceApplication" />
<method v="2"> <method v="2">
<option name="Make" enabled="true" /> <option name="Make" enabled="true" />

View File

@ -4,4 +4,37 @@
xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
xsi:schemaLocation="http://www.liquibase.org/xml/ns/dbchangelog xsi:schemaLocation="http://www.liquibase.org/xml/ns/dbchangelog
http://www.liquibase.org/xml/ns/dbchangelog/dbchangelog-4.9.xsd"> http://www.liquibase.org/xml/ns/dbchangelog/dbchangelog-4.9.xsd">
<changeSet id="20240926_create_product_table.xml" author="danil">
<preConditions>
<not>
<tableExists tableName="product" />
</not>
<not>
<tableExists tableName="product_price_history" />
</not>
</preConditions>
<createTable tableName="product">
<column name="id" type="bigint" autoIncrement="true" remarks="Идентификатор товара">
<constraints primaryKey="true" />
</column>
<column name="marketplace" type="varchar" remarks="Название маркетплейса (enum)">
<constraints nullable="false" />
</column>
<column name="category" type="varchar" remarks="Категория товара">
<constraints nullable="false" />
</column>
<column name="brand" type="varchar" remarks="Бренд товара">
<constraints nullable="false" />
</column>
<column name="product_name" type="varchar" remarks="Название товара">
<constraints nullable="false" />
</column>
<column name="created_at" type="timestamptz" remarks="Время добавления товара в базу">
<constraints nullable="false" />
</column>
</createTable>
<sql>
</sql>
</changeSet>
</databaseChangeLog> </databaseChangeLog>