Gremlinpython to Neptune with IAM Authentication

1,093 views
Skip to first unread message

Cyril Scetbon

unread,
Nov 26, 2019, 3:12:37 PM11/26/19
to Gremlin-users
Hey guys,

I aim to use IAM authentication to connect to Neptune. I see that there is a repository https://github.com/aws/amazon-neptune-gremlin-java-sigv4 that extends GremlinDriver with a custom channelizer that enables AWS Signature Version 4 signed requests. Is there a way to use do the same with gremlinpyhon ? I see the first parameter of DriverRemoteConnection can be an http request, so I suppose it's possible to do so ?

Thank you

Taylor Riggan

unread,
Nov 26, 2019, 10:17:37 PM11/26/19
to Gremlin-users
Hi,

Yes, I have an example of this in a personal repo at the moment.  I need to get it added to our neptune-tools repo.  For now you can see the examples here:  https://github.com/triggan/neptune-python-sigv4-ws

Cyril Scetbon

unread,
Nov 27, 2019, 10:17:43 AM11/27/19
to Gremlin-users

M P

unread,
Jul 21, 2020, 11:13:38 AM7/21/20
to Gremlin-users
I am trying to use this module. Have you managed to test it successfully? Any updates to the code? Thanks

Taylor Riggan

unread,
Jul 22, 2020, 4:43:08 PM7/22/20
to Gremlin-users
 
There's actually a newer set of python libraries that we've published to make this a bit easier:  https://github.com/awslabs/amazon-neptune-tools/tree/master/neptune-python-utils

M P

unread,
Jul 23, 2020, 11:52:06 AM7/23/20
to Gremlin-users
Thank you. Exactly what I was after for managing/refreshing AWS credentials. Saved my day.

akash gupta

unread,
Jun 11, 2021, 2:31:05 PM6/11/21
to Gremlin-users
Hey Guys,

I was using this code for connecting to Neptune with IAM Authentication: https://github.com/awslabs/amazon-neptune-tools/tree/master/neptune-python-utils

But I keep getting the below error.

TypeError: 'LazyHttpHeaders' object is not iterable

Stack trace: https://github.com/awslabs/amazon-neptune-tools/issues/134#issuecomment-859646293

Please let me know what changes should I do to run this code.

Thanks in advance.

Regards,
-Akash
Reply all
Reply to author
Forward
0 new messages