Skip to main content

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index] [List Home]
Re: [ajdt-dev] StreamCorruptedException


Adrians messages to the lists about compatibility gave rise to
bug 82134 ( https://bugs.eclipse.org/bugs/show_bug.cgi?id=82134 ).  I
implemented a first pass at this late last week so that a 1.5.0 weaver
(post build date 7th January) will correctly load an Aspect built with
either 1.5.0 or AspectJ 1.2.1.  This isn't available in an AJDT
build yet.  

*However* - the changes to Resolved Type Munger aren't strictly
related to this as when I added locations to the type munger I ensured
the 'reading back in' code could cope with them being missing (i.e. if it
encountered an old aspect).

Unfortunately, I left a line of debug code in !!

Here it is:

                try {
                   ... Skipping some code that reads in the location
                } catch (IOException ioe) {
              //   this includes StreamCorruptedException
                    ioe.printStackTrace();
                  return null;
                }

which means that although you are getting the stack trace out, the
weave should still be executing successfully??

To get rid of the message, you can rebuild the utility jar from source
so it includes a source location or wait for me to do a build
which removes that line of debug ...

cheers,
Andy.
---
Andy Clement
AspectJ
clemas@xxxxxxxxxx




"Wes Isberg" <wes@xxxxxxxxxxxxxx>
Sent by: ajdt-dev-admin@xxxxxxxxxxx

11/01/2005 20:37

Please respond to
ajdt-dev@xxxxxxxxxxx

To
ajdt-dev@xxxxxxxxxxx
cc
Subject
Re: [ajdt-dev] StreamCorruptedException





perhaps: Remember the latest weaver does not handle binary aspects
created with older weavers.  This is, we hope, a one-time
compatibility break.  See the latest readme's[1] and Adrian's
messages to aspectj-users for more details.
hth -
Wes
[1] also for aspectj, not just for ajdt.

> ------------Original Message------------
> From: "James CE Johnson" <jcej@xxxxxxxxxx>
> To: ajdt-dev@xxxxxxxxxxx
> Date: Tue, Jan-11-2005 12:15 PM
> Subject: Re: [ajdt-dev] StreamCorruptedException
>
> Some additional information...
>
> I have a utility jar containing an aspect that injects a default
> implementation onto an interface. This appears to be causing the
> problem
> below.
>
> If I remove the aspect binary from the utility jar and put its source
> into
> my application's source tree I get no errors.
>
>
> > Forgive me if this is the wrong place to post this. I've dug through
> the
> > various archives and google'd to no avail.
> >
> > I'm getting the following stacktrace when trying to build my project
> in
> > Eclipse:
> >
> > java.io.StreamCorruptedException: invalid stream header
> >         at
> >
> java.io.ObjectInputStream.readStreamHeader(ObjectInputStream.java:737)
> >         at
> java.io.ObjectInputStream.<init>(ObjectInputStream.java:253)
> > at
> >
> org.aspectj.weaver.ResolvedTypeMunger.readSourceLocation(ResolvedTypeMunger.java:153)
> >         at
> >
> org.aspectj.weaver.NewMethodTypeMunger.readMethod(NewMethodTypeMunger.java:47)
> >         at
> >
> org.aspectj.weaver.ResolvedTypeMunger.read(ResolvedTypeMunger.java:107)
> >         at
> > org.aspectj.weaver.WeaverStateInfo.read(WeaverStateInfo.java:106)
> > at org.aspectj.weaver.AjAttribute.read(AjAttribute.java:95) at
> >
> org.aspectj.weaver.bcel.BcelAttributes.readAjAttributes(BcelAttributes.java:39)
> >         at
> >
> org.aspectj.weaver.bcel.BcelObjectType.unpackAspectAttributes(BcelObjectType.java:172)
> >         at
> > org.aspectj.weaver.bcel.BcelObjectType.<init>(BcelObjectType.java:91)
> >         at
> >
> org.aspectj.weaver.bcel.BcelWorld.makeBcelObjectType(BcelWorld.java:213)
> >         at
> >
> org.aspectj.weaver.bcel.BcelWorld.addSourceObjectType(BcelWorld.java:243)
> >         at
> >
> org.aspectj.weaver.bcel.BcelWeaver.addLibraryJarFile(BcelWeaver.java:155)
> >         at
> >
> org.aspectj.ajdt.internal.core.builder.AjBuildManager.initBcelWorld(AjBuildManager.java:500)
> >         at
> >
> org.aspectj.ajdt.internal.core.builder.AjBuildManager.doBuild(AjBuildManager.java:151)
> >         at
> >
> org.aspectj.ajdt.internal.core.builder.AjBuildManager.batchBuild(AjBuildManager.java:102)
> >         at
> >
> org.aspectj.ajde.internal.CompilerAdapter.compile(CompilerAdapter.java:122)
> >         at
> >
> org.aspectj.ajde.internal.AspectJBuildManager$CompilerThread.run(AspectJBuildManager.java:165)
> >
> >
> > eclipse-SDK-3.1M4-linux-gtk
> >
> > Eclipse Platform
> > Version: 3.1.0
> > Build id: 200412162000
> >
> > With AJDT 1.5.0.2004122110
> >
> > On a rather old Mandrake 9.0 distribution.
> >
> >
> > I've upgraded Eclipse and AJDT to the bleeding edge this morning due
> to
> > the problem. Prior to that I was using 3.1M3 though I don't remember
> > which version of AJDT (200411 I believe).
> >
> > What else can I tell you about my environment to help track this
> down?
> >
> > Thanks,
> > James
> >
> > _______________________________________________
> > ajdt-dev mailing list
> > ajdt-dev@xxxxxxxxxxx
> > http://dev.eclipse.org/mailman/listinfo/ajdt-dev
>
> _______________________________________________
> ajdt-dev mailing list
> ajdt-dev@xxxxxxxxxxx
> http://dev.eclipse.org/mailman/listinfo/ajdt-dev
>


_______________________________________________
ajdt-dev mailing list
ajdt-dev@xxxxxxxxxxx
http://dev.eclipse.org/mailman/listinfo/ajdt-dev


Back to the top