Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Playing with Postgres #1

Open
wants to merge 1 commit into
base: master
Choose a base branch
from
Open

Playing with Postgres #1

wants to merge 1 commit into from

Conversation

matzew
Copy link

@matzew matzew commented Apr 9, 2018

Performance team prefers Postgres, instead of MySQL, so I figured adding Postgres driver to allow some runs against a Postgres instance:

docker run --name some-postgres -e POSTGRES_PASSWORD=perspicuus -e POSTGRES_USER=perspicuus -e POSTGRES_DATABASE=perspicuus  -d postgres:9.6

run the server, like:

java -Dswarm.datasources.data-sources.DataSourcePerspicuus.driver-name=org-postgresql -Dswarm.datasources.data-sources.DataSourcePerspicuus.connection-url=jdbc:postgresql://172.17.0.2:5432/perspicuus -Dswarm.datasources.data-sources.DataSourcePerspicuus.user-name=perspicuus -Dswarm.datasources.data-sources.DataSourcePerspicuus.password=perspicuus -jar target/server-0.1.0-SNAPSHOT-swarm

and do some test, like:

curl -u "testuser:testpass" -X POST -H "Content-Type: application/vnd.schemaregistry.v1+json" --data '{"schema":"{\"type\":\"record\",\"name\":\"recordname\",\"fields\":[{\"name\":\"fieldB\",\"type\":\"string\"},{\"name\":\"fieldsimilarone\",\"type\":\"string\"},{\"name\":\"fieldsimilartwo\",\"type\":\"string\"}]}"}' http://localhost:8080/subjects/testy/versions

On the DB, do a select * from subjectentity, and see the added entity in the table;

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

1 participant