All the examples I've seen using the gremlin API to query a CosmosDB graph use vertices that have one level of properties. But what if we want represent our vertices as JSON documents?
user.name = "Mike"
user.location.lat = "37.7749"
user.location.lng = "122.4194"
Sometimes nested properties should be split out as separate vertices and linked via edges, but often this is unnecessary.
What is the recommended approach for this? Should there simply be an adapter class that flattens/unflattens the vertices as they enter and leave the DB? This seems straightforward but very costly in terms of performance.