[JBoss JIRA] (JASSIST-226) automatical modification of class and method Annotation
by Paolo Paolo (JIRA)
[ https://issues.jboss.org/browse/JASSIST-226?page=com.atlassian.jira.plugi... ]
Paolo Paolo commented on JASSIST-226:
-------------------------------------
The created class works well if I don't use the RDFBeans library. Otherwise in another project the string "@RDFBean(value="http...")" works with the RDFBeans library.
This is the console output:
Exception in thread "main" java.lang.reflect.GenericSignatureFormatError
at sun.reflect.generics.parser.SignatureParser.error(Unknown Source)
at sun.reflect.generics.parser.SignatureParser.parsePackageNameAndSimpleClassTypeSignature(Unknown Source)
at sun.reflect.generics.parser.SignatureParser.parseClassTypeSignature(Unknown Source)
at sun.reflect.generics.parser.SignatureParser.parseFieldTypeSignature(Unknown Source)
at sun.reflect.generics.parser.SignatureParser.parseFieldTypeSignature(Unknown Source)
at sun.reflect.generics.parser.SignatureParser.parseTypeSignature(Unknown Source)
at sun.reflect.generics.parser.SignatureParser.parseTypeSig(Unknown Source)
at sun.reflect.annotation.AnnotationParser.parseSig(Unknown Source)
at sun.reflect.annotation.AnnotationParser.parseAnnotation(Unknown Source)
at sun.reflect.annotation.AnnotationParser.parseAnnotations2(Unknown Source)
at sun.reflect.annotation.AnnotationParser.parseAnnotations(Unknown Source)
at java.lang.reflect.Method.declaredAnnotations(Unknown Source)
at java.lang.reflect.Method.getAnnotation(Unknown Source)
at java.beans.PropertyDescriptor.setReadMethod(Unknown Source)
at java.beans.PropertyDescriptor.<init>(Unknown Source)
at java.beans.Introspector.getTargetPropertyInfo(Unknown Source)
at java.beans.Introspector.getBeanInfo(Unknown Source)
at java.beans.Introspector.getBeanInfo(Unknown Source)
at com.viceversatech.rdfbeans.reflect.RDFBeanInfo.<init>(RDFBeanInfo.java:85)
at com.viceversatech.rdfbeans.reflect.RDFBeanInfo.get(RDFBeanInfo.java:56)
at com.viceversatech.rdfbeans.RDFBeanManager.getAll(RDFBeanManager.java:305)
at main.AAL_Test.main(AAL_Test.java:44)
> automatical modification of class and method Annotation
> -------------------------------------------------------
>
> Key: JASSIST-226
> URL: https://issues.jboss.org/browse/JASSIST-226
> Project: Javassist
> Issue Type: Bug
> Security Level: Public(Everyone can see)
> Affects Versions: 3.18.0-GA
> Environment: JavaSE-1.7, Eclipse Kepler
> Reporter: Paolo Paolo
> Assignee: Shigeru Chiba
> Labels: annotations
>
> I'm using Javassist to create .class file at runtime. Every method of the created class must have a Java Annotation ("@annotation example") with an URI. The problem is that the Annotation class modifies automatically the URI by substituting slashes with dots.
> //the Annotation String that I need
> @RDFBean('http://www.semanticweb.org/pi/2014/5/test#Test')
> //the resulting String
> @RDFBean('http:..www.semanticweb.org.pi.2014.5.test#Test')
> Is there a way to prevent this String modification?
> I suppose it's related to the different notation between a file path and a Java package.
> This is the code:
> ClassPool pool = ClassPool.getDefault();
> CtClass cc = pool.makeClass(className);
>
> ClassFile ccFile = cc.getClassFile();
> ConstPool constpool = ccFile.getConstPool();
> // create the annotation
> AnnotationsAttribute attr = new AnnotationsAttribute(constpool, AnnotationsAttribute.visibleTag);
> // classLocalName contains: http://www.semanticweb.org/pi/2014/5/test#Test
> Annotation annot = new Annotation("RDFBean('" + classLocalName + "')", constpool);
> attr.addAnnotation(annot);
> ccFile.addAttribute(attr);
--
This message was sent by Atlassian JIRA
(v6.2.6#6264)
10 years, 6 months
[JBoss JIRA] (WFLY-3414) moduleAlias should be optional in jboss-deployment-structure.xml
by Chao Wang (JIRA)
[ https://issues.jboss.org/browse/WFLY-3414?page=com.atlassian.jira.plugin.... ]
Chao Wang reassigned WFLY-3414:
-------------------------------
Assignee: Chao Wang (was: Jason Greene)
> moduleAlias should be optional in jboss-deployment-structure.xml
> ----------------------------------------------------------------
>
> Key: WFLY-3414
> URL: https://issues.jboss.org/browse/WFLY-3414
> Project: WildFly
> Issue Type: Bug
> Security Level: Public(Everyone can see)
> Affects Versions: 8.0.0.Final
> Reporter: Harald Wellmann
> Assignee: Chao Wang
>
> Very similar to WFLY-2851, there is still another issue where the schema {{jboss-deployment-structure-1_2.xsd}} expects a mandatory element {{moduleAlias}} in {{moduleType}}, which should be optional.
> A module definition without {{moduleAlias}} works fine at runtime, but the {{jboss-deployment-structure.xml}} does not validate against the schema.
--
This message was sent by Atlassian JIRA
(v6.2.6#6264)
10 years, 6 months
[JBoss JIRA] (WFLY-3538) Application does not deploy because DefaultDataSource is missing
by Chao Wang (JIRA)
[ https://issues.jboss.org/browse/WFLY-3538?page=com.atlassian.jira.plugin.... ]
Chao Wang commented on WFLY-3538:
---------------------------------
With another local experiment, I can execute followings commands within CLI to remove the default datasource binding. And no ERROR pops up during deployment.
{noformat}
# /subsystem=datasources/data-source=ExampleDS:remove()
# /subsystem=ee/service=default-bindings:write-attribute(name=datasource,value=undefined)
# deploy xxx.war
{noformat}
Please let me know if this satisfies your requirement.
> Application does not deploy because DefaultDataSource is missing
> ----------------------------------------------------------------
>
> Key: WFLY-3538
> URL: https://issues.jboss.org/browse/WFLY-3538
> Project: WildFly
> Issue Type: Bug
> Security Level: Public(Everyone can see)
> Affects Versions: 8.1.0.Final
> Environment: Debian linux 7.5, openjdk 7u55-2.4.7-1~deb7u1, Wildfly 8.1.0.Final
> Reporter: Peter Van Biesen
> Assignee: Chao Wang
>
> On our servers, the ExampleDs is removed from the config. In 7.2.0, this poses no problem, but in the 8.1.0.Final, when we deploy an application, the default datasource needs to be available, even if the application does not use a datasource. The error :
> {code}
> failure description: {"JBAS014771: Services with missing/unavailable dependencies" => ["jboss.naming.context.java.module.jolokia.jolokia.DefaultDataSource is missing [jboss.naming.context.java.jboss.datasources.ExampleDS]"]}
> {code}
> The example above is for the deployment of the jolokia war.
> To reproduce :
> * remove ExampleDS
> * deploy any application
--
This message was sent by Atlassian JIRA
(v6.2.6#6264)
10 years, 6 months