[JBoss JIRA] Created: (JBAS-7752) JavaEE 6: META-INF/application.xml cannot be version="6"
by Juergen Zimmermann (JIRA)
JavaEE 6: META-INF/application.xml cannot be version="6"
--------------------------------------------------------
Key: JBAS-7752
URL: https://jira.jboss.org/jira/browse/JBAS-7752
Project: JBoss Application Server
Issue Type: Bug
Security Level: Public (Everyone can see)
Components: VFS
Affects Versions: JBossAS-6.0.0.M2
Reporter: Juergen Zimmermann
Assignee: Ales Justin
The following contents of META-INF/application.xml produces a stacktrace (see below) during deployment:
<?xml version="1.0" encoding="UTF-8"?>
<application xmlns="http://java.sun.com/xml/ns/javaee"
xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
xsi:schemaLocation="http://java.sun.com/xml/ns/javaee http://java.sun.com/xml/ns/javaee/application_6.xsd"
version="6">
<display-name>Beispiel 2</display-name>
<module>
<ejb>hskaEJB.jar</ejb>
</module>
<module>
<web>
<web-uri>hskaWeb.war</web-uri>
<context-root>/hska</context-root>
</web>
</module>
<module>
<ejb>testHskaEJB.jar</ejb>
</module>
<module>
<java>testHskaClient.jar</java>
</module>
</application>
Stacktrace:
13:50:39,195 ERROR [org.jboss.kernel.plugins.dependency.AbstractKernelController] Error installing to Parse: name=vfsfile:/C:/Users/Public/Documents/eclipse-workspace-swe2/.metadata/.plugins/org.jboss.ide.eclipse.as.core/JBoss_6.0_Runtime_Server1266414248806/deploy/hska.ear/ state=PreParse mode=Manual requiredState=Parse: org.jboss.deployers.spi.DeploymentException: Error creating managed object for vfsfile:/C:/Users/Public/Documents/eclipse-workspace-swe2/.metadata/.plugins/org.jboss.ide.eclipse.as.core/JBoss_6.0_Runtime_Server1266414248806/deploy/hska.ear/
at org.jboss.deployers.spi.DeploymentException.rethrowAsDeploymentException(DeploymentException.java:49)
at org.jboss.deployers.spi.deployer.helpers.AbstractParsingDeployerWithOutput.createMetaData(AbstractParsingDeployerWithOutput.java:362)
at org.jboss.deployers.spi.deployer.helpers.AbstractParsingDeployerWithOutput.createMetaData(AbstractParsingDeployerWithOutput.java:322)
at org.jboss.deployers.spi.deployer.helpers.AbstractParsingDeployerWithOutput.createMetaData(AbstractParsingDeployerWithOutput.java:294)
at org.jboss.deployers.spi.deployer.helpers.AbstractParsingDeployerWithOutput.deploy(AbstractParsingDeployerWithOutput.java:234)
at org.jboss.deployers.plugins.deployers.DeployerWrapper.deploy(DeployerWrapper.java:179)
at org.jboss.deployers.plugins.deployers.DeployersImpl.doDeploy(DeployersImpl.java:1660)
at org.jboss.deployers.plugins.deployers.DeployersImpl.doInstallParentFirst(DeployersImpl.java:1378)
at org.jboss.deployers.plugins.deployers.DeployersImpl.install(DeployersImpl.java:1319)
at org.jboss.dependency.plugins.AbstractControllerContext.install(AbstractControllerContext.java:378)
at org.jboss.dependency.plugins.AbstractController.install(AbstractController.java:2029)
at org.jboss.dependency.plugins.AbstractController.incrementState(AbstractController.java:1050)
at org.jboss.dependency.plugins.AbstractController.executeOrIncrementStateDirectly(AbstractController.java:1289)
at org.jboss.dependency.plugins.AbstractController.resolveContexts(AbstractController.java:1213)
at org.jboss.dependency.plugins.AbstractController.resolveContexts(AbstractController.java:1107)
at org.jboss.dependency.plugins.AbstractController.change(AbstractController.java:918)
at org.jboss.dependency.plugins.AbstractController.change(AbstractController.java:633)
at org.jboss.deployers.plugins.deployers.DeployersImpl.process(DeployersImpl.java:898)
at org.jboss.deployers.plugins.main.MainDeployerImpl.process(MainDeployerImpl.java:677)
at org.jboss.system.server.profileservice.repository.MainDeployerAdapter.process(MainDeployerAdapter.java:117)
at org.jboss.system.server.profileservice.hotdeploy.HDScanner.scan(HDScanner.java:409)
at org.jboss.system.server.profileservice.hotdeploy.HDScanner.run(HDScanner.java:294)
at java.util.concurrent.Executors$RunnableAdapter.call(Executors.java:441)
at java.util.concurrent.FutureTask$Sync.innerRunAndReset(FutureTask.java:317)
at java.util.concurrent.FutureTask.runAndReset(FutureTask.java:150)
at java.util.concurrent.ScheduledThreadPoolExecutor$ScheduledFutureTask.access$101(ScheduledThreadPoolExecutor.java:98)
at java.util.concurrent.ScheduledThreadPoolExecutor$ScheduledFutureTask.runPeriodic(ScheduledThreadPoolExecutor.java:181)
at java.util.concurrent.ScheduledThreadPoolExecutor$ScheduledFutureTask.run(ScheduledThreadPoolExecutor.java:205)
at java.util.concurrent.ThreadPoolExecutor$Worker.runTask(ThreadPoolExecutor.java:886)
at java.util.concurrent.ThreadPoolExecutor$Worker.run(ThreadPoolExecutor.java:908)
at java.lang.Thread.run(Thread.java:619)
Caused by: java.lang.Exception: The xml hska.ear/META-INF/application.xml is not well formed!
at org.jboss.xb.util.JBossXBHelper.parse(JBossXBHelper.java:231)
at org.jboss.xb.util.JBossXBHelper.parse(JBossXBHelper.java:206)
at org.jboss.deployers.vfs.spi.deployer.SchemaResolverDeployer.parse(SchemaResolverDeployer.java:137)
at org.jboss.deployers.vfs.spi.deployer.SchemaResolverDeployer.parse(SchemaResolverDeployer.java:121)
at org.jboss.deployment.AppParsingDeployer.parse(AppParsingDeployer.java:79)
at org.jboss.deployment.AppParsingDeployer.parse(AppParsingDeployer.java:46)
at org.jboss.deployers.vfs.spi.deployer.AbstractVFSParsingDeployer.parseAndInit(AbstractVFSParsingDeployer.java:315)
at org.jboss.deployers.vfs.spi.deployer.AbstractVFSParsingDeployer.parseAndInit(AbstractVFSParsingDeployer.java:297)
at org.jboss.deployers.vfs.spi.deployer.AbstractVFSParsingDeployer.parse(AbstractVFSParsingDeployer.java:221)
at org.jboss.deployers.spi.deployer.helpers.AbstractParsingDeployerWithOutput.createMetaData(AbstractParsingDeployerWithOutput.java:348)
... 29 more
--
This message is automatically generated by JIRA.
-
If you think it was sent incorrectly contact one of the administrators: https://jira.jboss.org/jira/secure/Administrators.jspa
-
For more information on JIRA, see: http://www.atlassian.com/software/jira
16 years, 2 months
[JBoss JIRA] Created: (JBRULES-2528) NullPointerException during rule compilation on ReturnValueRestriction.replaceDeclaration instead of clear, understandable compiler error
by Geoffrey De Smet (JIRA)
NullPointerException during rule compilation on ReturnValueRestriction.replaceDeclaration instead of clear, understandable compiler error
-----------------------------------------------------------------------------------------------------------------------------------------
Key: JBRULES-2528
URL: https://jira.jboss.org/browse/JBRULES-2528
Project: Drools
Issue Type: Bug
Security Level: Public (Everyone can see)
Components: drools-compiler (expert)
Affects Versions: 5.1.0.M2
Reporter: Geoffrey De Smet
Assignee: Edson Tirelli
Priority: Minor
Fix For: FUTURE
With this rule:
rule "unwantedPatternFreeBeforeWorkSequencePattern"
when
$pattern : FreeBeforeWorkSequencePattern(
$firstWorkDayOfWeek : firstWorkDayOfWeek,
$workShiftType : workShiftType,
$workDayLength : workDayLength
)
PatternContractLine(
pattern == $pattern, $contract : contract
)
Assignment(
eval($firstWorkDayOfWeek == null) || (shiftDateDayOfWeek == $firstWorkDayOfWeek),
eval($workShiftType == null) || (shiftType == $workShiftType),
contract == $contract,
$employee : employee, $firstWorkDayIndex : shiftDateDayIndex
)
eval($workDayLength < 2) or Assignment(
eval($workShiftType == null) || (shiftType == $workShiftType),
employee == $employee,
shiftDateDayIndex == ($firstWorkDayIndex + 1)
)
// A free day before
EmployeeFreeSequence(
employee == $employee,
lastDayIndex == ($firstWorkDayIndex - 1)
)
then
insertLogical(new IntConstraintOccurrence("unwantedPatternFreeBeforeWorkSequencePattern",
ConstraintType.NEGATIVE_SOFT,
$pattern.getWeight(),
$employee, $pattern, $firstWorkDayIndex));
end
I get a NullPointerException.
The problem seems to lie in:
eval($workDayLength < 2) or Assignment(...)
EmployeeFreeSequence(
...
lastDayIndex == ($firstWorkDayIndex - 1)
)
So I should not use "or" in this way, but it would be nice to get a readable, understandable error message.
Exception in thread "main" java.lang.NullPointerException
at org.drools.rule.ReturnValueRestriction.replaceDeclaration(ReturnValueRestriction.java:193)
at org.drools.rule.ReturnValueConstraint.replaceDeclaration(ReturnValueConstraint.java:78)
at org.drools.rule.LogicTransformer.processElement(LogicTransformer.java:162)
at org.drools.rule.LogicTransformer.processElement(LogicTransformer.java:189)
at org.drools.rule.LogicTransformer.fixClonedDeclarations(LogicTransformer.java:130)
at org.drools.rule.LogicTransformer.transform(LogicTransformer.java:112)
at org.drools.rule.Rule.getTransformedLhs(Rule.java:536)
at org.drools.reteoo.builder.ReteooRuleBuilder.addRule(ReteooRuleBuilder.java:100)
at org.drools.reteoo.ReteooBuilder.addRule(ReteooBuilder.java:117)
at org.drools.reteoo.ReteooRuleBase.addRule(ReteooRuleBase.java:409)
at org.drools.common.AbstractRuleBase.addRule(AbstractRuleBase.java:638)
at org.drools.common.AbstractRuleBase.addPackages(AbstractRuleBase.java:520)
at org.drools.reteoo.ReteooRuleBase.addPackage(ReteooRuleBase.java:435)
at org.drools.planner.config.localsearch.LocalSearchSolverConfig.buildRuleBase(LocalSearchSolverConfig.java:208)
at org.drools.planner.config.localsearch.LocalSearchSolverConfig.buildSolver(LocalSearchSolverConfig.java:170)
at org.drools.planner.benchmark.SolverBenchmarkSuite.benchmark(SolverBenchmarkSuite.java:183)
at org.drools.planner.benchmark.XmlSolverBenchmarker.benchmark(XmlSolverBenchmarker.java:72)
at org.drools.planner.examples.common.app.CommonBenchmarkApp.process(CommonBenchmarkApp.java:25)
at org.drools.planner.examples.nurserostering.app.NurseRosteringBenchmarkApp.main(NurseRosteringBenchmarkApp.java:42)
at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method)
at sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:39)
at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:25)
at java.lang.reflect.Method.invoke(Method.java:597)
at com.intellij.rt.execution.application.AppMain.main(AppMain.java:110)
--
This message is automatically generated by JIRA.
-
If you think it was sent incorrectly contact one of the administrators: https://jira.jboss.org/secure/Administrators.jspa
-
For more information on JIRA, see: http://www.atlassian.com/software/jira
16 years, 2 months
[JBoss JIRA] Created: (JBRULES-2098) Internal TupleSink list is not properly cleaned up when removing rules from a RuleBase
by Christian Nedregård (JIRA)
Internal TupleSink list is not properly cleaned up when removing rules from a RuleBase
--------------------------------------------------------------------------------------
Key: JBRULES-2098
URL: https://jira.jboss.org/jira/browse/JBRULES-2098
Project: JBoss Drools
Issue Type: Bug
Security Level: Public (Everyone can see)
Components: drools-core
Affects Versions: 4.0.7
Environment: Drools 4.0.7
Win XP
Sun JDK 1.4.2_11
Reporter: Christian Nedregård
Assignee: Mark Proctor
When a new rule is added to a rule base that has shareBetaNodes=true 'BuildUtils.attachNode' will iterate through existing TupleSink nodes and try to find an equal node to re-use.
In our production code we are seing NoClassDefFoundErrors from 'EvalConditionNode.equals' in scenarios where rules are both removed from and added to a rule base. The NoClassDefFoundErrors occours when a rule has recently been removed from the rule base and we are trying to add a new rule. When BuildUtils.attachNode' iterates through the existing TupleSinks it also encounters TupleSinks that belongs to the rule that was removed. The call to the TupleSinks 'equal' method yields a NoClassDefFoundErrors because the target TupleSink are trying to reference the rule class that has been removed.
In this scenario we have removed rule 10418 and are adding 11140:
java.lang.NoClassDefFoundError: rules.subscriptiontype.Rule_RequiredSubscriptionTypes_10418_0
at rules.subscriptiontype.Rule_RequiredSubscriptionTypes_10418_0Eval0Invoker.class$(Unknown Source)
at rules.subscriptiontype.Rule_RequiredSubscriptionTypes_10418_0Eval0Invoker.getMethodBytecode(Unknown Source)
at rules.subscriptiontype.Rule_RequiredSubscriptionTypes_11140_0Eval0Invoker.equals(Unknown Source)
at org.drools.rule.EvalCondition.equals(EvalCondition.java:121)
at org.drools.reteoo.EvalConditionNode.equals(EvalConditionNode.java:201)
at org.drools.reteoo.builder.BuildUtils.attachNode(BuildUtils.java:101)
Attached is a stand-alone JUnit 4 testcase where the test 'testWithBetaNodeSharing' shows this problem. It does not produce a NoClassDefFoundError but we get a NPE from <removed rule>Eval0Invoker.getMethodBytecode instead (rule 1 has been removed, rule 3 is about to be added):
java.lang.NullPointerException
at failure_on_removal.Rule_rule_1_0Eval0Invoker.getMethodBytecode(Unknown Source)
at failure_on_removal.Rule_rule_3_0Eval0Invoker.equals(Unknown Source)
at org.drools.rule.EvalCondition.equals(EvalCondition.java:121)
at org.drools.reteoo.EvalConditionNode.equals(EvalConditionNode.java:201)
at org.drools.reteoo.builder.BuildUtils.attachNode(BuildUtils.java:101)
We intepret this to be a symptom of the same problem.
The workaround is to disable beta node sharing wich will bypass the TupleSink iteration alltogheter. This is shown in the test 'testWithoutBetaNodeSharing'.
Kind regards
Christian Nedregård
--
This message is automatically generated by JIRA.
-
If you think it was sent incorrectly contact one of the administrators: https://jira.jboss.org/jira/secure/Administrators.jspa
-
For more information on JIRA, see: http://www.atlassian.com/software/jira
16 years, 2 months