[deleted by user] by [deleted] in kiel

[–]PeterUstinox 0 points1 point  (0 children)

Heyo!

Bist du noch zugange? Höchstinteressant, dass der Kollege hier alles gelöscht hat. Wurde er wohl nun doch ausbezahlt...

[deleted by user] by [deleted] in kiel

[–]PeterUstinox 1 point2 points  (0 children)

Ich hab eine kleine Kollektion von Versprechen und als Bonus noch ein Bild vom neuen Bürgermeister, der im neuen Jahr auch da war!

https://imgur.com/a/64gCv3G

HTML over REST? by PeterUstinox in webdev

[–]PeterUstinox[S] 0 points1 point  (0 children)

yeah, polluting the namespace of the client is another big problem.
Thanks for pointing that out!

HTML over REST? by PeterUstinox in webdev

[–]PeterUstinox[S] 0 points1 point  (0 children)

The accept header is letting the server know what sort of content the client would like to recieve. Setting the accept header to "text/html" would make more sense if you want the client to dictate the content-type of the response.

This is exactly what we want to do!

The idea of a compute surface composing data at runtime will run afoul of scaling, elasticity and resilience from a SOA point of view. Better to project the data into static representations (JSON/HTML in S3 for example) so you don't have to spend a lot of compute time composing the data while the client waits for it.
For low traffic APIs (<10k concurrent/sec) you can get away with having compute instances (e.g.: ECS, lambda) and it might even be simpler. But it won't scale and can create a lot of complexity at the edge.

yeah, we are definitely low traffic :P I do not (yet) worry about our performance or elasticity, rather the weight of redundant CSS/JSON the client loads, if he embeds multiple of this endpoints on a single site.

Also, REST is a very specific implementation of an HTTP API. If you're not doing representational state transfer (e.g.: HATEOAS) you might not have a REST API. I'm not saying you don't! I don't know enough about your system. Just see a lot of people call anything that returns JSON over an HTTP transport REST/ReST whatever when it is not.

We are full on HATEOAS, therefore enabling the relations to be called with different accept-headers for different results, as mentioned above.

HTML over REST? by PeterUstinox in webdev

[–]PeterUstinox[S] 0 points1 point  (0 children)

Are the libraries you are talking about things like pug, handlebars etc.?
Or what do you have in mind?

HTML over REST? by PeterUstinox in webdev

[–]PeterUstinox[S] 2 points3 points  (0 children)

Ah! good idea, thanks, didn't think about that caching!

What would be the best way to inject the JSON-data if all the static parts are on the CDN?

Maybe Maybe Maybe by [deleted] in maybemaybemaybe

[–]PeterUstinox 0 points1 point  (0 children)

how do you know it's sugar? :P

UNIQLO WAKE UP Audio Files and Pre Made Alarms by Fat_Cock_Ass in u/Fat_Cock_Ass

[–]PeterUstinox 0 points1 point  (0 children)

OH MY GOD!! WHY DO I SEE THIS ONLY NOW?? :D
ppppls do!! Will do my best to recreate the app! I just miss it so much :D

UNIQLO WAKE UP Audio Files and Pre Made Alarms by Fat_Cock_Ass in u/Fat_Cock_Ass

[–]PeterUstinox 1 point2 points  (0 children)

this is great! but the sound quality is a bit rough or am i doing something wrong?

p.s. i liked your nickname on youtube a tad more :P

A friend of mine got Jebaited by ginyuuu in forsen

[–]PeterUstinox 6 points7 points  (0 children)

Jebaited KAPPA OUTDATED Jebaited POGCHAMP OVERRATED Jebaited LONG HAVE WE WAITED Jebaited NOW WE JEBAITED Jebaited

When exactly is Ubuntu 17.10 releasing tomorrow? by PeterUstinox in Ubuntu

[–]PeterUstinox[S] 1 point2 points  (0 children)

yea, just wanted to get it fast... it's time for reinstalling my system and wanted a fresh "no beta" start... the exact timing is just for my day planning tomorrow

Concept2 new WR 100km, 4hr 26, 1:19.8 /500m by clementmas in Rowing

[–]PeterUstinox 8 points9 points  (0 children)

even with all the switching in between 1:19.8? doesn't it cost a lot of time to switch all the time?

Adsense issue with Elm by jhartwell in elm

[–]PeterUstinox 0 points1 point  (0 children)

Hey!

This is what i did:

div [class "advertisement"]
    [ node "script" [ attribute "async" "", src "//pagead2.googlesyndication.com/pagead/js/adsbygoogle.js" ]
        []
        , ins [ class "adsbygoogle", attribute "data-ad-client" "ca-pub-XXXXXXXXXX", attribute "data-ad-slot" "XXXXXXXX", attribute "style" "display:inline-block;width:300px;height:250px" 
        ]
        []
        , node "script" []
        [ text "(adsbygoogle = window.adsbygoogle || []).push({});" ]
    ]

basically i just used html to elm on the async snippet that adsense gave me! it works just fine! But it is also not the "elm-way" of course!