Skip to content
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

Roadmap Questions #2566

Closed
jasonrichardcraig opened this issue Jul 8, 2015 · 3 comments
Closed

Roadmap Questions #2566

jasonrichardcraig opened this issue Jul 8, 2015 · 3 comments
Assignees
Milestone

Comments

@jasonrichardcraig
Copy link

Would you know where I can find the documentation so I can implement the HierarchyId, 2D / 3D Spatial and custom CLR types to EF7? Also do you know if Microsoft has any OData V4 tooling ready to work with EF7?

I have also a few questions about the scalability and performance of EF7; some developers in a different division abandoned EF altogether because of this. Have these problems been addressed?

Regards,

Jason Craig

@rowanmiller
Copy link
Contributor

Custom types aren't really supported in EF7 just yet. We have laid some ground work to enable it in the future, but it won't be there for the initial RTM. You can track the work item here #240.

EF7 should address a number of the perf/scale issues with EF6. There are still some significant bottlenecks in the current beta code, we are waiting to address these until we have most of the features implemented (since new features change design, which in turn changes where the bottleneck is).

cc @danroth27 to answer the question of OData.

@rowanmiller rowanmiller self-assigned this Jul 14, 2015
@rowanmiller rowanmiller added this to the Discussions milestone Jul 14, 2015
@marinehero
Copy link

marinehero commented Dec 1, 2016

@rowanmiller (or anybody): any news/update re core support for spatial? (last I saw was dotnet/corefx#12034)

Am super excited that ef on .netcore work on Linux machines... was about to port some services to run on the cloud with Redis (for caching in HA mode) when I hit the show stopper on spatial which would hit my DB to seed the data.

Was looking at creating my own CustomSqlServerTypeMapper and adding temporary support for spatial based on implementing a subset of (surprise I found the source to VS2010 here)

What would be the quickest realistic approach to get running live ?

  1. Wait for it to come via official core channels
  2. Implement my temporary hack
  3. Is there an alternative?

Basically the main spatial functions I require are the DbGeometry.FromText() and .Distance() one(s).

Nutshell query I need to support:

var msgTarget = categoryId <= 0
        ? (from p in ctx.PostedMessages
            join t in ctx.MessagesTrendings on p.MessageID equals t.MessageID
            join r in ctx.MessageMedias on new {A = p.MessageID, B = 0} equals
            new {A = r.MessageID, B = (int) r.SeqNo}
            join u in ctx.UserFaceBookInfoes on p.UserID equals u.UserID
            where 
                (p.Expires >= DateTime.Now || p.Expires == null)
                && p.Deleted == null && p.Coordinate.Distance(targetGeo) <= userDistance
            select new {pm = p, m = r, ufb = u, t = t, distance = p.Coordinate.Distance(targetGeo)})
        : (from p in ctx.PostedMessages
            join t in ctx.MessagesTrendings on p.MessageID equals t.MessageID
            join r in ctx.MessageMedias on new {A = p.MessageID, B = 0} equals new {A = r.MessageID, B = (int) r.SeqNo}
            join u in ctx.UserFaceBookInfoes on p.UserID equals u.UserID
            where
                (p.Expires >= DateTime.Now || p.Expires == null)
                && p.Deleted == null && p.Coordinate.Distance(targetGeo) <= userDistance
                && (p.CategoryID & categoryId) > 0
            select new {pm = p, m = r, ufb = u, t = t, distance = p.Coordinate.Distance(targetGeo)});

var msgTargets = rankBy == 2
        ? msgTarget.OrderByDescending(m => m.t.AlgoB)
        : rankBy == 0 ? msgTarget.OrderBy(m => m.pm.Coordinate.Distance(targetGeo))
            : rankBy == 3 ? msgTarget.OrderBy(m => m.t.NewScore/(0.004*(m.pm.Coordinate.Distance(targetGeo) + 250)))
                : msgTarget.OrderByDescending(
                        m => m.t.NewScore*(100 - SqlFunctions.Exp(SqlFunctions.SquareRoot(m.pm.Coordinate.Distance(targetGeo)/userDistance*100)/2.25))/100
                    )
                    .ThenBy(m => m.pm.Coordinate.Distance(targetGeo));

@rowanmiller
Copy link
Contributor

rowanmiller commented Dec 5, 2016

@marinehero we are planning the exact feature set for 1.2 at the moment - type conversion work (which would enable spatial) is something we are considering. We'll blog as soon as plans are locked.

cc @divega in case he has any ideas about type mapping. I don't think it is as easy as replacing the type mapper (but Diego recently played with this area... so he may have some good insights).

@ajcvickers ajcvickers reopened this Oct 16, 2022
@ajcvickers ajcvickers closed this as not planned Won't fix, can't repro, duplicate, stale Oct 16, 2022
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

4 participants