KVM value is not populating

Not applicable

keymap-access-token.txtextract-variable-16.txtkvm-for-populate-cache-4.txttrace-session.txtI am trying to populate the KVM key and value in the environment. I have created a KVM name : ActonUPN and trying to get the key as the token id and the value as user principal name(UPN).

But here the key i.e the token id which is only get populated but the value i.e UPN is not populating.

I am getting null value.

I am sharing the trace session and the javascript,extract variable and KVM code

0 11 533
11 REPLIES 11

Hi @krishnendu sen, your tracesession file is not valid, offline trace session needs an XML format file. For text please use the Insert Code option in this editor.

So in Trace do you see the values under Javascript policy.

I see that you are using Extract Policy <Source>response</Source> side. I hope that is the intended approach.

If you have token reference in your proxy use ref tag else use name_literal.

<?xml version="1.0" encoding="UTF-8" standalone="yes"?>
<KeyValueMapOperations async="false" continueOnError="false" enabled="true" name="KVM-for-Populate-Cache-4" mapIdentifier="ActeonUPN">
    <DisplayName>KVM-for-Populate-Cache-4</DisplayName>
    <ExpiryTimeInSecs>86400</ExpiryTimeInSecs>
    <Scope>environment</Scope>
    <Put>
        <Key>
            <Parameter>key_name_literal</Parameter>     
        </Key>
        <Value ref="userPrincipalName"/>
    </Put>
</KeyValueMapOperations>

Hi,

No I can't see any value under java script policy in trace session. I m getting null value.screenshot attached.

And I m unable to attached the trace session in xml format or HTML format because those format are not supporting.

Please help.img-20180918-174231.jpg

Can anyone please help. This is very urgent

I'd like to help. Help me, to help you.

  1. Post the policy code, AS CODE, in your question.
  2. If you have screenshots, post them, AS IMAGES, in your question.
  3. If you have a trace session, post the valid XML.

Hi, I a have attached the code as screen shot and the trace session also. Please let me know if you need anything else

Sorry -

I cannot access that trace file at the link you provided.

7458-screenshot-20180919-141904.png

There's an easy way to capture and then share a Trace session.

From the UI, click "Download Trace Session". That is the file you want to share with me here.

You can rename it to a .txt extension, and then attach it here.

The thing you originally attached is not that. It appears to be some sort of reformatted not-really-XML thing. It has dashes before element names, and + signs. As if you were displaying it in a browser or some other tool, and then did a ctrl-C to copy/paste it. That's not going to work.

Hi,

I am unable to login to APIGEE community from my laptop. I am getting some error like "an internal error has occurred and we are sorry for the inconvenience"

So the trace session which I have saved as text I am unable to attached here it is asking for login. So i have shared it through Google drive

Can you please check now I have removed the permission you don't need any permission to see the file.

7454-img-20180919-132522.jpg

7455-img-20180919-132547.jpg

7456-img-20180919-133002.jpg

7457-img-20180919-133032.jpg

Please find the attached code for extract variable, JavaScript and kvm

Hi @krishnendu sen, I hope this issue is resolved, I couldnt login into community due to some issue.

Did you check your Extract variable policy? You are extracting JSON and using a VariablePrefix(apigee).

So in JS policy you need to use apigee.userPrincipleName