From michal at traffixsystems.com Tue Jan 5 22:09:55 2010 From: michal at traffixsystems.com (Michal Lefler) Date: Wed, 6 Jan 2010 08:09:55 +0200 Subject: [sctp-dev] Use SCTP with Java 1.6? Message-ID: Hi. I would like to use this SCTP implementation with my Java 1.6_17. Is there a binary distribution of this package alone? How can I use this SCTP package with Java 1.6? Thanks, Michal. -------------- next part -------------- An HTML attachment was scrubbed... URL: http://mail.openjdk.java.net/pipermail/sctp-dev/attachments/20100106/75cc43a7/attachment.html From Christopher.Hegarty at Sun.COM Wed Jan 6 06:57:12 2010 From: Christopher.Hegarty at Sun.COM (Christopher Hegarty - Sun Microsystems Ireland) Date: Wed, 06 Jan 2010 14:57:12 +0000 Subject: [sctp-dev] Use SCTP with Java 1.6? In-Reply-To: References: Message-ID: <4B44A4C8.6030002@Sun.COM> Hi Michal, There is no binary/package of SCTP available for JDK6. We received a number of inquiries about this so far, but none of which are considered a high enough priority to consider an official backport to JDK6. That being said, a while back I took the API and implementation from JDK7 and tried to bolt it onto a JDK6 update. It was close to completion, but I got side tracked with other things. When designing the API, and doing the implementation, I considered the possibility that it may one day be ported to JDK6. If you look at the implementation and you will see that there are very little JDK7 dependencies. It should be relatively straight forward to extract the API and implementation and have it run with JDK6. One caveat, the implementation depends on a sun private API and will only run with Sun's JDK. Is this something you would be willing to work on? I can certainly help, but I don't have the time right now to run with it myself. -Chris. On 06/01/2010 06:09, Michal Lefler wrote: > Hi. > > I would like to use this SCTP implementation with my Java 1.6_17. Is > there a binary distribution of this package alone? > > How can I use this SCTP package with Java 1.6? > > Thanks, > > Michal. > > > > From Christopher.Hegarty at Sun.COM Fri Jan 8 08:23:18 2010 From: Christopher.Hegarty at Sun.COM (Christopher Hegarty - Sun Microsystems Ireland) Date: Fri, 08 Jan 2010 16:23:18 +0000 Subject: [sctp-dev] Use SCTP with Java 1.6? In-Reply-To: <4B44A4C8.6030002@Sun.COM> References: <4B44A4C8.6030002@Sun.COM> Message-ID: <4B475BF6.50703@Sun.COM> Hi Michal, I was trying to come up with a list of things to do to get the SCTP implementation working on JDK6, when I came across a previous attempt I made at it. To my surprise I had actually got further than I thought, and I found a list of changes I wanted to push into JDK7 so make this simpler ( as well as a few new ones ). From that I created; 6915313: (sctp) Reorganize implementation to make it more feasible to port to JDK6 Webrev: http://cr.openjdk.java.net/~chegar/6915313/webrev.0/webrev/ With these changes applied we can simply take the JDK7 SCTP code, and with two very minor edits have it run with JDK6. I did this and have it running with JDK6u17. Without the above mentioned changes it is a little more tricky because you need to make many more edits and recompile the native code. I will be requesting a review of 6915313 and hope to be in a position to push it early next week. I can then send detailed instructions of how to get it working with JDK 6. -Chris. On 06/01/2010 14:57, Christopher Hegarty - Sun Microsystems Ireland wrote: > Hi Michal, > > There is no binary/package of SCTP available for JDK6. We received a > number of inquiries about this so far, but none of which are considered > a high enough priority to consider an official backport to JDK6. > > That being said, a while back I took the API and implementation from > JDK7 and tried to bolt it onto a JDK6 update. It was close to > completion, but I got side tracked with other things. When designing the > API, and doing the implementation, I considered the possibility that it > may one day be ported to JDK6. If you look at the implementation and you > will see that there are very little JDK7 dependencies. It should be > relatively straight forward to extract the API and implementation and > have it run with JDK6. One caveat, the implementation depends on a sun > private API and will only run with Sun's JDK. > > Is this something you would be willing to work on? I can certainly help, > but I don't have the time right now to run with it myself. > > -Chris. > > On 06/01/2010 06:09, Michal Lefler wrote: >> Hi. >> >> I would like to use this SCTP implementation with my Java 1.6_17. Is >> there a binary distribution of this package alone? >> >> How can I use this SCTP package with Java 1.6? >> >> Thanks, >> >> Michal. >> >> >> >> From Christopher.Hegarty at Sun.COM Fri Jan 8 08:26:03 2010 From: Christopher.Hegarty at Sun.COM (Christopher Hegarty - Sun Microsystems Ireland) Date: Fri, 08 Jan 2010 16:26:03 +0000 Subject: [sctp-dev] Request for Review: 6915313 Message-ID: <4B475C9B.5050207@Sun.COM> Hi, We have received several requests about porting the SCTP API to JDK6. This bug aims to amend the current implementation to minimize the amount of changes required to port it to JDK6. 1) Remove JDK7 API dependences from the implementation 2) provide all native functionality within libsctp.so 6915313: (sctp) Reorganize implementation to make it more feasible to port to JDK6 Webrev: http://cr.openjdk.java.net/~chegar/6915313/webrev.0/webrev/ Thanks, -Chris. From gnu_andrew at member.fsf.org Fri Jan 8 08:32:02 2010 From: gnu_andrew at member.fsf.org (Andrew John Hughes) Date: Fri, 8 Jan 2010 16:32:02 +0000 Subject: [sctp-dev] Request for Review: 6915313 In-Reply-To: <4B475C9B.5050207@Sun.COM> References: <4B475C9B.5050207@Sun.COM> Message-ID: <17c6771e1001080832s7e794de9id6bb3e96636e06f5@mail.gmail.com> 2010/1/8 Christopher Hegarty - Sun Microsystems Ireland : > Hi, > > We have received several requests about porting the SCTP API to JDK6. This > bug aims to amend the current implementation to minimize the amount of > changes required to port it to JDK6. > > 1) Remove JDK7 API dependences from the implementation > 2) provide all native functionality within libsctp.so > > 6915313: (sctp) Reorganize implementation to make it more feasible to port > to JDK6 > > Webrev: > ?http://cr.openjdk.java.net/~chegar/6915313/webrev.0/webrev/ > > Thanks, > -Chris. > For OpenJDK6, I think it would be better to port over SCTP after the b18 release which is currently undergoing final testing. So please don't push anything to the OpenJDK6 repositories just yet :-) -- Andrew :-) Free Java Software Engineer Red Hat, Inc. (http://www.redhat.com) Support Free Java! Contribute to GNU Classpath and the OpenJDK http://www.gnu.org/software/classpath http://openjdk.java.net PGP Key: 94EFD9D8 (http://subkeys.pgp.net) Fingerprint: F8EF F1EA 401E 2E60 15FA 7927 142C 2591 94EF D9D8 From Christopher.Hegarty at Sun.COM Fri Jan 8 08:38:21 2010 From: Christopher.Hegarty at Sun.COM (Christopher Hegarty - Sun Microsystems Ireland) Date: Fri, 08 Jan 2010 16:38:21 +0000 Subject: [sctp-dev] Request for Review: 6915313 In-Reply-To: <17c6771e1001080832s7e794de9id6bb3e96636e06f5@mail.gmail.com> References: <4B475C9B.5050207@Sun.COM> <17c6771e1001080832s7e794de9id6bb3e96636e06f5@mail.gmail.com> Message-ID: <4B475F7D.7040401@Sun.COM> On 08/01/2010 16:32, Andrew John Hughes wrote: > .... > > For OpenJDK6, I think it would be better to port over SCTP after the > b18 release which is currently undergoing final testing. So please > don't push anything to the OpenJDK6 repositories just yet :-) Oh, maybe the bug description is a little misleading. What this bug plans to do is simply reorganize the SCTP implementation in JDK7 so that it can be ripped out and bolted onto a standard Sun JDK6 (if that's the kind of thing you like to do!). There are no changes planned for OpenJDK6, just JDK7. -Chris. From Alan.Bateman at Sun.COM Sun Jan 10 08:27:51 2010 From: Alan.Bateman at Sun.COM (Alan Bateman) Date: Sun, 10 Jan 2010 16:27:51 +0000 Subject: [sctp-dev] Request for Review: 6915313 In-Reply-To: <4B475C9B.5050207@Sun.COM> References: <4B475C9B.5050207@Sun.COM> Message-ID: <4B4A0007.2090909@sun.com> Christopher Hegarty - Sun Microsystems Ireland wrote: > Hi, > > We have received several requests about porting the SCTP API to JDK6. > This bug aims to amend the current implementation to minimize the > amount of changes required to port it to JDK6. > > 1) Remove JDK7 API dependences from the implementation > 2) provide all native functionality within libsctp.so > > 6915313: (sctp) Reorganize implementation to make it more feasible to > port to JDK6 > > Webrev: > http://cr.openjdk.java.net/~chegar/6915313/webrev.0/webrev/ > > Thanks, > -Chris. If I understand correctly, you're trying to help the folks that want to take this code and hack on it with jdk6 - is that right? Have you considered creating a page on the SCTP project with the recipe. Seems like removing the dependency on SocketOption and AlreadyBoundException are trivial and maybe there isn't a need to add commented out code. As the implementation is very tied to the selector implementation then I assume it's not an issue to keep the dependency on NativeDispatcher. That would avoid having to duplicate close/preClose at least. Otherwise looks okay to me. -Alan. From Christopher.Hegarty at Sun.COM Mon Jan 11 01:38:27 2010 From: Christopher.Hegarty at Sun.COM (Christopher Hegarty - Sun Microsystems Ireland) Date: Mon, 11 Jan 2010 09:38:27 +0000 Subject: [sctp-dev] Request for Review: 6915313 In-Reply-To: <4B4A0007.2090909@sun.com> References: <4B475C9B.5050207@Sun.COM> <4B4A0007.2090909@sun.com> Message-ID: <4B4AF193.70101@Sun.COM> On 10/01/2010 16:27, Alan Bateman wrote: > .... > If I understand correctly, you're trying to help the folks that want to > take this code and hack on it with jdk6 - is that right? Yes, this is correct. > Have you > considered creating a page on the SCTP project with the recipe. This is a great idea. > Seems > like removing the dependency on SocketOption and AlreadyBoundException > are trivial and maybe there isn't a need to add commented out code. As > the implementation is very tied to the selector implementation then I > assume it's not an issue to keep the dependency on NativeDispatcher. > That would avoid having to duplicate close/preClose at least. Otherwise > looks okay to me. The only reason I removed the dependency on NativeDispatcher is that its implementation invokes FileDispatcherImpl close & preClose, and this class was renamed in JDK7, from FileDispatcher. I decided to remove it as it was just another edit to make and the implementation was so trivial anyway. -Chris. > > -Alan. From dennis.hjort at ericsson.com Tue Jan 12 04:22:22 2010 From: dennis.hjort at ericsson.com (Dennis Hjort) Date: Tue, 12 Jan 2010 13:22:22 +0100 Subject: [sctp-dev] Use SCTP with Java 1.6? In-Reply-To: <4B475BF6.50703@Sun.COM> References: <4B44A4C8.6030002@Sun.COM> <4B475BF6.50703@Sun.COM> Message-ID: Hi Christopher ! I've been reading your posts regarding this topic, and downloaded the source, and applied the patch. Now I would like to compile a jdk6 compatible sctp-lib! :-) As you already know, our management is holding of moving up to JDK7 until a standard release, maybe even longer, and we are now trying to cut of performance costs in the product we are building, and now we even have numbers on what our implementation using the JNI library + additions to our eventkernel to handle the blocking channels is costing in performance, so it would be great to be able to use the sctplib with JDK6 already ! :-) So, if it's possible I would appreciate the detailed instructions on how to get it working with JDK6 ! :-) With kind regards // Dennis -----Original Message----- From: sctp-dev-bounces at openjdk.java.net [mailto:sctp-dev-bounces at openjdk.java.net] On Behalf Of Christopher Hegarty - Sun Microsystems Ireland Sent: den 8 januari 2010 17:23 To: Michal Lefler Cc: sctp-dev at openjdk.java.net Subject: Re: [sctp-dev] Use SCTP with Java 1.6? Hi Michal, I was trying to come up with a list of things to do to get the SCTP implementation working on JDK6, when I came across a previous attempt I made at it. To my surprise I had actually got further than I thought, and I found a list of changes I wanted to push into JDK7 so make this simpler ( as well as a few new ones ). From that I created; 6915313: (sctp) Reorganize implementation to make it more feasible to port to JDK6 Webrev: http://cr.openjdk.java.net/~chegar/6915313/webrev.0/webrev/ With these changes applied we can simply take the JDK7 SCTP code, and with two very minor edits have it run with JDK6. I did this and have it running with JDK6u17. Without the above mentioned changes it is a little more tricky because you need to make many more edits and recompile the native code. I will be requesting a review of 6915313 and hope to be in a position to push it early next week. I can then send detailed instructions of how to get it working with JDK 6. -Chris. On 06/01/2010 14:57, Christopher Hegarty - Sun Microsystems Ireland wrote: > Hi Michal, > > There is no binary/package of SCTP available for JDK6. We received a > number of inquiries about this so far, but none of which are > considered a high enough priority to consider an official backport to JDK6. > > That being said, a while back I took the API and implementation from > JDK7 and tried to bolt it onto a JDK6 update. It was close to > completion, but I got side tracked with other things. When designing > the API, and doing the implementation, I considered the possibility > that it may one day be ported to JDK6. If you look at the > implementation and you will see that there are very little JDK7 > dependencies. It should be relatively straight forward to extract the > API and implementation and have it run with JDK6. One caveat, the > implementation depends on a sun private API and will only run with Sun's JDK. > > Is this something you would be willing to work on? I can certainly > help, but I don't have the time right now to run with it myself. > > -Chris. > > On 06/01/2010 06:09, Michal Lefler wrote: >> Hi. >> >> I would like to use this SCTP implementation with my Java 1.6_17. Is >> there a binary distribution of this package alone? >> >> How can I use this SCTP package with Java 1.6? >> >> Thanks, >> >> Michal. >> >> >> >> From Christopher.Hegarty at Sun.COM Wed Jan 13 03:41:02 2010 From: Christopher.Hegarty at Sun.COM (Christopher Hegarty - Sun Microsystems) Date: Wed, 13 Jan 2010 11:41:02 +0000 Subject: [sctp-dev] Use SCTP with Java 1.6? In-Reply-To: References: <4B44A4C8.6030002@Sun.COM> <4B475BF6.50703@Sun.COM> Message-ID: <4B4DB14E.50208@sun.com> Hi Dennis, Michal, I added a page to the sctp project site [1] with, what I believe are detailed, instructions of how to use SCTP with JDK6. Please take a look and try them out. If you encounter any problems of find something lacking from the instructions then please let me know. If the instructions are sufficient and you getting it running without any problem, please let me know you experience. -Chris. [1] http://openjdk.java.net/projects/sctp/html/sctp6.html Dennis Hjort wrote: > Hi Christopher ! > > I've been reading your posts regarding this topic, and downloaded the > source, and applied the patch. Now I would like to compile a jdk6 > compatible sctp-lib! :-) > > As you already know, our management is holding of moving up to JDK7 > until a standard release, maybe even longer, and we are now trying to > cut of performance costs in the product we are building, and now we even > have numbers on what our implementation using the JNI library + > additions to our eventkernel to handle the blocking channels is costing > in performance, so it would be great to be able to use the sctplib with > JDK6 already ! :-) > > So, if it's possible I would appreciate the detailed instructions on how > to get it working with JDK6 ! :-) > > With kind regards > > // Dennis > > -----Original Message----- > From: sctp-dev-bounces at openjdk.java.net > [mailto:sctp-dev-bounces at openjdk.java.net] On Behalf Of Christopher > Hegarty - Sun Microsystems Ireland > Sent: den 8 januari 2010 17:23 > To: Michal Lefler > Cc: sctp-dev at openjdk.java.net > Subject: Re: [sctp-dev] Use SCTP with Java 1.6? > > Hi Michal, > > I was trying to come up with a list of things to do to get the SCTP > implementation working on JDK6, when I came across a previous attempt I > made at it. To my surprise I had actually got further than I thought, > and I found a list of changes I wanted to push into JDK7 so make this > simpler ( as well as a few new ones ). > > From that I created; > 6915313: (sctp) Reorganize implementation to make it more feasible to > port to JDK6 > > Webrev: > http://cr.openjdk.java.net/~chegar/6915313/webrev.0/webrev/ > > With these changes applied we can simply take the JDK7 SCTP code, and > with two very minor edits have it run with JDK6. I did this and have it > running with JDK6u17. Without the above mentioned changes it is a little > more tricky because you need to make many more edits and recompile the > native code. > > I will be requesting a review of 6915313 and hope to be in a position to > push it early next week. I can then send detailed instructions of how to > get it working with JDK 6. > > -Chris. > > On 06/01/2010 14:57, Christopher Hegarty - Sun Microsystems Ireland > wrote: >> Hi Michal, >> >> There is no binary/package of SCTP available for JDK6. We received a >> number of inquiries about this so far, but none of which are >> considered a high enough priority to consider an official backport to > JDK6. >> That being said, a while back I took the API and implementation from >> JDK7 and tried to bolt it onto a JDK6 update. It was close to >> completion, but I got side tracked with other things. When designing >> the API, and doing the implementation, I considered the possibility >> that it may one day be ported to JDK6. If you look at the >> implementation and you will see that there are very little JDK7 >> dependencies. It should be relatively straight forward to extract the >> API and implementation and have it run with JDK6. One caveat, the >> implementation depends on a sun private API and will only run with > Sun's JDK. >> Is this something you would be willing to work on? I can certainly >> help, but I don't have the time right now to run with it myself. >> >> -Chris. >> >> On 06/01/2010 06:09, Michal Lefler wrote: >>> Hi. >>> >>> I would like to use this SCTP implementation with my Java 1.6_17. Is >>> there a binary distribution of this package alone? >>> >>> How can I use this SCTP package with Java 1.6? >>> >>> Thanks, >>> >>> Michal. >>> >>> >>> >>> From dennis.hjort at ericsson.com Thu Jan 14 02:19:38 2010 From: dennis.hjort at ericsson.com (Dennis Hjort) Date: Thu, 14 Jan 2010 11:19:38 +0100 Subject: [sctp-dev] Use SCTP with Java 1.6? In-Reply-To: <4B4DB14E.50208@sun.com> References: <4B44A4C8.6030002@Sun.COM> <4B475BF6.50703@Sun.COM> <4B4DB14E.50208@sun.com> Message-ID: Thanks Christopher ! :-) I'll get right on trying it out ! :-) With kind regards // D -----Original Message----- From: Christopher.Hegarty at Sun.COM [mailto:Christopher.Hegarty at Sun.COM] Sent: den 13 januari 2010 12:41 To: Dennis Hjort; Michal Lefler Cc: sctp-dev at openjdk.java.net Subject: Re: [sctp-dev] Use SCTP with Java 1.6? Hi Dennis, Michal, I added a page to the sctp project site [1] with, what I believe are detailed, instructions of how to use SCTP with JDK6. Please take a look and try them out. If you encounter any problems of find something lacking from the instructions then please let me know. If the instructions are sufficient and you getting it running without any problem, please let me know you experience. -Chris. [1] http://openjdk.java.net/projects/sctp/html/sctp6.html Dennis Hjort wrote: > Hi Christopher ! > > I've been reading your posts regarding this topic, and downloaded the > source, and applied the patch. Now I would like to compile a jdk6 > compatible sctp-lib! :-) > > As you already know, our management is holding of moving up to JDK7 > until a standard release, maybe even longer, and we are now trying to > cut of performance costs in the product we are building, and now we > even have numbers on what our implementation using the JNI library + > additions to our eventkernel to handle the blocking channels is > costing in performance, so it would be great to be able to use the > sctplib with > JDK6 already ! :-) > > So, if it's possible I would appreciate the detailed instructions on > how to get it working with JDK6 ! :-) > > With kind regards > > // Dennis > > -----Original Message----- > From: sctp-dev-bounces at openjdk.java.net > [mailto:sctp-dev-bounces at openjdk.java.net] On Behalf Of Christopher > Hegarty - Sun Microsystems Ireland > Sent: den 8 januari 2010 17:23 > To: Michal Lefler > Cc: sctp-dev at openjdk.java.net > Subject: Re: [sctp-dev] Use SCTP with Java 1.6? > > Hi Michal, > > I was trying to come up with a list of things to do to get the SCTP > implementation working on JDK6, when I came across a previous attempt > I made at it. To my surprise I had actually got further than I > thought, and I found a list of changes I wanted to push into JDK7 so > make this simpler ( as well as a few new ones ). > > From that I created; > 6915313: (sctp) Reorganize implementation to make it more feasible > to port to JDK6 > > Webrev: > http://cr.openjdk.java.net/~chegar/6915313/webrev.0/webrev/ > > With these changes applied we can simply take the JDK7 SCTP code, and > with two very minor edits have it run with JDK6. I did this and have > it running with JDK6u17. Without the above mentioned changes it is a > little more tricky because you need to make many more edits and > recompile the native code. > > I will be requesting a review of 6915313 and hope to be in a position > to push it early next week. I can then send detailed instructions of > how to get it working with JDK 6. > > -Chris. > > On 06/01/2010 14:57, Christopher Hegarty - Sun Microsystems Ireland > wrote: >> Hi Michal, >> >> There is no binary/package of SCTP available for JDK6. We received a >> number of inquiries about this so far, but none of which are >> considered a high enough priority to consider an official backport to > JDK6. >> That being said, a while back I took the API and implementation from >> JDK7 and tried to bolt it onto a JDK6 update. It was close to >> completion, but I got side tracked with other things. When designing >> the API, and doing the implementation, I considered the possibility >> that it may one day be ported to JDK6. If you look at the >> implementation and you will see that there are very little JDK7 >> dependencies. It should be relatively straight forward to extract the >> API and implementation and have it run with JDK6. One caveat, the >> implementation depends on a sun private API and will only run with > Sun's JDK. >> Is this something you would be willing to work on? I can certainly >> help, but I don't have the time right now to run with it myself. >> >> -Chris. >> >> On 06/01/2010 06:09, Michal Lefler wrote: >>> Hi. >>> >>> I would like to use this SCTP implementation with my Java 1.6_17. Is >>> there a binary distribution of this package alone? >>> >>> How can I use this SCTP package with Java 1.6? >>> >>> Thanks, >>> >>> Michal. >>> >>> >>> >>> From Christopher.Hegarty at Sun.COM Thu Jan 14 02:23:59 2010 From: Christopher.Hegarty at Sun.COM (Christopher Hegarty - Sun Microsystems Ireland) Date: Thu, 14 Jan 2010 10:23:59 +0000 Subject: [sctp-dev] Use SCTP with Java 1.6? In-Reply-To: References: <4B44A4C8.6030002@Sun.COM> <4B475BF6.50703@Sun.COM> <4B4DB14E.50208@sun.com> Message-ID: <4B4EF0BF.5010909@Sun.COM> You may want to get the latest JDK6 update, u18, which was just releases ;-) http://java.sun.com/javase/downloads/ -Chris. On 14/01/2010 10:19, Dennis Hjort wrote: > Thanks Christopher ! :-) > > I'll get right on trying it out ! :-) > > With kind regards > > // D > > -----Original Message----- > From: Christopher.Hegarty at Sun.COM [mailto:Christopher.Hegarty at Sun.COM] > Sent: den 13 januari 2010 12:41 > To: Dennis Hjort; Michal Lefler > Cc: sctp-dev at openjdk.java.net > Subject: Re: [sctp-dev] Use SCTP with Java 1.6? > > Hi Dennis, Michal, > > I added a page to the sctp project site [1] with, what I believe are > detailed, instructions of how to use SCTP with JDK6. Please take a look > and try them out. > > If you encounter any problems of find something lacking from the > instructions then please let me know. If the instructions are sufficient > and you getting it running without any problem, please let me know you > experience. > > -Chris. > > [1] http://openjdk.java.net/projects/sctp/html/sctp6.html > > Dennis Hjort wrote: >> Hi Christopher ! >> >> I've been reading your posts regarding this topic, and downloaded the >> source, and applied the patch. Now I would like to compile a jdk6 >> compatible sctp-lib! :-) >> >> As you already know, our management is holding of moving up to JDK7 >> until a standard release, maybe even longer, and we are now trying to >> cut of performance costs in the product we are building, and now we >> even have numbers on what our implementation using the JNI library + >> additions to our eventkernel to handle the blocking channels is >> costing in performance, so it would be great to be able to use the >> sctplib with >> JDK6 already ! :-) >> >> So, if it's possible I would appreciate the detailed instructions on >> how to get it working with JDK6 ! :-) >> >> With kind regards >> >> // Dennis >> >> -----Original Message----- >> From: sctp-dev-bounces at openjdk.java.net >> [mailto:sctp-dev-bounces at openjdk.java.net] On Behalf Of Christopher >> Hegarty - Sun Microsystems Ireland >> Sent: den 8 januari 2010 17:23 >> To: Michal Lefler >> Cc: sctp-dev at openjdk.java.net >> Subject: Re: [sctp-dev] Use SCTP with Java 1.6? >> >> Hi Michal, >> >> I was trying to come up with a list of things to do to get the SCTP >> implementation working on JDK6, when I came across a previous attempt >> I made at it. To my surprise I had actually got further than I >> thought, and I found a list of changes I wanted to push into JDK7 so >> make this simpler ( as well as a few new ones ). >> >> From that I created; >> 6915313: (sctp) Reorganize implementation to make it more feasible >> to port to JDK6 >> >> Webrev: >> http://cr.openjdk.java.net/~chegar/6915313/webrev.0/webrev/ >> >> With these changes applied we can simply take the JDK7 SCTP code, and >> with two very minor edits have it run with JDK6. I did this and have >> it running with JDK6u17. Without the above mentioned changes it is a >> little more tricky because you need to make many more edits and >> recompile the native code. >> >> I will be requesting a review of 6915313 and hope to be in a position >> to push it early next week. I can then send detailed instructions of >> how to get it working with JDK 6. >> >> -Chris. >> >> On 06/01/2010 14:57, Christopher Hegarty - Sun Microsystems Ireland >> wrote: >>> Hi Michal, >>> >>> There is no binary/package of SCTP available for JDK6. We received a >>> number of inquiries about this so far, but none of which are >>> considered a high enough priority to consider an official backport to >> JDK6. >>> That being said, a while back I took the API and implementation from >>> JDK7 and tried to bolt it onto a JDK6 update. It was close to >>> completion, but I got side tracked with other things. When designing >>> the API, and doing the implementation, I considered the possibility >>> that it may one day be ported to JDK6. If you look at the >>> implementation and you will see that there are very little JDK7 >>> dependencies. It should be relatively straight forward to extract the > >>> API and implementation and have it run with JDK6. One caveat, the >>> implementation depends on a sun private API and will only run with >> Sun's JDK. >>> Is this something you would be willing to work on? I can certainly >>> help, but I don't have the time right now to run with it myself. >>> >>> -Chris. >>> >>> On 06/01/2010 06:09, Michal Lefler wrote: >>>> Hi. >>>> >>>> I would like to use this SCTP implementation with my Java 1.6_17. Is > >>>> there a binary distribution of this package alone? >>>> >>>> How can I use this SCTP package with Java 1.6? >>>> >>>> Thanks, >>>> >>>> Michal. >>>> >>>> >>>> >>>> From michal at traffixsystems.com Thu Jan 14 02:25:49 2010 From: michal at traffixsystems.com (Michal Lefler) Date: Thu, 14 Jan 2010 12:25:49 +0200 Subject: [sctp-dev] Use SCTP with Java 1.6? In-Reply-To: References: <4B44A4C8.6030002@Sun.COM> <4B475BF6.50703@Sun.COM> <4B4DB14E.50208@sun.com> Message-ID: It looks great!!! :-) I just executed the simple test (com.sun.nio.sctp.SctpChannel sc = com.sun.nio.sctp.SctpChannel.open();), and it is working!! Thanks a LOT, Michal. -----Original Message----- From: Dennis Hjort [mailto:dennis.hjort at ericsson.com] Sent: Thursday, January 14, 2010 12:20 PM To: Christopher.Hegarty at Sun.COM; Michal Lefler Cc: sctp-dev at openjdk.java.net Subject: RE: [sctp-dev] Use SCTP with Java 1.6? Thanks Christopher ! :-) I'll get right on trying it out ! :-) With kind regards // D -----Original Message----- From: Christopher.Hegarty at Sun.COM [mailto:Christopher.Hegarty at Sun.COM] Sent: den 13 januari 2010 12:41 To: Dennis Hjort; Michal Lefler Cc: sctp-dev at openjdk.java.net Subject: Re: [sctp-dev] Use SCTP with Java 1.6? Hi Dennis, Michal, I added a page to the sctp project site [1] with, what I believe are detailed, instructions of how to use SCTP with JDK6. Please take a look and try them out. If you encounter any problems of find something lacking from the instructions then please let me know. If the instructions are sufficient and you getting it running without any problem, please let me know you experience. -Chris. [1] http://openjdk.java.net/projects/sctp/html/sctp6.html Dennis Hjort wrote: > Hi Christopher ! > > I've been reading your posts regarding this topic, and downloaded the > source, and applied the patch. Now I would like to compile a jdk6 > compatible sctp-lib! :-) > > As you already know, our management is holding of moving up to JDK7 > until a standard release, maybe even longer, and we are now trying to > cut of performance costs in the product we are building, and now we > even have numbers on what our implementation using the JNI library + > additions to our eventkernel to handle the blocking channels is > costing in performance, so it would be great to be able to use the > sctplib with > JDK6 already ! :-) > > So, if it's possible I would appreciate the detailed instructions on > how to get it working with JDK6 ! :-) > > With kind regards > > // Dennis > > -----Original Message----- > From: sctp-dev-bounces at openjdk.java.net > [mailto:sctp-dev-bounces at openjdk.java.net] On Behalf Of Christopher > Hegarty - Sun Microsystems Ireland > Sent: den 8 januari 2010 17:23 > To: Michal Lefler > Cc: sctp-dev at openjdk.java.net > Subject: Re: [sctp-dev] Use SCTP with Java 1.6? > > Hi Michal, > > I was trying to come up with a list of things to do to get the SCTP > implementation working on JDK6, when I came across a previous attempt > I made at it. To my surprise I had actually got further than I > thought, and I found a list of changes I wanted to push into JDK7 so > make this simpler ( as well as a few new ones ). > > From that I created; > 6915313: (sctp) Reorganize implementation to make it more feasible > to port to JDK6 > > Webrev: > http://cr.openjdk.java.net/~chegar/6915313/webrev.0/webrev/ > > With these changes applied we can simply take the JDK7 SCTP code, and > with two very minor edits have it run with JDK6. I did this and have > it running with JDK6u17. Without the above mentioned changes it is a > little more tricky because you need to make many more edits and > recompile the native code. > > I will be requesting a review of 6915313 and hope to be in a position > to push it early next week. I can then send detailed instructions of > how to get it working with JDK 6. > > -Chris. > > On 06/01/2010 14:57, Christopher Hegarty - Sun Microsystems Ireland > wrote: >> Hi Michal, >> >> There is no binary/package of SCTP available for JDK6. We received a >> number of inquiries about this so far, but none of which are >> considered a high enough priority to consider an official backport to > JDK6. >> That being said, a while back I took the API and implementation from >> JDK7 and tried to bolt it onto a JDK6 update. It was close to >> completion, but I got side tracked with other things. When designing >> the API, and doing the implementation, I considered the possibility >> that it may one day be ported to JDK6. If you look at the >> implementation and you will see that there are very little JDK7 >> dependencies. It should be relatively straight forward to extract the >> API and implementation and have it run with JDK6. One caveat, the >> implementation depends on a sun private API and will only run with > Sun's JDK. >> Is this something you would be willing to work on? I can certainly >> help, but I don't have the time right now to run with it myself. >> >> -Chris. >> >> On 06/01/2010 06:09, Michal Lefler wrote: >>> Hi. >>> >>> I would like to use this SCTP implementation with my Java 1.6_17. Is >>> there a binary distribution of this package alone? >>> >>> How can I use this SCTP package with Java 1.6? >>> >>> Thanks, >>> >>> Michal. >>> >>> >>> >>> From bbuffam at rim.com Thu Jan 14 06:17:56 2010 From: bbuffam at rim.com (Bruce Buffam) Date: Thu, 14 Jan 2010 09:17:56 -0500 Subject: [sctp-dev] Socket Options Issue Message-ID: <37335766762332458F9F59CD831915BC01C68ED4@XCH28YOW.rim.net> Hi Chris, I am currently working on integrating the use of SCTP channels into Netty, an Open Source networking framework and I encountered an odd behaviour in setting/getting SO_RCVBUF or SO_SNDBUF. Typically, I have some test code that sets one or both of these options and then immediately tries to retrieve the value. If the retrieved value does not match the value that was set, the test code throws an exception. Here is some example code: @SuppressWarnings("restriction") public void setReceiveBufferSize(int receiveBufferSize) { // TODO Auto-generated method stub try { channel.setOption(SctpStandardSocketOption.SO_RCVBUF, receiveBufferSize); int temp = channel.getOption(SctpStandardSocketOption.SO_RCVBUF); if (temp != receiveBufferSize) throw new IOException("SO_RCVBUF not correctly set"); } catch (IOException e) { // TODO Auto-generated catch block e.printStackTrace(); } } My test case uses odd values like 9753, etc. What I noticed, is that when I do the get, it consistently retrieves the value I set, multiplied by 2. Any thoughts on a possible cause? BTW, the problem is found in: fedora fc11 linux 2.6.30.9-102.fc11.i586 java java version "1.7.0-ea" Java(TM) SE Runtime Environment (build 1.7.0-ea-b78) Java HotSpot(TM) Server VM (build 17.0-b05, mixed mode) Rgds, Bruce Bruce Buffam Blackberry System Architecture Research in Motion tel: +1-613-599-7465 x13036 mobile:+1-613-240-7769 fax: +1-613-599-1922 --------------------------------------------------------------------- This transmission (including any attachments) may contain confidential information, privileged material (including material protected by the solicitor-client or other applicable privileges), or constitute non-public information. Any use of this information by anyone other than the intended recipient is prohibited. If you have received this transmission in error, please immediately reply to the sender and delete this information from your system. Use, dissemination, distribution, or reproduction of this transmission by unintended recipients is not authorized and may be unlawful. -------------- next part -------------- An HTML attachment was scrubbed... URL: http://mail.openjdk.java.net/pipermail/sctp-dev/attachments/20100114/694ab131/attachment-0001.html From Alan.Bateman at Sun.COM Thu Jan 14 07:23:09 2010 From: Alan.Bateman at Sun.COM (Alan Bateman) Date: Thu, 14 Jan 2010 15:23:09 +0000 Subject: [sctp-dev] Socket Options Issue In-Reply-To: <37335766762332458F9F59CD831915BC01C68ED4@XCH28YOW.rim.net> References: <37335766762332458F9F59CD831915BC01C68ED4@XCH28YOW.rim.net> Message-ID: <4B4F36DD.8070708@sun.com> Bruce Buffam wrote: > > Hi Chris, > > > > I am currently working on integrating the use of SCTP channels into > Netty, an Open Source networking framework and I encountered an odd > behaviour in setting/getting SO_RCVBUF or SO_SNDBUF. Typically, I > have some test code that sets one or both of these options and then > immediately tries to retrieve the value. If the retrieved value does > not match the value that was set, the test code throws an exception. > FWIW, when you set these socket options then you are providing a "hint" so you can't assume that the retrieved value will always be exactly the value that you set. > > > > > Here is some example code: > > > > @SuppressWarnings("restriction") > > public void setReceiveBufferSize(int receiveBufferSize) { > > // TODO Auto-generated method stub > > > > try { > > > channel.setOption(SctpStandardSocketOption.SO_RCVBUF, receiveBufferSize); > > int temp = > channel.getOption(SctpStandardSocketOption.SO_RCVBUF); > > if (temp != receiveBufferSize) > > throw new IOException("SO_RCVBUF not correctly > set"); > > } catch (IOException e) { > > // TODO Auto-generated catch block > > e.printStackTrace(); > > } > > } > > > > My test case uses odd values like 9753, etc. What I noticed, is that > when I do the get, it consistently retrieves the value I set, > multiplied by 2. > > Chris - this sounds like you might be missing the conversion/mapping that is done by NET_SetSockOpt/NET_GetSocketOpt. -Alan. From Christopher.Hegarty at Sun.COM Thu Jan 14 07:53:34 2010 From: Christopher.Hegarty at Sun.COM (Christopher Hegarty - Sun Microsystems Ireland) Date: Thu, 14 Jan 2010 15:53:34 +0000 Subject: [sctp-dev] Socket Options Issue In-Reply-To: <4B4F36DD.8070708@sun.com> References: <37335766762332458F9F59CD831915BC01C68ED4@XCH28YOW.rim.net> <4B4F36DD.8070708@sun.com> Message-ID: <4B4F3DFE.2090001@Sun.COM> Hi Bruce, Alan, This is certainly an interesting issue, and surprising it wasn't noticed earlier. As was stated the retrieved SO_RCVBUF or SO_SNDBUF value is exactly twice the size of the value set. [I must admit Bruce sent me a private mail about this issue a few days ago, so I have had a chance to investigate] ;-) Running a simple native test shows that the problem is actually with the native LKSCTP stack, in fact there are actually functional tests for lksctp that test that the retrieved value is twice the value given! I sent a mail to lksctp-developers [1], and they essentially said that the given value is doubled to provide a rough (very rough) estimate of the Socket Kernel Buffer overhead in the kernel per frame. I'm not sure if we want to do anything at the java level to at least make these values match. As Alan said, the value set is only a hint to the OS so I don't think we should have functional tests that are relying on this. Actually, looking at the socket option tests we have in the test directory of OpenJDK the value set for these options is never directly compared to the value retrieved. -Chris. [1] http://sourceforge.net/mailarchive/forum.php?thread_name=20100112114607.GB23290%40hmsreliant.think-freely.org&forum_name=lksctp-developers On 14/01/2010 15:23, Alan Bateman wrote: > Bruce Buffam wrote: >> >> Hi Chris, >> >> >> >> I am currently working on integrating the use of SCTP channels into >> Netty, an Open Source networking framework and I encountered an odd >> behaviour in setting/getting SO_RCVBUF or SO_SNDBUF. Typically, I >> have some test code that sets one or both of these options and then >> immediately tries to retrieve the value. If the retrieved value does >> not match the value that was set, the test code throws an exception. >> > FWIW, when you set these socket options then you are providing a "hint" > so you can't assume that the retrieved value will always be exactly the > value that you set. > >> >> >> >> >> Here is some example code: >> >> >> >> @SuppressWarnings("restriction") >> >> public void setReceiveBufferSize(int receiveBufferSize) { >> >> // TODO Auto-generated method stub >> >> >> try { >> >> >> channel.setOption(SctpStandardSocketOption.SO_RCVBUF, receiveBufferSize); >> >> int temp = >> channel.getOption(SctpStandardSocketOption.SO_RCVBUF); >> >> if (temp != receiveBufferSize) >> >> throw new IOException("SO_RCVBUF not correctly >> set"); >> >> } catch (IOException e) { >> >> // TODO Auto-generated catch block >> >> e.printStackTrace(); >> >> } >> >> } >> >> >> >> My test case uses odd values like 9753, etc. What I noticed, is that >> when I do the get, it consistently retrieves the value I set, >> multiplied by 2. >> >> > Chris - this sounds like you might be missing the conversion/mapping > that is done by NET_SetSockOpt/NET_GetSocketOpt. > > -Alan. > > > From Alan.Bateman at Sun.COM Thu Jan 14 08:06:24 2010 From: Alan.Bateman at Sun.COM (Alan Bateman) Date: Thu, 14 Jan 2010 16:06:24 +0000 Subject: [sctp-dev] Socket Options Issue In-Reply-To: <4B4F3DFE.2090001@Sun.COM> References: <37335766762332458F9F59CD831915BC01C68ED4@XCH28YOW.rim.net> <4B4F36DD.8070708@sun.com> <4B4F3DFE.2090001@Sun.COM> Message-ID: <4B4F4100.1010109@sun.com> Christopher Hegarty - Sun Microsystems Ireland wrote: > : > > I sent a mail to lksctp-developers [1], and they essentially said that > the given value is doubled to provide a rough (very rough) estimate of > the Socket Kernel Buffer overhead in the kernel per frame. > > I'm not sure if we want to do anything at the java level to at least > make these values match. As Alan said, the value set is only a hint to > the OS so I don't think we should have functional tests that are > relying on this. Actually, looking at the socket option tests we have > in the test directory of OpenJDK the value set for these options is > never directly compared to the value retrieved. > > -Chris. It's the similar with TCP and UDP sockets which is why methods such as Socket.getSendBufferSize or SocketChannel.getOption(SO_SNDBUF) return the result / 2. That is, the returned result is meant to be close to what should be available as the send (or receive) buffer. You could do something similar in the SCTP code. -Alan. From Christopher.Hegarty at Sun.COM Thu Jan 14 08:39:05 2010 From: Christopher.Hegarty at Sun.COM (Christopher Hegarty - Sun Microsystems Ireland) Date: Thu, 14 Jan 2010 16:39:05 +0000 Subject: [sctp-dev] Socket Options Issue In-Reply-To: <4B4F4100.1010109@sun.com> References: <37335766762332458F9F59CD831915BC01C68ED4@XCH28YOW.rim.net> <4B4F36DD.8070708@sun.com> <4B4F3DFE.2090001@Sun.COM> <4B4F4100.1010109@sun.com> Message-ID: <4B4F48A9.80309@Sun.COM> On 14/01/2010 16:06, Alan Bateman wrote: > Christopher Hegarty - Sun Microsystems Ireland wrote: >> .... > It's the similar with TCP and UDP sockets which is why methods such as > Socket.getSendBufferSize or SocketChannel.getOption(SO_SNDBUF) return > the result / 2. That is, the returned result is meant to be close to > what should be available as the send (or receive) buffer. You could do > something similar in the SCTP code. OK, got it Alan. I completely overlooked this. I'll filed: 6916922: (sctp) SO_RCVBUF & SO_SNDBUF returns twice the value set Bruce, I hope to have a fix for this in b81, the next available promoted build. -Chris. > > -Alan. From Christopher.Hegarty at Sun.COM Fri Jan 15 02:52:18 2010 From: Christopher.Hegarty at Sun.COM (Christopher Hegarty -Sun Microsystems Ireland) Date: Fri, 15 Jan 2010 10:52:18 +0000 Subject: [sctp-dev] [Fwd: RE: IAE multiple sends] Message-ID: <4B5048E2.9070703@sun.com> [Forwarding because the original message did not make it] -------- Original Message -------- Subject: RE: IAE multiple sends Date: Thu, 14 Jan 2010 12:12:47 -0500 From: Bruce Buffam To: sctp-dev at openjdk.java.net Hi Chris, I have test code that sends a sequence of data packets, generated consecutively from a common byte array, such that on each send a new ByteBuffer is wrapped on the next portion of the byte array. Consistently, the second packet sent (the one with an offset other than 0 triggers the following exception from within SctpChannel.send, regardless of the size of the packets sent The test code looks like the following: byte data[128]; . . . for (int i = 0; i < data.length;) { int length = 64; cc.write(ChannelBuffers.wrappedBuffer(data, i, length),messageInfo); i += length; } This code loops around, wrapping the data in a ChannelBuffer using the function ChannelBuffers.wrappedBuffer, and then scheduling each ChannelBuffer for transmission via the write function. If the data starts at offset 0, but does not encompass all of the contents in the byte array, data, the ChannelBuffer will be instantiated as a TruncatedChannelBuffer. Otherwise, the ChannelBuffer is instantiated as SlicedChannelBuffer. A SlicedChannelBuffer stores the offset into the underlying byte array in integer field named, adjustment. Inside the writer thread, the following sequence ensues: * * . . . ByteBuffer sendBuf = buf.toByteBuffer(); * * if (!sendBuf.hasRemaining()) break; localWrittenBytes += channel.socket.send( sendBuf, messageInfo); . . . The function SlicedChannelBuffer.toByteBuffer does the conversion of the ChannelBuffer to a ChannelBuffer executing the following: public ByteBuffer toByteBuffer(int index, int length) { checkIndex(index, length); return buffer.toByteBuffer(index + adjustment, length); } ?setting the offset to adjustment + index, and ChannelBuffer.toByteBuffer does the final conversion to a ByteBuffer as follows: public ByteBuffer toByteBuffer(int index, int length) { return ByteBuffer.wrap(array, index, length).order(order()); } The error consistently occurs on the second message sent from the underlying data array. As you can see from the following trace where the underlying data array consists of 128 bytes, and the test loop is traversing the byte array creating a sequence of 64 byte messages, the individual ByteBuffers seem to be formatted correctly, with adjustment reflected in the pos value: 1st Buffer java.nio.HeapByteBuffer[pos=0 lim=64 cap=128] 2nd Buffer java.nio.HeapByteBuffer[pos=64 lim=128 cap=128] however, on the second buffer in the sequence, I get the following exception from within the send function. java.lang.IllegalArgumentException at java.nio.Buffer.position(Buffer.java:236) at sun.nio.ch.SctpChannelImpl.sendFromNativeBuffer(SctpChannelImpl.java:1032) at sun.nio.ch.SctpChannelImpl.send(SctpChannelImpl.java:1008) at sun.nio.ch.SctpChannelImpl.send(SctpChannelImpl.java:972) at org.jboss.netty.channel.socket.nio.NioSctpWorker.writeNow(NioSctpWorker.java:517) at org.jboss.netty.channel.socket.nio.NioSctpWorker.write(NioSctpWorker.java:430) at org.jboss.netty.channel.socket.nio.NioSctpSocketChannel$WriteTask.run(NioSctpSocketChannel.java:503) at org.jboss.netty.channel.socket.nio.NioSctpWorker.processWriteTaskQueue(NioSctpWorker.java:307) at org.jboss.netty.channel.socket.nio.NioSctpWorker.run(NioSctpWorker.java:238) at org.jboss.netty.util.internal.IoWorkerRunnable.run(IoWorkerRunnable.java:46) at java.util.concurrent.ThreadPoolExecutor.runWorker(ThreadPoolExecutor.java:1110) at java.util.concurrent.ThreadPoolExecutor$Worker.run(ThreadPoolExecutor.java:603) at java.lang.Thread.run(Thread.java:717) I can reproduce this problem consistently while varying the size of the data array, and varying the size of each message to be generated from the array, the problem still occurs on the second iteration of the test loop. The first instance wherein pos ~= 0? If I change the loop to instead copy the data from the underlying data array, thus resulting in ByteBuffers that wrap from the start of the data array ala the following trace: 1st Buffer java.nio.HeapByteBuffer[pos=0 lim=64 cap=64] 2nd Buffer java.nio.HeapByteBuffer[pos=0 lim=64 cap=64] ?it executes without exception. Hope this helps. Rgds, Bruce From Christopher.Hegarty at Sun.COM Fri Jan 15 07:46:30 2010 From: Christopher.Hegarty at Sun.COM (Christopher Hegarty -Sun Microsystems Ireland) Date: Fri, 15 Jan 2010 15:46:30 +0000 Subject: [sctp-dev] [Fwd: RE: IAE multiple sends] In-Reply-To: <4B5048E2.9070703@sun.com> References: <4B5048E2.9070703@sun.com> Message-ID: <4B508DD6.1080006@sun.com> Bruce, I filed the following bug against this issue. 6916890: SctpChannel.send may cause IAE if given a heap buffer with an offset In the case where a heap buffer is supplied the implementation copies the data into a temporary native buffer before going native. The position and remaining data is incorrectly determined for this temporary buffer when the position of the original buffer is not 0. -Chris. From Christopher.Hegarty at Sun.COM Fri Jan 15 07:54:48 2010 From: Christopher.Hegarty at Sun.COM (Christopher Hegarty -Sun Microsystems Ireland) Date: Fri, 15 Jan 2010 15:54:48 +0000 Subject: [sctp-dev] Request for review: 6916890 Message-ID: <4B508FC8.4030103@sun.com> In the case where a heap buffer is supplied the implementation copies the data into a temporary native buffer before going native. The position and remaining data is incorrectly determined for this temporary buffer when the position of the original buffer is not 0. Also, remove incorrect assertion from implementation. CR 6916890: SctpChannel.send may cause IAE if given a heap buffer with an offset Webrev: http://cr.openjdk.java.net/~chegar/6916890/webrev.0/webrev/ Thanks, -Chris. From Christopher.Hegarty at Sun.COM Fri Jan 15 07:58:31 2010 From: Christopher.Hegarty at Sun.COM (Christopher Hegarty -Sun Microsystems Ireland) Date: Fri, 15 Jan 2010 15:58:31 +0000 Subject: [sctp-dev] Request for Review: 6916922 Message-ID: <4B5090A7.10406@sun.com> see discussion on sctp-dev: http://mail.openjdk.java.net/pipermail/sctp-dev/2010-January/000151.html Essentially, on Linux SO_SNDBUF/SO_RCVBUF aren't symmetric. This stems from additional socket structures in the send and receive buffers. Net_GetSockOpt handles this by dividing the retrieved values by 2. CR 6916922: SO_RCVBUF & SO_SNDBUF returns twice the value set Webrev: http://cr.openjdk.java.net/~chegar/6916922/webrev.0/webrev/ -Chris. From Alan.Bateman at Sun.COM Fri Jan 15 08:23:57 2010 From: Alan.Bateman at Sun.COM (Alan Bateman) Date: Fri, 15 Jan 2010 16:23:57 +0000 Subject: [sctp-dev] Request for Review: 6916922 In-Reply-To: <4B5090A7.10406@sun.com> References: <4B5090A7.10406@sun.com> Message-ID: <4B50969D.8030203@sun.com> Christopher Hegarty -Sun Microsystems Ireland wrote: > see discussion on sctp-dev: > > http://mail.openjdk.java.net/pipermail/sctp-dev/2010-January/000151.html > > Essentially, on Linux SO_SNDBUF/SO_RCVBUF aren't symmetric. This stems > from additional socket structures in the send and receive buffers. > Net_GetSockOpt handles this by dividing the retrieved values by 2. > > CR 6916922: SO_RCVBUF & SO_SNDBUF returns twice the value set > > Webrev: > http://cr.openjdk.java.net/~chegar/6916922/webrev.0/webrev/ > > -Chris. Good okay to me. -Alan. From Christopher.Hegarty at Sun.COM Fri Jan 15 08:35:57 2010 From: Christopher.Hegarty at Sun.COM (Christopher Hegarty -Sun Microsystems Ireland) Date: Fri, 15 Jan 2010 16:35:57 +0000 Subject: [sctp-dev] Socket Options Issue In-Reply-To: <4B4F48A9.80309@Sun.COM> References: <37335766762332458F9F59CD831915BC01C68ED4@XCH28YOW.rim.net> <4B4F36DD.8070708@sun.com> <4B4F3DFE.2090001@Sun.COM> <4B4F4100.1010109@sun.com> <4B4F48A9.80309@Sun.COM> Message-ID: <4B50996D.8060507@sun.com> Christopher Hegarty - Sun Microsystems Ireland wrote: > On 14/01/2010 16:06, Alan Bateman wrote: >> Christopher Hegarty - Sun Microsystems Ireland wrote: >>> .... > > OK, got it Alan. I completely overlooked this. I'll filed: > > 6916922: (sctp) SO_RCVBUF & SO_SNDBUF returns twice the value set For reference, here is the review for this fix http://mail.openjdk.java.net/pipermail/sctp-dev/2010-January/000159.html -Chris. > > Bruce, I hope to have a fix for this in b81, the next available promoted > build. > > -Chris. > >> >> -Alan. From dennis.hjort at ericsson.com Sun Jan 17 23:10:57 2010 From: dennis.hjort at ericsson.com (Dennis Hjort) Date: Mon, 18 Jan 2010 08:10:57 +0100 Subject: [sctp-dev] FW: Use SCTP with Java 1.6? Message-ID: Hi Christopher, sending this one to the list too. ! We seem to have trigger something during testing SCTP in jdk6, causing a an error, that works using Sockets, and TCP. Here comes an example of output: eodenns at ltesim12:~/SockIO/src$ java -Xbootclasspath/a:/proj/ltesim/usr/eodenns/jdk6classes/sctp6.jar Main Client starting Doing accept Client connecting... Doing accept1 Doing accept2 Doing accept3 Doing accept4 Sending traffic... Doing accept5 Doing accept6 Avg number of msgs sent per second: 13077 Doing accept Client starting Client connecting... Doing accept1 Sending traffic... Doing accept2 Doing accept3 Doing accept4 Doing accept5 Doing accept6 Avg number of msgs sent per second: 13545 Client starting Client connecting... Sending traffic... Doing accept Doing accept1 Doing accept2 Doing accept3 Doing accept4 Doing accept5 Doing accept6 Doing accept java: relocation error: /proj/ltesim/usr/eodenns/jdk1.6.0_18/jre/lib/amd64/libsctp.so: symbol handleSocketError, version SUNWprivate_1.1 not defined in file libnio.so with link time reference And I've attached the source we used to exhibit this behavior. We might have done some "do not do like this" shortcuts, and if we have, please tell us what we done wrong ! :-) With kind regards // Dennis -----Original Message----- From: Christopher.Hegarty at Sun.COM [mailto:Christopher.Hegarty at Sun.COM] Sent: den 14 januari 2010 15:22 To: Dennis Hjort Subject: Re: [sctp-dev] Use SCTP with Java 1.6? On 14/01/2010 14:14, Dennis Hjort wrote: > Ow, sorry, I read it the wrong way ! :-) > > And after running with that one it works just perfectly ! :-) > > Now I'll try to use it in a bigger scope, and I'll get back to you ! That would be great. Looking forward to hearing your experience with it. -Chris. > > With kind regards ! > > // D > > -----Original Message----- > From: Christopher.Hegarty at Sun.COM [mailto:Christopher.Hegarty at Sun.COM] > Sent: den 14 januari 2010 14:57 > To: Dennis Hjort > Subject: Re: [sctp-dev] Use SCTP with Java 1.6? > > You will need to get the libstcp.so from the link on the webpage I sent. > > Please look at the red writing on this page. > > The reason you will need to get this "special" native library is that > the most recent changes I pushed (a few days ago) add new native > methods to libsctp so that we can remove dependencies on JDK7 specific > native methods. Until the next JDK7 promotion, b80 I believe, you > cannot simply get libsctp from JDK7. After b80 this should be fine. > > Let me know how it goes. > > -Chris. > > On 14/01/2010 13:52, Dennis Hjort wrote: >> Hi Christopher ! >> >> I followed you instructions using JDK6 update u18 on our linux >> platform (amd64), and got the following error when executing the > TestSCTP: >> eodenns at ltesim12:~$ java -Xbootclasspath/a:jdk6classes/sctp6.jar >> TestSCTP >> Exception in thread "main" java.lang.UnsatisfiedLinkError: >> sun.nio.ch.SctpNet.init()V >> at sun.nio.ch.SctpNet.init(Native Method) >> at sun.nio.ch.SctpNet.(SctpNet.java:309) >> at sun.nio.ch.SctpChannelImpl.(SctpChannelImpl.java:131) >> at com.sun.nio.sctp.SctpChannel.open(SctpChannel.java:165) >> at TestSCTP.main(TestSCTP.java:4) >> >> But when I think about it I do have a old release of JDK7 where I got >> the libsctp.so from ... I'll do another try after I've downloaded a >> later jdk7 release... >> >> // D >> >> -----Original Message----- >> From: Christopher.Hegarty at Sun.COM >> [mailto:Christopher.Hegarty at Sun.COM] >> Sent: den 14 januari 2010 11:24 >> To: Dennis Hjort >> Cc: sctp-dev at openjdk.java.net >> Subject: Re: [sctp-dev] Use SCTP with Java 1.6? >> >> You may want to get the latest JDK6 update, u18, which was just >> releases >> ;-) >> >> http://java.sun.com/javase/downloads/ >> >> -Chris. >> >> On 14/01/2010 10:19, Dennis Hjort wrote: >>> Thanks Christopher ! :-) >>> >>> I'll get right on trying it out ! :-) >>> >>> With kind regards >>> >>> // D >>> >>> -----Original Message----- >>> From: Christopher.Hegarty at Sun.COM >>> [mailto:Christopher.Hegarty at Sun.COM] >>> Sent: den 13 januari 2010 12:41 >>> To: Dennis Hjort; Michal Lefler >>> Cc: sctp-dev at openjdk.java.net >>> Subject: Re: [sctp-dev] Use SCTP with Java 1.6? >>> >>> Hi Dennis, Michal, >>> >>> I added a page to the sctp project site [1] with, what I believe are >>> detailed, instructions of how to use SCTP with JDK6. Please take a >>> look and try them out. >>> >>> If you encounter any problems of find something lacking from the >>> instructions then please let me know. If the instructions are >>> sufficient and you getting it running without any problem, please >>> let > >>> me know you experience. >>> >>> -Chris. >>> >>> [1] http://openjdk.java.net/projects/sctp/html/sctp6.html >>> >>> Dennis Hjort wrote: >>>> Hi Christopher ! >>>> >>>> I've been reading your posts regarding this topic, and downloaded >>>> the source, and applied the patch. Now I would like to compile a >>>> jdk6 compatible sctp-lib! :-) >>>> >>>> As you already know, our management is holding of moving up to JDK7 >>>> until a standard release, maybe even longer, and we are now trying >>>> to cut of performance costs in the product we are building, and now >>>> we even have numbers on what our implementation using the JNI >>>> library + > >>>> additions to our eventkernel to handle the blocking channels is >>>> costing in performance, so it would be great to be able to use the >>>> sctplib with >>>> JDK6 already ! :-) >>>> >>>> So, if it's possible I would appreciate the detailed instructions >>>> on > >>>> how to get it working with JDK6 ! :-) >>>> >>>> With kind regards >>>> >>>> // Dennis >>>> >>>> -----Original Message----- >>>> From: sctp-dev-bounces at openjdk.java.net >>>> [mailto:sctp-dev-bounces at openjdk.java.net] On Behalf Of Christopher >>>> Hegarty - Sun Microsystems Ireland >>>> Sent: den 8 januari 2010 17:23 >>>> To: Michal Lefler >>>> Cc: sctp-dev at openjdk.java.net >>>> Subject: Re: [sctp-dev] Use SCTP with Java 1.6? >>>> >>>> Hi Michal, >>>> >>>> I was trying to come up with a list of things to do to get the SCTP >>>> implementation working on JDK6, when I came across a previous >>>> attempt I made at it. To my surprise I had actually got further >>>> than I thought, and I found a list of changes I wanted to push into >>>> JDK7 so > >>>> make this simpler ( as well as a few new ones ). >>>> >>>> From that I created; >>>> 6915313: (sctp) Reorganize implementation to make it more >>>> feasible > >>>> to port to JDK6 >>>> >>>> Webrev: >>>> http://cr.openjdk.java.net/~chegar/6915313/webrev.0/webrev/ >>>> >>>> With these changes applied we can simply take the JDK7 SCTP code, >>>> and with two very minor edits have it run with JDK6. I did this and >>>> have > >>>> it running with JDK6u17. Without the above mentioned changes it is >>>> a > >>>> little more tricky because you need to make many more edits and >>>> recompile the native code. >>>> >>>> I will be requesting a review of 6915313 and hope to be in a >>>> position to push it early next week. I can then send detailed >>>> instructions of > >>>> how to get it working with JDK 6. >>>> >>>> -Chris. >>>> >>>> On 06/01/2010 14:57, Christopher Hegarty - Sun Microsystems Ireland >>>> wrote: >>>>> Hi Michal, >>>>> >>>>> There is no binary/package of SCTP available for JDK6. We received >>>>> a number of inquiries about this so far, but none of which are >>>>> considered a high enough priority to consider an official backport >>>>> to >>>> JDK6. >>>>> That being said, a while back I took the API and implementation >>>>> from >>>>> JDK7 and tried to bolt it onto a JDK6 update. It was close to >>>>> completion, but I got side tracked with other things. When >>>>> designing the API, and doing the implementation, I considered the >>>>> possibility > >>>>> that it may one day be ported to JDK6. If you look at the >>>>> implementation and you will see that there are very little JDK7 >>>>> dependencies. It should be relatively straight forward to extract >>>>> the API and implementation and have it run with JDK6. One caveat, >>>>> the implementation depends on a sun private API and will only run >>>>> with >>>> Sun's JDK. >>>>> Is this something you would be willing to work on? I can certainly >>>>> help, but I don't have the time right now to run with it myself. >>>>> >>>>> -Chris. >>>>> >>>>> On 06/01/2010 06:09, Michal Lefler wrote: >>>>>> Hi. >>>>>> >>>>>> I would like to use this SCTP implementation with my Java 1.6_17. >>>>>> Is >>>>>> there a binary distribution of this package alone? >>>>>> >>>>>> How can I use this SCTP package with Java 1.6? >>>>>> >>>>>> Thanks, >>>>>> >>>>>> Michal. >>>>>> >>>>>> >>>>>> >>>>>> -------------- next part -------------- A non-text attachment was scrubbed... Name: testsrc.tar.gz Type: application/x-gzip Size: 1446 bytes Desc: testsrc.tar.gz Url : http://mail.openjdk.java.net/pipermail/sctp-dev/attachments/20100118/ff9ebc0c/attachment.bin From Alan.Bateman at Sun.COM Mon Jan 18 03:14:20 2010 From: Alan.Bateman at Sun.COM (Alan Bateman) Date: Mon, 18 Jan 2010 11:14:20 +0000 Subject: [sctp-dev] Request for review: 6916890 In-Reply-To: <4B508FC8.4030103@sun.com> References: <4B508FC8.4030103@sun.com> Message-ID: <4B54428C.4070002@sun.com> Christopher Hegarty -Sun Microsystems Ireland wrote: > > In the case where a heap buffer is supplied the implementation copies > the data into a temporary native buffer before going native. The > position and remaining data is incorrectly determined for this > temporary buffer when the position of the original buffer is not 0. > > Also, remove incorrect assertion from implementation. > > CR 6916890: SctpChannel.send may cause IAE if given a heap buffer with > an offset > > Webrev: > http://cr.openjdk.java.net/~chegar/6916890/webrev.0/webrev/ > > Thanks, > -Chris. In SctpChannelImpl it looks like you can move lines 985-988 to after you've checked if the user's buffer is direct or not - that would avoid fetching the position and limit twice for the direct buffer case. Same comment for SctpMultiChannelImpl. Otherwise the implementation change looks right to me. For the tests, one suggestion is to go a step further and verify the received message. Without that it only checks the return value and that the buffer position has been updated. -Alan. From Christopher.Hegarty at Sun.COM Mon Jan 18 03:56:11 2010 From: Christopher.Hegarty at Sun.COM (Christopher Hegarty -Sun Microsystems Ireland) Date: Mon, 18 Jan 2010 11:56:11 +0000 Subject: [sctp-dev] FW: Use SCTP with Java 1.6? In-Reply-To: References: Message-ID: <4B544C5B.1010602@sun.com> Hi Dennis, handleSocketError is an exported nio function in JDK7, but not JDK6. The sctp implementation calls it in the case of an error on the socket. You will receive an error from the dynamic linker becuase this function is not in libnio of JDK6, if running SCTP with Suns JDK6. While not strictly not a bug in JDK7, I think we can simply copy the small native function, handleSockeError, to the SCTP implementation and have it built into libsctp.so removing this dependency. Thanks for reporting this issue. I filed the following bug: 6917317: (sctp) Remove dependency on handleSocketError -Chris. Dennis Hjort wrote: > > Hi Christopher, sending this one to the list too. ! > > We seem to have trigger something during testing SCTP in jdk6, causing a > an error, that works using Sockets, and TCP. > > Here comes an example of output: > > > eodenns at ltesim12:~/SockIO/src$ java > -Xbootclasspath/a:/proj/ltesim/usr/eodenns/jdk6classes/sctp6.jar Main > Client starting Doing accept Client connecting... > Doing accept1 > Doing accept2 > Doing accept3 > Doing accept4 > Sending traffic... > Doing accept5 > Doing accept6 > Avg number of msgs sent per second: 13077 Doing accept Client starting > Client connecting... > Doing accept1 > Sending traffic... > Doing accept2 > Doing accept3 > Doing accept4 > Doing accept5 > Doing accept6 > Avg number of msgs sent per second: 13545 Client starting Client > connecting... > Sending traffic... > Doing accept > Doing accept1 > Doing accept2 > Doing accept3 > Doing accept4 > Doing accept5 > Doing accept6 > Doing accept > java: relocation error: > /proj/ltesim/usr/eodenns/jdk1.6.0_18/jre/lib/amd64/libsctp.so: symbol > handleSocketError, version SUNWprivate_1.1 not defined in file libnio.so > with link time reference > > And I've attached the source we used to exhibit this behavior. > > We might have done some "do not do like this" shortcuts, and if we have, > please tell us what we done wrong ! :-) > > With kind regards > > // Dennis > > > -----Original Message----- > From: Christopher.Hegarty at Sun.COM [mailto:Christopher.Hegarty at Sun.COM] > Sent: den 14 januari 2010 15:22 > To: Dennis Hjort > Subject: Re: [sctp-dev] Use SCTP with Java 1.6? > > On 14/01/2010 14:14, Dennis Hjort wrote: >> Ow, sorry, I read it the wrong way ! :-) >> >> And after running with that one it works just perfectly ! :-) >> >> Now I'll try to use it in a bigger scope, and I'll get back to you ! > > That would be great. Looking forward to hearing your experience with it. > > -Chris. > >> With kind regards ! >> >> // D >> >> -----Original Message----- >> From: Christopher.Hegarty at Sun.COM [mailto:Christopher.Hegarty at Sun.COM] >> Sent: den 14 januari 2010 14:57 >> To: Dennis Hjort >> Subject: Re: [sctp-dev] Use SCTP with Java 1.6? >> >> You will need to get the libstcp.so from the link on the webpage I > sent. >> Please look at the red writing on this page. >> >> The reason you will need to get this "special" native library is that >> the most recent changes I pushed (a few days ago) add new native >> methods to libsctp so that we can remove dependencies on JDK7 specific > >> native methods. Until the next JDK7 promotion, b80 I believe, you >> cannot simply get libsctp from JDK7. After b80 this should be fine. >> >> Let me know how it goes. >> >> -Chris. >> >> On 14/01/2010 13:52, Dennis Hjort wrote: >>> Hi Christopher ! >>> >>> I followed you instructions using JDK6 update u18 on our linux >>> platform (amd64), and got the following error when executing the >> TestSCTP: >>> eodenns at ltesim12:~$ java -Xbootclasspath/a:jdk6classes/sctp6.jar >>> TestSCTP >>> Exception in thread "main" java.lang.UnsatisfiedLinkError: >>> sun.nio.ch.SctpNet.init()V >>> at sun.nio.ch.SctpNet.init(Native Method) >>> at sun.nio.ch.SctpNet.(SctpNet.java:309) >>> at > sun.nio.ch.SctpChannelImpl.(SctpChannelImpl.java:131) >>> at com.sun.nio.sctp.SctpChannel.open(SctpChannel.java:165) >>> at TestSCTP.main(TestSCTP.java:4) >>> >>> But when I think about it I do have a old release of JDK7 where I got > >>> the libsctp.so from ... I'll do another try after I've downloaded a >>> later jdk7 release... >>> >>> // D >>> >>> -----Original Message----- >>> From: Christopher.Hegarty at Sun.COM >>> [mailto:Christopher.Hegarty at Sun.COM] >>> Sent: den 14 januari 2010 11:24 >>> To: Dennis Hjort >>> Cc: sctp-dev at openjdk.java.net >>> Subject: Re: [sctp-dev] Use SCTP with Java 1.6? >>> >>> You may want to get the latest JDK6 update, u18, which was just >>> releases >>> ;-) >>> >>> http://java.sun.com/javase/downloads/ >>> >>> -Chris. >>> >>> On 14/01/2010 10:19, Dennis Hjort wrote: >>>> Thanks Christopher ! :-) >>>> >>>> I'll get right on trying it out ! :-) >>>> >>>> With kind regards >>>> >>>> // D >>>> >>>> -----Original Message----- >>>> From: Christopher.Hegarty at Sun.COM >>>> [mailto:Christopher.Hegarty at Sun.COM] >>>> Sent: den 13 januari 2010 12:41 >>>> To: Dennis Hjort; Michal Lefler >>>> Cc: sctp-dev at openjdk.java.net >>>> Subject: Re: [sctp-dev] Use SCTP with Java 1.6? >>>> >>>> Hi Dennis, Michal, >>>> >>>> I added a page to the sctp project site [1] with, what I believe are > >>>> detailed, instructions of how to use SCTP with JDK6. Please take a >>>> look and try them out. >>>> >>>> If you encounter any problems of find something lacking from the >>>> instructions then please let me know. If the instructions are >>>> sufficient and you getting it running without any problem, please >>>> let >>>> me know you experience. >>>> >>>> -Chris. >>>> >>>> [1] http://openjdk.java.net/projects/sctp/html/sctp6.html >>>> >>>> Dennis Hjort wrote: >>>>> Hi Christopher ! >>>>> >>>>> I've been reading your posts regarding this topic, and downloaded >>>>> the source, and applied the patch. Now I would like to compile a >>>>> jdk6 compatible sctp-lib! :-) >>>>> >>>>> As you already know, our management is holding of moving up to JDK7 > >>>>> until a standard release, maybe even longer, and we are now trying >>>>> to cut of performance costs in the product we are building, and now > >>>>> we even have numbers on what our implementation using the JNI >>>>> library + >>>>> additions to our eventkernel to handle the blocking channels is >>>>> costing in performance, so it would be great to be able to use the >>>>> sctplib with >>>>> JDK6 already ! :-) >>>>> >>>>> So, if it's possible I would appreciate the detailed instructions >>>>> on >>>>> how to get it working with JDK6 ! :-) >>>>> >>>>> With kind regards >>>>> >>>>> // Dennis >>>>> >>>>> -----Original Message----- >>>>> From: sctp-dev-bounces at openjdk.java.net >>>>> [mailto:sctp-dev-bounces at openjdk.java.net] On Behalf Of Christopher > >>>>> Hegarty - Sun Microsystems Ireland >>>>> Sent: den 8 januari 2010 17:23 >>>>> To: Michal Lefler >>>>> Cc: sctp-dev at openjdk.java.net >>>>> Subject: Re: [sctp-dev] Use SCTP with Java 1.6? >>>>> >>>>> Hi Michal, >>>>> >>>>> I was trying to come up with a list of things to do to get the SCTP > >>>>> implementation working on JDK6, when I came across a previous >>>>> attempt I made at it. To my surprise I had actually got further >>>>> than I thought, and I found a list of changes I wanted to push into >>>>> JDK7 so >>>>> make this simpler ( as well as a few new ones ). >>>>> >>>>> From that I created; >>>>> 6915313: (sctp) Reorganize implementation to make it more >>>>> feasible >>>>> to port to JDK6 >>>>> >>>>> Webrev: >>>>> http://cr.openjdk.java.net/~chegar/6915313/webrev.0/webrev/ >>>>> >>>>> With these changes applied we can simply take the JDK7 SCTP code, >>>>> and with two very minor edits have it run with JDK6. I did this and > >>>>> have >>>>> it running with JDK6u17. Without the above mentioned changes it is >>>>> a >>>>> little more tricky because you need to make many more edits and >>>>> recompile the native code. >>>>> >>>>> I will be requesting a review of 6915313 and hope to be in a >>>>> position to push it early next week. I can then send detailed >>>>> instructions of >>>>> how to get it working with JDK 6. >>>>> >>>>> -Chris. >>>>> >>>>> On 06/01/2010 14:57, Christopher Hegarty - Sun Microsystems Ireland >>>>> wrote: >>>>>> Hi Michal, >>>>>> >>>>>> There is no binary/package of SCTP available for JDK6. We received > >>>>>> a number of inquiries about this so far, but none of which are >>>>>> considered a high enough priority to consider an official backport > >>>>>> to >>>>> JDK6. >>>>>> That being said, a while back I took the API and implementation >>>>>> from >>>>>> JDK7 and tried to bolt it onto a JDK6 update. It was close to >>>>>> completion, but I got side tracked with other things. When >>>>>> designing the API, and doing the implementation, I considered the >>>>>> possibility >>>>>> that it may one day be ported to JDK6. If you look at the >>>>>> implementation and you will see that there are very little JDK7 >>>>>> dependencies. It should be relatively straight forward to extract >>>>>> the API and implementation and have it run with JDK6. One caveat, >>>>>> the implementation depends on a sun private API and will only run >>>>>> with >>>>> Sun's JDK. >>>>>> Is this something you would be willing to work on? I can certainly > >>>>>> help, but I don't have the time right now to run with it myself. >>>>>> >>>>>> -Chris. >>>>>> >>>>>> On 06/01/2010 06:09, Michal Lefler wrote: >>>>>>> Hi. >>>>>>> >>>>>>> I would like to use this SCTP implementation with my Java 1.6_17. > >>>>>>> Is >>>>>>> there a binary distribution of this package alone? >>>>>>> >>>>>>> How can I use this SCTP package with Java 1.6? >>>>>>> >>>>>>> Thanks, >>>>>>> >>>>>>> Michal. >>>>>>> >>>>>>> >>>>>>> >>>>>>> From Christopher.Hegarty at Sun.COM Mon Jan 18 05:50:53 2010 From: Christopher.Hegarty at Sun.COM (Christopher Hegarty -Sun Microsystems Ireland) Date: Mon, 18 Jan 2010 13:50:53 +0000 Subject: [sctp-dev] Request for review: 6916890 In-Reply-To: <4B54428C.4070002@sun.com> References: <4B508FC8.4030103@sun.com> <4B54428C.4070002@sun.com> Message-ID: <4B54673D.5040004@sun.com> Alan Bateman wrote: > ..... > In SctpChannelImpl it looks like you can move lines 985-988 to after > you've checked if the user's buffer is direct or not - that would avoid > fetching the position and limit twice for the direct buffer case. Same > comment for SctpMultiChannelImpl. Otherwise the implementation change > looks right to me. For the tests, one suggestion is to go a step further > and verify the received message. Without that it only checks the return > value and that the buffer position has been updated. Thanks Alan for the review and the comments. I made the changes and updated the webrev: http://cr.openjdk.java.net/~chegar/6916890/webrev.1/ -Chris. > > -Alan. From Alan.Bateman at Sun.COM Mon Jan 18 06:03:54 2010 From: Alan.Bateman at Sun.COM (Alan Bateman) Date: Mon, 18 Jan 2010 14:03:54 +0000 Subject: [sctp-dev] Request for review: 6916890 In-Reply-To: <4B54673D.5040004@sun.com> References: <4B508FC8.4030103@sun.com> <4B54428C.4070002@sun.com> <4B54673D.5040004@sun.com> Message-ID: <4B546A4A.6030905@sun.com> Christopher Hegarty -Sun Microsystems Ireland wrote: > > > Alan Bateman wrote: >> ..... >> In SctpChannelImpl it looks like you can move lines 985-988 to after >> you've checked if the user's buffer is direct or not - that would >> avoid fetching the position and limit twice for the direct buffer >> case. Same comment for SctpMultiChannelImpl. Otherwise the >> implementation change looks right to me. For the tests, one >> suggestion is to go a step further and verify the received message. >> Without that it only checks the return value and that the buffer >> position has been updated. > > Thanks Alan for the review and the comments. I made the changes and > updated the webrev: > http://cr.openjdk.java.net/~chegar/6916890/webrev.1/ Looks OK to me. -Alan. From Christopher.Hegarty at Sun.COM Mon Jan 18 06:08:41 2010 From: Christopher.Hegarty at Sun.COM (Christopher Hegarty -Sun Microsystems Ireland) Date: Mon, 18 Jan 2010 14:08:41 +0000 Subject: [sctp-dev] Request for Review: 6917317 Message-ID: <4B546B69.6050306@sun.com> Problem Description: handleSocketError is an exported nio function in JDK7, but not JDK6. The sctp implementation calls it in the case of an error on the socket. You will receive an error from the dynamic linker becuase this function is not in libnio of JDK6, if running SCTP with Suns JDK6. While not strictly not a bug in JDK7, I think we can simply copy the small native function, handleSockeError, to the SCTP implementation and have it built into libsctp.so removing this dependency. 6917317: (sctp) Remove dependency on handleSocketError Webrev: http://cr.openjdk.java.net/~chegar/6917317/webrev.0/webrev/ Thanks, -Chris. From Christopher.Hegarty at Sun.COM Mon Jan 18 07:22:09 2010 From: Christopher.Hegarty at Sun.COM (Christopher Hegarty -Sun Microsystems Ireland) Date: Mon, 18 Jan 2010 15:22:09 +0000 Subject: [sctp-dev] [Fwd: RE: IAE multiple sends] In-Reply-To: <4B508DD6.1080006@sun.com> References: <4B5048E2.9070703@sun.com> <4B508DD6.1080006@sun.com> Message-ID: <4B547CA1.4090205@sun.com> Christopher Hegarty -Sun Microsystems Ireland wrote: > Bruce, > > I filed the following bug against this issue. > > 6916890: SctpChannel.send may cause IAE if given a heap buffer with an > offset I pushed the changes for this bug, and it should be available in JDK7 b81. For reference, Code Review: http://mail.openjdk.java.net/pipermail/sctp-dev/2010-January/000158.html changeset: http://hg.openjdk.java.net/jdk7/tl/jdk/rev/680d7d312a30 -Chris. > > In the case where a heap buffer is supplied the implementation copies > the data into a temporary native buffer before going native. The > position and remaining data is incorrectly determined for this temporary > buffer when the position of the original buffer is not 0. > > -Chris. From Christopher.Hegarty at Sun.COM Mon Jan 18 07:22:51 2010 From: Christopher.Hegarty at Sun.COM (Christopher Hegarty -Sun Microsystems Ireland) Date: Mon, 18 Jan 2010 15:22:51 +0000 Subject: [sctp-dev] FW: Use SCTP with Java 1.6? In-Reply-To: <4B544C5B.1010602@sun.com> References: <4B544C5B.1010602@sun.com> Message-ID: <4B547CCB.9050601@sun.com> Christopher Hegarty -Sun Microsystems Ireland wrote: > Hi Dennis, > > handleSocketError is an exported nio function in JDK7, but not JDK6. The > sctp implementation calls it in the case of an error on the socket. You > will receive an error from the dynamic linker becuase this function is > not in libnio of JDK6, if running SCTP with Suns JDK6. > > While not strictly not a bug in JDK7, I think we can simply copy the > small native function, handleSockeError, to the SCTP implementation and > have it built into libsctp.so removing this dependency. > > Thanks for reporting this issue. I filed the following bug: > 6917317: (sctp) Remove dependency on handleSocketError Dennis, I've pushed the source changes for this and updated the libsctp.so on the instructions page [1]. Again, until the next JDK7 promotion you will need to get libsctp from there. Alan made a good point during review of 6917317: The SCTP implementation run with Sun's JDK6 is completely unsupported. The implementation uses Sun proprietary APIs that may be removed or changed in the future. Also, Sun's JDK6 is built with RHAS 2.1A and an old gcc. JDK7 is built with Fedora 9 and a more modern gcc. Everything should work (in theory) but there are bound to to be older Linux distributions where Sun's JDK6 works but libsctp will not work. -Chris. [1] http://openjdk.java.net/projects/sctp/html/sctp6.html > > -Chris. From dennis.hjort at ericsson.com Mon Jan 18 09:19:10 2010 From: dennis.hjort at ericsson.com (Dennis Hjort) Date: Mon, 18 Jan 2010 18:19:10 +0100 Subject: [sctp-dev] FW: Use SCTP with Java 1.6? In-Reply-To: <4B544C5B.1010602@sun.com> References: <4B544C5B.1010602@sun.com> Message-ID: Hi again, Thanks for the quick answer ! When I sent this problem, I did forget to write that the problem was just one of two problems we had with the code referenced, the other was that the we for some reason, seems to get stuck in the select call. See the following execution trail... Do you have any suggestions on what we could do to perhaps know more why we hang there ? Only thing we could see is that the doing accept printout gets printed before the "Avg number of msgs..." printout, which shouldn't happen. It seems pretty repetative, either the first problem occurs, or this one. We never get a full "run"... With kind regards // Dennis eodenns at ltesim12:~/SockIO/src$ java -Xbootclasspath/a:/proj/ltesim/usr/eodenns/jdk6classes/sctp6.jar Main Client starting Doing accept Client connecting... Doing accept1 Doing accept2 Doing accept3 Doing accept4 Sending traffic... Doing accept5 Doing accept6 Avg number of msgs sent per second: 13026 Doing accept Client starting Client connecting... Doing accept1 Sending traffic... Doing accept2 Doing accept3 Doing accept4 Doing accept5 Doing accept6 Avg number of msgs sent per second: 13660 Doing accept Client starting Client connecting... Doing accept1 Doing accept2 Sending traffic... Doing accept3 Doing accept4 Doing accept5 Doing accept6 Avg number of msgs sent per second: 12305 Doing accept Client starting Client connecting... Doing accept1 Sending traffic... Doing accept2 Doing accept3 Doing accept4 Doing accept5 Doing accept6 Doing accept -----Original Message----- From: Christopher.Hegarty at Sun.COM [mailto:Christopher.Hegarty at Sun.COM] Sent: den 18 januari 2010 12:56 To: Dennis Hjort Cc: sctp-dev at openjdk.java.net Subject: Re: FW: [sctp-dev] Use SCTP with Java 1.6? Hi Dennis, handleSocketError is an exported nio function in JDK7, but not JDK6. The sctp implementation calls it in the case of an error on the socket. You will receive an error from the dynamic linker becuase this function is not in libnio of JDK6, if running SCTP with Suns JDK6. While not strictly not a bug in JDK7, I think we can simply copy the small native function, handleSockeError, to the SCTP implementation and have it built into libsctp.so removing this dependency. Thanks for reporting this issue. I filed the following bug: 6917317: (sctp) Remove dependency on handleSocketError -Chris. Dennis Hjort wrote: > > Hi Christopher, sending this one to the list too. ! > > We seem to have trigger something during testing SCTP in jdk6, causing > a an error, that works using Sockets, and TCP. > > Here comes an example of output: > > > eodenns at ltesim12:~/SockIO/src$ java > -Xbootclasspath/a:/proj/ltesim/usr/eodenns/jdk6classes/sctp6.jar Main > Client starting Doing accept Client connecting... > Doing accept1 > Doing accept2 > Doing accept3 > Doing accept4 > Sending traffic... > Doing accept5 > Doing accept6 > Avg number of msgs sent per second: 13077 Doing accept Client starting > Client connecting... > Doing accept1 > Sending traffic... > Doing accept2 > Doing accept3 > Doing accept4 > Doing accept5 > Doing accept6 > Avg number of msgs sent per second: 13545 Client starting Client > connecting... > Sending traffic... > Doing accept > Doing accept1 > Doing accept2 > Doing accept3 > Doing accept4 > Doing accept5 > Doing accept6 > Doing accept > java: relocation error: > /proj/ltesim/usr/eodenns/jdk1.6.0_18/jre/lib/amd64/libsctp.so: symbol > handleSocketError, version SUNWprivate_1.1 not defined in file > libnio.so with link time reference > > And I've attached the source we used to exhibit this behavior. > > We might have done some "do not do like this" shortcuts, and if we > have, please tell us what we done wrong ! :-) > > With kind regards > > // Dennis > > > -----Original Message----- > From: Christopher.Hegarty at Sun.COM [mailto:Christopher.Hegarty at Sun.COM] > Sent: den 14 januari 2010 15:22 > To: Dennis Hjort > Subject: Re: [sctp-dev] Use SCTP with Java 1.6? > > On 14/01/2010 14:14, Dennis Hjort wrote: >> Ow, sorry, I read it the wrong way ! :-) >> >> And after running with that one it works just perfectly ! :-) >> >> Now I'll try to use it in a bigger scope, and I'll get back to you ! > > That would be great. Looking forward to hearing your experience with it. > > -Chris. > >> With kind regards ! >> >> // D >> >> -----Original Message----- >> From: Christopher.Hegarty at Sun.COM >> [mailto:Christopher.Hegarty at Sun.COM] >> Sent: den 14 januari 2010 14:57 >> To: Dennis Hjort >> Subject: Re: [sctp-dev] Use SCTP with Java 1.6? >> >> You will need to get the libstcp.so from the link on the webpage I > sent. >> Please look at the red writing on this page. >> >> The reason you will need to get this "special" native library is that >> the most recent changes I pushed (a few days ago) add new native >> methods to libsctp so that we can remove dependencies on JDK7 >> specific > >> native methods. Until the next JDK7 promotion, b80 I believe, you >> cannot simply get libsctp from JDK7. After b80 this should be fine. >> >> Let me know how it goes. >> >> -Chris. >> >> On 14/01/2010 13:52, Dennis Hjort wrote: >>> Hi Christopher ! >>> >>> I followed you instructions using JDK6 update u18 on our linux >>> platform (amd64), and got the following error when executing the >> TestSCTP: >>> eodenns at ltesim12:~$ java -Xbootclasspath/a:jdk6classes/sctp6.jar >>> TestSCTP >>> Exception in thread "main" java.lang.UnsatisfiedLinkError: >>> sun.nio.ch.SctpNet.init()V >>> at sun.nio.ch.SctpNet.init(Native Method) >>> at sun.nio.ch.SctpNet.(SctpNet.java:309) >>> at > sun.nio.ch.SctpChannelImpl.(SctpChannelImpl.java:131) >>> at com.sun.nio.sctp.SctpChannel.open(SctpChannel.java:165) >>> at TestSCTP.main(TestSCTP.java:4) >>> >>> But when I think about it I do have a old release of JDK7 where I >>> got > >>> the libsctp.so from ... I'll do another try after I've downloaded a >>> later jdk7 release... >>> >>> // D >>> >>> -----Original Message----- >>> From: Christopher.Hegarty at Sun.COM >>> [mailto:Christopher.Hegarty at Sun.COM] >>> Sent: den 14 januari 2010 11:24 >>> To: Dennis Hjort >>> Cc: sctp-dev at openjdk.java.net >>> Subject: Re: [sctp-dev] Use SCTP with Java 1.6? >>> >>> You may want to get the latest JDK6 update, u18, which was just >>> releases >>> ;-) >>> >>> http://java.sun.com/javase/downloads/ >>> >>> -Chris. >>> >>> On 14/01/2010 10:19, Dennis Hjort wrote: >>>> Thanks Christopher ! :-) >>>> >>>> I'll get right on trying it out ! :-) >>>> >>>> With kind regards >>>> >>>> // D >>>> >>>> -----Original Message----- >>>> From: Christopher.Hegarty at Sun.COM >>>> [mailto:Christopher.Hegarty at Sun.COM] >>>> Sent: den 13 januari 2010 12:41 >>>> To: Dennis Hjort; Michal Lefler >>>> Cc: sctp-dev at openjdk.java.net >>>> Subject: Re: [sctp-dev] Use SCTP with Java 1.6? >>>> >>>> Hi Dennis, Michal, >>>> >>>> I added a page to the sctp project site [1] with, what I believe >>>> are > >>>> detailed, instructions of how to use SCTP with JDK6. Please take a >>>> look and try them out. >>>> >>>> If you encounter any problems of find something lacking from the >>>> instructions then please let me know. If the instructions are >>>> sufficient and you getting it running without any problem, please >>>> let me know you experience. >>>> >>>> -Chris. >>>> >>>> [1] http://openjdk.java.net/projects/sctp/html/sctp6.html >>>> >>>> Dennis Hjort wrote: >>>>> Hi Christopher ! >>>>> >>>>> I've been reading your posts regarding this topic, and downloaded >>>>> the source, and applied the patch. Now I would like to compile a >>>>> jdk6 compatible sctp-lib! :-) >>>>> >>>>> As you already know, our management is holding of moving up to >>>>> JDK7 > >>>>> until a standard release, maybe even longer, and we are now trying >>>>> to cut of performance costs in the product we are building, and >>>>> now > >>>>> we even have numbers on what our implementation using the JNI >>>>> library + additions to our eventkernel to handle the blocking >>>>> channels is costing in performance, so it would be great to be >>>>> able to use the sctplib with >>>>> JDK6 already ! :-) >>>>> >>>>> So, if it's possible I would appreciate the detailed instructions >>>>> on how to get it working with JDK6 ! :-) >>>>> >>>>> With kind regards >>>>> >>>>> // Dennis >>>>> >>>>> -----Original Message----- >>>>> From: sctp-dev-bounces at openjdk.java.net >>>>> [mailto:sctp-dev-bounces at openjdk.java.net] On Behalf Of >>>>> Christopher > >>>>> Hegarty - Sun Microsystems Ireland >>>>> Sent: den 8 januari 2010 17:23 >>>>> To: Michal Lefler >>>>> Cc: sctp-dev at openjdk.java.net >>>>> Subject: Re: [sctp-dev] Use SCTP with Java 1.6? >>>>> >>>>> Hi Michal, >>>>> >>>>> I was trying to come up with a list of things to do to get the >>>>> SCTP > >>>>> implementation working on JDK6, when I came across a previous >>>>> attempt I made at it. To my surprise I had actually got further >>>>> than I thought, and I found a list of changes I wanted to push >>>>> into >>>>> JDK7 so >>>>> make this simpler ( as well as a few new ones ). >>>>> >>>>> From that I created; >>>>> 6915313: (sctp) Reorganize implementation to make it more >>>>> feasible to port to JDK6 >>>>> >>>>> Webrev: >>>>> http://cr.openjdk.java.net/~chegar/6915313/webrev.0/webrev/ >>>>> >>>>> With these changes applied we can simply take the JDK7 SCTP code, >>>>> and with two very minor edits have it run with JDK6. I did this >>>>> and > >>>>> have >>>>> it running with JDK6u17. Without the above mentioned changes it is >>>>> a little more tricky because you need to make many more edits and >>>>> recompile the native code. >>>>> >>>>> I will be requesting a review of 6915313 and hope to be in a >>>>> position to push it early next week. I can then send detailed >>>>> instructions of how to get it working with JDK 6. >>>>> >>>>> -Chris. >>>>> >>>>> On 06/01/2010 14:57, Christopher Hegarty - Sun Microsystems >>>>> Ireland >>>>> wrote: >>>>>> Hi Michal, >>>>>> >>>>>> There is no binary/package of SCTP available for JDK6. We >>>>>> received > >>>>>> a number of inquiries about this so far, but none of which are >>>>>> considered a high enough priority to consider an official >>>>>> backport > >>>>>> to >>>>> JDK6. >>>>>> That being said, a while back I took the API and implementation >>>>>> from >>>>>> JDK7 and tried to bolt it onto a JDK6 update. It was close to >>>>>> completion, but I got side tracked with other things. When >>>>>> designing the API, and doing the implementation, I considered the >>>>>> possibility that it may one day be ported to JDK6. If you look at >>>>>> the implementation and you will see that there are very little >>>>>> JDK7 dependencies. It should be relatively straight forward to >>>>>> extract the API and implementation and have it run with JDK6. One >>>>>> caveat, the implementation depends on a sun private API and will >>>>>> only run with >>>>> Sun's JDK. >>>>>> Is this something you would be willing to work on? I can >>>>>> certainly > >>>>>> help, but I don't have the time right now to run with it myself. >>>>>> >>>>>> -Chris. >>>>>> >>>>>> On 06/01/2010 06:09, Michal Lefler wrote: >>>>>>> Hi. >>>>>>> >>>>>>> I would like to use this SCTP implementation with my Java 1.6_17. > >>>>>>> Is >>>>>>> there a binary distribution of this package alone? >>>>>>> >>>>>>> How can I use this SCTP package with Java 1.6? >>>>>>> >>>>>>> Thanks, >>>>>>> >>>>>>> Michal. >>>>>>> >>>>>>> >>>>>>> >>>>>>> From dennis.hjort at ericsson.com Mon Jan 18 09:43:05 2010 From: dennis.hjort at ericsson.com (Dennis Hjort) Date: Mon, 18 Jan 2010 18:43:05 +0100 Subject: [sctp-dev] FW: Use SCTP with Java 1.6? In-Reply-To: <4B547CCB.9050601@sun.com> References: <4B544C5B.1010602@sun.com> <4B547CCB.9050601@sun.com> Message-ID: Christopher, Thanks ! As to Alan's point, I do understand that it is and will be unsupported. We will use it as such also, and try to keep the questions to a minimum. If I get any other problems I'll try running with JDK7, and if it's reproduceable under JDK7, otherwise I'll mark it as "could be good to know", when using this unsupported version. With kind regards // Dennis -----Original Message----- From: Christopher.Hegarty at Sun.COM [mailto:Christopher.Hegarty at Sun.COM] Sent: den 18 januari 2010 16:23 To: Dennis Hjort Cc: sctp-dev at openjdk.java.net Subject: Re: [sctp-dev] FW: Use SCTP with Java 1.6? Christopher Hegarty -Sun Microsystems Ireland wrote: > Hi Dennis, > > handleSocketError is an exported nio function in JDK7, but not JDK6. > The sctp implementation calls it in the case of an error on the > socket. You will receive an error from the dynamic linker becuase this > function is not in libnio of JDK6, if running SCTP with Suns JDK6. > > While not strictly not a bug in JDK7, I think we can simply copy the > small native function, handleSockeError, to the SCTP implementation > and have it built into libsctp.so removing this dependency. > > Thanks for reporting this issue. I filed the following bug: > 6917317: (sctp) Remove dependency on handleSocketError Dennis, I've pushed the source changes for this and updated the libsctp.so on the instructions page [1]. Again, until the next JDK7 promotion you will need to get libsctp from there. Alan made a good point during review of 6917317: The SCTP implementation run with Sun's JDK6 is completely unsupported. The implementation uses Sun proprietary APIs that may be removed or changed in the future. Also, Sun's JDK6 is built with RHAS 2.1A and an old gcc. JDK7 is built with Fedora 9 and a more modern gcc. Everything should work (in theory) but there are bound to to be older Linux distributions where Sun's JDK6 works but libsctp will not work. -Chris. [1] http://openjdk.java.net/projects/sctp/html/sctp6.html > > -Chris. From gnu_andrew at member.fsf.org Mon Jan 18 10:56:00 2010 From: gnu_andrew at member.fsf.org (Andrew John Hughes) Date: Mon, 18 Jan 2010 18:56:00 +0000 Subject: [sctp-dev] Request for Review: 6915313 In-Reply-To: <4B475F7D.7040401@Sun.COM> References: <4B475C9B.5050207@Sun.COM> <17c6771e1001080832s7e794de9id6bb3e96636e06f5@mail.gmail.com> <4B475F7D.7040401@Sun.COM> Message-ID: <17c6771e1001181056l6ade4883o2e8097b4413d1082@mail.gmail.com> 2010/1/8 Christopher Hegarty - Sun Microsystems Ireland : > > On 08/01/2010 16:32, Andrew John Hughes wrote: >> >> .... >> >> For OpenJDK6, I think it would be better to port over SCTP after the >> b18 release which is currently undergoing final testing. ?So please >> don't push anything to the OpenJDK6 repositories just yet :-) > > Oh, maybe the bug description is a little misleading. What this bug plans to > do is simply reorganize the SCTP implementation in JDK7 so that it can be > ripped out and bolted onto a standard Sun JDK6 (if that's the kind of thing > you like to do!). There are no changes planned for OpenJDK6, just JDK7. > > -Chris. > Yeah, I got that this was a patch for OpenJDK7, but I thought the long term goal was to backport SCTP to OpenJDK6, not just provide the hack approach of http://openjdk.java.net/projects/sctp/html/sctp6.html with 'standard Sun JDK6' (whatever that is - I guess you mean the proprietary Sun JDK6 builds). I think it would be nice to provide this backport as an option with IcedTea6. Then users could use this with 6 out of the box. Do you know what impact this would have when built with OpenJDK6 (rather than hacked into an existing proprietary build built against ancient system libraries)? -- Andrew :-) Free Java Software Engineer Red Hat, Inc. (http://www.redhat.com) Support Free Java! Contribute to GNU Classpath and the OpenJDK http://www.gnu.org/software/classpath http://openjdk.java.net PGP Key: 94EFD9D8 (http://subkeys.pgp.net) Fingerprint: F8EF F1EA 401E 2E60 15FA 7927 142C 2591 94EF D9D8 From Christopher.Hegarty at Sun.COM Tue Jan 19 03:18:06 2010 From: Christopher.Hegarty at Sun.COM (Christopher Hegarty -Sun Microsystems Ireland) Date: Tue, 19 Jan 2010 11:18:06 +0000 Subject: [sctp-dev] FW: Use SCTP with Java 1.6? In-Reply-To: References: <4B544C5B.1010602@sun.com> Message-ID: <4B5594EE.9030608@sun.com> Dennis Hjort wrote: > Hi again, > > Thanks for the quick answer ! > > When I sent this problem, I did forget to write that the problem was > just one of two problems we had with the code referenced, the other was > that the we for some reason, seems to get stuck in the select call. See > the following execution trail... > > Do you have any suggestions on what we could do to perhaps know more why > we hang there ? Only thing we could see is that the doing accept > printout gets printed before the "Avg number of msgs..." printout, which > shouldn't happen. It seems pretty repetative, either the first problem > occurs, or this one. We never get a full "run"... I wonder if this is a problem with a spurious wake up of the selector when there is nothing available on the channel. If this was the case then your Server code would expect that the channel was closed, when it is in fact still open and connected. This would explain the debugging output of the are seeing. Would it be possible to check the value of the returned MessageInfo.bytes()? bytes() will return -1 if end of stream. Example: if (messageInfo != null) if (messageInfo.bytes() == -1) channel.close What system are you running on? Maybe I could reproduce in house. -Chris. > With kind regards > > // Dennis > From dennis.hjort at ericsson.com Tue Jan 19 03:26:37 2010 From: dennis.hjort at ericsson.com (Dennis Hjort) Date: Tue, 19 Jan 2010 12:26:37 +0100 Subject: [sctp-dev] FW: Use SCTP with Java 1.6? In-Reply-To: <4B5594EE.9030608@sun.com> References: <4B544C5B.1010602@sun.com> <4B5594EE.9030608@sun.com> Message-ID: > > I wonder if this is a problem with a spurious wake up of the > selector when there is nothing available on the channel. If > this was the case then your Server code would expect that the > channel was closed, when it is in fact still open and > connected. This would explain the debugging output of the are seeing. > > Would it be possible to check the value of the returned > MessageInfo.bytes()? bytes() will return -1 if end of stream. > > Example: > if (messageInfo != null) > if (messageInfo.bytes() == -1) > channel.close > > What system are you running on? Maybe I could reproduce in house. > > -Chris. Hi ! I'll try checking the the returned MessageInfo.bytes(), and get back to you when I've done that. We use Suse Enterprise v 11, if i got it right. // D > > > > With kind regards > > > > // Dennis > > > From Christopher.Hegarty at Sun.COM Thu Jan 21 05:50:08 2010 From: Christopher.Hegarty at Sun.COM (Christopher Hegarty -Sun Microsystems Ireland) Date: Thu, 21 Jan 2010 13:50:08 +0000 Subject: [sctp-dev] Request for Review: 6915313 In-Reply-To: <17c6771e1001181056l6ade4883o2e8097b4413d1082@mail.gmail.com> References: <4B475C9B.5050207@Sun.COM> <17c6771e1001080832s7e794de9id6bb3e96636e06f5@mail.gmail.com> <4B475F7D.7040401@Sun.COM> <17c6771e1001181056l6ade4883o2e8097b4413d1082@mail.gmail.com> Message-ID: <4B585B90.10905@sun.com> Andrew John Hughes wrote: > 2010/1/8 Christopher Hegarty - Sun Microsystems Ireland > : >> On 08/01/2010 16:32, Andrew John Hughes wrote: >>> .... >>> >>> For OpenJDK6, I think it would be better to port over SCTP after the >>> b18 release which is currently undergoing final testing. So please >>> don't push anything to the OpenJDK6 repositories just yet :-) >> Oh, maybe the bug description is a little misleading. What this bug plans to >> do is simply reorganize the SCTP implementation in JDK7 so that it can be >> ripped out and bolted onto a standard Sun JDK6 (if that's the kind of thing >> you like to do!). There are no changes planned for OpenJDK6, just JDK7. >> >> -Chris. >> > > Yeah, I got that this was a patch for OpenJDK7, but I thought the long > term goal was to backport SCTP to OpenJDK6, not just provide the hack > approach of http://openjdk.java.net/projects/sctp/html/sctp6.html with > 'standard Sun JDK6' (whatever that is - I guess you mean the > proprietary Sun JDK6 builds). Yes, this is correct. > I think it would be nice to provide this backport as an option with > IcedTea6. Then users could use this with 6 out of the box. Do you > know what impact this would have when built with OpenJDK6 (rather than > hacked into an existing proprietary build built against ancient system > libraries)? I think building the SCTP source with OpenJDK6 should not be a problem. -Chris.