[JBoss JIRA] (JASSIST-226) automatical modification of class and method Annotation
by Shigeru Chiba (JIRA)
[ https://issues.jboss.org/browse/JASSIST-226?page=com.atlassian.jira.plugi... ]
Shigeru Chiba commented on JASSIST-226:
---------------------------------------
Well, the first argument to addMemberValue() is the name of the member.
It is a filed name in the annotation type. Maybe, "value" would be the right name in your case.
> 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, 2 months
[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:
-------------------------------------
Thanks, I've tried with this code:
ClassFile ccFile = cc.getClassFile();
ConstPool constpool = ccFile.getConstPool();
// create the annotation
AnnotationsAttribute attr = new AnnotationsAttribute(constpool, AnnotationsAttribute.visibleTag);
Annotation annot = new Annotation("RDFBean", constpool);
StringMemberValue stringMember = new StringMemberValue(classLocalName, constpool);
annot.addMemberValue("nameMember", stringMember);
System.out.println("Type: " + annot.getTypeName());
attr.addAnnotation(annot);
ccFile.addAttribute(attr);
But the resulting Annotation will be: "@RDFBean(nameMember="http://www.semanticweb.org/pi/ontologies/2014/5/test_aal#Entry")"
Is there a way to remove "nameMember="?
> 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, 2 months
[JBoss JIRA] (WFLY-1017) Filesystem deployment scanner for a managed domain
by RH Bugzilla Integration (JIRA)
[ https://issues.jboss.org/browse/WFLY-1017?page=com.atlassian.jira.plugin.... ]
RH Bugzilla Integration updated WFLY-1017:
------------------------------------------
Bugzilla Update: Perform
Bugzilla References: https://bugzilla.redhat.com/show_bug.cgi?id=1078889
> Filesystem deployment scanner for a managed domain
> --------------------------------------------------
>
> Key: WFLY-1017
> URL: https://issues.jboss.org/browse/WFLY-1017
> Project: WildFly
> Issue Type: Enhancement
> Security Level: Public(Everyone can see)
> Components: Domain Management
> Environment: Ubuntu 12.04 Os , JBOSS As 7.1.0 final
> Reporter: hitesh yadav
> Original Estimate: 1 day, 4 hours
> Remaining Estimate: 1 day, 4 hours
>
> Is there any folder or path at which if any .war is put, in such a way that when JBOSS AS 7.1.0 start in domain mode the .war file deploy in Master node and it's related slave Node.
> For Example......... In standalone mode if we put .war file in /jboss-as-7.1.0.Final/standalone/deployments/ folder and start the JBOSS AS 7.1.0 in standalone mode ,the .war deploy properly.......i want same thing domain mode, in other-server-group .....
> Means the requirement is that the .war file should put in one folder and when JBOSS AS 7.1.0 start in domain mode the .war file should deploy in other-server-group .............
--
This message was sent by Atlassian JIRA
(v6.2.6#6264)
10 years, 2 months
[JBoss JIRA] (WFLY-3561) mod_proxy incompatible with logout mechanism
by Heiko Braun (JIRA)
[ https://issues.jboss.org/browse/WFLY-3561?page=com.atlassian.jira.plugin.... ]
Heiko Braun moved HAL-20 to WFLY-3561:
--------------------------------------
Project: WildFly (was: HAL)
Key: WFLY-3561 (was: HAL-20)
Workflow: GIT Pull Request workflow (was: classic default workflow)
Component/s: Domain Management
(was: Authentication)
Security: Public
> mod_proxy incompatible with logout mechanism
> --------------------------------------------
>
> Key: WFLY-3561
> URL: https://issues.jboss.org/browse/WFLY-3561
> Project: WildFly
> Issue Type: Bug
> Security Level: Public(Everyone can see)
> Components: Domain Management
> Reporter: Jason Greene
> Assignee: Jason Greene
> Attachments: apache_mod_proxy_mgmt.conf, Screenshot_proxy_logs.png
>
>
> We need to either outlaw proxies, or to make sure the console works with them.
--
This message was sent by Atlassian JIRA
(v6.2.6#6264)
10 years, 2 months
[JBoss JIRA] (JASSIST-226) automatical modification of class and method Annotation
by Shigeru Chiba (JIRA)
[ https://issues.jboss.org/browse/JASSIST-226?page=com.atlassian.jira.plugi... ]
Shigeru Chiba commented on JASSIST-226:
---------------------------------------
It seems that the usage of the API is wrong.
The argument to new Annotation() is the type name of the annotation.
The member of the annotation must be given by addMemberValue().
Please see the javadoc.
> 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, 2 months