Invalid Token in Jdeveloper with BPM 11G - java

I'm working with Oracle BPM 11G(11.1.1.7) and Jdeveloper.
I am getting below error while creating BPM MDS, my database and my SOA-MDS are working perfectly for a connection.
Only when I try to create the BPM-MDS error happens
Test Failed: ORABPEL-30503
Invalid Token Error in Verification Service.
Invalid Token Error in Verification Service. Received invalid token in null.
Verify that correct token is passed.
at oracle.bpel.services.workflow.verification.impl.VerificationService.validateContextToken(VerificationService.java:1769)
at oracle.bpel.services.workflow.verification.impl.VerificationService.validateContext(VerificationService.java:1662)
at oracle.bpel.services.workflow.verification.impl.VerificationService.validateContext(VerificationService.java:1969)
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 org.springframework.aop.support.AopUtils.invokeJoinpointUsingReflection(AopUtils.java:307)
at org.springframework.aop.framework.ReflectiveMethodInvocation.invokeJoinpoint(ReflectiveMethodInvocation.java:182)
at org.springframework.aop.framework.ReflectiveMethodInvocation.proceed(ReflectiveMethodInvocation.java:149)
at oracle.bpel.services.workflow.common.WorkflowServiceCacheEventAdvice.invoke(WorkflowServiceCacheEventAdvice.java:91)
at org.springframework.aop.framework.ReflectiveMethodInvocation.proceed(ReflectiveMethodInvocation.java:171)
at org.springframework.aop.framework.JdkDynamicAopProxy.invoke(JdkDynamicAopProxy.java:204)
at $Proxy243.validateContext(Unknown Source)
at oracle.bpm.services.pml.impl.SecurityService.validateContext(SecurityService.java:237)
at oracle.bpm.services.pml.impl.SecurityService.getSecurityService(SecurityService.java:247)
at oracle.bpm.services.pml.impl.SecurityService.getPrincipal(SecurityService.java:109)
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 org.springframework.aop.support.AopUtils.invokeJoinpointUsingReflection(AopUtils.java:307)
at org.springframework.aop.framework.ReflectiveMethodInvocation.invokeJoinpoint(ReflectiveMethodInvocation.java:182)
at org.springframework.aop.framework.ReflectiveMethodInvocation.proceed(ReflectiveMethodInvocation.java:149)
at oracle.bpel.services.workflow.common.WorkflowServiceCacheEventAdvice.invoke(WorkflowServiceCacheEventAdvice.java:91)
at org.springframework.aop.framework.ReflectiveMethodInvocation.proceed(ReflectiveMethodInvocation.java:171)
at org.springframework.aop.framework.JdkDynamicAopProxy.invoke(JdkDynamicAopProxy.java:204)
at $Proxy270.getPrincipal(Unknown Source)
at oracle.bpm.services.pml.ejb.SecurityServiceBean.getPrincipal(SecurityServiceBean.java:71)
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.bea.core.repackaged.springframework.aop.support.AopUtils.invokeJoinpointUsingReflection(AopUtils.java:310)
at com.bea.core.repackaged.springframework.aop.framework.ReflectiveMethodInvocation.invokeJoinpoint(ReflectiveMethodInvocation.java:182)
at com.bea.core.repackaged.springframework.aop.framework.ReflectiveMethodInvocation.proceed(ReflectiveMethodInvocation.java:149)
at com.bea.core.repackaged.springframework.aop.support.DelegatingIntroductionInterceptor.doProceed(DelegatingIntroductionInterceptor.java:131)
at com.bea.core.repackaged.springframework.aop.support.DelegatingIntroductionInterceptor.invoke(DelegatingIntroductionInterceptor.java:119)
at com.bea.core.repackaged.springframework.aop.framework.ReflectiveMethodInvocation.proceed(ReflectiveMethodInvocation.java:171)
at com.oracle.pitchfork.spi.MethodInvocationVisitorImpl.visit(MethodInvocationVisitorImpl.java:34)
at weblogic.ejb.container.injection.EnvironmentInterceptorCallbackImpl.callback(EnvironmentInterceptorCallbackImpl.java:54)
at com.oracle.pitchfork.spi.EnvironmentInterceptor.invoke(EnvironmentInterceptor.java:42)
at com.bea.core.repackaged.springframework.aop.framework.ReflectiveMethodInvocation.proceed(ReflectiveMethodInvocation.java:171)
at com.bea.core.repackaged.springframework.aop.interceptor.ExposeInvocationInterceptor.invoke(ExposeInvocationInterceptor.java:89)
at com.bea.core.repackaged.springframework.aop.framework.ReflectiveMethodInvocation.proceed(ReflectiveMethodInvocation.java:171)
at com.bea.core.repackaged.springframework.aop.support.DelegatingIntroductionInterceptor.doProceed(DelegatingIntroductionInterceptor.java:131)
at com.bea.core.repackaged.springframework.aop.support.DelegatingIntroductionInterceptor.invoke(DelegatingIntroductionInterceptor.java:119)
at com.bea.core.repackaged.springframework.aop.framework.ReflectiveMethodInvocation.proceed(ReflectiveMethodInvocation.java:171)
at com.bea.core.repackaged.springframework.aop.framework.JdkDynamicAopProxy.invoke(JdkDynamicAopProxy.java:204)
at $Proxy269.getPrincipal(Unknown Source)
at oracle.bpm.services.pml.ejb.SecurityServiceBean_z7zjfk_ISecurityServiceRemoteImpl.__WL_invoke(Unknown Source)
at weblogic.ejb.container.internal.SessionRemoteMethodInvoker.invoke(SessionRemoteMethodInvoker.java:40)
at oracle.bpm.services.pml.ejb.SecurityServiceBean_z7zjfk_ISecurityServiceRemoteImpl.getPrincipal(Unknown Source)
at oracle.bpm.services.pml.ejb.SecurityServiceBean_z7zjfk_ISecurityServiceRemoteImpl_WLSkel.invoke(Unknown Source)
at weblogic.rmi.internal.BasicServerRef.invoke(BasicServerRef.java:667)
at weblogic.rmi.cluster.ClusterableServerRef.invoke(ClusterableServerRef.java:230)
at weblogic.rmi.internal.BasicServerRef$1.run(BasicServerRef.java:522)
at weblogic.security.acl.internal.AuthenticatedSubject.doAs(AuthenticatedSubject.java:363)
at weblogic.security.service.SecurityManager.runAs(SecurityManager.java:146)
at weblogic.rmi.internal.BasicServerRef.handleRequest(BasicServerRef.java:518)
at weblogic.rmi.internal.wls.WLSExecuteRequest.run(WLSExecuteRequest.java:118)
at weblogic.work.ExecuteThread.execute(ExecuteThread.java:256)
at weblogic.work.ExecuteThread.run(ExecuteThread.java:221)
Caused By: java.lang.Exception: Null token
at oracle.bpel.services.workflow.verification.impl.VerificationService.validateContextToken(VerificationService.java:1769)
at oracle.bpel.services.workflow.verification.impl.VerificationService.validateContext(VerificationService.java:1662)
at oracle.bpel.services.workflow.verification.impl.VerificationService.validateContext(VerificationService.java:1969)
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 org.springframework.aop.support.AopUtils.invokeJoinpointUsingReflection(AopUtils.java:307)
at org.springframework.aop.framework.ReflectiveMethodInvocation.invokeJoinpoint(ReflectiveMethodInvocation.java:182)
at org.springframework.aop.framework.ReflectiveMethodInvocation.proceed(ReflectiveMethodInvocation.java:149)
at oracle.bpel.services.workflow.common.WorkflowServiceCacheEventAdvice.invoke(WorkflowServiceCacheEventAdvice.java:91)
at org.springframework.aop.framework.ReflectiveMethodInvocation.proceed(ReflectiveMethodInvocation.java:171)
at org.springframework.aop.framework.JdkDynamicAopProxy.invoke(JdkDynamicAopProxy.java:204)
at $Proxy243.validateContext(Unknown Source)
at oracle.bpm.services.pml.impl.SecurityService.validateContext(SecurityService.java:237)
at oracle.bpm.services.pml.impl.SecurityService.getSecurityService(SecurityService.java:247)
at oracle.bpm.services.pml.impl.SecurityService.getPrincipal(SecurityService.java:109)
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 org.springframework.aop.support.AopUtils.invokeJoinpointUsingReflection(AopUtils.java:307)
at org.springframework.aop.framework.ReflectiveMethodInvocation.invokeJoinpoint(ReflectiveMethodInvocation.java:182)
at org.springframework.aop.framework.ReflectiveMethodInvocation.proceed(ReflectiveMethodInvocation.java:149)
at oracle.bpel.services.workflow.common.WorkflowServiceCacheEventAdvice.invoke(WorkflowServiceCacheEventAdvice.java:91)
at org.springframework.aop.framework.ReflectiveMethodInvocation.proceed(ReflectiveMethodInvocation.java:171)
at org.springframework.aop.framework.JdkDynamicAopProxy.invoke(JdkDynamicAopProxy.java:204)
at $Proxy270.getPrincipal(Unknown Source)
at oracle.bpm.services.pml.ejb.SecurityServiceBean.getPrincipal(SecurityServiceBean.java:71)
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.bea.core.repackaged.springframework.aop.support.AopUtils.invokeJoinpointUsingReflection(AopUtils.java:310)
at com.bea.core.repackaged.springframework.aop.framework.ReflectiveMethodInvocation.invokeJoinpoint(ReflectiveMethodInvocation.java:182)
at com.bea.core.repackaged.springframework.aop.framework.ReflectiveMethodInvocation.proceed(ReflectiveMethodInvocation.java:149)
at com.bea.core.repackaged.springframework.aop.support.DelegatingIntroductionInterceptor.doProceed(DelegatingIntroductionInterceptor.java:131)
at com.bea.core.repackaged.springframework.aop.support.DelegatingIntroductionInterceptor.invoke(DelegatingIntroductionInterceptor.java:119)
at com.bea.core.repackaged.springframework.aop.framework.ReflectiveMethodInvocation.proceed(ReflectiveMethodInvocation.java:171)
at com.oracle.pitchfork.spi.MethodInvocationVisitorImpl.visit(MethodInvocationVisitorImpl.java:34)
at weblogic.ejb.container.injection.EnvironmentInterceptorCallbackImpl.callback(EnvironmentInterceptorCallbackImpl.java:54)
at com.oracle.pitchfork.spi.EnvironmentInterceptor.invoke(EnvironmentInterceptor.java:42)
at com.bea.core.repackaged.springframework.aop.framework.ReflectiveMethodInvocation.proceed(ReflectiveMethodInvocation.java:171)
at com.bea.core.repackaged.springframework.aop.interceptor.ExposeInvocationInterceptor.invoke(ExposeInvocationInterceptor.java:89)
at com.bea.core.repackaged.springframework.aop.framework.ReflectiveMethodInvocation.proceed(ReflectiveMethodInvocation.java:171)
at com.bea.core.repackaged.springframework.aop.support.DelegatingIntroductionInterceptor.doProceed(DelegatingIntroductionInterceptor.java:131)
at com.bea.core.repackaged.springframework.aop.support.DelegatingIntroductionInterceptor.invoke(DelegatingIntroductionInterceptor.java:119)
at com.bea.core.repackaged.springframework.aop.framework.ReflectiveMethodInvocation.proceed(ReflectiveMethodInvocation.java:171)
at com.bea.core.repackaged.springframework.aop.framework.JdkDynamicAopProxy.invoke(JdkDynamicAopProxy.java:204)
at $Proxy269.getPrincipal(Unknown Source)
at oracle.bpm.services.pml.ejb.SecurityServiceBean_z7zjfk_ISecurityServiceRemoteImpl.__WL_invoke(Unknown Source)
at weblogic.ejb.container.internal.SessionRemoteMethodInvoker.invoke(SessionRemoteMethodInvoker.java:40)
at oracle.bpm.services.pml.ejb.SecurityServiceBean_z7zjfk_ISecurityServiceRemoteImpl.getPrincipal(Unknown Source)
at oracle.bpm.services.pml.ejb.SecurityServiceBean_z7zjfk_ISecurityServiceRemoteImpl_WLSkel.invoke(Unknown Source)
at weblogic.rmi.internal.BasicServerRef.invoke(BasicServerRef.java:667)
at weblogic.rmi.cluster.ClusterableServerRef.invoke(ClusterableServerRef.java:230)
at weblogic.rmi.internal.BasicServerRef$1.run(BasicServerRef.java:522)
at weblogic.security.acl.internal.AuthenticatedSubject.doAs(AuthenticatedSubject.java:363)
at weblogic.security.service.SecurityManager.runAs(SecurityManager.java:146)
at weblogic.rmi.internal.BasicServerRef.handleRequest(BasicServerRef.java:518)
at weblogic.rmi.internal.wls.WLSExecuteRequest.run(WLSExecuteRequest.java:118)
at weblogic.work.ExecuteThread.execute(ExecuteThread.java:256)
at weblogic.work.ExecuteThread.run(ExecuteThread.java:221)
Could someone help me, I'm very difficult to find a solution for this problem!!

This has been resolved. I ended up generating my own web service proxy services for the TaskService, instead of using the one that was bundled with jDeveloper. So honestly speaking, because of time constraints, I did not get a chance to fix the exact root cause of this error. After generating this webservice proxy/stub, i bundled it as a shared webapp library and my Custom Worklist portlet refers to this library. This worked for me.
I used this WSDL to generate the proxy classes and then used the generated classes/methods to query tasks data.
http://soa_host:soa_port/integration/services/TaskQueryService/TaskQueryService?wsdl
Also, later taking the original case forward, I was also able to get around the token problem by using RMI/EBJ provider ( t3://: ) instead of SOAP binding (http://:).
Here's what my code looks like :
String serverUrl ="t3://soa_server:soa_port"; // host:Port of the soa server
Map<IWorkflowServiceClientConstants.CONNECTION_PROPERTY, String> connProperties = new HashMap<IWorkflowServiceClientConstants.CONNECTION_PROPERTY, String>();
connProperties.put(IWorkflowServiceClientConstants.CONNECTION_PROPERTY.CLIENT_TYPE,WorkflowServiceClientFactory.REMOTE_CLIENT);
connProperties.put(IWorkflowServiceClientConstants.CONNECTION_PROPERTY.EJB_PROVIDER_URL,serverUrl);
connProperties.put(IWorkflowServiceClientConstants.CONNECTION_PROPERTY.EJB_INITIAL_CONTEXT_FACTORY, "weblogic.jndi.WLInitialContextFactory");
IWorkflowServiceClient wfSvcClient = WorkflowServiceClientFactory.getWorkflowServiceClient(connProperties, null, null);
ITaskQueryService querySvc = wfSvcClient.getTaskQueryService();
IWorkflowContext adminCtx = wfSvcClient.getTaskQueryService().authenticate(adminID, adminPass.toCharArray(), "jazn.com" );
IWorkflowContext userCtx = querySvc.authenticateOnBehalfOf(adminCtx, userID);
List displayColumns = new ArrayList();
displayColumns.add("TASKNUMBER");
displayColumns.add("TITLE");
displayColumns.add("STATE");
displayColumns.add("CREATOR");
List optionalInfo = new ArrayList();
optionalInfo.add("Comments");
optionalInfo.add("Payload");
tasks=querySvc.queryTasks(userCtx, null, null, ITaskQueryService.AssignmentFilter.MY,null, null, null, 0, 0);
This returns list of tasks assigned to the user whose ID you send to authenticateOnBehalfOf() method call above.
I hope this helps.

Below solution from Oracle Support Documentation fixed the issue for me. In summary, it's a jar mismatch between server and jdev that caused the issue.
=========================================================================
You are unable to get the BPM context successfully. There will not be an exception while retrieving the context but when trying to use it you see the exception:
BPM-70684
Exception
exception.70684.type: error
exception.70684.severity: 2
exception.70684.name: Invalid authentication context.
exception.70684.description: Invalid authentication context has been passed.
exception.70684.fix: Ensure valid authentication context is passed.
The following exceptions have known to be associated with the same issue:
Caused by: java.lang.NullPointerException
at oracle.bpel.services.workflow.verification.impl.WorkflowContext.hashCode(WorkflowContext.java:583)
at java.util.HashMap.get(HashMap.java:300)
at oracle.bpel.services.workflow.common.ThreadLocalCache.isContextValidated(ThreadLocalCache.java:146)
at oracle.bpel.services.workflow.verification.impl.VerificationService.validateNotNullWorkflowContext(VerificationService.java:1824)
at oracle.bpel.services.workflow.verification.impl.VerificationService.validateContext(VerificationService.java:1806)
Error while authenticating on behalf of user weblogic using adminContext [user=null][sessionKey=null][token=null][requester=null][objectId=null]
<<.> Verification Service cannot resolve user identity.
User null cannot be found in the identity repository.
Workflow Context token cannot be null in request.
ORABPEL-30511
Verification Service cannot resolve user identity.
User null cannot be found in the identity repository.
Workflow Context token cannot be null in request.
at oracle.bpel.services.workflow.verification.impl.LocalCacheManager.lookupUser(LocalCacheManager.java:600)
Caused By: ORABPEL-10501
Illegal argument.
Illegal argument.
This is because an unexpected value, possibly null, was passed as an argument. Check the error stack and fix the cause of the error. Contact Oracle Support Services if error is not fixable.
at oracle.tip.pc.services.identity.jps.AuthorizationServiceImpl.lookupUser(AuthorizationServiceImpl.java:236)
at oracle.tip.pc.services.identity.jps.IdentityServiceImpl.lookupUser(IdentityServiceImpl.java:183)
at oracle.bpel.services.workflow.verification.impl.LocalCacheManager.lookupUser(LocalCacheManager.java:596)
We are embedding a BPM task Flow list in an ADF App. It gives the following error
infra] <.> Invalid Token Error in Verification Service.[[
Invalid Token Error in Verification Service. Received invalid token in null.
Verify that correct token is passed.
ORABPEL-30503
Also, If you log the username from the context you'll notice it is null.
Cause
The bpm-services.jar on the client application and the server may not match. The SOA/BPM related jars being used on the client and server must be the same or unexpected issues can occur.
Solution
Copy the bpm-services.jar from the server
Replace the bpm-services.jar on the client application with the one from the server
Ensure that after any patches are applied that the jars on the server are replaced in the client application.
This also applies to using jars within JDeveloper which can become out of sync due to patches not being applied on both dev and server machines. You may need to replace the bpm-services.jar located here JDeveloper/soa/modules/oracle.soa.workflow_11.1.1/bpm-services.jar with the one located here [soa_install_dir]/soa/modules/oracle.soa.workflow_11.1.1/bpm-services.jar.

Related

Unable to Validate Json Schema in rest assured

I am using rest assured and validating JSON schema using it. I generated the schema using jsonschema.net(draft 7) and saved the generated schema in the file and matched the generated schema against the response of GET API.
But the code throwing the error with output like:
Actual: {"success":true,"message":"FacilityAttributes List","error":{},"result":[{"id":"aa2cdb2e-89cd-4970-a976-42df3349df74","name":"INTERNATIONAL","rank":null,"data_type":"BOOLEAN","default_value":"false","mandatory":false,"business_unit":"TRA","options":null,"facility_type":null,"group_name":"BusinessType","description":"Please check if facility is international!"},{"id":"144e7c1c-9df4-4c65-ae7e-685013566731","name":"HEAVY","rank":null,"data_type":"BOOLEAN","default_value":"false","mandatory":false,"business_unit":"TRA","options":null,"facility_type":null,"group_name":"BusinessType","description":"Please check if facility can handle heavy goods!"},{"id":"ca20c185-4c9a-425e-82e4-a5b244b5ef9d","name":"B2B","rank":5,"data_type":"BOOLEAN","default_value":"false","mandatory":false,"business_unit":"TRA","options":null,"facility_type":null,"group_name":"BusinessType","description":null},{"id":"12a2c7f3-7da7-4682-953c-2e06ab8c8335","name":"B2C","rank":4,"data_type":"BOOLEAN","default_value":"false","mandatory":false,"business_unit":"TRA","options":null,"facility_type":null,"group_name":"BusinessType","description":null},{"id":"34ef64ee-33dc-43ea-9ef0-722aeb2377f8","name":"HLD","rank":2,"data_type":"BOOLEAN","default_value":"false","mandatory":false,"business_unit":"TRA","options":null,"facility_type":null,"group_name":"BusinessType","description":null},{"id":"5147ec36-59ac-4843-9f46-a881548e33aa","name":"dock_count","rank":null,"data_type":"INTEGER","default_value":"0","mandatory":false,"business_unit":"TRA","options":null,"facility_type":null,"group_name":"Facility Attributes","description":"Dock Door count in Facility!"},{"id":"1bdd7e0f-3a47-4d57-b641-439ba8790e48","name":"capacity","rank":null,"data_type":"INTEGER","default_value":"0","mandatory":false,"business_unit":"TRA","options":null,"facility_type":null,"group_name":"Facility Attributes","description":"Facility Capacity!"},{"id":"16e81b0c-fe3b-4827-bcf0-dbfd6f2cc386","name":"dimention_unit","rank":null,"data_type":"OPTION","default_value":"CM","mandatory":false,"business_unit":"TRA","options":["CM","IN"],"facility_type":null,"group_name":"Facility Attributes","description":"Dimention unit on facility works!"},{"id":"75569bc1-f5f0-40c1-8e36-f3ef88940486","name":"weight_unit","rank":null,"data_type":"OPTION","default_value":"KG","mandatory":false,"business_unit":"TRA","options":["KG","GM","LB"],"facility_type":null,"group_name":"Facility Attributes","description":"Weight unit on facility works!"},{"id":"48b121ba-e142-4f10-955c-12be4c33f787","name":"sort_code","rank":null,"data_type":"TEXT","default_value":null,"mandatory":false,"business_unit":"TRA","options":null,"facility_type":null,"group_name":"Facility Attributes","description":"Facility sort code!"},{"id":"dc5cc52c-2f65-4b92-beaa-d8165dfdc157","name":"slab_rate","rank":null,"data_type":"FLOAT","default_value":"0","mandatory":false,"business_unit":"TRA","options":null,"facility_type":null,"group_name":"Facility Attributes","description":"Slab rate of facility"},{"id":"d6b3ac6d-5f97-46a5-8e71-72b96f2aa419","name":"slab_type","rank":null,"data_type":"OPTION","default_value":"Incentive Based","mandatory":false,"business_unit":"TRA","options":["Incentive Based","Fuel Based"],"facility_type":null,"group_name":"Facility Attributes","description":"Slab rate of facility"},{"id":"03654f31-150f-4420-837c-f22bda1bc476","name":"ProductivityBenchmark","rank":null,"data_type":"INTEGER","default_value":"0","mandatory":false,"business_unit":"TRA","options":null,"facility_type":null,"group_name":"Productivity","description":"Productivity Benchmark of facility!"},{"id":"ad471316-0858-4ed7-b817-7b554c780536","name":"ReverseDispatchCutoff","rank":null,"data_type":"TIME","default_value":"09:00","mandatory":false,"business_unit":"TRA","options":null,"facility_type":null,"group_name":"Facility Timings","description":"Reverse Dispatch Cutoff time"},{"id":"18041d87-a88d-4ed3-b457-9c6e96c2c250","name":"ForwardDispatchCutoff","rank":null,"data_type":"TIME","default_value":"12:00","mandatory":false,"business_unit":"TRA","options":null,"facility_type":null,"group_name":"Facility Timings","description":"Forward Dispatch Cutoff time"},{"id":"c3e677a7-5b21-4c6b-8384-27c936720177","name":"Implant_enabled","rank":13,"data_type":"BOOLEAN","default_value":"false","mandatory":false,"business_unit":"TRA","options":null,"facility_type":null,"group_name":"Flags","description":"Please check Implant is enabled in Facility!"},{"id":"0fcd0fbe-c448-455a-b825-8b1eb2fcc8b3","name":"DG_enabled","rank":12,"data_type":"BOOLEAN","default_value":"false","mandatory":false,"business_unit":"TRA","options":null,"facility_type":null,"group_name":"Flags","description":"Please check DG is enabled in Facility!"},{"id":"34067f20-ece0-4775-8596-4447f74c5084","name":"FMODx_enabled","rank":11,"data_type":"BOOLEAN","default_value":"false","mandatory":false,"business_unit":"TRA","options":null,"facility_type":null,"group_name":"Flags","description":"Please check Odx FM is enabled in Facility!"},{"id":"6237f744-e685-4aca-906a-48bd1bad9160","name":"FEApp_enabled","rank":9,"data_type":"BOOLEAN","default_value":"false","mandatory":false,"business_unit":"TRA","options":null,"facility_type":null,"group_name":"Flags","description":"Please check FE App is enabled in Facility!"},{"id":"5ceb5fd0-74db-46fc-97a1-afbbaabc3686","name":"PayTM_enabled","rank":8,"data_type":"BOOLEAN","default_value":"false","mandatory":false,"business_unit":"TRA","options":null,"facility_type":null,"group_name":"Flags","description":"Please check if PayTM is enabled in facility!"},{"id":"f69817cb-8662-4f38-b44b-fb875703e9cd","name":"CardOnDelivery_enabled","rank":7,"data_type":"BOOLEAN","default_value":"false","mandatory":false,"business_unit":"TRA","options":null,"facility_type":null,"group_name":"Flags","description":"Please check if Card On Delivery is enabled in facility!"},{"id":"a3bcf54b-d734-4f95-92fd-a15bb2a00be3","name":"BagGuide_enabled","rank":6,"data_type":"BOOLEAN","default_value":"false","mandatory":false,"business_unit":"TRA","options":null,"facility_type":null,"group_name":"Flags","description":"Please check if BagGuide is enabled in facility!"},{"id":"19cfc5d1-f5fb-4666-a13f-7519588e3bb2","name":"LMOdx_enabled","rank":5,"data_type":"BOOLEAN","default_value":"false","mandatory":false,"business_unit":"TRA","options":null,"facility_type":null,"group_name":"Flags","description":"Please check if LMOdx is enabled in facility!"},{"id":"dc99d927-5925-4b09-a686-9c0231259337","name":"Constellation_enabled","rank":4,"data_type":"BOOLEAN","default_value":"false","mandatory":false,"business_unit":"TRA","options":null,"facility_type":null,"group_name":"Flags","description":"Please check if Constellation is enabled in facility!"},{"id":"41ba47fe-ec23-4649-bf0b-51101e631e68","name":"Bagging_enabled","rank":3,"data_type":"BOOLEAN","default_value":"false","mandatory":false,"business_unit":"TRA","options":null,"facility_type":null,"group_name":"Flags","description":"Please check if Bagging is enabled in facility!"},{"id":"7ead8afd-2e98-4330-8e15-40d4cb944a3c","name":"MidMile_enabled","rank":2,"data_type":"BOOLEAN","default_value":"false","mandatory":false,"business_unit":"TRA","options":null,"facility_type":null,"group_name":"Flags","description":"Please check if MidMile is enabled in facility!"},{"id":"4b9ffcab-b5df-4f19-bbd9-52e208168039","name":"Sorter_enabled","rank":1,"data_type":"BOOLEAN","default_value":"false","mandatory":false,"business_unit":"TRA","options":null,"facility_type":null,"group_name":"Flags","description":"Please check if sorter is enabled in facility!"},{"id":"c81e981d-2c44-4bd7-9cc9-5ea20a3eaa3a","name":"Can_Handle_Palletised_Load","rank":null,"data_type":"BOOLEAN","default_value":"false","mandatory":false,"business_unit":"TRA","options":null,"facility_type":null,"group_name":"Flags","description":"Check if facility Can Handle Palletised Load"}]}
at sun.reflect.NativeConstructorAccessorImpl.newInstance0(Native Method)
at sun.reflect.NativeConstructorAccessorImpl.newInstance(NativeConstructorAccessorImpl.java:62)
at sun.reflect.DelegatingConstructorAccessorImpl.newInstance(DelegatingConstructorAccessorImpl.java:45)
at java.lang.reflect.Constructor.newInstance(Constructor.java:423)
at org.codehaus.groovy.reflection.CachedConstructor.invoke(CachedConstructor.java:83)
at org.codehaus.groovy.reflection.CachedConstructor.doConstructorInvoke(CachedConstructor.java:77)
at org.codehaus.groovy.runtime.callsite.ConstructorSite$ConstructorSiteNoUnwrap.callConstructor(ConstructorSite.java:84)
at org.codehaus.groovy.runtime.callsite.CallSiteArray.defaultCallConstructor(CallSiteArray.java:60)
at org.codehaus.groovy.runtime.callsite.AbstractCallSite.callConstructor(AbstractCallSite.java:235)
at org.codehaus.groovy.runtime.callsite.AbstractCallSite.callConstructor(AbstractCallSite.java:247)
at io.restassured.internal.ResponseSpecificationImpl$HamcrestAssertionClosure.validate(ResponseSpecificationImpl.groovy:471)
at io.restassured.internal.ResponseSpecificationImpl$HamcrestAssertionClosure$validate$1.call(Unknown Source)
at org.codehaus.groovy.runtime.callsite.CallSiteArray.defaultCall(CallSiteArray.java:48)
at org.codehaus.groovy.runtime.callsite.AbstractCallSite.call(AbstractCallSite.java:113)
at org.codehaus.groovy.runtime.callsite.AbstractCallSite.call(AbstractCallSite.java:125)
at io.restassured.internal.ResponseSpecificationImpl.validateResponseIfRequired(ResponseSpecificationImpl.groovy:643)
at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method)
at sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:62)
at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:43)
at java.lang.reflect.Method.invoke(Method.java:498)
at org.codehaus.groovy.runtime.callsite.PogoMetaMethodSite$PogoCachedMethodSiteNoUnwrapNoCoerce.invoke(PogoMetaMethodSite.java:210)
at org.codehaus.groovy.runtime.callsite.PogoMetaMethodSite.callCurrent(PogoMetaMethodSite.java:59)
at org.codehaus.groovy.runtime.callsite.CallSiteArray.defaultCallCurrent(CallSiteArray.java:52)
at org.codehaus.groovy.runtime.callsite.AbstractCallSite.callCurrent(AbstractCallSite.java:154)
at org.codehaus.groovy.runtime.callsite.AbstractCallSite.callCurrent(AbstractCallSite.java:166)
at io.restassured.internal.ResponseSpecificationImpl.content(ResponseSpecificationImpl.groovy:94)
at io.restassured.specification.ResponseSpecification$content$0.callCurrent(Unknown Source)
at org.codehaus.groovy.runtime.callsite.CallSiteArray.defaultCallCurrent(CallSiteArray.java:52)
at org.codehaus.groovy.runtime.callsite.AbstractCallSite.callCurrent(AbstractCallSite.java:154)
at org.codehaus.groovy.runtime.callsite.AbstractCallSite.callCurrent(AbstractCallSite.java:174)
at io.restassured.internal.ResponseSpecificationImpl.body(ResponseSpecificationImpl.groovy:244)
at io.restassured.internal.ValidatableResponseOptionsImpl.body(ValidatableResponseOptionsImpl.java:262)
at com.ums.api.AppTest.GetserData(AppTest.java:46)
at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method)
at sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:62)
at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:43)
at java.lang.reflect.Method.invoke(Method.java:498)
at org.testng.internal.MethodInvocationHelper.invokeMethod(MethodInvocationHelper.java:108)
at org.testng.internal.Invoker.invokeMethod(Invoker.java:669)
at org.testng.internal.Invoker.invokeTestMethod(Invoker.java:877)
at org.testng.internal.Invoker.invokeTestMethods(Invoker.java:1201)
at org.testng.internal.TestMethodWorker.invokeTestMethods(TestMethodWorker.java:125)
at org.testng.internal.TestMethodWorker.run(TestMethodWorker.java:109)
at org.testng.TestRunner.privateRun(TestRunner.java:776)
at org.testng.TestRunner.run(TestRunner.java:634)
at org.testng.SuiteRunner.runTest(SuiteRunner.java:425)
at org.testng.SuiteRunner.runSequentially(SuiteRunner.java:420)
at org.testng.SuiteRunner.privateRun(SuiteRunner.java:385)
at org.testng.SuiteRunner.run(SuiteRunner.java:334)
at org.testng.SuiteRunnerWorker.runSuite(SuiteRunnerWorker.java:52)
at org.testng.SuiteRunnerWorker.run(SuiteRunnerWorker.java:86)
at org.testng.TestNG.runSuitesSequentially(TestNG.java:1318)
at org.testng.TestNG.runSuitesLocally(TestNG.java:1243)
at org.testng.TestNG.runSuites(TestNG.java:1161)
at org.testng.TestNG.run(TestNG.java:1129)
at org.testng.remote.AbstractRemoteTestNG.run(AbstractRemoteTestNG.java:114)
at org.testng.remote.RemoteTestNG.initAndRun(RemoteTestNG.java:251)
at org.testng.remote.RemoteTestNG.main(RemoteTestNG.java:77)
my genereated schema is schema link
Repsonse of the api API repsonse
Maybe the current REST Assured library work until draft 4. I'm using json-schema-generator tool to generate json schema in draft 4 and able to validate the response.
Commands to install and generate schema: -
npm install -g json-schema-generator
json-schema-generator path/to/input_response.json -o path/to/json_schema.json
Reference links:
https://github.com/krg7880/json-schema-generator

#Preauthorize in GWT

I'm writting my application using GWT. There're two roles (ROLE_USER and ROLE_ADMIN) in my app. ROLE_ADMIN has access to some handler
#Service
#PreAuthorize("hasAnyRole('ROLE_ADMIN')")
public class GetAuditDataListHandler extends AbstractActionHandler<GetAuditDataListAction, GetAuditDataListResult> {
// Code here
}
When I try to access under ROLE_USER I want to show dialogbox ("Access denied!"). But it returns 500 The call failed on the server; see server log for details
com.google.gwt.user.client.rpc.impl.RequestCallbackAdapter.onResponseReceived(RequestCallbackAdapter.java:209)
com.test.web.main.api.client.AuthRemoteServiceProxy$1.onResponseReceived(AuthRemoteServiceProxy.java:74)
com.google.gwt.http.client.Request.fireOnResponseReceived(Request.java:258)
com.google.gwt.http.client.RequestBuilder$1.onReadyStateChange(RequestBuilder.java:412)
sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method)
sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:57)
sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:43)
java.lang.reflect.Method.invoke(Method.java:606)
com.google.gwt.dev.shell.MethodAdaptor.invoke(MethodAdaptor.java:103)
com.google.gwt.dev.shell.MethodDispatch.invoke(MethodDispatch.java:71)
com.google.gwt.dev.shell.OophmSessionHandler.invoke(OophmSessionHandler.java:172)
com.google.gwt.dev.shell.BrowserChannelServer.reactToMessagesWhileWaitingForReturn(BrowserChannelServer.java:338)
com.google.gwt.dev.shell.BrowserChannelServer.invokeJavascript(BrowserChannelServer.java:219)
com.google.gwt.dev.shell.ModuleSpaceOOPHM.doInvoke(ModuleSpaceOOPHM.java:136)
com.google.gwt.dev.shell.ModuleSpace.invokeNative(ModuleSpace.java:571)
com.google.gwt.dev.shell.ModuleSpace.invokeNativeObject(ModuleSpace.java:279)
com.google.gwt.dev.shell.JavaScriptHost.invokeNativeObject(JavaScriptHost.java:91)
com.google.gwt.core.client.impl.Impl.apply(Impl.java)
com.google.gwt.core.client.impl.Impl.entry0(Impl.java:242)
sun.reflect.GeneratedMethodAccessor53.invoke(Unknown Source)
sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:43)
java.lang.reflect.Method.invoke(Method.java:606)
com.google.gwt.dev.shell.MethodAdaptor.invoke(MethodAdaptor.java:103)
com.google.gwt.dev.shell.MethodDispatch.invoke(MethodDispatch.java:71)
com.google.gwt.dev.shell.OophmSessionHandler.invoke(OophmSessionHandler.java:172)
com.google.gwt.dev.shell.BrowserChannelServer.reactToMessages(BrowserChannelServer.java:293)
com.google.gwt.dev.shell.BrowserChannelServer.processConnection(BrowserChannelServer.java:547)
com.google.gwt.dev.shell.BrowserChannelServer.run(BrowserChannelServer.java:364)
java.lang.Thread.run(Thread.java:744)
Spring will be checking the security roles and throwing an exception before executing the handler.
You would normally be able to catch this exception in the client onFailure() method of the Request but the exception thrown may not be serialisable or most likely not available to the GWT client side code and cannot be serialised - leading to the error.
It looks like you are using the gwt-dispatch library? I haven't used this for some time but you can override the SpringSecureDispatchServlet and add your own implementation of the doUnexpectedFailure(Throwable e) method. In there you could check the exception to see if it is a Spring security exception and instead of calling RPCServletUtils.writeResponseForUnexpectedFailure(...) that returns a status code of 500 implement your own that returns a more suitable error code (401, or 403).
Couldn't you add a Servlet Filter to catch this particular exception and turn it into the HTTP response you would like?

Security:090759 in weblogic managed logs

i am getting following error in weblogic managed log files and not able to trace source of client IP or URL. It is look like some SQL injection are happening on servers so please provide detail to prevent it and get more detail about it.
<[ACTIVE] ExecuteThread: '14' for queue: 'weblogic.kernel.Default (self-tuning)'> <<WLS Kernel>> <> <> <1355487016719> <BEA-000000> <[Security:090759]A SQLException occurred while retrieving password information
java.sql.SQLException: [Security:090798]Invalid characters found in input #^Y#.#o*.2,./2|pq{jvk#-1('#lvo)&1,.1(.1.+(#./*
at weblogic.security.providers.authentication.shared.DBMSUtils.verifyInputCharactersName(DBMSUtils.java:338)
at weblogic.security.providers.authentication.shared.DBMSSQLRuntimeQueryImpl.executeUserPassword(DBMSSQLRuntimeQueryImpl.java:71)
at weblogic.security.providers.authentication.shared.DBMSAtnLoginModuleImpl.authenticateDBMS(DBMSAtnLoginModuleImpl.java:672)
at weblogic.security.providers.authentication.shared.DBMSAtnLoginModuleImpl.login(DBMSAtnLoginModuleImpl.java:271)
at com.bea.common.security.internal.service.LoginModuleWrapper$1.run(LoginModuleWrapper.java:110)
at com.bea.common.security.internal.service.LoginModuleWrapper.login(LoginModuleWrapper.java:106)
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 javax.security.auth.login.LoginContext.invoke(LoginContext.java:769)
at javax.security.auth.login.LoginContext.access$000(LoginContext.java:186)
at javax.security.auth.login.LoginContext$4.run(LoginContext.java:683)
at javax.security.auth.login.LoginContext.invokePriv(LoginContext.java:680)
at javax.security.auth.login.LoginContext.login(LoginContext.java:579)
at com.bea.common.security.internal.service.JAASLoginServiceImpl.login(JAASLoginServiceImpl.java:113)
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.bea.common.security.internal.utils.Delegator$ProxyInvocationHandler.invoke(Delegator.java:57)
at $Proxy17.login(Unknown Source)
at weblogic.security.service.internal.WLSJAASLoginServiceImpl$ServiceImpl.login(Unknown Source)
at com.bea.common.security.internal.service.JAASAuthenticationServiceImpl.authenticate(JAASAuthenticationServiceImpl.java:82)
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.bea.common.security.internal.utils.Delegator$ProxyInvocationHandler.invoke(Delegator.java:57)
at $Proxy37.authenticate(Unknown Source)
at weblogic.security.service.WLSJAASAuthenticationServiceWrapper.authenticate(Unknown Source)
at weblogic.security.service.PrincipalAuthenticator.authenticate(Unknown Source)
at weblogic.servlet.security.internal.SecurityModule.checkAuthenticate(SecurityModule.java:236)
at weblogic.servlet.security.internal.SecurityModule.checkAuthenticate(SecurityModule.java:185)
at weblogic.servlet.security.internal.BasicSecurityModule.checkUserPerm(BasicSecurityModule.java:75)
at weblogic.servlet.security.internal.SecurityModule.checkAccess(SecurityModule.java:106)
at weblogic.servlet.security.internal.ServletSecurityManager.checkAccess(ServletSecurityManager.java:82)
at weblogic.servlet.internal.WebAppServletContext.securedExecute(WebAppServletContext.java:2122)
at weblogic.servlet.security.internal.AuthFilterChain$LastFilter.doFilter(AuthFilterChain.java:45)
at weblogic.servlet.security.internal.AuthFilterChain.doFilter(AuthFilterChain.java:37)
at com.bea.common.security.internal.service.SAMLSingleSignOnServiceImpl.callChain(SAMLSingleSignOnServiceImpl.java:416)
at com.bea.common.security.internal.service.SAMLSingleSignOnServiceImpl.doRedirectFilter(SAMLSingleSignOnServiceImpl.java:407)
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.bea.common.security.internal.utils.Delegator$ProxyInvocationHandler.invoke(Delegator.java:57)
at $Proxy22.doRedirectFilter(Unknown Source)
at weblogic.security.providers.saml.SAMLServletAuthenticationFilter.doFilter(SAMLServletAuthenticationFilter.java:101)
at weblogic.servlet.security.internal.AuthFilterChain.doFilter(AuthFilterChain.java:37)
at weblogic.servlet.security.internal.SecurityModule$ServletAuthenticationFilterAction.run(SecurityModule.java:612)
at weblogic.security.acl.internal.AuthenticatedSubject.doAs(AuthenticatedSubject.java:321)
at weblogic.security.service.SecurityManager.runAs(Unknown Source)
at weblogic.servlet.security.internal.SecurityModule.invokeAuthFilterChain(SecurityModule.java:501)
at weblogic.servlet.security.internal.BasicSecurityModule.handleFailure(BasicSecurityModule.java:114)
at weblogic.servlet.security.internal.BasicSecurityModule.checkUserPerm(BasicSecurityModule.java:80)
at weblogic.servlet.security.internal.SecurityModule.checkAccess(SecurityModule.java:106)
at weblogic.servlet.security.internal.ServletSecurityManager.checkAccess(ServletSecurityManager.java:82)
at weblogic.servlet.internal.WebAppServletContext.securedExecute(WebAppServletContext.java:2122)
at weblogic.servlet.internal.WebAppServletContext.execute(WebAppServletContext.java:2092)
at weblogic.servlet.internal.ServletRequestImpl.run(ServletRequestImpl.java:1406)
at weblogic.work.ExecuteThread.execute(ExecuteThread.java:201)
at weblogic.work.ExecuteThread.run(ExecuteThread.java:173)
This is weblogic validating the userid input as part of their login implementation. I believe Oracle's OID does not allow an apostrophe in userids. Perhaps someone was simply testing your site with classic keyboard smashing and just happened to smash the keys in such a way that an apostrophe was entered for the userID.
It appears Weblogic is checking if the user input entered contains 'invalid' characters that would imply a sql injection attack with the userID. But is my understanding that they are using PreparedStatements which makes validating the input for characters a bit odd. It is likely just a constraint on what makes a valid userID in their backend LDAP.
In your case the user entered the following:
#^Y#.#o*.2,./2|pq{jvk#-1('#lvo)&1,.1(.1.+(#./*
Most of this answer is based on this forum discussion.
I did check metalink.oracle.com but did not find the SR listed in the forum.

jaxb implementation not working for windows 7

I am creating java classes from xsd using jaxb, but when i try to send xml over http i get a run time error
java.lang.annotation.AnnotationTypeMismatchException: Incorrectly typed data found for annotation element public abstract javax.xml.bind.annotation.AccessType javax.xml.bind.annotation.XmlAccessorType.value() (Found data of type Ljavax/xml/bind/annotation/XmlAccessType;.FIELD)
sun.reflect.annotation.AnnotationTypeMismatchExceptionProxy.generateException(AnnotationTypeMismatchExceptionProxy.java:38)
sun.reflect.annotation.AnnotationInvocationHandler.invoke(AnnotationInvocationHandler.java:56)
$Proxy6.value(Unknown Source)
sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method)
sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:39)
sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:25)
java.lang.reflect.Method.invoke(Method.java:597)
com.sun.xml.bind.v2.model.annotation.LocatableAnnotation.invoke(LocatableAnnotation.java:60)
$Proxy8.value(Unknown Source)
com.sun.xml.bind.v2.model.impl.ClassInfoImpl.getAccessType(ClassInfoImpl.java:339)
com.sun.xml.bind.v2.model.impl.ClassInfoImpl.getProperties(ClassInfoImpl.java:228)
com.sun.xml.bind.v2.model.impl.RuntimeClassInfoImpl.getProperties(RuntimeClassInfoImpl.java:87)
com.sun.xml.bind.v2.model.impl.ModelBuilder.getClassInfo(ModelBuilder.java:127)
com.sun.xml.bind.v2.model.impl.RuntimeModelBuilder.getClassInfo(RuntimeModelBuilder.java:49)
com.sun.xml.bind.v2.model.impl.RuntimeModelBuilder.getClassInfo(RuntimeModelBuilder.java:41)
com.sun.xml.bind.v2.model.impl.ModelBuilder.getTypeInfo(ModelBuilder.java:189)
com.sun.xml.bind.v2.model.impl.RegistryInfoImpl.<init>(RegistryInfoImpl.java:51)
com.sun.xml.bind.v2.model.impl.ModelBuilder.addRegistry(ModelBuilder.java:232)
com.sun.xml.bind.v2.model.impl.ModelBuilder.getTypeInfo(ModelBuilder.java:201)
com.sun.xml.bind.v2.runtime.JAXBContextImpl.getTypeInfoSet(JAXBContextImpl.java:327)
com.sun.xml.bind.v2.runtime.JAXBContextImpl.<init>(JAXBContextImpl.java:198)
com.sun.xml.bind.v2.ContextFactory.createContext(ContextFactory.java:76)
com.sun.xml.bind.v2.ContextFactory.createContext(ContextFactory.java:55)
com.sun.xml.bind.v2.ContextFactory.createContext(ContextFactory.java:124)
sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method)
sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:39)
sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:25)
java.lang.reflect.Method.invoke(Method.java:597)
javax.xml.bind.ContextFinder.newInstance(ContextFinder.java:132)
javax.xml.bind.ContextFinder.find(ContextFinder.java:286)
javax.xml.bind.JAXBContext.newInstance(JAXBContext.java:358)
javax.xml.bind.JAXBContext.newInstance(JAXBContext.java:323)
javax.xml.bind.JAXBContext.newInstance(JAXBContext.java:244)
com.arcot.jaxb.KECHPSWI.KECHPSWI.marshal(KECHPSWI.java:117)
com.arcot.jaxb.servlet.ClientMachine.doPost(ClientMachine.java:39)
com.arcot.jaxb.servlet.ClientMachine.doGet(ClientMachine.java:84)
javax.servlet.http.HttpServlet.service(HttpServlet.java:617)
javax.servlet.http.HttpServlet.service(HttpServlet.java:717)
my development environment is Tomcat 6.0, jdk 1.6 on windows 7, can someone please help me resolve this problem?
Looks like you have two different version of class javax.xml.bind.annotation.AccessType.
May be you have duplicate jax-api.jar in your classpath.

Gwtp NullpointerException- annotation

I am trying to implement a mobileweb app using Gwtp. I have the desktop and tablet view working but i get an error for mobile view. I am binding 3 different presenters for desktop, mobile and tablet view. So it will be a different landing page on different devices. I need different landing page functionality on different devices. The first presenter on a tablet will be a list of tasks, but on a mobile the user has to login first to see the list of tasks. Also, some of the presenters will be shared by a tablet and mobile view.
MobileModule-
bindConstant().annotatedWith(DefaultPlace.class).to(NameTokens.login);
bindPresenter(LoginPresenter.class, LoginPresenter.MyView.class,
LoginView.class, LoginPresenter.MyProxy.class);
bindPresenter(MainListTabletPresenter.class,
MainListTabletPresenter.MyView.class, MainListMobileView.class,
MainListTabletPresenter.MyProxy.class);
TabletModule-
bindConstant().annotatedWith(DefaultPlace.class).to(NameTokens.mainList);
bindPresenter(MainListTabletPresenter.class,
MainListTabletPresenter.MyView.class, MainListTabletView.class,
MainListTabletPresenter.MyProxy.class);
bindPresenter(LoginPresenter.class, LoginPresenter.MyView.class,
LoginView.class, LoginPresenter.MyProxy.class);
Any ideas why i would get the following (NullpointerException about annotations), when i run the application? I think i have the annotations correct for the LoginPresenter.
(MainPageEntryPoint.java:83) 2012-08-27 18:43:54,360 [ERROR] e: com.google.gwt.event.shared.UmbrellaException: One or more exceptions caught, see full set in UmbrellaException#getCauses
com.google.gwt.event.shared.UmbrellaException: One or more exceptions caught, see full set in UmbrellaException#getCauses
at com.google.gwt.event.shared.HandlerManager.fireEvent(HandlerManager.java:129)
at com.google.gwt.user.client.impl.HistoryImpl.fireEvent(HistoryImpl.java:75)
at com.google.gwt.event.logical.shared.ValueChangeEvent.fire(ValueChangeEvent.java:43)
at com.google.gwt.user.client.impl.HistoryImpl.fireHistoryChangedImpl(HistoryImpl.java:82)
at com.google.gwt.user.client.History.fireCurrentHistoryState(History.java:121)
at com.gwtplatform.mvp.client.proxy.PlaceManagerImpl.revealCurrentPlace(PlaceManagerImpl.java:310)
at com.happs.curveapp.client.MainPageEntryPoint.revealCurrentPlace(MainPageEntryPoint.java:114)
at com.happs.curveapp.client.MainPageEntryPoint.onModuleLoad2(MainPageEntryPoint.java:68)
at com.happs.curveapp.client.MainPageEntryPoint$1.execute(MainPageEntryPoint.java:40)
at com.google.gwt.core.client.impl.SchedulerImpl$Task$.executeScheduled$(SchedulerImpl.java:50)
at com.google.gwt.core.client.impl.SchedulerImpl.runScheduledTasks(SchedulerImpl.java:228)
at com.google.gwt.core.client.impl.SchedulerImpl.flushPostEventPumpCommands(SchedulerImpl.java:388)
at com.google.gwt.core.client.impl.SchedulerImpl$Flusher.execute(SchedulerImpl.java:78)
at com.google.gwt.core.client.impl.SchedulerImpl.execute(SchedulerImpl.java:138)
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.google.gwt.dev.shell.MethodAdaptor.invoke(MethodAdaptor.java:103)
at com.google.gwt.dev.shell.MethodDispatch.invoke(MethodDispatch.java:71)
at com.google.gwt.dev.shell.OophmSessionHandler.invoke(OophmSessionHandler.java:172)
at com.google.gwt.dev.shell.BrowserChannelServer.reactToMessagesWhileWaitingForReturn(BrowserChannelServer.java:337)
at com.google.gwt.dev.shell.BrowserChannelServer.invokeJavascript(BrowserChannelServer.java:218)
at com.google.gwt.dev.shell.ModuleSpaceOOPHM.doInvoke(ModuleSpaceOOPHM.java:136)
at com.google.gwt.dev.shell.ModuleSpace.invokeNative(ModuleSpace.java:561)
at com.google.gwt.dev.shell.ModuleSpace.invokeNativeObject(ModuleSpace.java:269)
at com.google.gwt.dev.shell.JavaScriptHost.invokeNativeObject(JavaScriptHost.java:91)
at com.google.gwt.core.client.impl.Impl.apply(Impl.java)
at com.google.gwt.core.client.impl.Impl.entry0(Impl.java:213)
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.google.gwt.dev.shell.MethodAdaptor.invoke(MethodAdaptor.java:103)
at com.google.gwt.dev.shell.MethodDispatch.invoke(MethodDispatch.java:71)
at com.google.gwt.dev.shell.OophmSessionHandler.invoke(OophmSessionHandler.java:172)
at com.google.gwt.dev.shell.BrowserChannelServer.reactToMessages(BrowserChannelServer.java:292)
at com.google.gwt.dev.shell.BrowserChannelServer.processConnection(BrowserChannelServer.java:546)
at com.google.gwt.dev.shell.BrowserChannelServer.run(BrowserChannelServer.java:363)
at java.lang.Thread.run(Thread.java:619)
Caused by: com.google.web.bindery.event.shared.UmbrellaException: One or more exceptions caught, see full set in UmbrellaException#getCauses
at com.google.web.bindery.event.shared.SimpleEventBus.doFire(SimpleEventBus.java:203)
at com.google.web.bindery.event.shared.SimpleEventBus.fireEventFromSource(SimpleEventBus.java:96)
at com.gwtplatform.mvp.client.proxy.PlaceManagerImpl.fireEvent(PlaceManagerImpl.java:146)
at com.gwtplatform.mvp.client.proxy.PlaceManagerImpl.doRevealPlace(PlaceManagerImpl.java:121)
at com.gwtplatform.mvp.client.proxy.PlaceManagerImpl.revealPlace(PlaceManagerImpl.java:339)
at com.happs.curveapp.client.place.ClientPlaceManager.revealDefaultPlace(ClientPlaceManager.java:27)
at com.gwtplatform.mvp.client.proxy.PlaceManagerImpl.onValueChange(PlaceManagerImpl.java:264)
at com.google.gwt.event.logical.shared.ValueChangeEvent.dispatch(ValueChangeEvent.java:128)
at com.google.gwt.event.logical.shared.ValueChangeEvent.dispatch(ValueChangeEvent.java:1)
at com.google.gwt.event.shared.GwtEvent.dispatch(GwtEvent.java:1)
at com.google.web.bindery.event.shared.EventBus.dispatchEvent(EventBus.java:40)
at com.google.web.bindery.event.shared.SimpleEventBus.doFire(SimpleEventBus.java:193)
at com.google.web.bindery.event.shared.SimpleEventBus.fireEvent(SimpleEventBus.java:88)
at com.google.gwt.event.shared.HandlerManager.fireEvent(HandlerManager.java:127)
... 39 more
Caused by: java.lang.NullPointerException
at com.happs.curveapp.client.view.mobile.LoginView.<init>(LoginView.java:54)
at com.happs.curveapp.client.gin.MobileGinjectorImpl.com$happs$curveapp$client$view$mobile$LoginView_LoginView_methodInjection(MobileGinjectorImpl.java:1749)
at com.happs.curveapp.client.gin.MobileGinjectorImpl.create_Key$type$com$happs$curveapp$client$view$mobile$LoginView$_annotation$$none$$(MobileGinjectorImpl.java:1753)
at com.happs.curveapp.client.gin.MobileGinjectorImpl.get_Key$type$com$happs$curveapp$client$view$mobile$LoginView$_annotation$$none$$(MobileGinjectorImpl.java:1767)
at com.happs.curveapp.client.gin.MobileGinjectorImpl.create_Key$type$com$happs$curveapp$client$presenter$LoginPresenter$MyView$_annotation$$none$$(MobileGinjectorImpl.java:231)
at com.happs.curveapp.client.gin.MobileGinjectorImpl.get_Key$type$com$happs$curveapp$client$presenter$LoginPresenter$MyView$_annotation$$none$$(MobileGinjectorImpl.java:240)
at com.happs.curveapp.client.gin.MobileGinjectorImpl.create_Key$type$com$happs$curveapp$client$presenter$LoginPresenter$_annotation$$none$$(MobileGinjectorImpl.java:299)
at com.happs.curveapp.client.gin.MobileGinjectorImpl.get_Key$type$com$happs$curveapp$client$presenter$LoginPresenter$_annotation$$none$$(MobileGinjectorImpl.java:313)
at com.happs.curveapp.client.gin.MobileGinjectorImpl.access$0(MobileGinjectorImpl.java:311)
at com.happs.curveapp.client.gin.MobileGinjectorImpl$1$1.onSuccess(MobileGinjectorImpl.java:254)
at com.google.gwt.core.client.GWT.runAsync(GWT.java:255)
at com.happs.curveapp.client.gin.MobileGinjectorImpl$1.get(MobileGinjectorImpl.java:252)
at com.gwtplatform.common.client.CodeSplitProvider.get(CodeSplitProvider.java:48)
at com.gwtplatform.mvp.client.proxy.ProxyImpl.getPresenter(ProxyImpl.java:46)
at com.gwtplatform.mvp.client.proxy.ProxyPlaceAbstract.handleRequest(ProxyPlaceAbstract.java:193)
at com.gwtplatform.mvp.client.proxy.ProxyPlaceAbstract.access$0(ProxyPlaceAbstract.java:192)
at com.gwtplatform.mvp.client.proxy.ProxyPlaceAbstract$1.onPlaceRequest(ProxyPlaceAbstract.java:143)
at com.gwtplatform.mvp.client.proxy.PlaceRequestInternalEvent.dispatch(PlaceRequestInternalEvent.java:134)
at com.gwtplatform.mvp.client.proxy.PlaceRequestInternalEvent.dispatch(PlaceRequestInternalEvent.java:1)
at com.google.gwt.event.shared.GwtEvent.dispatch(GwtEvent.java:1)
at com.google.web.bindery.event.shared.EventBus.dispatchEvent(EventBus.java:40)
at com.google.web.bindery.event.shared.SimpleEventBus.doFire(SimpleEventBus.java:193)
... 52 more

Categories

Resources