Giter VIP home page Giter VIP logo

Comments (7)

longility avatar longility commented on September 3, 2024

Is this valuable? Most of the time, I would think you would be using the same data context when doing a unit of work, which means if you query twice, the entities have the same reference. Having the same reference means it is pointless to return what is truly in the data storage.

The only thing I can think of is for verification purposes for unit testing to see what the actual values are in the data storage.

Am I missing something here?

from highway.data.

DevlinLiles avatar DevlinLiles commented on September 3, 2024

The wording is a bit odd, but what we want is to provide the same commit/rollback behavior of a RDBMS backed repository.

  1. If I make a bunch of object changes without a commit when I query again those changes are not there.
  2. If I add/remove an object, those changes do not change the asqueryable result until a commit is called.

Something like that.

from highway.data.

longility avatar longility commented on September 3, 2024

Let me try again.

I don't think your first point can happen. I was uncertain so I tested it. The test I did was...query for an object, modify without committing, do that same query. The object from the 2nd query is the same object (same reference) so it has my modifications that I did from the first query.

My previous pull request covered your 2nd point. I can send you another pull request with some updates if you want this still. I haven't pushed it from my local yet.

from highway.data.

DevlinLiles avatar DevlinLiles commented on September 3, 2024

I was thinking serialize the storage, and on query return the deserialized objects. Then on commit update the serialized version. Thoughts?

Sent from my Windows Phone


From: Long Maimailto:[email protected]
Sent: ‎4/‎6/‎2014 8:35 PM
To: HighwayFramework/Highway.Datamailto:[email protected]
Cc: Devlin Lilesmailto:[email protected]
Subject: Re: [Highway.Data] InMemoryDataContext should honor the Unit of Work and Commit design (#57)

Let me try again.

I don't think your first point can happen. I was uncertain so I tested it. The test I did was...query for an object, modify without committing, do that same query. The object from the 2nd query is the same object (same reference) so it has my modifications that I did from the first query.

My previous pull request covered your 2nd point.


Reply to this email directly or view it on GitHub:
#57 (comment)

from highway.data.

longility avatar longility commented on September 3, 2024

I think I know where the miscommunication is.

When I said "I don't think your first point can happen", I was talking about EF usage, not my implementation of InMemoryDataContext to get your first point to work. So what I was testing was how EF works, or at least EF w/ Highway.Data. If the scenario doesn't exist in actual EF w/ Highway.Data, then there isn't a point to do that. Can you reread last few comments with this thought in mind. I assume I cleared up the miscommunication.

Thanks!

from highway.data.

longility avatar longility commented on September 3, 2024

Close as this is implemented through InMemoryActiveDataContext?

from highway.data.

DevlinLiles avatar DevlinLiles commented on September 3, 2024

Implemented via the InMemoryActiveDataContext

from highway.data.

Related Issues (20)

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. 📊📈🎉

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❤️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.