[ 
https://issues.apache.org/jira/browse/IGNITE-15794?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=17444441#comment-17444441
 ] 

Ignite TC Bot commented on IGNITE-15794:
----------------------------------------

{panel:title=Branch: [pull/9510/head] Base: [master] : No blockers 
found!|borderStyle=dashed|borderColor=#ccc|titleBGColor=#D6F7C1}{panel}
{panel:title=Branch: [pull/9510/head] Base: [master] : New Tests 
(12)|borderStyle=dashed|borderColor=#ccc|titleBGColor=#D6F7C1}
{color:#00008b}Service Grid (Legacy Mode){color} [[tests 
6|https://ci.ignite.apache.org/viewLog.html?buildId=6270615]]
* {color:#013220}IgniteServiceGridTestSuite: 
IgniteServiceCallContextTest.testContextAttributeMultithreaded[clusterSingleton=false,
 sticky=true] - PASSED{color}
* {color:#013220}IgniteServiceGridTestSuite: 
IgniteServiceCallContextTest.testContextAttribute[clusterSingleton=false, 
sticky=false] - PASSED{color}
* {color:#013220}IgniteServiceGridTestSuite: 
IgniteServiceCallContextTest.testContextAttributeMultithreaded[clusterSingleton=false,
 sticky=false] - PASSED{color}
* {color:#013220}IgniteServiceGridTestSuite: 
IgniteServiceCallContextTest.testContextAttribute[clusterSingleton=true, 
sticky=true] - PASSED{color}
* {color:#013220}IgniteServiceGridTestSuite: 
IgniteServiceCallContextTest.testContextAttributeMultithreaded[clusterSingleton=true,
 sticky=true] - PASSED{color}
* {color:#013220}IgniteServiceGridTestSuite: 
IgniteServiceCallContextTest.testContextAttribute[clusterSingleton=false, 
sticky=true] - PASSED{color}

{color:#00008b}Service Grid{color} [[tests 
6|https://ci.ignite.apache.org/viewLog.html?buildId=6270594]]
* {color:#013220}IgniteServiceGridTestSuite: 
IgniteServiceCallContextTest.testContextAttributeMultithreaded[clusterSingleton=false,
 sticky=true] - PASSED{color}
* {color:#013220}IgniteServiceGridTestSuite: 
IgniteServiceCallContextTest.testContextAttribute[clusterSingleton=false, 
sticky=false] - PASSED{color}
* {color:#013220}IgniteServiceGridTestSuite: 
IgniteServiceCallContextTest.testContextAttributeMultithreaded[clusterSingleton=false,
 sticky=false] - PASSED{color}
* {color:#013220}IgniteServiceGridTestSuite: 
IgniteServiceCallContextTest.testContextAttribute[clusterSingleton=true, 
sticky=true] - PASSED{color}
* {color:#013220}IgniteServiceGridTestSuite: 
IgniteServiceCallContextTest.testContextAttributeMultithreaded[clusterSingleton=true,
 sticky=true] - PASSED{color}
* {color:#013220}IgniteServiceGridTestSuite: 
IgniteServiceCallContextTest.testContextAttribute[clusterSingleton=false, 
sticky=true] - PASSED{color}

{panel}
[TeamCity *--> Run :: All* 
Results|https://ci.ignite.apache.org/viewLog.html?buildId=6270620&buildTypeId=IgniteTests24Java8_RunAll]

> Request attributes for a java service. 
> ---------------------------------------
>
>                 Key: IGNITE-15794
>                 URL: https://issues.apache.org/jira/browse/IGNITE-15794
>             Project: Ignite
>          Issue Type: Sub-task
>          Components: managed services
>            Reporter: Pavel Pereslegin
>            Assignee: Pavel Pereslegin
>            Priority: Major
>              Labels: iep-79, ise
>          Time Spent: 1h 10m
>  Remaining Estimate: 0h
>
> Implement support for passing implicit "request" attributes from the proxy to 
> the Java service.
> *Implementation notes*.
>  # If no caller attributes are passed - there should be no performance 
> overhead when executing service methods.
>  # Attributes allow only {{string}} and {{byte[]}} values and does not permit 
> nulls in key/values.
>  # Currently, the context should be immutable, but in the future, it should 
> be possible to change it through the interceptor.
>  # {{ServiceResource}} annotation allows to inject service/proxy, we must 
> provide the ability to transparently pass the context to the injected service.
> *Public API changes:*
> New methods in {{IgniteServices}}  to pass caller context to service proxy.
> {code:java}
> public <T> T serviceProxy(String name, Class<? super T> svcItf, boolean 
> sticky, ServiceCallContext callCtx)
> public <T> T serviceProxy(String name, Class<? super T> svcItf, boolean 
> sticky, ServiceCallContext callCtx, long timeout)
> {code}
> New method in {{ServiceContext}} for getting caller context inside the 
> service method.
> {code:java}
> /**
>  * Gets context of the current service call.
>  *
>  * @return Context of the current service call, possibly {@code null}.
>  * @see ServiceCallContext
>  */
> @Nullable public ServiceCallContext currentCallContext();
> {code}
> New interface {{ServiceCallContext}}
> {code:java}
> public interface ServiceCallContext {
>     public String attribute(String name);
>     public byte[] binaryAttribute(String name);
> }
> {code}
> And the builder {{ServiceCallContextBuilder}} for creating 
> {{ServiceCallContext}}.
> New property in {{ServiceResource annotation}}.
> {code:java}
> /**
>  * Flag indicating that the service call context should be passed to the 
> injected service.
>  *
>  * @return {@code True} if the service call context should be passed to the 
> injected service.
>  */
> public boolean forwardCallerContext() default false;
> {code}
>  



--
This message was sent by Atlassian Jira
(v8.20.1#820001)

Reply via email to