Tabnine Logo
Invocation.getMetaData
Code IndexAdd Tabnine to your IDE (free)

How to use
getMetaData
method
in
org.jboss.aop.joinpoint.Invocation

Best Java code snippets using org.jboss.aop.joinpoint.Invocation.getMetaData (Showing top 20 results out of 315)

origin: org.jboss.ejb3/jboss-ejb3-core

public static void addMetadata(Invocation invocation, Object key, Object value)
{
 invocation.getMetaData().addMetaData(CLIENT_METADATA, key, value);
}
origin: org.jboss.ejb3/jboss-ejb3-core

public static Object getMetadata(Invocation invocation, Object key)
{
 return invocation.getMetaData().getMetaData(CLIENT_METADATA, key);
}
origin: org.jboss.ejb3/jboss-ejb3-core

public static void addMetadata(Invocation invocation, Object key, Object value, PayloadKey payload)
{
 invocation.getMetaData().addMetaData(CLIENT_METADATA, key, value, payload);
}
origin: org.jboss.ejb3.async/jboss-ejb3-async-impl

/**
* Obtains the current {@link AsyncInvocationId}, first looking in the
* current Thread, then examining the specified invocation metadata.
* If the current invocation is not asynchronous, null is returned.
*/
public static AsyncInvocationId getCurrentAsyncInvocationId(final Invocation invocation)
{
 // Precondition checks
 assert invocation != null : "Invocation must be specified";
 // Attempt to get from the Thread (local)
 AsyncInvocationId current = CurrentAsyncInvocation.getCurrentAsyncInvocationId();
 // Attempt to get from the invocation
 if (current == null)
 {
   current = (AsyncInvocationId) invocation.getMetaData(AsyncInvocation.METADATA_GROUP_ASYNC,
      AsyncInvocation.METADATA_KEY_ID);
 }
 // Return
 return current;
}
origin: org.jboss.ejb3.async/jboss-ejb3-async-impl

public static void markCurrentInvocation(final AsyncInvocationId uuid, final Invocation invocation)
{
 // Precondition checks
 assert invocation != null : "Invocation must be specified";
 CurrentAsyncInvocation.markCurrentInvocationOnThread(uuid);
 invocation.getMetaData().addMetaData(AsyncInvocation.METADATA_GROUP_ASYNC, AsyncInvocation.METADATA_KEY_ID, uuid);
}
origin: org.jboss.ejb3.async/jboss-ejb3-async-impl

  public static AsyncInvocationId unmarkCurrentInvocation(final Invocation invocation)
  {
   // Pop off
   final AsyncInvocationId current = CurrentAsyncInvocation.unmarkCurrentInvocationFromThread();

   // Remove metadata from the invocation
   invocation.getMetaData().removeMetaData(AsyncInvocation.METADATA_GROUP_ASYNC, AsyncInvocation.METADATA_KEY_ID);

   return current;
  }
}
origin: org.jboss.ejb3/jboss-ejb3-core

static Map getClientMetadataMap(Invocation invocation)
{
 Map map =  invocation.getMetaData().tag(CLIENT_METADATA);
 if (map != null)
 {
   return new ClientValueMap(map);
 }
 return null;
}
origin: org.jboss.ejb3.async/jboss-ejb3-async-impl

final String beenHere = (String) invocation.getMetaData().getMetaData(INVOCATION_METADATA_TAG,
   INVOCATION_METADATA_ATTR);
if (beenHere != null && beenHere.equals(INVOCATION_METADATA_VALUE))
origin: org.jboss.ejb3/jboss-ejb3-core

private Container findLocalContainer(Invocation invocation)
 String guid = (String)invocation.getMetaData(IS_LOCAL, GUID);
 String partitionName = (String) invocation.getMetaData(ClusterConstants.CLUSTERED_REMOTING, ClusterConstants.PARTITION_NAME);
   if (container == null)
    String oid = (String)invocation.getMetaData(Dispatcher.DISPATCHER, Dispatcher.OID);
    container = Ejb3Registry.getClusterContainer(Ejb3Registry.clusterUid(oid, partitionName));
origin: org.jboss.cluster/jboss-ha-server-api

  @Override
  public Object invoke(Invocation invocation) throws Throwable
  {
   Object response = invocation.invokeNext();
   String clientFamily = (String) invocation.getMetaData(CLUSTERED_REMOTING, CLUSTER_FAMILY);

   HATarget target = families.get(clientFamily);
   if (target == null)
   {
     return response;
   }

   Long clientViewId = (Long) invocation.getMetaData(CLUSTERED_REMOTING, CLUSTER_VIEW_ID);
   if (clientViewId == null)
   {
     // Maybe we're being invoked upon by a non-clustered proxy
     return response;
   }
   if (clientViewId.longValue() != target.getCurrentViewId())
   {
     invocation.addResponseAttachment("replicants", new ArrayList<Object>(target.getReplicantList()));
     invocation.addResponseAttachment("viewId", new Long(target.getCurrentViewId()));
   }
   return response;
  }
}
origin: org.jboss.ejb3/jboss-ejb3-core

public Object invoke(Invocation invocation) throws Throwable
 Object message = invocation.getMetaData().getMetaData(ConsumerContainer.CONSUMER_MESSAGE, ConsumerContainer.CONSUMER_MESSAGE);
 if (fields != null)
origin: org.jboss.ejb3.async/jboss-ejb3-async-impl

final InvokerLocator locator = (InvokerLocator) invocation.getMetaData(InvokeRemoteInterceptor.REMOTING,
   InvokeRemoteInterceptor.INVOKER_LOCATOR);
final Object oid = invocation.getMetaData().getMetaData(Dispatcher.DISPATCHER, Dispatcher.OID);
final PojiProxy proxy = new PojiProxyHack(oid, locator, new Interceptor[]
{});
origin: org.jboss.jbossas/jboss-as-aspects

VersionedObject manager = (VersionedObject)invocation.getMetaData(Versioned.VERSIONED, Versioned.VERSIONED_OBJECT);
if (invocation instanceof MethodInvocation)
  String readonly = (String)invocation.getMetaData(Versioned.VERSIONED, Versioned.READONLY);
  if (readonly != null)
origin: org.jboss.ejb3/jboss-ejb3-core

public Object invoke(Invocation invocation) throws Throwable
{
 if (isLocal())
 {
   String guid = (String)invocation.getMetaData(IS_LOCAL, GUID);
   Container container = Ejb3Registry.getContainer(guid);
      return invokeLocal(invocation, container);
 }
 return invocation.invokeNext();
}
origin: org.jboss.aop/jboss-aop

public InvocationResponse invoke(Invocation invocation) throws NotFoundInDispatcherException, Throwable
 Object oid = invocation.getMetaData(DISPATCHER, OID);
origin: org.jboss.ejb3/jboss-ejb3-core

protected Object invokeLocal(Invocation invocation, Container container) throws Throwable
{
 Invocation copy = marshallOrPass(invocation, Invocation.class);
 copy.getMetaData().addMetaData(IS_LOCAL, IS_LOCAL, Boolean.TRUE, PayloadKey.AS_IS);
 try
 {
   // Invoke upon the container
   SessionContainer sc = (SessionContainer) container;
   InvocationResponse response = sc.dynamicInvoke(copy);
   // it could really have been a copy
   invocation.setResponseContextInfo(response.getContextInfo());
   return marshallOrPass(response.getResponse(), Object.class);
 }
 // TODO: Either Throwable (as it used to be) or Exception (which is better)
 catch(Throwable t)
 {
   throw marshallOrPass(t, Throwable.class);
 }
 finally
 {
   copy.getMetaData().removeMetaData(IS_LOCAL, IS_LOCAL);
 }
}
origin: org.jboss.ejb3.async/jboss-ejb3-async-impl

nextInvocation.getMetaData().addMetaData(INVOCATION_METADATA_TAG, INVOCATION_METADATA_ATTR,
   INVOCATION_METADATA_VALUE);
origin: org.jboss.ejb3/jboss-ejb3-core

public Object invoke(Invocation invocation) throws Throwable
{
 if (isLocal())
 {
   Object oid = invocation.getMetaData(Dispatcher.DISPATCHER, Dispatcher.OID);
   if (Dispatcher.singleton.isRegistered(oid))
   {
    InvocationResponse response = Dispatcher.singleton.invoke(invocation);
    invocation.setResponseContextInfo(response.getContextInfo());
    return response.getResponse();
   }
 }
 return invocation.invokeNext();
}
origin: org.picketlink.distribution/picketlink-jbas5

public Object invoke(Invocation invocation) throws Throwable {
  SecurityContext sc = (SecurityContext) invocation.getMetaData("security", "context");
  logger.trace("Retrieved SecurityContext from invocation:" + sc);
  if (sc != null) {
      newSC.getUtil().createSubjectInfo(principal, new SamlCredential(assertion), subject);
      invocation.getMetaData().addMetaData("security", "context", newSC);
origin: org.jboss.aop/jboss-aop

nextInvocation.setMetaData(invocation.getMetaData());
nextInvocation.setTargetObject(target);
nextInvocation.setArguments(methodInvocation.getArguments());
org.jboss.aop.joinpointInvocationgetMetaData

Javadoc

Return all the contextual untyped data attached to this invocation

Popular methods of Invocation

  • invokeNext
    Invoke on the next interceptor in the chain. If this is already the end of the chain, reflection wil
  • getTargetObject
  • getAdvisor
  • addResponseAttachment
  • copy
    Copies complete state of Invocation object so that it could possibly be reused in a spawned thread.
  • getInterceptors
  • getResponseContextInfo
  • getWrapper
    Get a wrapper invocation object that can insert a new chain of interceptors at runtime to the invoca
  • setResponseContextInfo
  • setTargetObject

Popular in Java

  • Parsing JSON documents to java classes using gson
  • addToBackStack (FragmentTransaction)
  • requestLocationUpdates (LocationManager)
  • getResourceAsStream (ClassLoader)
  • DecimalFormat (java.text)
    A concrete subclass of NumberFormat that formats decimal numbers. It has a variety of features desig
  • Format (java.text)
    The base class for all formats. This is an abstract base class which specifies the protocol for clas
  • Timer (java.util)
    Timers schedule one-shot or recurring TimerTask for execution. Prefer java.util.concurrent.Scheduled
  • ConcurrentHashMap (java.util.concurrent)
    A plug-in replacement for JDK1.5 java.util.concurrent.ConcurrentHashMap. This version is based on or
  • JCheckBox (javax.swing)
  • JFrame (javax.swing)
  • Top Vim plugins
Tabnine Logo
  • Products

    Search for Java codeSearch for JavaScript code
  • IDE Plugins

    IntelliJ IDEAWebStormVisual StudioAndroid StudioEclipseVisual Studio CodePyCharmSublime TextPhpStormVimGoLandRubyMineEmacsJupyter NotebookJupyter LabRiderDataGripAppCode
  • Company

    About UsContact UsCareers
  • Resources

    FAQBlogTabnine AcademyTerms of usePrivacy policyJava Code IndexJavascript Code Index
Get Tabnine for your IDE now