Giter Site home page Giter Site logo

adapters's People

Contributors

idanadar avatar liorbu1 avatar nathanhazout avatar zhangzxm avatar

Stargazers

 avatar  avatar  avatar  avatar  avatar

Watchers

 avatar  avatar  avatar  avatar

adapters's Issues

CDI doesn't work in a simple adapter

I've added the CDI feature to the server.xml file<feature>cdi-1.2</feature>.

My maven module contains the beans.xml inside the <module_name>/src/main/resources/META-INF folder.

This is the beans.xml content:

<?xml version="1.0" encoding="UTF-8"?>
<beans xmlns="http://xmlns.jcp.org/xml/ns/javaee"
       xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
       xsi:schemaLocation="http://xmlns.jcp.org/xml/ns/javaee
                           http://xmlns.jcp.org/xml/ns/javaee/beans_1_1.xsd"
       version="1.1" bean-discovery-mode="all">
</beans>

But when I use the @Inject annotation it doesn't work, my bean is always null.

Code:

@Path("/test/")
public class MyController {
    @Inject
    private MyService myService;

    @GET
    @Path("/foo/{count}")
    @OAuthSecurity(scope = "login")
    @Produces("application/json")
    public Response news(@PathParam("count") int count) {
        return Response
                .ok(myService.getBar(count))
                .build();
    }
}

What's wrong?

UsingJavaInJavaScriptAdapters ConfigurationAPI issue

Hi,

in our MobileFirst project, we are using Javascript adapters, but we have many utilities in Java code.
These utilities need to read MobileFirst properties using ConfigurationAPI. The problem is that configurationApi variable is always null.

Here is my example code:
`public class ResponseUtils {

@Context 
public ConfigurationAPI configurationAPI ;

     public static Scriptable createGenericResponse(String statusKey) {
	System.out.println("Test config:"+ResponseUtils.configurationAPI);
	
	return createGenericResponse(statusKey, null);
}

}`

I'm calling the "createGenericResponse" method from javascript adapters.

Where is the problem?

Thank you

We needs REST push API integration for java based adapter hands on samples

Dear Team,
We are struggling to implement if use sdk based push service registration as per business needs so that we would request IBM team, if possible to share sample java based or adapter based PUSH rest API integration hands on code. it will really help us. below senario we required ,

1 . how to register the notification user id with device based
2. how to send the notification with particular user id and device

if above senario available sample hands, it will really help us. please do the needful.

Example for HTTPs Java Adapter with mutual authentication?

Hi,

I'm currently trying to establish a secure connection from a Java Adapter to a backend with mutual authentication on MFP 8.

I already have configured a custom keystore containing the identity cert+key of the MFP Runtime (for OAuth - mobile client <--> mfp), the client auth certificate+private key for MFP --> backend authentication and the public key of the backend server (for MFP <-- backend).

I have also defined the connection policy within the adapter.xml, referencing the client auth cert alias.

Still, I can't manage to establish a secure connection - the cert defined in the adapter.xml never gets used.

How can I access the keystore configured using the mfpconsole web interface?
Simply establishing a connection using by using the HttpClientBuilder with its default configuration, won't help.

How am I supposed to build the context for the configuration by still using the custom keystore uploaded within the web interface?
I am able to work around this by loading a keystore file and building my own SSLContext - but that's not how it's supposed to be.

I would appreciate any help, as I can't find any further documentation or samples regarding this subject on public portals (except for the Tutorials).

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    ๐Ÿ–– Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. ๐Ÿ“Š๐Ÿ“ˆ๐ŸŽ‰

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google โค๏ธ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.