[JBoss Tools] - jboss-packaging-maven-plugin jboss-sar + m2e + JBT = NPE
by R Finlayson
R Finlayson [http://community.jboss.org/people/rfinlayson] created the discussion
"jboss-packaging-maven-plugin jboss-sar + m2e + JBT = NPE"
To view the discussion, visit: http://community.jboss.org/message/643854#643854
--------------------------------------------------------------
Hi,
Eclipse Indigo 3.6 latest 2011/12/29
m2e latest
m2e-wtp latest
jBossTools latest
Maven project is jboss-sar packaging configured with jboss-packaging-maven-plugin.
Import Maven Project:
java.lang.NullPointerException
at org.jboss.ide.eclipse.as.wtp.core.vcf.ExportedClassFolderReferenceResolver.canResolve(ExportedClassFolderReferenceResolver.java:36)
at org.eclipse.wst.common.componentcore.resolvers.ReferenceResolverUtil.getResolver(ReferenceResolverUtil.java:43)
at org.eclipse.wst.common.componentcore.internal.StructureEdit.createVirtualReference(StructureEdit.java:326)
at org.jboss.ide.eclipse.as.wtp.core.vcf.JBTVirtualComponent.getHardReferences(JBTVirtualComponent.java:106)
at org.jboss.ide.eclipse.as.wtp.core.vcf.JBTVirtualComponent.getReferences(JBTVirtualComponent.java:76)
at org.maven.ide.eclipse.wtp.overlay.internal.servers.OverlayResourceChangeListener.hasOverlayChanged(OverlayResourceChangeListener.java:117)
at org.maven.ide.eclipse.wtp.overlay.internal.servers.OverlayResourceChangeListener.resourceChanged(OverlayResourceChangeListener.java:60)
at org.eclipse.core.internal.events.NotificationManager$1.run(NotificationManager.java:291)
...
Seems that "ReferencedComponent.getHandle()" returns null.
Project builds with mvn OK, project import doesn't complete with NPE above, in Eclipse Indigo, m2e and m2e-wtp, with jBoss Tools Maven integration.
Other projects in workspace (EAR, WAR, Dynamic Web Modules) import and build OK and work with m2e-wtp OK.
How can I resolve this?
--------------------------------------------------------------
Reply to this message by going to Community
[http://community.jboss.org/message/643854#643854]
Start a new discussion in JBoss Tools at Community
[http://community.jboss.org/choose-container!input.jspa?contentType=1&cont...]
14 years, 3 months
[JBoss Tools] - JBoss tools does not put impl classes on classpath for AS7
by henk de boer
henk de boer [http://community.jboss.org/people/henk53] created the discussion
"JBoss tools does not put impl classes on classpath for AS7"
To view the discussion, visit: http://community.jboss.org/message/633122#633122
--------------------------------------------------------------
Using JBoss Tools 3.2m4 (isn't released, but somehow came with server runtime discovery in Eclipse 3.7sr1) and JBoss AS 7.02, it seems the implementation classes are not put on the classpath anymore.
Depending on the role of the developer, this is both a blessing and a curse.
It's a blessing, since 'ordinary' application developers can now not mistakingly depend on implementation classes.
It's a curse, since more experienced developers typically fix problems by stepping into the framework to see where exactly something goes wrong (one of the MAJOR benefits of open source software).
Without those classes present on the classpath, it will be very troublesome to get the right versions and then to attach the right source-code. This problem is like the source code that was missing in the JBoss AS 6 source download, but worse. Now not only the source code is missing, but the implementation is missing as well (in the IDE).
As a small example, suppose I expect there's a problem in say class ActionListenerImpl (because I see this at a crucial point in my stacktrace). I try to open this class using ctrl-shift-t.
With the JBoss AS 6 runtime, it shows that this class is in jsf-impl-2.0.3-b05.jar. When I open the class there's no source-attachment, but I have a lead that I can use to hunt the Internet for the source attachment.
With the JBoss AS 7 runtime, nothing...
Just nothing...
Nothing shows up... :(
So now I have to unpack all jars from the binary distribution of JBoss AS, do grepping on the filesystem, when I find the jar, copy it to my project, exclude it from source control, add it to the classpath, and -then- I can start hunting the Internet for the source attachment.
Basically, with every version of JBoss AS, it seems to get more difficult to easily step through the source code that makes up JBoss AS. Am I perhaps one of the very few developers who actually likes to step into the framework's source-code instead of treating it as a black-box?
Would it be possible to have an option somewhere so the runtime actually puts the implementation classes on the IDE's classpath?
--------------------------------------------------------------
Reply to this message by going to Community
[http://community.jboss.org/message/633122#633122]
Start a new discussion in JBoss Tools at Community
[http://community.jboss.org/choose-container!input.jspa?contentType=1&cont...]
14 years, 3 months
[JBoss Tools] - I met a problem when install freemarker
by Ye Li
Ye Li [http://community.jboss.org/people/yingtju] created the discussion
"I met a problem when install freemarker"
To view the discussion, visit: http://community.jboss.org/message/643105#643105
--------------------------------------------------------------
I download the 3.2.2 zip file, and selected only freemarker to install, here is the detail:
Cannot complete the install because one or more required items could not be found.
Software being installed: FreeMarker IDE 1.1.0.v20111025-0320-H192-Final (org.jboss.ide.eclipse.freemarker.feature.feature.group 1.1.0.v20111025-0320-H192-Final)
Missing requirement: FreeMarker IDE 1.1.0.v20111025-0320-H192-Final (org.jboss.ide.eclipse.freemarker 1.1.0.v20111025-0320-H192-Final) requires 'bundle org.junit 0.0.0' but it could not be found
Cannot satisfy dependency:
From: FreeMarker IDE 1.1.0.v20111025-0320-H192-Final (org.jboss.ide.eclipse.freemarker.feature.feature.group 1.1.0.v20111025-0320-H192-Final)
To: org.jboss.ide.eclipse.freemarker [1.1.0.v20111025-0320-H192-Final]
it seems like has stm to do with org.junit, i found the resource-bound in the manifest.mf has the org.junit,so i delete it but it did not work out
Any suggestion is appreciated!
--------------------------------------------------------------
Reply to this message by going to Community
[http://community.jboss.org/message/643105#643105]
Start a new discussion in JBoss Tools at Community
[http://community.jboss.org/choose-container!input.jspa?contentType=1&cont...]
14 years, 3 months
[jBPM] - problem with MVEL:Possible incorrect version of ASM present (3.0 required). Disabling JIT compiler. Reflective Optimizer will be used.
by hong lu
hong lu [http://community.jboss.org/people/luhong] created the discussion
"problem with MVEL:Possible incorrect version of ASM present (3.0 required). Disabling JIT compiler. Reflective Optimizer will be used."
To view the discussion, visit: http://community.jboss.org/message/645632#645632
--------------------------------------------------------------
hi,
I use bpmn2 eclipse plugin create a process flow and program a test.
I get below output messages:
(null: 2, 307): cvc-elt.1: Cannot find the declaration of element 'bpmn2:definitions'.
(null: 33, 63): cvc-elt.4.2: Cannot resolve 'dc:Point' to a type definition for element 'di:waypoint'.
(null: 34, 63): cvc-elt.4.2: Cannot resolve 'dc:Point' to a type definition for element 'di:waypoint'.
(null: 37, 63): cvc-elt.4.2: Cannot resolve 'dc:Point' to a type definition for element 'di:waypoint'.
(null: 38, 63): cvc-elt.4.2: Cannot resolve 'dc:Point' to a type definition for element 'di:waypoint'.
java.lang.NullPointerException
at org.mvel2.optimizers.OptimizerFactory.<clinit>(OptimizerFactory.java:45)
at org.drools.base.mvel.MVELCompilationUnit.compile(MVELCompilationUnit.java:419)
at org.drools.base.mvel.MVELCompilationUnit.getCompiledExpression(MVELCompilationUnit.java:243)
at org.jbpm.process.instance.impl.MVELAction.compile(MVELAction.java:70)
at org.jbpm.process.builder.dialect.mvel.MVELActionBuilder.build(MVELActionBuilder.java:131)
at org.jbpm.process.builder.ActionNodeBuilder.build(ActionNodeBuilder.java:25)
at org.jbpm.compiler.ProcessBuilderImpl.processNodes(ProcessBuilderImpl.java:213)
at org.jbpm.compiler.ProcessBuilderImpl.buildNodes(ProcessBuilderImpl.java:199)
at org.jbpm.compiler.ProcessBuilderImpl.buildProcess(ProcessBuilderImpl.java:163)
at org.jbpm.compiler.ProcessBuilderImpl.addProcessFromXml(ProcessBuilderImpl.java:252)
at org.drools.compiler.PackageBuilder.addProcessFromXml(PackageBuilder.java:564)
at org.drools.compiler.PackageBuilder.addKnowledgeResource(PackageBuilder.java:608)
at org.drools.builder.impl.KnowledgeBuilderImpl.add(KnowledgeBuilderImpl.java:37)
at com.test.workflow.BPMN2Test.main(BPMN2Test.java:14)
[MVEL] Notice: Possible incorrect version of ASM present (3.0 required). Disabling JIT compiler. Reflective Optimizer will be used.
hello world
Could anybody tell me how to resolve above NullPointerException. I don't find any solution from google's results.
and where I can find an full guider of how to use the BPMN2 eclipse plugin, thanks.
Forgive me for my bad english.Thanks very much.
bpmn file:
<?xml version="1.0" encoding="UTF-8"?>
<bpmn2:definitions xmlns:xsi=" http://www.w3.org/2001/XMLSchema-instance http://www.w3.org/2001/XMLSchema-instance" xmlns:bpmn2=" http://www.omg.org/spec/BPMN/20100524/MODEL http://www.omg.org/spec/BPMN/20100524/MODEL" xmlns:bpmndi=" http://www.omg.org/spec/BPMN/20100524/DI http://www.omg.org/spec/BPMN/20100524/DI" xmlns:dc=" http://www.omg.org/spec/DD/20100524/DC http://www.omg.org/spec/DD/20100524/DC" xmlns:di=" http://www.omg.org/spec/DD/20100524/DI http://www.omg.org/spec/DD/20100524/DI" id="Definitions_1">
<bpmn2:collaboration id="Collaboration_1">
<bpmn2:participant id="Participant_1" name="Internal" processRef="com.test.login"/>
</bpmn2:collaboration>
<bpmn2:process id="com.test.login" name="loginProcess" isClosed="true">
<bpmn2:startEvent id="StartEvent_1" name="Start">
<bpmn2:outgoing>SequenceFlow_3</bpmn2:outgoing>
</bpmn2:startEvent>
<bpmn2:endEvent id="EndEvent_1" name="End">
<bpmn2:incoming>SequenceFlow_6</bpmn2:incoming>
</bpmn2:endEvent>
<bpmn2:sequenceFlow id="SequenceFlow_3" name="" sourceRef="StartEvent_1" targetRef="ScriptTask_1"/>
<bpmn2:scriptTask id="ScriptTask_1" name="Script Task" scriptFormat="">
<bpmn2:incoming>SequenceFlow_3</bpmn2:incoming>
<bpmn2:outgoing>SequenceFlow_6</bpmn2:outgoing>
<bpmn2:script>System.out.println("hello world");</bpmn2:script>
</bpmn2:scriptTask>
<bpmn2:sequenceFlow id="SequenceFlow_6" name="" sourceRef="ScriptTask_1" targetRef="EndEvent_1"/>
</bpmn2:process>
<bpmndi:BPMNDiagram id="_L0Uu0DtuEeGfR6QZoDLdng">
<bpmndi:BPMNPlane id="_L0Uu0TtuEeGfR6QZoDLdng" bpmnElement="com.test.login">
<bpmndi:BPMNShape id="BPMNShape_StartEvent_1" bpmnElement="StartEvent_1">
<dc:Bounds height="51.0" width="36.0" x="90.0" y="170.0"/>
</bpmndi:BPMNShape>
<bpmndi:BPMNShape id="BPMNShape_EndEvent_1" bpmnElement="EndEvent_1">
<dc:Bounds height="51.0" width="36.0" x="450.0" y="170.0"/>
</bpmndi:BPMNShape>
<bpmndi:BPMNShape id="BPMNShape_ScriptTask_1" bpmnElement="ScriptTask_1">
<dc:Bounds height="50.0" width="110.0" x="230.0" y="163.0"/>
</bpmndi:BPMNShape>
<bpmndi:BPMNEdge id="BPMNEdge_SequenceFlow_3" bpmnElement="SequenceFlow_3" sourceElement="BPMNShape_StartEvent_1" targetElement="BPMNShape_ScriptTask_1">
<di:waypoint xsi:type="dc:Point" x="126.0" y="188.0"/>
<di:waypoint xsi:type="dc:Point" x="230.0" y="188.0"/>
</bpmndi:BPMNEdge>
<bpmndi:BPMNEdge id="BPMNEdge_SequenceFlow_4" bpmnElement="SequenceFlow_6" sourceElement="BPMNShape_ScriptTask_1" targetElement="BPMNShape_EndEvent_1">
<di:waypoint xsi:type="dc:Point" x="340.0" y="188.0"/>
<di:waypoint xsi:type="dc:Point" x="450.0" y="188.0"/>
</bpmndi:BPMNEdge>
</bpmndi:BPMNPlane>
</bpmndi:BPMNDiagram>
</bpmn2:definitions>
java source:
package com.test.workflow;
import org.drools.KnowledgeBase;
import org.drools.builder.KnowledgeBuilder;
import org.drools.builder.KnowledgeBuilderFactory;
import org.drools.builder.ResourceType;
import org.drools.io.ResourceFactory;
import org.drools.runtime.StatefulKnowledgeSession;
import org.drools.runtime.process.ProcessInstance;
public class BPMN2Test {
public static void main(String[] args) {
KnowledgeBuilder kbuilder = KnowledgeBuilderFactory.newKnowledgeBuilder();
kbuilder.add(ResourceFactory.newClassPathResource("com/test/workflow/flow/loginProcess.bpmn"),
ResourceType.BPMN2);
KnowledgeBase kbase = kbuilder.newKnowledgeBase();
StatefulKnowledgeSession ksession = kbase.newStatefulKnowledgeSession();
ProcessInstance processInstance = ksession.startProcess("com.test.login");
}
}
--------------------------------------------------------------
Reply to this message by going to Community
[http://community.jboss.org/message/645632#645632]
Start a new discussion in jBPM at Community
[http://community.jboss.org/choose-container!input.jspa?contentType=1&cont...]
14 years, 3 months
[Beginner's Corner] - Evading Authentication
by Satish Kinikiri
Satish Kinikiri [http://community.jboss.org/people/satish.kinikiri] created the discussion
"Evading Authentication"
To view the discussion, visit: http://community.jboss.org/message/645578#645578
--------------------------------------------------------------
Hi
I am trying to introduce single-sign-on (SSO) for our application.
Currently our application has a custom login module. I want to retain it the same authenication process when user is logging in directly with username/password (through non-SSO).
And want to add authenication system to when the user tried to login into my app using application through some API.
(Through SSO user name is availalble but not password I will make use of the username to create roles)
Current authenication process :
LoginClient loginClient = new LoginClient(loginName, loginPassword, true /* server login */);
AppIQUserData user = loginClient.login();
......
......
and Login client is
public LoginClient(String username, String password, boolean serverLogin)
throws LoginException
{
this(new UsernamePasswordHandler(username, password), serverLogin);
}
public LoginClient (CallbackHandler handler, boolean serverLogin) throws LoginException
{
this(handler, serverLogin ? SecurityConstants.SECURITY_DOMAIN : SecurityConstants.CLIENT_DOMAIN, serverLogin);
}
public LoginClient (CallbackHandler handler, String securityDomain, boolean serverLogin) throws LoginException
{
log.trace2("login security domain: " + securityDomain);
this.serverLogin = serverLogin;
context = new LoginContext(securityDomain, handler);
}
/**
* Perform a login to the AppIQ system.
* @return The AppIQUserData that has been authenticated
* @throws LoginException if the login fails
*/
public synchronized AppIQUserData login() throws LoginException
{
log.trace2("login - " + (serverLogin ? "SERVER" : "CLIENT"));
context.login();
if (!serverLogin)
return null;
Subject subject = context.getSubject();
if (subject == null)
throw new LoginException(LocalizationUtilities.localize("Exceptions", "LoginFailedNoSubject"));
log.trace2("login SERVER returns subject: " + subject.toString());
AppIQUserData user = SecurityMethods.getCallerPrincipal(subject);
if (user == null)
throw new LoginException(LocalizationUtilities.localize("Exceptions", "UnableToExtractAppIQUserData"));
/* Stash the context in a cache so that we can re-authenticate when we
* need to in order to force updates to login credentials when
* necessary.
*/
SecurityMethods.add(context);
return user;
}
Any idea how we can have the option of avoiding authenication when we are using UsernamePasswordHandler.
Thanks
mailto:Satish.kinikiri@gmail.com Satish.kinikiri(a)gmail.com
--------------------------------------------------------------
Reply to this message by going to Community
[http://community.jboss.org/message/645578#645578]
Start a new discussion in Beginner's Corner at Community
[http://community.jboss.org/choose-container!input.jspa?contentType=1&cont...]
14 years, 3 months
[Beginner's Corner] - TorqueBox related question
by Morgan Daniel
Morgan Daniel [http://community.jboss.org/people/chikigai] created the discussion
"TorqueBox related question"
To view the discussion, visit: http://community.jboss.org/message/644950#644950
--------------------------------------------------------------
Hello,
First of all, I'd like to apologize in advance if this topic is unrelated to the JBoss community.
I have been looking for information for some time now with no success.
Haven't managed to find a forum specific to TorqueBox either.
I am trying to use Redmine 1.3.0 (Rails App) with TorqueBox 2.0.0.beta1 (Contains JBoss AS7 and JRuby 1.6.5).
I have got JBoss up and running with Redmine accessible without any problems.
However, outgoing emails from Redmine are not working at all. (No errors in log)
I currently have no idea whether I'm missing something in either JBoss or JRuby.
My current setup is as follows:
WinXP SP3
TorqueBox 2.0.0.beta1
JBoss AS7
JRuby 1.6.5
Redmine 1.3.0
My previous setup had no problems with outgoing emails:
WinXP SP3
Apache 2.2.21
Ruby 1.8.7
Thin 1.3.1
Redmine 1.3.0
Any pointers to a starting point would be greatly appreciated.
--------------------------------------------------------------
Reply to this message by going to Community
[http://community.jboss.org/message/644950#644950]
Start a new discussion in Beginner's Corner at Community
[http://community.jboss.org/choose-container!input.jspa?contentType=1&cont...]
14 years, 3 months
[jBPM] - NPE Loading Knowledge Base from URL
by M Arnold
M Arnold [http://community.jboss.org/people/marnold] created the discussion
"NPE Loading Knowledge Base from URL"
To view the discussion, visit: http://community.jboss.org/message/645516#645516
--------------------------------------------------------------
Hi,
I'm using Drools and Guvnor 5.3.1. When I try to load my knowledge base from Guvnor like this:
{code}
KnowledgeAgentConfiguration kaconf = KnowledgeAgentFactory.newKnowledgeAgentConfiguration();
kaconf.setProperty("drools.agent.scanDirectories", "false");
kaconf.setProperty("drools.agent.scanResources", "false");
KnowledgeAgent ka = KnowledgeAgentFactory.newKnowledgeAgent("agent", kaconf);
URL url = new URL(urlString);
UrlResource urlResource = (UrlResource)ResourceFactory.newUrlResource(url);
ka.applyChangeSet(urlResource);
kbase = ka.getKnowledgeBase();
{code}
I get this exception:
{code}
java.lang.NullPointerException
at org.drools.impl.KnowledgeBaseImpl.addKnowledgePackages(KnowledgeBaseImpl.java:148)
at org.drools.agent.impl.KnowledgeAgentImpl.addResourcesToKnowledgeBase(KnowledgeAgentImpl.java:1016)
at org.drools.agent.impl.KnowledgeAgentImpl.rebuildResources(KnowledgeAgentImpl.java:785)
at org.drools.agent.impl.KnowledgeAgentImpl.buildKnowledgeBase(KnowledgeAgentImpl.java:657)
at org.drools.agent.impl.KnowledgeAgentImpl.applyChangeSet(KnowledgeAgentImpl.java:190)
at org.drools.agent.impl.KnowledgeAgentImpl.applyChangeSet(KnowledgeAgentImpl.java:169)
[snip]
{code}
I've tried 'Rebuilding all snapshot binaries'. Has my repository become corrupted?
Also, can I build my knowledge base directly from Guvnor's JCR implementation, rather than over HTTP? I'm not interested in listening / scanning for changes to the underlying packages. I just want to load my rules and processes from Guvnor.
Apologies if this is not the correct forum. I couldn't find a discussion forum for Drools.
Thanks
--------------------------------------------------------------
Reply to this message by going to Community
[http://community.jboss.org/message/645516#645516]
Start a new discussion in jBPM at Community
[http://community.jboss.org/choose-container!input.jspa?contentType=1&cont...]
14 years, 3 months