Coder Social home page Coder Social logo

Comments (12)

ryannewington avatar ryannewington commented on June 11, 2024 1

Fixed transform library and updated nuget package lithnet/transform-engine@288673c

from umare.

ryannewington avatar ryannewington commented on June 11, 2024

@mwassell,

Test this release and see if it resolves the issue for you
https://github.com/lithnet/umare/releases/tag/v1.5.6117

Let me know how it goes.

Ryan

from umare.

mwassell avatar mwassell commented on June 11, 2024

@ryannewington Thank you for the quick response Ryan!

This flow doesn't seem to work:
accountExpires>>LookupValue>>ConvertToDateTime>>accountExpires

It appears that LookupValue returns a NULL of type String by default.

But, this flow does work:
accountExpires>>LookupValue>>ToInteger>>ConvertToDateTime>>accountExpires

from umare.

ryannewington avatar ryannewington commented on June 11, 2024

Can you attach or email me your umarex file? Also, the exact error message you are getting?

from umare.

mwassell avatar mwassell commented on June 11, 2024

Sorry for the delay! I've attached the UMAREX transform file. Here's the error:

System.FormatException: A null object cannot be converted to 'long'
   at Lithnet.MetadirectoryServices.TypeConverter.ConvertToLong(Object obj)
   at Lithnet.MetadirectoryServices.TypeConverter.ConvertData(Object obj, ExtendedAttributeType type)
   at Lithnet.Transforms.SimpleLookupTransform.TransformSingleValue(Object inputValue)
   at Lithnet.Transforms.Transform.TransformValue(Object inputValue)
   at Lithnet.Transforms.Transform.TransformValue(IList`1 inputValues)
   at Lithnet.Transforms.Transform.ExecuteTransformChain(IEnumerable`1 transforms, IList`1 inputValues)
   at Lithnet.Umare.MAExtensionObject.Microsoft.MetadirectoryServices.IMASynchronization.MapAttributesForImport(String flowRuleName, CSEntry csentry, MVEntry mventry)

umarex-transforms.txt

from umare.

ryannewington avatar ryannewington commented on June 11, 2024

@mwassell If I understand your logic correctly, you want to take account expires values of 'never' in AD and have them map into something useful in FIM. I can see that the value for account expires 'never' is Int64.MaxValue in AD, but that exceeds the allowed value for FILETIME (the underlying data type in AD) which the transform uses for AD dates. If this is the case, i'm wondering if we actually make a special case for handling this in the date converter transform. (The 'filetime' input type is actually designed to handle native AD date data - it seems we don't handle this situation).

The date would come through as 9999-12-31, which you can then do a lookup transform on and replace it with null if you didnt want that value?

Would that work for you? Then you could just do something like

accountExpires>>ConvertFromFileTime>>accountExpires

or if you didnt want the 9999-12-31 value

accountExpires>>ConvertFromFileTime>>ReplaceMaxDateWithNull>>accountExpires

from umare.

mwassell avatar mwassell commented on June 11, 2024

@ryannewington Correct! Thank you for taking the time to understand this situation.

The eventual goal is to export the value to the Portal. I thought that replacing the invalid value with a Null and not allowing Nulls to be Exported will provide the desired result.

from umare.

ryannewington avatar ryannewington commented on June 11, 2024

Ok try this version.
If you create a new DateTimeConverter transform with 'FileTime' type selected as the input type, and FIM Service Date as the output type, it will convert those values to 9999-12-31.

accountExpires>>ConvertFromFileTime>>accountExpires

Lithnet.Umare.msi.zip

from umare.

mwassell avatar mwassell commented on June 11, 2024

Thanks Ryan! I'll give it a go and let you know the results,

On Wed, Oct 5, 2016 at 7:16 PM, Ryan Newington [email protected]
wrote:

Ok try this version.
If you create a new DateTimeConverter transform with 'FileTime' type
selected as the input type, and FIM Service Date as the output type, it
will convert those values to 9999-12-31.

accountExpires>>ConvertFromFileTime>>accountExpires

Lithnet.Umare.msi.zip
https://github.com/lithnet/umare/files/512507/Lithnet.Umare.msi.zip


You are receiving this because you were mentioned.
Reply to this email directly, view it on GitHub
#1 (comment), or mute
the thread
https://github.com/notifications/unsubscribe-auth/AIA1YdTzx12Zd8gOHCYQI-11QFC4yk0wks5qxC--gaJpZM4KKc7I
.

from umare.

ryannewington avatar ryannewington commented on June 11, 2024

Hi @mwassell,

Did you have a chance to look at this?

Ryan

from umare.

mwassell avatar mwassell commented on June 11, 2024

You are the man! It works perfectly.

Thank you for all of your hard work (again). :-)

On Mon, Oct 17, 2016 at 12:14 AM, Ryan Newington [email protected]
wrote:

Hi @mwassell https://github.com/mwassell,

Did you have a chance to look at this?

Ryan


You are receiving this because you were mentioned.
Reply to this email directly, view it on GitHub
#1 (comment), or mute
the thread
https://github.com/notifications/unsubscribe-auth/AIA1YeiOij3BOAwOfPt2QR4V4NXWk3zUks5q0vYigaJpZM4KKc7I
.

from umare.

ryannewington avatar ryannewington commented on June 11, 2024

Released as production version 1.5.6123

https://github.com/lithnet/umare/releases/tag/v1.5.6123

from umare.

Related Issues (10)

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.