![]() ![]() I confirmed that it fixes the problem in Tc Server. Don't assume that aspect libraries are files, and hence that urls are file url, and use URLConnection to fetch aspect library contents. ![]() Use Files instead of Strings and let Java handle the URL, using the File(URI) constructor ![]() Decode the string obtained by URL.getPath() using code() Multiple solutions are possible for this simple bug, in order of impact : This issue is quite important, because on older windows "Documents and Settings" is an unfortunately common path, for example Maven stores there its repository. When later this string is used to create a new File instance, that file contains an invalid path, and the weaver fails as follows :Ĭaused by: : bad aspect library: '/home/sym/path%20with%20space/aspect-library.jar'Īt .WeavingAdaptor$WeavingAdaptorMessageHolder.handleMessage(WeavingAdaptor.java:624)Īt .error(MessageUtil.java:80)Īt .WeavingAdaptor.error(WeavingAdaptor.java:504)Īt .WeavingAdaptor.addAspectLibrary(WeavingAdaptor.java:472)Īt .WeavingAdaptor.registerAspectLibraries(WeavingAdaptor.java:447)Īt .WeavingAdaptor.init(WeavingAdaptor.java:177)Īt .WeavingAdaptor.(WeavingAdaptor.java:112) But this method does not decode the string, it returns it as it is in the URL. This method uses URL.getPath() to obtain the path. This is done inside the FileUtil.makeClasspath(URL). It then converts these file:// urls to simple string paths, and then tries to access files pointed by those paths. The URL of a file is encoded, for example if it contains spaces they will be represented with %20. The WeavingAdaptor requires the aspect path to be composed by URLs. ![]()
0 Comments
Leave a Reply. |
AuthorWrite something about yourself. No need to be fancy, just an overview. ArchivesCategories |