SQL connection on a web service

Discussion in 'ASP .Net Web Services' started by Andrea, Jul 16, 2005.

  1. Andrea

    Andrea Guest

    I'm building my first webservice and I've some doubt about the life's
    cycle.
    Teorically a webservice is consumed and dead just after it has released
    the information for which it has been built.

    So, because I've to use the webservice like a bridge to store sql info
    on a SQL Server table, how can I make sql connection persistent?
    Just to avoid sql connection create and destroy process every time.

    Thanks
    Andrea
     
    Andrea, Jul 16, 2005
    #1
    1. Advertising

  2. Hi Andrea.
    if you need a persistent connection, how about a replication scenario
    instead of Web svc?
    On the other side, Web svc consuming is tipically disconnected, while svc
    itself could be or not.

    "Andrea" <> ha scritto nel messaggio
    news:...
    > I'm building my first webservice and I've some doubt about the life's
    > cycle.
    > Teorically a webservice is consumed and dead just after it has released
    > the information for which it has been built.
    >
    > So, because I've to use the webservice like a bridge to store sql info
    > on a SQL Server table, how can I make sql connection persistent?
    > Just to avoid sql connection create and destroy process every time.
    >
    > Thanks
    > Andrea
    >
     
    Saverio Tedeschi, Jul 17, 2005
    #2
    1. Advertising

  3. ..NET keeps a pool of SQL connections 'alive', this way SQL connections are
    re-used and not recreated every time you do a 'cn.open'. for SQL connections
    to be 'pooled' they'd have to have to exact same ConnectString.

    HTH,
    Jurjen.

    "Andrea" <> wrote in message
    news:...
    > I'm building my first webservice and I've some doubt about the life's
    > cycle.
    > Teorically a webservice is consumed and dead just after it has released
    > the information for which it has been built.
    >
    > So, because I've to use the webservice like a bridge to store sql info
    > on a SQL Server table, how can I make sql connection persistent?
    > Just to avoid sql connection create and destroy process every time.
    >
    > Thanks
    > Andrea
    >
     
    Jurjen de Groot, Jul 20, 2005
    #3
    1. Advertising

Want to reply to this thread or ask your own question?

It takes just 2 minutes to sign up (and it's free!). Just click the sign up button to choose a username and then you can ask your own questions on the forum.
Similar Threads
  1. hocho888
    Replies:
    1
    Views:
    680
  2. HalcyonWild
    Replies:
    2
    Views:
    1,003
    HalcyonWild
    Dec 19, 2005
  3. Michael Averstegge
    Replies:
    0
    Views:
    4,323
    Michael Averstegge
    Jan 10, 2006
  4. Scott Baierl
    Replies:
    1
    Views:
    302
    Scott Baierl
    Jul 29, 2006
  5. Leo Violette
    Replies:
    0
    Views:
    1,099
    Leo Violette
    Apr 17, 2009
Loading...

Share This Page