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

Add new internal endpoint for updating public csv data into S3 #645

Merged
merged 13 commits into from
Jan 20, 2025

Conversation

etahto
Copy link
Contributor

@etahto etahto commented Dec 11, 2024

Aika pitkälti olemassaolevaa totetusta mukaillen toteutettu uusi sisäinen endpoint julkisen puolen CSV-tiedostojen lataamiselle S3:een.

Aineisto.clj -tiedostossa tulee nyt hieman duplikaatti koodia ja ajattelin yhtenäistää toteutusta kunhan saan palautetta että olenhan tajunnut toiminnallisuuden oikein.

Testasin MinIO Consolen kautta ja näytti tulevan oikean kansion alle CSV:t

@etahto etahto marked this pull request as draft December 11, 2024 11:01
@etahto etahto self-assigned this Dec 18, 2024
Copy link
Contributor

@solita-juhohaa solita-juhohaa left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Joitakin ehdotuksia. Oleellisin varmaankin nuo middlewaret.

Copy link
Contributor

@outamaa outamaa left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Osasin tässä vaiheessa lähinnä peukutella Juhon kommentteja, eli niiden jälkeen approved. 👍

@etahto etahto marked this pull request as ready for review January 8, 2025 08:53
Copy link
Contributor

@muep muep left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Pikkuparannusehdotuksia vielä

(let [hidden-headers #{"tila-id" "laatija-id" "yritys"}]
;; Verify hidden columns don't exist
(t/is (empty? (clojure.set/intersection hidden-headers header-set)))))))
expected-headers (columns->header-strings public-columns)
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Mietin että kannattaisiko vaan ottaa muodostaa tuo public columns - hidden-columns tähän testiin hardcodattuna ja testata että otsikkojoukko on täysin sama. Nämä muuttuvat kuitenkin todella harvoin, ja tämä varmistaisi että jos public-columnsiin tulee joku yllättävä muutos (nyt taitaa olla hardcodattu, mutta varalta jos asia muuttuu), niin testi nappaa kiinni edelleen.

Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Uusimmassa commitissa on nyt kolumnit kovakoodattuna testin sisälle, toivottavasti ymmärsin tämän kommentin oikein

Comment on lines +96 to +98
;; - todistus-1 with kayttotarkoitus "PK"
;; - todistus-2 with kayttotarkoitus "PK"
;; - todistus-3 with kayttotarkoitus "YAT"
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Olisikohan huono idea testata nuo kaikki käyttötarkoitusluokat tässä? 🤔

Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Olisi se kyllä tarpeen, mutta näihin testeihin on kyllä jo alkuperäisen työmääräarvion lisäksi kulunut hieman ylimääräistä aikaa domainiin tutustumisen takia. Voisin kysyä tiimiltä mielipidettä myös

@etahto etahto merged commit c9a399f into main Jan 20, 2025
16 checks passed
@etahto etahto deleted the feature/AE-2362 branch January 20, 2025 11:47
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.

4 participants