Skip to content
  • Categories
  • Recent
  • Tags
  • Popular
  • World
  • Users
  • Groups
Skins
  • Light
  • Cerulean
  • Cosmo
  • Flatly
  • Journal
  • Litera
  • Lumen
  • Lux
  • Materia
  • Minty
  • Morph
  • Pulse
  • Sandstone
  • Simplex
  • Sketchy
  • Spacelab
  • United
  • Yeti
  • Zephyr
  • Dark
  • Cyborg
  • Darkly
  • Quartz
  • Slate
  • Solar
  • Superhero
  • Vapor

  • Default (No Skin)
  • No Skin
Collapse
Code Project
  1. Home
  2. General Programming
  3. C#
  4. design question.

design question.

Scheduled Pinned Locked Moved C#
questiondesignsysadmintutorial
4 Posts 3 Posters 0 Views 1 Watching
  • Oldest to Newest
  • Newest to Oldest
  • Most Votes
Reply
  • Reply as topic
Log in to reply
This topic has been deleted. Only users with topic management privileges can see it.
  • J Offline
    J Offline
    jtmtv18
    wrote on last edited by
    #1

    im trying to write a effective file sharing program. The program should brake down a file into pieces (byte[]) and send them over the network to the client. The client should then return a recipt or something, letting the sender know that he just recieved the byte[] then repeat. in the event the client never sends a recipt, the sender will then resend the previous byte[]. What im asking is, what is a efficient way and effective way of doing this. obviously hashcodes would need to be employed to ensure the client has recieved the correct data. any ideas/code examples on how to do this would be much appreciated. as it stands now i wrote a dll that automaticly deserializes (spelling),compresses,encrypts and sends it. the recieved does the oposite and then sends the newly formed object back. is there a easyier way of doing this? thnx, jesse The Code Project Is Your Friend...

    D 1 Reply Last reply
    0
    • J jtmtv18

      im trying to write a effective file sharing program. The program should brake down a file into pieces (byte[]) and send them over the network to the client. The client should then return a recipt or something, letting the sender know that he just recieved the byte[] then repeat. in the event the client never sends a recipt, the sender will then resend the previous byte[]. What im asking is, what is a efficient way and effective way of doing this. obviously hashcodes would need to be employed to ensure the client has recieved the correct data. any ideas/code examples on how to do this would be much appreciated. as it stands now i wrote a dll that automaticly deserializes (spelling),compresses,encrypts and sends it. the recieved does the oposite and then sends the newly formed object back. is there a easyier way of doing this? thnx, jesse The Code Project Is Your Friend...

      D Offline
      D Offline
      Daniel Turini
      wrote on last edited by
      #2

      jtmtv18 wrote: im trying to write a effective file sharing program Depending on what you're trying to achieve, this is not easy. jtmtv18 wrote: The client should then return a recipt or something, letting the sender know that he just recieved the byte[] then repeat. Unless you're using UDP packets, there's no need on doing this. TCP assures that the connection is either dropped or the packet is received. jtmtv18 wrote: obviously hashcodes would need to be employed to ensure the client has recieved the correct data. Again, TCP assures that, and handle packet retransmissions automatically. Yes, even I am blogging now!

      L 1 Reply Last reply
      0
      • D Daniel Turini

        jtmtv18 wrote: im trying to write a effective file sharing program Depending on what you're trying to achieve, this is not easy. jtmtv18 wrote: The client should then return a recipt or something, letting the sender know that he just recieved the byte[] then repeat. Unless you're using UDP packets, there's no need on doing this. TCP assures that the connection is either dropped or the packet is received. jtmtv18 wrote: obviously hashcodes would need to be employed to ensure the client has recieved the correct data. Again, TCP assures that, and handle packet retransmissions automatically. Yes, even I am blogging now!

        L Offline
        L Offline
        leppie
        wrote on last edited by
        #3

        .NET Sockets is very poor, to say at best, it fails miserbly under load, sending packets in the wrong order... top secret
        Download xacc-ide 0.0.3 now!
        See some screenshots

        J 1 Reply Last reply
        0
        • L leppie

          .NET Sockets is very poor, to say at best, it fails miserbly under load, sending packets in the wrong order... top secret
          Download xacc-ide 0.0.3 now!
          See some screenshots

          J Offline
          J Offline
          jtmtv18
          wrote on last edited by
          #4

          is there a already established class or dll that would do the job ? i have noticed that the packets do send out of order sometimes. The Code Project Is Your Friend...

          1 Reply Last reply
          0
          Reply
          • Reply as topic
          Log in to reply
          • Oldest to Newest
          • Newest to Oldest
          • Most Votes


          • Login

          • Don't have an account? Register

          • Login or register to search.
          • First post
            Last post
          0
          • Categories
          • Recent
          • Tags
          • Popular
          • World
          • Users
          • Groups