Results 1 to 6 of 6

Thread: How to use an intermediate (front-end) server to access data

  1. #1

    Thread Starter
    Lively Member
    Join Date
    Jul 2007
    Posts
    64

    How to use an intermediate (front-end) server to access data

    Hello, I've been developing some small data driven applications for my company.
    Basically, I have a SQL Server, and build local applications, deployed to a network share (click once) that run locally and access data by using sqlclient.

    Today some guys from the IT department said that, for security purposes, direct access to databases are meant to cease. So I'd better think of a solution involving an intermediate front-end server (the only to have have conectivity to the SQLServer).

    I was thinking...
    Is it possible for my applications to be executed remotelly (in this front-end server)?
    Is it possible for my applications to run locally, but accessing data through the front-end server, somehow?

    What's the best approach?
    Thanks,
    JaVo

  2. #2
    Hyperactive Member
    Join Date
    Mar 2012
    Posts
    311

    Re: How to use an intermediate (front-end) server to access data

    Ouch! that's pretty harsh... I could see restricting access to users that only have SELECT (and possibly INSERT and UPDATE) capabilities, but to completely restrict any access whatsoever seems a little overboard, esp. if these are internal programs that you are creating. Anyways...

    How dynamic is the data? What you may be able to do is have your database server create some flat-file system (like some XML files, which technically are also a "database", but those security guys don't need to know that ) that then pushes those flat-files out to your intermediate server. Then you'd have your applications query those flat-files instead of directly querying the database. If the data is static enough, you could get by with pushing out more current flat-files every few minutes. This type of system shouldn't tax the database server too much, esp. if very few tables are dynamic and even then may change every couple of minutes, yet will still provide your application the necessary data to process.

    I'm not sure about your IT policies, but you might also look into creating dual database servers each with copies of the database, but have one be your "master" database that only provides updates to the "production" database which is what your app's would connect to. This way if someone did mess around with the database thru your app's connection, they'd only mess up the "production" one leaving the golden "master" DB intact.

    Hopefully your programs just pull data from the DB and don't have to go back and update the DB in any way. If data is transferred in both directions, then you may have to use transactions that wait for the intermediate server to check the transaction to see if its safe, before processing the transaction (I'm saying this because otherwise having an open flow of data in both directions would be just as secure whether your connecting directly with the DB server or have some intermediate server).

  3. #3

    Thread Starter
    Lively Member
    Join Date
    Jul 2007
    Posts
    64

    Re: How to use an intermediate (front-end) server to access data

    My apps run locally and do retreive, update, insert and delete records.

    I am about to lose conectivity to my DB server.
    I am about to have a new application server, with conectivity to DB server.

    I'm still struggling, trying to find an easy solution for this.

    I've come across "WCF Data Services", that manages data as a service, which would be a solution. But still don't know if:
    - it is applicable in this scenario (of updating / inserting / deleting records)...
    - works with windows forms apps (the examples I found are all for web applications).

    ... it's not easy... apparently...

  4. #4
    Smooth Moperator techgnome's Avatar
    Join Date
    May 2002
    Posts
    34,532

    Re: How to use an intermediate (front-end) server to access data

    Actually... it's not all that uncommon... what you're looking at is a 3-tier application - NOT to be confused with a 3-layered app... but if your app is layered, then it's not that much harder to get it into tiers...

    Yes, WCF would be a solution... basically what you're going to end up with is this: A client app that connects to the middle server for its data... that middle server then takes care of the calls to the database, retrieves the data, and then returns it back to the calling application. This is done through a WebService call from the client app to the middle tier. Between googline "WCF Data Services" "WCF" and "Web Services" ... there should be plenty out there for you to sink your teeth into.

    -tg
    * I don't respond to private (PM) requests for help. It's not conducive to the general learning of others.*
    * I also don't respond to friend requests. Save a few bits and don't bother. I'll just end up rejecting anyways.*
    * How to get EFFECTIVE help: The Hitchhiker's Guide to Getting Help at VBF - Removing eels from your hovercraft *
    * How to Use Parameters * Create Disconnected ADO Recordset Clones * Set your VB6 ActiveX Compatibility * Get rid of those pesky VB Line Numbers * I swear I saved my data, where'd it run off to??? *

  5. #5

    Thread Starter
    Lively Member
    Join Date
    Jul 2007
    Posts
    64

    Re: How to use an intermediate (front-end) server to access data

    Quote Originally Posted by techgnome View Post
    Actually... it's not all that uncommon... what you're looking at is a 3-tier application - NOT to be confused with a 3-layered app... but if your app is layered, then it's not that much harder to get it into tiers...

    Yes, WCF would be a solution... basically what you're going to end up with is this: A client app that connects to the middle server for its data... that middle server then takes care of the calls to the database, retrieves the data, and then returns it back to the calling application. This is done through a WebService call from the client app to the middle tier. Between googline "WCF Data Services" "WCF" and "Web Services" ... there should be plenty out there for you to sink your teeth into.

    -tg
    I am using Visual Studio 2010 Express. All "WCF Data Services" guides I found have the step:
    (right-click in the solution, "Add.." > "New Item" > "WCF Data Service").

    I have to stop here, since I don't have the option "WCF Data Service".

    Is this a framework 4.5 feature?
    Can I use this, using the Express version?
    Can I use this, using a Windows Forms project?

  6. #6
    Hyperactive Member
    Join Date
    Jan 2010
    Posts
    259

    Re: How to use an intermediate (front-end) server to access data

    Odds are you have c# express and WCF projects are part of the Web Developer Express package.

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •  



Click Here to Expand Forum to Full Width