-
Notifications
You must be signed in to change notification settings - Fork 0
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
Feature/store files #23
base: master
Are you sure you want to change the base?
Conversation
we're waiting for google/jsonapi to implement nested structs or to accept this PR google/jsonapi#99 We need nested structs for the upcoming mail endpoint
We have to format and parse addresses every time we store/read them from mysql. We could prevent this if we store them as json. Which is ugly. A better way is to store the whole mail/attachment as document. The addresses in to,cc and bcc stay easily accessible that way
we store mail content inside the db for now
We should be able to use the same bootstrap (db, queue, etc.) for the api and the workers.
remove everything uneccessary from worker and mailer
we had some recent API changes
# Conflicts: # cmd/styx-api/main.go # cmd/styx-worker/main.go # mailer/mailer.go # resource/resource_mail.go # storage/mail.go # storage/mail_status.go # worker/worker.go
defer styx.Close() | ||
|
||
aHandler := handler.Attachment{Validator: styx.Validator, Service: styx.AttachmentService} | ||
uHandler := handler.Upload{Service: styx.AttachmentService} |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Ich finde das abkürzen echt kacke - des uHandler kann so viel heißen (User, Upload, Update...) bin ich da alleine?
cmd/styx-api/main.go
Outdated
r.Handle("/mails", mHandler).Methods("POST") | ||
r.Handle("/mails/{id}", mHandler).Methods("GET") | ||
http.Handle("/", r) | ||
log.Fatal(http.ListenAndServe(":9999", nil)) |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Wir haben ja ein config file da würd ich den Port auslesen
handler/mail.go
Outdated
"github.com/Slemgrim/styx/model" | ||
"github.com/Slemgrim/styx/service" | ||
"github.com/Slemgrim/jsonapi" | ||
//"github.com/gorilla/mux" |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
bitte löschen wenns nicht mehr gebraucht wird
No description provided.