nlnetlabs, to random
@nlnetlabs@fosstodon.org avatar

We plan to implement output in our investigation tool dnsi. There is informational RFC 8427 for representing DNS messages in JSON, but we’d like to see if there is a more ergonomic way of representing such a format. We'd love to hear about your use cases and wishes. https://github.com/NLnetLabs/dnsi/issues/12

hunleyd, to PostgreSQL
@hunleyd@fosstodon.org avatar
xtrc, to sysadmin
@xtrc@social.tchncs.de avatar

Just encountered the #EDIFACT standard while in touch with our logistics firm. Why the hell is this nothing readable and yet another useless standard that could've been implemented in #protobuf #json or something modern....

And the best part is everyone uses a subset or has some customizarions which forces us to implement it again and again

#sysadmin #logistics #wholesale

fell,
@fell@ma.fellr.net avatar

@xtrc I think plain text would be ideal.

Foxboron, to Bash
@Foxboron@chaos.social avatar

How do you parse json in bash?

Asking for a friend.

(No, jq is not a solution here)

#json #bash

nf3xn,
@nf3xn@mastodon.social avatar

@Foxboron with great difficulty

remixtures, to TechnicalWriting Portuguese
@remixtures@tldr.nettime.org avatar

: "Luckily there's a specification similar to OpenAPI but directed at defining event-driven APIs. I'm talking about AsyncAPI. It's a specification that lets you define an API that's asynchronous in nature. By using AsyncAPI you can define, among other things, the different topics where events will be dropped, and the shape of the messages that represent each topic.

And this is where things get interesting. The shape of messages or, in other words, its payload, can adhere to specific standards. Without messages, there's no way to communicate events. And, following standards helps to guarantee the correct publishing, transport, and consumption of messages. If messages don't follow any standards, it's hard for developers to understand the shape of the messages. In addition, it's easy for consumers to stop working because, suddenly, messages are being shared in a slightly different format.

Among different message standards, there's one particularly interesting to me. Apache Avro isn't just a theoretical standard. It's also a serialization format. You can say it's a competitor to JSON but specialized in working with event-driven APIs. In the same way you can use JSON Schema to define the shape of JSON data you have Avro Schema to help you specify what Avro message payloads look like."

https://apichangelog.substack.com/p/how-to-document-event-driven-api

mobileatom, to random
@mobileatom@flipboard.com avatar
ythos, to dotnet
@ythos@dotnet.social avatar

We've just published a series of 17 (!) posts on common patterns in JSON Schema; lots of these have been culled from questions asked in the JSON-Schema Slack channel.

They are written from the perspective of .NET developers who are used to JSON serialization as a code-first exercise, and want to migrate towards schema-first (with generated code examples from Corvus.JsonSchema).

https://endjin.com/blog/2024/05/json-schema-patterns-dotnet-data-object

pixel, to programming
@pixel@social.pixels.pizza avatar

Parsing JSON Data is a fundamental in modern SwiftUI apps. This comprehensive guide covers all the aspects of the Codable protocols in Swift.


https://matteomanferdini.com/swift-parse-json/

davidbures,
@davidbures@mstdn.social avatar

@pixel Jk on the picture, this is probably the best guide I’ve seen so far. I’ve been struggling with adopting Codable for years

pablolarah, to wordpress
@pablolarah@mastodon.social avatar
dbushell,
@dbushell@fosstodon.org avatar

@joachim @pablolarah exactly! personally I'm not fond on the UX either (if falls part for beyond simple layouts), but the DX is another level of bad.

joachim,
@joachim@drupal.community avatar

@dbushell @pablolarah We've got Drupal making crazy nested structure of entities on one side, and Wordpress dumping everything in flat text fields with magic markup tags... Opposite approaches but both badly flawed.

jmcastagnetto, to random
@jmcastagnetto@mastodon.social avatar

@coolbutuseless -- just saw this on the incognito site :-)

https://x.com/JosiahParry/status/1787871177677115698

{yyjsonr} rewlz in speed and size

gaborcsardi,
@gaborcsardi@fosstodon.org avatar

@jmcastagnetto Those numbers seem wrong:

❯ du -hs /Users/gaborcsardi/Library/R/arm64/4.4/library/rapidjsonr
780K

❯ du -hs /Users/gaborcsardi/Library/R/arm64/4.4/library/yyjsonr
2.9M

gaborcsardi,
@gaborcsardi@fosstodon.org avatar

@jmcastagnetto jsonlite being extremely slow is also just not true:

❯ system.time(x1 <- jsonlite::fromJSON("./biocatgh/cran-full.json", simplifyVector=FALSE))
user system elapsed
2.046 0.245 2.349

❯ system.time(x2 <- yyjsonr::read_json_file("./biocatgh/cran-full.json"))
user system elapsed
0.910 0.095 1.026

❯ system.time(x3 <- jsonify::from_json("./biocatgh/cran-full.json"))
user system elapsed
2.124 0.108 2.248

hunleyd, to PostgreSQL
@hunleyd@fosstodon.org avatar

in : Revolutionizing Data Flexibility in Your Database - Highgo Software Inc. https://www.highgo.ca/2024/01/15/json-in-postgresql-revolutionizing-data-flexibility-in-your-database/

governa, to linux
@governa@fosstodon.org avatar

: An Interactive Viewer and jq Filter Editor for 🐧

https://linuxtldr.com/installing-jnv/

meuon, to random
@meuon@fosstodon.org avatar

JSON is usually beautifully simply and useful. I'm starting to see the same un-necessarily over-complicated nesting of simple data by API vendors as the XML crowd. All I'm missing is Base64encoded JSON inside of Base64encoded JSON.

(Used to see that in the XML world)

meuon,
@meuon@fosstodon.org avatar

@derickr The value out of the DB call is effectively a string. I can (and did) change that, the frustration is they want it as a number in one place, and the same value as string in another. and they did this in multiple fields.

In my head there is only text. It's all just text. But that's just my strange way of looking at things.

derickr,
@derickr@phpc.social avatar

@meuon Sure, it's an odd API, but "but if I pass 17.37 (bare) to PHPs json_encode it wraps it in quotes." is an incorrect statement.

hamnis, to programming Norwegian
@hamnis@snabelen.no avatar

Released 0.14.7 https://github.com/circe/circe/releases/tag/v0.14.7

It has been a long time coming, but it is finally in maven-central. If you are a user, please read the release notes.

davidbisset, to wordpress
@davidbisset@phpc.social avatar

TIL about the Block Data API - used for retrieving block editor posts structured as data, with integrations for both the official WordPress REST API and .

Primarily designed for use in decoupled WordPress.

From

https://github.com/Automattic/vip-block-data-api

  • All
  • Subscribed
  • Moderated
  • Favorites
  • megavids
  • rosin
  • thenastyranch
  • GTA5RPClips
  • tester
  • InstantRegret
  • DreamBathrooms
  • ngwrru68w68
  • magazineikmin
  • everett
  • Youngstown
  • mdbf
  • slotface
  • kavyap
  • JUstTest
  • cisconetworking
  • khanakhh
  • normalnudes
  • osvaldo12
  • cubers
  • tacticalgear
  • Durango
  • ethstaker
  • modclub
  • anitta
  • provamag3
  • Leos
  • lostlight
  • All magazines