Uninformative Sharing Metadata
For some images the Sharing Metadata is not very helpful and often says things like "This photo has been shared with multiple services" while for others I see an upload date for each service and album. Why the difference. It may be that these are images uploaded prior to 3.1; all my recent uploads seem to have the more informative form. Does anyone else see this difference? Is there a way to fix it (other than re-uploading)?
No, images that were in the web albums prior to 3.1 have rudimentary info. Images only downloaded after using 3.1 also get a brief blurb. Images that were published from your library with 3.1 get the new goodness.
Similar Messages
-
Displaying Album Usage/Sharing Metadata
I know this has been asked before, but I was wondering if anyone knows how to display in the Metadata Inspector tab, which albums might contain a selected image. The reason I ask has to do with posting images to Facebook for example. Working with a project containing many images, I selected a number of them to be published to Facebook. Essentially this creates an "album" containing these images. At a later date, I might want to add additional images from this project to the Facebook album. Looking at all the images in the project, there is no way of knowing if a certain image has already been published or not. I know you can use the Sharing Metadata View in the inspector which tells you if a selected image has been shared or not. This works only for the Facebook "Album" or other published albums. There is no corresponding way to know if a selected image is in any other type of album by using the metadata inspector. I know you can filter the images by using the Aperture metadata field "album name" with any of a number of conditions, which does provide the information. However, as far as I can know, you can't display the Aperture metadata field "album name" in the metadata inspector. Am I understanding this correctly?
Thanks!!
EdI know this has been asked before, but I was wondering if anyone knows how to display in the Metadata Inspector tab, which albums might contain a selected image. The reason I ask has to do with posting images to Facebook for example. Working with a project containing many images, I selected a number of them to be published to Facebook. Essentially this creates an "album" containing these images. At a later date, I might want to add additional images from this project to the Facebook album. Looking at all the images in the project, there is no way of knowing if a certain image has already been published or not. I know you can use the Sharing Metadata View in the inspector which tells you if a selected image has been shared or not. This works only for the Facebook "Album" or other published albums. There is no corresponding way to know if a selected image is in any other type of album by using the metadata inspector. I know you can filter the images by using the Aperture metadata field "album name" with any of a number of conditions, which does provide the information. However, as far as I can know, you can't display the Aperture metadata field "album name" in the metadata inspector. Am I understanding this correctly?
Thanks!!
Ed -
Problem when trying to delete shared metadata folder
I am trying to undeploy one shared metadata folder from server using command:
MIDDLEWARE_HOME/Oracle_SOA1/common/bin and execute wlst.sh
connect('adminuser', 'adminpassword', 't3://hostname:port')
deleteMetadata(application='soa-infra',server='soa_server1',docs='/apps/Proj_xref')
Proj_xref is the folder I want to delete.But it is giving error.Please suggest.Hi,
What is the error it is giving?
See if this helps.
http://neeraj-soa-tips.blogspot.com/2011/06/delete-data-from-mds-single-files.html
Regards,
Neeraj Sehgal -
I noticed that iPhoto on my iPad yesterday has been 'upgraded' to a new version.
Unfortunately, I've noticed that it is no longer sharing location data to Flickr (even though the 'share location' option is enabled in settings). Is this a bug? If so, I hope Apple remedy it soon as it's very irritating having to add the location manually to Flickr and makes a nonsense of having GPS data already in the photo.
I wonder if GPS is the only bit of metadata not being shared?I noticed this same issue, doesn't seem to matter whether I upload through iPhoto or the photos app, the metadata isn't shared. When I email the file to myself from iPhoto using the original size the metadata _is_ preserved. I've checked and I have the flag set for sharing so I assume it's a bug
-
Shared Metadata in Windows Vista
When I want to apply a metadata template in lightroom on my iMac, I am presented the full collection of xmp metadata templates generated mostly with Photoshop.
When I try the same maneuver using Lightroom on my Windows Vista laptop, LR appears to be generating and accessing only those templates generated while using LR. Members of the Photoshop collection are not shown.
LR preferences do not appear to include choice of path to metadata templates (or did I miss that?).
Any insights/suggested solutions welcome.I did this quite successfully on our old family PC with Windows 2000 and iTunes 7.4. All 4 had own Windows accounts. iTunes was set up for each user to use a shared folder to store the music files. This way everyone could have an own iTunes library with own playlists, evaluations etc, but all music was accessible to everyone, though after adding music with one account others need to include add the shared folder again in the library to add new music into own library.
The same works now on our new family PC with Vista and iTunes 7.5 after copying the Music files, iTunes library files for each user and defining the new shared music folder location in iTunes. To be able to listen to music bought from iTunes Music Store I had to authorize the new computer, and I also deauthorized the old one before getting rid of it so that I don't keep one additional computer authorized forever for no reason.
However, one thing doesn't work like it did on Win2000 and I haven't found an acceptable solution yet:
We have bought music from iTunes MS using two different accounts, mine and my daughter's. The first time I try to play something bought by my daughter I need to authorize the computer using her Apple ID. Then the song plays and synhronizes with iPod ok.
But next time someone else wants to play any of the songs bought by my daughter, he/she is required to authorize the computer again. And next time I do the same, I'll have to do it again. After each authorization it says that I have only 1 of 5 authorizations used. So each authorization cancels previous authorizations done using other accounts on the same computer.
I might even accept using 4 of 5 computer authorizations for each user of the same computer, but iTunes doesn't give such option.
I've considered setting up a shared quest account for everyone for using iTunes, but then I would lose personal iTunes libraries.
Any better ideas? -
Shared Services - Sharing MetaData between Essbase and Planning?
<p><font size="2" face="Verdana">I have been out of the Hyperionworld for about a 1 and 1/2 years now and am trying to playcatch-up. I am looking at Planning admin doc for 9.2.0.3 and it isdiscussing sharing models in Shared Services (old HUB stuff that Ididn't get to do much with back in the day either).<br><br>At the risk of appearing dense, I wanted to verify if metadatamodels from Essbase cube can be shared with Planning applications?It may be somewhere in some doc explicitly that I am not readingbut only seems to talk about HFM and Planning sharingmodels.<br><br>If this is the case has anyone used it in this manner before? Areall properties for Planning dim/members translated across fromEssbase or are there dim/member properties that I would have to goback and complete still? Any drawbacks/issues with using the sharedmodel approach that I should watch out for? Other doc you canpoint me at that discusses using this in more detail?<br></font></p><p><font size="2" face="Verdana">Kathy<br></font></p>
To be honest it looks you after some of the functionality within EPMA, though if you have an essbase database then surely you will have a source for the dimensions so this could be used to populate the planning application as well.
Cheers
John
http://john-goodwin.blogspot.com/ -
public void ShareCalendar(Calendar calendar)
ExchangeService service = new ExchangeService(ExchangeVersion.Exchange2013);
service.Credentials = new NetworkCredential("user1", "password", "domain");
service.Url = new Uri("https://sampleUrl/ews/exchange.asmx");
try
// Bind to the folder
//Folder folderStoreInfo;
//folderStoreInfo = Folder.Bind(service, calendar.ExchangeId);
//string EwsID = folderStoreInfo.Id.UniqueId;
string EwsID = calendar.FolderExchangeId;
// The value of folderidHex will be what we need to use for the FolderId in the xml file
AutodiscoverService autoDiscover = new AutodiscoverService(ExchangeVersion.Exchange2013);
autoDiscover.Credentials = new NetworkCredential("user1", "password", "domain");
autoDiscover.RedirectionUrlValidationCallback = RedirectionUrlValidationCallback;
Dictionary<string, string> userSettings = GetUserSettings(autoDiscover);
string folderidHex = GetConvertedEWSIDinHex(service, EwsID, "[email protected]");
string domainName = string.Empty;
string mailBoxServer = string.Empty;
string userName = string.Empty;
foreach (var item in userSettings)
switch (item.Key)
case "UserDN":
domainName = item.Value.ToString();
break;
case "InternalMailboxServer":
mailBoxServer = item.Value.ToString();
break;
case "UserDisplayName":
userName = item.Value.ToString();
break;
string entryId = GetIntiatorEntryID(domainName);
string mailboxId = GetInvitationMailboxId(mailBoxServer, domainName);
string sharedFilePath = CreateSharingMessageAttachment(folderidHex, userName, entryId, mailboxId, "[email protected]", "calendar", calendar.FolderName);
// Create a new message
EmailMessage invitationRequest = new EmailMessage(service);
invitationRequest.Subject = "I'd like to share my calendar with you";
invitationRequest.Body = "Sent by Exchange Administrator on behalf of user";
//invitationRequest.Culture = "en-US";
invitationRequest.Sensitivity = Sensitivity.Normal;
// Set a sharing specific property on the message
invitationRequest.ItemClass = "IPM.Sharing"; /* Constant Required Value [MS-ProtocolSpec] */
byte[] byteEntryId = HexStringToByteArray(entryId);
// This is the Guid of the Sharing Provider in Exchange, and it's value does not change
Guid binSharingProviderGuid = new Guid("{AEF00600-0000-0000-C000-000000000046}");
// Even though I don't think setting this property is mandatory,
// it just seemed like the right thing to do and it works so I \
// ain't messin with it!
byte[] byteSharingProviderGuid = binSharingProviderGuid.ToByteArray();
string strPRBODYHTML = "<html dir=\"ltr\">\r\n<head>\r\n<meta http-equiv=\"Content-Type\" content=\"text/html; charset=iso-8859-1\">\r\n<meta name=\"GENERATOR\"
content=\"MSHTML 8.00.7601.17514\">\r\n<style id=\"owaParaStyle\">P {\r\n MARGIN-TOP: 0px; MARGIN-BOTTOM: 0px \r\n}\r\n</style>\r\n</head>\r\n<body fPStyle=\"1\" ocsi=\"0\">\r\n<tt>\r\n<pre>SharedByUserDisplayName
(SharedByUserSmtpAddress) has invited you to view his or her Microsoft Exchange Calendar.\r\n\r\nFor instructions on how to view shared folders on Exchange, see the following article:\r\n\r\nhttp://go.microsoft.com/fwlink/?LinkId=57561\r\n\r\n*~*~*~*~*~*~*~*~*~*\r\n\r\n</pre>\r\n</tt>\r\n<div>\r\n<div
style=\"direction: ltr;font-family: Tahoma;color: #000000;font-size: 10pt;\">this is a test message</div>\r\n</div>\r\n</body>\r\n</html>\r\n";
string strBODY = @"
SharedByUserDisplayName (SharedByUserSmtpAddress) has invited you to view his or
her Microsoft Exchange Calendar.
For instructions on how to view shared folders on Exchange, see the
following article:
http://go.microsoft.com/fwlink/?LinkId=57561
*~*~*~*~*~*~*~*~*~*
test body
// Convert these to hex and binary equivelants to assign to their relevant
// extended properties
string hexPRBODYHTML = ConvertStringToHex(strPRBODYHTML);
byte[] binPRBODYHTML = HexStringToByteArray(hexPRBODYHTML);
Guid PropertySetSharing = Guid.Parse("00062040-0000-0000-C000-000000000046");//constant
Guid PropertySetInternetHeaders = Guid.Parse("00020386-0000-0000-C000-000000000046");//constant
ExtendedPropertyDefinition PidLidSharingProviderGuidProperty = new ExtendedPropertyDefinition(PropertySetSharing, 0x8A01, MapiPropertyType.CLSID);
ExtendedPropertyDefinition ConversationIdProperty = new ExtendedPropertyDefinition(0x3013, MapiPropertyType.Binary);
// Sharing Properties (in order of reference according to protocol examples in: [MS-OXSHARE])
// Additional Property Constraints
// [MS-OXSHARE] 2.2.5.2
ExtendedPropertyDefinition PidTagMessageClass = new ExtendedPropertyDefinition(0x001A, MapiPropertyType.String);
// [MS-OXSHARE] 2.2.5.1
//ExtendedPropertyDefinition PidNameContentClass = new ExtendedPropertyDefinition(DefaultExtendedPropertySet.InternetHeaders, "Content-Class", MapiPropertyType.String);
ExtendedPropertyDefinition PidNameContentClass = new ExtendedPropertyDefinition(PropertySetInternetHeaders, "Content-class", MapiPropertyType.String);
// Common Message Object Properties
// [MS-OXSHARE] 2.2.1
ExtendedPropertyDefinition PidTagNormalizedSubject = new ExtendedPropertyDefinition(0x0E1D, MapiPropertyType.String);
// The PidTagSubjectPrefix is a zero-length string, so I do not set it
// ExtendedPropertyDefinition PidTagSubjectPrefix = new ExtendedPropertyDefinition(0x003D, MapiPropertyType.String);
// Sharing Object Message Properties
// [MS-OXSHARE] 2.2.2.12
ExtendedPropertyDefinition PidLidSharingProviderGuid = new ExtendedPropertyDefinition(PropertySetSharing, 0x8A01, MapiPropertyType.Binary);
// [MS-OXSHARE] 2.2.2.13
ExtendedPropertyDefinition PidNameXSharingProviderGuid = new ExtendedPropertyDefinition(PropertySetInternetHeaders, "X-Sharing-Provider-GUID", MapiPropertyType.String);
// [MS-OXSHARE] 2.2.2.14
ExtendedPropertyDefinition PidLidSharingProviderName = new ExtendedPropertyDefinition(PropertySetSharing, 0x8A02, MapiPropertyType.String);
// [MS-OXSHARE] 2.2.2.15
ExtendedPropertyDefinition PidNameXSharingProviderName = new ExtendedPropertyDefinition(PropertySetInternetHeaders, "X-Sharing-Provider-Name", MapiPropertyType.String);
// [MS-OXSHARE] 2.2.2.16
ExtendedPropertyDefinition PidLidSharingProviderUrl = new ExtendedPropertyDefinition(PropertySetSharing, 0x8A03, MapiPropertyType.String);
// [MS-OXSHARE] 2.2.2.17
ExtendedPropertyDefinition PidNameXSharingProviderUrl = new ExtendedPropertyDefinition(PropertySetInternetHeaders, "X-Sharing-Provider-URL", MapiPropertyType.String);
// [MS-OXSHARE] 2.2.2.5
ExtendedPropertyDefinition PidLidSharingFlavor = new ExtendedPropertyDefinition(PropertySetSharing, 0x8A18, MapiPropertyType.Integer);
// [MS-OXSHARE] 2.2.2.6
ExtendedPropertyDefinition PidNameXSharingFlavor = new ExtendedPropertyDefinition(PropertySetInternetHeaders, "X-Sharing-Flavor", MapiPropertyType.String);
// [MS-OXSHARE] 2.2.2.1
ExtendedPropertyDefinition PidLidSharingCapabilities = new ExtendedPropertyDefinition(PropertySetSharing, 0x8A17, MapiPropertyType.Integer);
// [MS-OXSHARE] 2.2.2.2
ExtendedPropertyDefinition PidNameXSharingCapabilities = new ExtendedPropertyDefinition(PropertySetInternetHeaders, "X-Sharing-Capabilities", MapiPropertyType.String);
// Sections 2.3 and 2.4 are also zero-length strings, so I won't set those either
// [MS-OXSHARE] 2.2.2.3
// ExtendedPropertyDefinition PidLidSharingConfigurationUrl = new //ExtendedPropertyDefinition(PropertySetSharing, 0x8A24, MapiPropertyType.String);
// [MS-OXSHARE] 2.2.2.4
//ExtendedPropertyDefinition PidNameXSharingConfigUrl = new //ExtendedPropertyDefinition(DefaultExtendedPropertySet.InternetHeaders, "X-Sharing-Config-Url", MapiPropertyType.String);
// [MS-OXSHARE] 2.2.2.10
ExtendedPropertyDefinition PidLidSharingLocalType = new ExtendedPropertyDefinition(PropertySetSharing, 0x8A14, MapiPropertyType.String);
// [MS-OXSHARE] 2.2.2.11
ExtendedPropertyDefinition PidNameXSharingLocalType = new ExtendedPropertyDefinition(PropertySetInternetHeaders, "X-Sharing-Local-Type", MapiPropertyType.String);
// [MS-OXSHARE] 2.2.2.7
ExtendedPropertyDefinition PidLidSharingInitiatorEntryId = new ExtendedPropertyDefinition(PropertySetSharing, 0x8A09, MapiPropertyType.Binary);
// [MS-OXSHARE] 2.2.2.8
ExtendedPropertyDefinition PidLidSharingInitiatorName = new ExtendedPropertyDefinition(PropertySetSharing, 0x8A07, MapiPropertyType.String);
// [MS-OXSHARE] 2.2.2.9
ExtendedPropertyDefinition PidLidSharingInitiatorSMTP = new ExtendedPropertyDefinition(PropertySetSharing, 0x8A08, MapiPropertyType.String);
// [MS-OXSHARE] 2.2.3.1
ExtendedPropertyDefinition PidLidSharingRemoteName = new ExtendedPropertyDefinition(PropertySetSharing, 0x8A05, MapiPropertyType.String);
// [MS-OXSHARE] 2.2.3.2
ExtendedPropertyDefinition PidNameXSharingRemoteName = new ExtendedPropertyDefinition(PropertySetInternetHeaders, "X-Sharing-Remote-Name", MapiPropertyType.String);
// [MS-OXSHARE] 2.2.3.5
ExtendedPropertyDefinition PidLidSharingRemoteType = new ExtendedPropertyDefinition(PropertySetSharing, 0x8A1D, MapiPropertyType.String);
// [MS-OXSHARE] 2.2.3.6
ExtendedPropertyDefinition PidNameXSharingRemoteType = new ExtendedPropertyDefinition(PropertySetInternetHeaders, "X-Sharing-Remote-Type", MapiPropertyType.String);
// [MS-OXSHARE] 2.2.3.7
ExtendedPropertyDefinition PidLidSharingRemoteUid = new ExtendedPropertyDefinition(PropertySetSharing, 0x8A06, MapiPropertyType.String);
// [MS-OXSHARE] 2.2.3.8
ExtendedPropertyDefinition PidNameXSharingRemoteUid = new ExtendedPropertyDefinition(PropertySetInternetHeaders, "X-Sharing-Remote-Uid", MapiPropertyType.String);
// [MS-OXSHARE] 2.2.3.3
ExtendedPropertyDefinition PidLidSharingRemoteStoreUid = new ExtendedPropertyDefinition(PropertySetSharing, 0x8A48, MapiPropertyType.String);
// [MS-OXSHARE] 2.2.3.4
ExtendedPropertyDefinition PidNameXSharingRemoteStoreUid = new ExtendedPropertyDefinition(PropertySetInternetHeaders, "X-Sharing-Remote-Store-Uid", MapiPropertyType.String);
//From troubleshooting I noticed I was missing
ExtendedPropertyDefinition PidTagPriority = new ExtendedPropertyDefinition(0x0026, MapiPropertyType.Integer);
ExtendedPropertyDefinition PidTagSensitivity = new ExtendedPropertyDefinition(0x0036, MapiPropertyType.Integer);
ExtendedPropertyDefinition PR_BODY_HTML = new ExtendedPropertyDefinition(0x1013, MapiPropertyType.Binary); //PR_BOD
ExtendedPropertyDefinition PR_BODY = new ExtendedPropertyDefinition(0x1000, MapiPropertyType.String);
ExtendedPropertyDefinition RecipientReassignmentProhibited = new ExtendedPropertyDefinition(0x002b, MapiPropertyType.Boolean);
// Section 2.2.1
invitationRequest.SetExtendedProperty(PidTagNormalizedSubject, "I'd like to share my calendar with you"); /* Constant Required Value [MS-OXSHARE] 2.2.1 */
//invitationRequest.SetExtendedProperty(PidTagSubjectPrefix, String.Empty); /* Constant Required Value [MS-OXSHARE] 2.2.1 */
// Section 2.2.2
invitationRequest.SetExtendedProperty(PidLidSharingCapabilities, 0x40220); /* value for Special Folders */
invitationRequest.SetExtendedProperty(PidNameXSharingCapabilities, "40220"); /* Test representation of SharingCapabilities value */
//invitationRequest.SetExtendedProperty(PidLidSharingConfigurationUrl, String.Empty); /* Zero-Length String [MS-OXSHARE] 2.2.2.3 */
//invitationRequest.SetExtendedProperty(PidNameXSharingConfigUrl, String.Empty); /* Zero-Length String [MS-OXSHARE] 2.2.2.4 */
invitationRequest.SetExtendedProperty(PidLidSharingFlavor, 0x20310); /* Indicates Invitation for a special folder [MS-OXSHARE] 2.2.2.5 */
invitationRequest.SetExtendedProperty(PidNameXSharingFlavor, "20310"); /* Text representation of SharingFlavor value [MS-OXSHARE] 2.2.2.6 */
invitationRequest.SetExtendedProperty(PidLidSharingInitiatorEntryId, byteEntryId); /* Value from the Initiator/EntryId value in the Sharing Message attachment .xml document */
invitationRequest.SetExtendedProperty(PidLidSharingInitiatorSMTP, "[email protected]"); /* Value from Initiator/Smtp Address in the Sharing message attachment .xml document */
invitationRequest.SetExtendedProperty(PidLidSharingInitiatorName, "User1"); /* Value from Initiator/Name Address in the Sharing message attachment .xml document */
invitationRequest.SetExtendedProperty(PidLidSharingLocalType, "IPF.Appointment"); /* MUST be set to PidTagContainerClass of folder to be shared */
invitationRequest.SetExtendedProperty(PidNameXSharingLocalType, "IPF.Appointment"); /* MUST be set to same value as PidLidSharingLocalType */
invitationRequest.SetExtendedProperty(PidLidSharingProviderGuid, byteSharingProviderGuid); /* Constant Required Value [MS-OXSHARE] 2.2.2.12 */
invitationRequest.SetExtendedProperty(PidNameXSharingProviderGuid, "AEF0060000000000C000000000000046"); /* Constant Required Value [MS-OXSHARE] 2.2.2.13 */
invitationRequest.SetExtendedProperty(PidLidSharingProviderName, "Microsoft Exchange"); /* Constant Required Value [MS-OXSHARE] 2.2.2.14 */
invitationRequest.SetExtendedProperty(PidNameXSharingProviderName, "Microsoft Exchange"); /* Constant Required Value [MS-OXSHARE] 2.2.2.15] */
invitationRequest.SetExtendedProperty(PidLidSharingProviderUrl, "http://www.microsoft.com/exchange"); /* Constant Required Value [MS-OXSHARE] 2.2.2.16 */
invitationRequest.SetExtendedProperty(PidNameXSharingProviderUrl, "http://www.microsoft.com/exchange"); /* Constant Required Value [MS-OXSHARE] 2.2.2.17 */
// Section 2.2.3
invitationRequest.SetExtendedProperty(PidLidSharingRemoteName, calendar.FolderName); /* MUST be set to PidTagDisplayName of the folder being shared */
invitationRequest.SetExtendedProperty(PidNameXSharingRemoteName, calendar.FolderName); /* MUST be set to same value as PidLidSharingRemoteName */
invitationRequest.SetExtendedProperty(PidLidSharingRemoteStoreUid, mailboxId); /* Must be set to PidTagStoreEntryId of the folder being shared */
invitationRequest.SetExtendedProperty(PidNameXSharingRemoteStoreUid, mailboxId); /* MUST be set to same value as PidLidSharingRemoteStoreUid */
invitationRequest.SetExtendedProperty(PidLidSharingRemoteType, "IPF.Appointment"); /* Constant Required Value [MS-OXSHARE] 2.2.3.5 */
invitationRequest.SetExtendedProperty(PidNameXSharingRemoteType, "IPF.Appointment"); /* Constant Required Value [MS-OXSHARE] 2.2.3.6 */
invitationRequest.SetExtendedProperty(PidLidSharingRemoteUid, folderidHex); /* MUST be set to PidTagEntryId of folder being shared */
invitationRequest.SetExtendedProperty(PidNameXSharingRemoteUid, folderidHex); /* Must be set to same value as PidLidSharingRemoteUid */
// Section 2.2.5
invitationRequest.SetExtendedProperty(PidNameContentClass, "Sharing"); /* Constant Required Value [MS-ProtocolSpec] */
invitationRequest.SetExtendedProperty(PidTagMessageClass, "IPM.Sharing"); /* Constant Required Value [MS-ProtocolSpec] */
// ********* ADDITIONAL MAPPED PROPERTIES IM FINDING AS I TROUBLESHOOT ********************** //
invitationRequest.SetExtendedProperty(PidTagPriority, 0); /* From troubleshooting I'm just trying to match up values that were missing */
invitationRequest.SetExtendedProperty(PidTagSensitivity, 0); /* From troubleshooting as well */
invitationRequest.SetExtendedProperty(PR_BODY_HTML, binPRBODYHTML); /* From troubleshooting OWA error pointing to serializing HTML failing */
invitationRequest.SetExtendedProperty(PR_BODY, strBODY);
invitationRequest.SetExtendedProperty(RecipientReassignmentProhibited, true); /* Because it seemed like a good idea */
// Add a file attachment by using a stream
// We need to do the following in order to prevent 3 extra bytes from being prepended to the attachment
string sharMetadata = File.ReadAllText(sharedFilePath, Encoding.ASCII);
byte[] fileContents;
UTF8Encoding encoding = new System.Text.UTF8Encoding();
fileContents = encoding.GetBytes(sharMetadata);
//fileContents = File.ReadAllBytes(sharedFilePath);
//// fileContents is a Stream object that represents the content of the file to attach.
invitationRequest.Attachments.AddFileAttachment("sharing_metadata.xml", fileContents);
////invitationRequest.Attachments.AddFileAttachment(sharedFilePath);
//// This is where we set those "special" headers and other pertinent
//// information I noted in Part 1 of this series...
//Attachment thisAttachment = invitationRequest.Attachments[0];
//thisAttachment.ContentType = "application/x-sharing-metadata-xml";
//thisAttachment.Name = "sharing_metadata.xml";
//thisAttachment.IsInline = false;
// Add recipient info and send message
invitationRequest.ToRecipients.Add(new EmailAddress() { Address = "[email protected]" });
invitationRequest.SendAndSaveCopy();
// I always end my methods by returning the EWS
// impersonated user to null to clean up
service.ImpersonatedUserId = null;
catch (Exception ex)
public String GetConvertedEWSIDinHex(ExchangeService esb, String sID, String strSMTPAdd)
// Create a request to convert identifiers.
AlternateId objAltID = new AlternateId();
objAltID.Format = IdFormat.EwsId;
objAltID.Mailbox = strSMTPAdd;
objAltID.UniqueId = sID;
//Convert PR_ENTRYID identifier format to an EWS identifier.
AlternateIdBase objAltIDBase = esb.ConvertId(objAltID, IdFormat.HexEntryId);
AlternateId objAltIDResp = (AlternateId)objAltIDBase;
return objAltIDResp.UniqueId.ToString();
public String GetInvitationMailboxId(string mailBoxServer, string domainName)
ExchangeService service = new ExchangeService(ExchangeVersion.Exchange2013);
service.ImpersonatedUserId = new ImpersonatedUserId(ConnectingIdType.SmtpAddress, "[email protected]");
// Generate The Store Entry Id for the impersonated user
StringBuilder MailboxIDPointer = new StringBuilder();
string fqdn = mailBoxServer;
string legacyDN = domainName;
MailboxIDPointer.Append("00000000"); /* Flags */
MailboxIDPointer.Append("38A1BB1005E5101AA1BB08002B2A56C2"); /* ProviderUID */
MailboxIDPointer.Append("00"); /* Version */
MailboxIDPointer.Append("00"); /* Flag */
MailboxIDPointer.Append("454D534D44422E444C4C00000000"); /* DLLFileName */
MailboxIDPointer.Append("00000000"); /* Wrapped Flags */
MailboxIDPointer.Append("1B55FA20AA6611CD9BC800AA002FC45A"); /* WrappedProvider UID (Mailbox Store Object) */
MailboxIDPointer.Append("0C000000"); /* Wrapped Type (Mailbox Store) */
MailboxIDPointer.Append(ConvertStringToHex(fqdn)); /* ServerShortname (FQDN) */
MailboxIDPointer.Append("00"); /* termination bit */
MailboxIDPointer.Append(ConvertStringToHex(legacyDN)); /* Returns the userDN of the impersonated user */
MailboxIDPointer.Append("00"); /* terminator bit */
service.ImpersonatedUserId = null;
return MailboxIDPointer.ToString();
static bool RedirectionUrlValidationCallback(String redirectionUrl)
bool redirectionValidated = false;
if (redirectionUrl.Equals("https://SampleUrl/autodiscover/autodiscover.xml"))
redirectionValidated = true;
return redirectionValidated;
public String GetIntiatorEntryID(string domainName)
String result = String.Empty;
//// Bind to EWS
//ExchangeService service = ExchangeConnection.ExchangeService();
//service.ImpersonatedUserId =
//new ImpersonatedUserId(ConnectingIdType.SmtpAddress, "[email protected]");
//// Get LegacyDN Using the function above this one
string sharedByLegacyDN = domainName;
// A conversion function from earlier
string legacyDNinHex = ConvertStringToHex(sharedByLegacyDN);
StringBuilder addBookEntryId = new StringBuilder();
addBookEntryId.Append("00000000"); /* Flags */
addBookEntryId.Append("DCA740C8C042101AB4B908002B2FE182"); /* ProviderUID */
addBookEntryId.Append("01000000"); /* Version */
addBookEntryId.Append("00000000"); /* Type - 00 00 00 00 = Local Mail User */
addBookEntryId.Append(legacyDNinHex); /* Returns the userDN of the impersonated user */
addBookEntryId.Append("00"); /* terminator bit */
result = addBookEntryId.ToString();
//service.ImpersonatedUserId = null;
return result;
public string ConvertStringToHex(string input)
// Take our input and break it into an array
char[] arrInput = input.ToCharArray();
String result = String.Empty;
// For each set of characters
foreach (char element in arrInput)
if (String.IsNullOrEmpty(result))
result = String.Format("{0:X2}", Convert.ToUInt16(element)).ToString();
else
result += String.Format("{0:X2}", Convert.ToUInt16(element)).ToString();
return result.ToString();
public string CreateSharingMessageAttachment(string folderid, string userSharing, string userSharingEntryID, string invitationMailboxID, string userSharedTo, string dataType, string calendarName)
XmlDocument sharedMetadataXML = new XmlDocument();
string sharedMetaDataFilePath = string.Empty;
try
// Create a String that contains our new sharing_metadata.xml file
StringBuilder metadataString = new StringBuilder("<?xml version=\"1.0\"?>");
metadataString.Append("<SharingMessage xmlns=\"http://schemas.microsoft.com/sharing/2008\">");
metadataString.Append("<DataType>" + dataType + "</DataType>");
metadataString.Append("<Initiator>");
metadataString.Append("<Name>" + userSharing + "</Name>");
metadataString.Append("<SmtpAddress>" + "[email protected]" + "</SmtpAddress><EntryId>" + userSharingEntryID.Trim());
metadataString.Append("</EntryId>");
metadataString.Append("</Initiator>");
metadataString.Append("<Invitation>");
metadataString.Append("<Title>" + calendarName + "</Title>");
metadataString.Append("<Providers>");
metadataString.Append("<Provider Type=\"ms-exchange-internal\" TargetRecipients=\"" + userSharedTo + "\">");
metadataString.Append("<FolderId xmlns=\"http://schemas.microsoft.com/exchange/sharing/2008\">");
metadataString.Append(folderid);
metadataString.Append("</FolderId>");
metadataString.Append("<MailboxId xmlns=\"http://schemas.microsoft.com/exchange/sharing/2008\">");
metadataString.Append(invitationMailboxID);
metadataString.Append("</MailboxId>");
metadataString.Append("</Provider>");
metadataString.Append("</Providers>");
metadataString.Append("</Invitation>");
metadataString.Append("</SharingMessage>");
sharedMetadataXML.LoadXml(metadataString.ToString());
string tempPath = System.IO.Path.GetTempPath();
sharedMetaDataFilePath = tempPath + "sharing_metadata.xml";
sharedMetadataXML.Save(sharedMetaDataFilePath);
catch (Exception eg)
throw eg;
return sharedMetaDataFilePath;
public Dictionary<string, string> GetUserSettings(AutodiscoverService autodiscoverService)
GetUserSettingsResponse userresponse = autodiscoverService.GetUserSettings(
"[email protected]",
UserSettingName.UserDisplayName,
UserSettingName.InternalMailboxServerDN,
UserSettingName.UserDN
Dictionary<string, string> myUserSettings = new Dictionary<string, string>();
foreach (KeyValuePair<UserSettingName, Object> usersetting in userresponse.Settings)
if (usersetting.Key.ToString() == "InternalMailboxServerDN")
int lastIndexOfEqual = usersetting.Value.ToString().LastIndexOf("=");
string subString = usersetting.Value.ToString().Substring(lastIndexOfEqual + 1);
string value = subString;
myUserSettings.Add("InternalMailboxServer", value.ToString());
if (usersetting.Key.ToString() == "UserDisplayName")
string[] arrResult = usersetting.Value.ToString().Split('.');
myUserSettings.Add("UserDisplayName", arrResult[0].ToString());
if (usersetting.Key.ToString() == "UserDN")
string[] arrResult = usersetting.Value.ToString().Split('.');
myUserSettings.Add("UserDN", arrResult[0].ToString());
return myUserSettings;
private static byte[] HexStringToByteArray(string input)
byte[] Bytes;
int ByteLength;
string HexValue = "\x0\x1\x2\x3\x4\x5\x6\x7\x8\x9|||||||\xA\xB\xC\xD\xE\xF";
ByteLength = input.Length / 2;
Bytes = new byte[ByteLength];
for (int x = 0, i = 0; i < input.Length; i += 2, x += 1)
Bytes[x] = (byte)(HexValue[Char.ToUpper(input[i + 0]) - '0'] << 4);
Bytes[x] |= (byte)(HexValue[Char.ToUpper(input[i + 1]) - '0']);
return Bytes;Hi,
I'm trying to share a calendar through ews managed api v.2 and using exchange 2013 version.
i'm preparing a shared calendar and providing values to extended properties .
Here comes the problem when i'm trying to send the sharing request(email message)
The following is code snippet.
public void ShareCalendar(Calendar calendar)
ExchangeService service = new ExchangeService(ExchangeVersion.Exchange2013);
service.Credentials = new NetworkCredential("user1", "password", "domain");
service.Url = new Uri("https://sampleUrl/ews/exchange.asmx");
try
// Bind to the folder
//Folder folderStoreInfo;
//folderStoreInfo = Folder.Bind(service, calendar.ExchangeId);
//string EwsID = folderStoreInfo.Id.UniqueId;
string EwsID = calendar.FolderExchangeId;
// The value of folderidHex will be what we need to use for the FolderId in the xml file
AutodiscoverService autoDiscover = new AutodiscoverService(ExchangeVersion.Exchange2013);
autoDiscover.Credentials = new NetworkCredential("user1", "password", "domain");
autoDiscover.RedirectionUrlValidationCallback = RedirectionUrlValidationCallback;
Dictionary<string, string> userSettings = GetUserSettings(autoDiscover);
string folderidHex = GetConvertedEWSIDinHex(service, EwsID, "[email protected]");
string domainName = string.Empty;
string mailBoxServer = string.Empty;
string userName = string.Empty;
foreach (var item in userSettings)
switch (item.Key)
case "UserDN":
domainName = item.Value.ToString();
break;
case "InternalMailboxServer":
mailBoxServer = item.Value.ToString();
break;
case "UserDisplayName":
userName = item.Value.ToString();
break;
string entryId = GetIntiatorEntryID(domainName);
string mailboxId = GetInvitationMailboxId(mailBoxServer, domainName);
string sharedFilePath = CreateSharingMessageAttachment(folderidHex, userName, entryId, mailboxId, "[email protected]", "calendar", calendar.FolderName);
// Create a new message
EmailMessage invitationRequest = new EmailMessage(service);
invitationRequest.Subject = "I'd like to share my calendar with you";
invitationRequest.Body = "Sent by Exchange Administrator on behalf of user";
//invitationRequest.Culture = "en-US";
invitationRequest.Sensitivity = Sensitivity.Normal;
// Set a sharing specific property on the message
invitationRequest.ItemClass = "IPM.Sharing"; /* Constant Required Value [MS-ProtocolSpec] */
byte[] byteEntryId = HexStringToByteArray(entryId);
// This is the Guid of the Sharing Provider in Exchange, and it's value does not change
Guid binSharingProviderGuid = new Guid("{AEF00600-0000-0000-C000-000000000046}");
// Even though I don't think setting this property is mandatory,
// it just seemed like the right thing to do and it works so I \
// ain't messin with it!
byte[] byteSharingProviderGuid = binSharingProviderGuid.ToByteArray();
string strPRBODYHTML = "<html dir=\"ltr\">\r\n<head>\r\n<meta http-equiv=\"Content-Type\" content=\"text/html; charset=iso-8859-1\">\r\n<meta name=\"GENERATOR\"
content=\"MSHTML 8.00.7601.17514\">\r\n<style id=\"owaParaStyle\">P {\r\n MARGIN-TOP: 0px; MARGIN-BOTTOM: 0px \r\n}\r\n</style>\r\n</head>\r\n<body fPStyle=\"1\" ocsi=\"0\">\r\n<tt>\r\n<pre>SharedByUserDisplayName
(SharedByUserSmtpAddress) has invited you to view his or her Microsoft Exchange Calendar.\r\n\r\nFor instructions on how to view shared folders on Exchange, see the following article:\r\n\r\nhttp://go.microsoft.com/fwlink/?LinkId=57561\r\n\r\n*~*~*~*~*~*~*~*~*~*\r\n\r\n</pre>\r\n</tt>\r\n<div>\r\n<div
style=\"direction: ltr;font-family: Tahoma;color: #000000;font-size: 10pt;\">this is a test message</div>\r\n</div>\r\n</body>\r\n</html>\r\n";
string strBODY = @"
SharedByUserDisplayName (SharedByUserSmtpAddress) has invited you to view his or
her Microsoft Exchange Calendar.
For instructions on how to view shared folders on Exchange, see the
following article:
http://go.microsoft.com/fwlink/?LinkId=57561
*~*~*~*~*~*~*~*~*~*
test body
// Convert these to hex and binary equivelants to assign to their relevant
// extended properties
string hexPRBODYHTML = ConvertStringToHex(strPRBODYHTML);
byte[] binPRBODYHTML = HexStringToByteArray(hexPRBODYHTML);
Guid PropertySetSharing = Guid.Parse("00062040-0000-0000-C000-000000000046");//constant
Guid PropertySetInternetHeaders = Guid.Parse("00020386-0000-0000-C000-000000000046");//constant
ExtendedPropertyDefinition PidLidSharingProviderGuidProperty = new ExtendedPropertyDefinition(PropertySetSharing, 0x8A01, MapiPropertyType.CLSID);
ExtendedPropertyDefinition ConversationIdProperty = new ExtendedPropertyDefinition(0x3013, MapiPropertyType.Binary);
// Sharing Properties (in order of reference according to protocol examples in: [MS-OXSHARE])
// Additional Property Constraints
// [MS-OXSHARE] 2.2.5.2
ExtendedPropertyDefinition PidTagMessageClass = new ExtendedPropertyDefinition(0x001A, MapiPropertyType.String);
// [MS-OXSHARE] 2.2.5.1
//ExtendedPropertyDefinition PidNameContentClass = new ExtendedPropertyDefinition(DefaultExtendedPropertySet.InternetHeaders, "Content-Class", MapiPropertyType.String);
ExtendedPropertyDefinition PidNameContentClass = new ExtendedPropertyDefinition(PropertySetInternetHeaders, "Content-class", MapiPropertyType.String);
// Common Message Object Properties
// [MS-OXSHARE] 2.2.1
ExtendedPropertyDefinition PidTagNormalizedSubject = new ExtendedPropertyDefinition(0x0E1D, MapiPropertyType.String);
// The PidTagSubjectPrefix is a zero-length string, so I do not set it
// ExtendedPropertyDefinition PidTagSubjectPrefix = new ExtendedPropertyDefinition(0x003D, MapiPropertyType.String);
// Sharing Object Message Properties
// [MS-OXSHARE] 2.2.2.12
ExtendedPropertyDefinition PidLidSharingProviderGuid = new ExtendedPropertyDefinition(PropertySetSharing, 0x8A01, MapiPropertyType.Binary);
// [MS-OXSHARE] 2.2.2.13
ExtendedPropertyDefinition PidNameXSharingProviderGuid = new ExtendedPropertyDefinition(PropertySetInternetHeaders, "X-Sharing-Provider-GUID", MapiPropertyType.String);
// [MS-OXSHARE] 2.2.2.14
ExtendedPropertyDefinition PidLidSharingProviderName = new ExtendedPropertyDefinition(PropertySetSharing, 0x8A02, MapiPropertyType.String);
// [MS-OXSHARE] 2.2.2.15
ExtendedPropertyDefinition PidNameXSharingProviderName = new ExtendedPropertyDefinition(PropertySetInternetHeaders, "X-Sharing-Provider-Name", MapiPropertyType.String);
// [MS-OXSHARE] 2.2.2.16
ExtendedPropertyDefinition PidLidSharingProviderUrl = new ExtendedPropertyDefinition(PropertySetSharing, 0x8A03, MapiPropertyType.String);
// [MS-OXSHARE] 2.2.2.17
ExtendedPropertyDefinition PidNameXSharingProviderUrl = new ExtendedPropertyDefinition(PropertySetInternetHeaders, "X-Sharing-Provider-URL", MapiPropertyType.String);
// [MS-OXSHARE] 2.2.2.5
ExtendedPropertyDefinition PidLidSharingFlavor = new ExtendedPropertyDefinition(PropertySetSharing, 0x8A18, MapiPropertyType.Integer);
// [MS-OXSHARE] 2.2.2.6
ExtendedPropertyDefinition PidNameXSharingFlavor = new ExtendedPropertyDefinition(PropertySetInternetHeaders, "X-Sharing-Flavor", MapiPropertyType.String);
// [MS-OXSHARE] 2.2.2.1
ExtendedPropertyDefinition PidLidSharingCapabilities = new ExtendedPropertyDefinition(PropertySetSharing, 0x8A17, MapiPropertyType.Integer);
// [MS-OXSHARE] 2.2.2.2
ExtendedPropertyDefinition PidNameXSharingCapabilities = new ExtendedPropertyDefinition(PropertySetInternetHeaders, "X-Sharing-Capabilities", MapiPropertyType.String);
// Sections 2.3 and 2.4 are also zero-length strings, so I won't set those either
// [MS-OXSHARE] 2.2.2.3
// ExtendedPropertyDefinition PidLidSharingConfigurationUrl = new //ExtendedPropertyDefinition(PropertySetSharing, 0x8A24, MapiPropertyType.String);
// [MS-OXSHARE] 2.2.2.4
//ExtendedPropertyDefinition PidNameXSharingConfigUrl = new //ExtendedPropertyDefinition(DefaultExtendedPropertySet.InternetHeaders, "X-Sharing-Config-Url", MapiPropertyType.String);
// [MS-OXSHARE] 2.2.2.10
ExtendedPropertyDefinition PidLidSharingLocalType = new ExtendedPropertyDefinition(PropertySetSharing, 0x8A14, MapiPropertyType.String);
// [MS-OXSHARE] 2.2.2.11
ExtendedPropertyDefinition PidNameXSharingLocalType = new ExtendedPropertyDefinition(PropertySetInternetHeaders, "X-Sharing-Local-Type", MapiPropertyType.String);
// [MS-OXSHARE] 2.2.2.7
ExtendedPropertyDefinition PidLidSharingInitiatorEntryId = new ExtendedPropertyDefinition(PropertySetSharing, 0x8A09, MapiPropertyType.Binary);
// [MS-OXSHARE] 2.2.2.8
ExtendedPropertyDefinition PidLidSharingInitiatorName = new ExtendedPropertyDefinition(PropertySetSharing, 0x8A07, MapiPropertyType.String);
// [MS-OXSHARE] 2.2.2.9
ExtendedPropertyDefinition PidLidSharingInitiatorSMTP = new ExtendedPropertyDefinition(PropertySetSharing, 0x8A08, MapiPropertyType.String);
// [MS-OXSHARE] 2.2.3.1
ExtendedPropertyDefinition PidLidSharingRemoteName = new ExtendedPropertyDefinition(PropertySetSharing, 0x8A05, MapiPropertyType.String);
// [MS-OXSHARE] 2.2.3.2
ExtendedPropertyDefinition PidNameXSharingRemoteName = new ExtendedPropertyDefinition(PropertySetInternetHeaders, "X-Sharing-Remote-Name", MapiPropertyType.String);
// [MS-OXSHARE] 2.2.3.5
ExtendedPropertyDefinition PidLidSharingRemoteType = new ExtendedPropertyDefinition(PropertySetSharing, 0x8A1D, MapiPropertyType.String);
// [MS-OXSHARE] 2.2.3.6
ExtendedPropertyDefinition PidNameXSharingRemoteType = new ExtendedPropertyDefinition(PropertySetInternetHeaders, "X-Sharing-Remote-Type", MapiPropertyType.String);
// [MS-OXSHARE] 2.2.3.7
ExtendedPropertyDefinition PidLidSharingRemoteUid = new ExtendedPropertyDefinition(PropertySetSharing, 0x8A06, MapiPropertyType.String);
// [MS-OXSHARE] 2.2.3.8
ExtendedPropertyDefinition PidNameXSharingRemoteUid = new ExtendedPropertyDefinition(PropertySetInternetHeaders, "X-Sharing-Remote-Uid", MapiPropertyType.String);
// [MS-OXSHARE] 2.2.3.3
ExtendedPropertyDefinition PidLidSharingRemoteStoreUid = new ExtendedPropertyDefinition(PropertySetSharing, 0x8A48, MapiPropertyType.String);
// [MS-OXSHARE] 2.2.3.4
ExtendedPropertyDefinition PidNameXSharingRemoteStoreUid = new ExtendedPropertyDefinition(PropertySetInternetHeaders, "X-Sharing-Remote-Store-Uid", MapiPropertyType.String);
//From troubleshooting I noticed I was missing
ExtendedPropertyDefinition PidTagPriority = new ExtendedPropertyDefinition(0x0026, MapiPropertyType.Integer);
ExtendedPropertyDefinition PidTagSensitivity = new ExtendedPropertyDefinition(0x0036, MapiPropertyType.Integer);
ExtendedPropertyDefinition PR_BODY_HTML = new ExtendedPropertyDefinition(0x1013, MapiPropertyType.Binary); //PR_BOD
ExtendedPropertyDefinition PR_BODY = new ExtendedPropertyDefinition(0x1000, MapiPropertyType.String);
ExtendedPropertyDefinition RecipientReassignmentProhibited = new ExtendedPropertyDefinition(0x002b, MapiPropertyType.Boolean);
// Section 2.2.1
invitationRequest.SetExtendedProperty(PidTagNormalizedSubject, "I'd like to share my calendar with you"); /* Constant Required Value [MS-OXSHARE] 2.2.1 */
//invitationRequest.SetExtendedProperty(PidTagSubjectPrefix, String.Empty); /* Constant Required Value [MS-OXSHARE] 2.2.1 */
// Section 2.2.2
invitationRequest.SetExtendedProperty(PidLidSharingCapabilities, 0x40220); /* value for Special Folders */
invitationRequest.SetExtendedProperty(PidNameXSharingCapabilities, "40220"); /* Test representation of SharingCapabilities value */
//invitationRequest.SetExtendedProperty(PidLidSharingConfigurationUrl, String.Empty); /* Zero-Length String [MS-OXSHARE] 2.2.2.3 */
//invitationRequest.SetExtendedProperty(PidNameXSharingConfigUrl, String.Empty); /* Zero-Length String [MS-OXSHARE] 2.2.2.4 */
invitationRequest.SetExtendedProperty(PidLidSharingFlavor, 0x20310); /* Indicates Invitation for a special folder [MS-OXSHARE] 2.2.2.5 */
invitationRequest.SetExtendedProperty(PidNameXSharingFlavor, "20310"); /* Text representation of SharingFlavor value [MS-OXSHARE] 2.2.2.6 */
invitationRequest.SetExtendedProperty(PidLidSharingInitiatorEntryId, byteEntryId); /* Value from the Initiator/EntryId value in the Sharing Message attachment .xml document */
invitationRequest.SetExtendedProperty(PidLidSharingInitiatorSMTP, "[email protected]"); /* Value from Initiator/Smtp Address in the Sharing message attachment .xml document */
invitationRequest.SetExtendedProperty(PidLidSharingInitiatorName, "User1"); /* Value from Initiator/Name Address in the Sharing message attachment .xml document */
invitationRequest.SetExtendedProperty(PidLidSharingLocalType, "IPF.Appointment"); /* MUST be set to PidTagContainerClass of folder to be shared */
invitationRequest.SetExtendedProperty(PidNameXSharingLocalType, "IPF.Appointment"); /* MUST be set to same value as PidLidSharingLocalType */
invitationRequest.SetExtendedProperty(PidLidSharingProviderGuid, byteSharingProviderGuid); /* Constant Required Value [MS-OXSHARE] 2.2.2.12 */
invitationRequest.SetExtendedProperty(PidNameXSharingProviderGuid, "AEF0060000000000C000000000000046"); /* Constant Required Value [MS-OXSHARE] 2.2.2.13 */
invitationRequest.SetExtendedProperty(PidLidSharingProviderName, "Microsoft Exchange"); /* Constant Required Value [MS-OXSHARE] 2.2.2.14 */
invitationRequest.SetExtendedProperty(PidNameXSharingProviderName, "Microsoft Exchange"); /* Constant Required Value [MS-OXSHARE] 2.2.2.15] */
invitationRequest.SetExtendedProperty(PidLidSharingProviderUrl, "http://www.microsoft.com/exchange"); /* Constant Required Value [MS-OXSHARE] 2.2.2.16 */
invitationRequest.SetExtendedProperty(PidNameXSharingProviderUrl, "http://www.microsoft.com/exchange"); /* Constant Required Value [MS-OXSHARE] 2.2.2.17 */
// Section 2.2.3
invitationRequest.SetExtendedProperty(PidLidSharingRemoteName, calendar.FolderName); /* MUST be set to PidTagDisplayName of the folder being shared */
invitationRequest.SetExtendedProperty(PidNameXSharingRemoteName, calendar.FolderName); /* MUST be set to same value as PidLidSharingRemoteName */
invitationRequest.SetExtendedProperty(PidLidSharingRemoteStoreUid, mailboxId); /* Must be set to PidTagStoreEntryId of the folder being shared */
invitationRequest.SetExtendedProperty(PidNameXSharingRemoteStoreUid, mailboxId); /* MUST be set to same value as PidLidSharingRemoteStoreUid */
invitationRequest.SetExtendedProperty(PidLidSharingRemoteType, "IPF.Appointment"); /* Constant Required Value [MS-OXSHARE] 2.2.3.5 */
invitationRequest.SetExtendedProperty(PidNameXSharingRemoteType, "IPF.Appointment"); /* Constant Required Value [MS-OXSHARE] 2.2.3.6 */
invitationRequest.SetExtendedProperty(PidLidSharingRemoteUid, folderidHex); /* MUST be set to PidTagEntryId of folder being shared */
invitationRequest.SetExtendedProperty(PidNameXSharingRemoteUid, folderidHex); /* Must be set to same value as PidLidSharingRemoteUid */
// Section 2.2.5
invitationRequest.SetExtendedProperty(PidNameContentClass, "Sharing"); /* Constant Required Value [MS-ProtocolSpec] */
invitationRequest.SetExtendedProperty(PidTagMessageClass, "IPM.Sharing"); /* Constant Required Value [MS-ProtocolSpec] */
// ********* ADDITIONAL MAPPED PROPERTIES IM FINDING AS I TROUBLESHOOT ********************** //
invitationRequest.SetExtendedProperty(PidTagPriority, 0); /* From troubleshooting I'm just trying to match up values that were missing */
invitationRequest.SetExtendedProperty(PidTagSensitivity, 0); /* From troubleshooting as well */
invitationRequest.SetExtendedProperty(PR_BODY_HTML, binPRBODYHTML); /* From troubleshooting OWA error pointing to serializing HTML failing */
invitationRequest.SetExtendedProperty(PR_BODY, strBODY);
invitationRequest.SetExtendedProperty(RecipientReassignmentProhibited, true); /* Because it seemed like a good idea */
// Add a file attachment by using a stream
// We need to do the following in order to prevent 3 extra bytes from being prepended to the attachment
string sharMetadata = File.ReadAllText(sharedFilePath, Encoding.ASCII);
byte[] fileContents;
UTF8Encoding encoding = new System.Text.UTF8Encoding();
fileContents = encoding.GetBytes(sharMetadata);
//fileContents = File.ReadAllBytes(sharedFilePath);
//// fileContents is a Stream object that represents the content of the file to attach.
invitationRequest.Attachments.AddFileAttachment("sharing_metadata.xml", fileContents);
////invitationRequest.Attachments.AddFileAttachment(sharedFilePath);
//// This is where we set those "special" headers and other pertinent
//// information I noted in Part 1 of this series...
//Attachment thisAttachment = invitationRequest.Attachments[0];
//thisAttachment.ContentType = "application/x-sharing-metadata-xml";
//thisAttachment.Name = "sharing_metadata.xml";
//thisAttachment.IsInline = false;
// Add recipient info and send message
invitationRequest.ToRecipients.Add(new EmailAddress() { Address = "[email protected]" });
invitationRequest.SendAndSaveCopy();
// I always end my methods by returning the EWS
// impersonated user to null to clean up
service.ImpersonatedUserId = null;
catch (Exception ex)
public String GetConvertedEWSIDinHex(ExchangeService esb, String sID, String strSMTPAdd)
// Create a request to convert identifiers.
AlternateId objAltID = new AlternateId();
objAltID.Format = IdFormat.EwsId;
objAltID.Mailbox = strSMTPAdd;
objAltID.UniqueId = sID;
//Convert PR_ENTRYID identifier format to an EWS identifier.
AlternateIdBase objAltIDBase = esb.ConvertId(objAltID, IdFormat.HexEntryId);
AlternateId objAltIDResp = (AlternateId)objAltIDBase;
return objAltIDResp.UniqueId.ToString();
public String GetInvitationMailboxId(string mailBoxServer, string domainName)
ExchangeService service = new ExchangeService(ExchangeVersion.Exchange2013);
service.ImpersonatedUserId = new ImpersonatedUserId(ConnectingIdType.SmtpAddress, "[email protected]");
// Generate The Store Entry Id for the impersonated user
StringBuilder MailboxIDPointer = new StringBuilder();
string fqdn = mailBoxServer;
string legacyDN = domainName;
MailboxIDPointer.Append("00000000"); /* Flags */
MailboxIDPointer.Append("38A1BB1005E5101AA1BB08002B2A56C2"); /* ProviderUID */
MailboxIDPointer.Append("00"); /* Version */
MailboxIDPointer.Append("00"); /* Flag */
MailboxIDPointer.Append("454D534D44422E444C4C00000000"); /* DLLFileName */
MailboxIDPointer.Append("00000000"); /* Wrapped Flags */
MailboxIDPointer.Append("1B55FA20AA6611CD9BC800AA002FC45A"); /* WrappedProvider UID (Mailbox Store Object) */
MailboxIDPointer.Append("0C000000"); /* Wrapped Type (Mailbox Store) */
MailboxIDPointer.Append(ConvertStringToHex(fqdn)); /* ServerShortname (FQDN) */
MailboxIDPointer.Append("00"); /* termination bit */
MailboxIDPointer.Append(ConvertStringToHex(legacyDN)); /* Returns the userDN of the impersonated user */
MailboxIDPointer.Append("00"); /* terminator bit */
service.ImpersonatedUserId = null;
return MailboxIDPointer.ToString();
static bool RedirectionUrlValidationCallback(String redirectionUrl)
bool redirectionValidated = false;
if (redirectionUrl.Equals("https://SampleUrl/autodiscover/autodiscover.xml"))
redirectionValidated = true;
return redirectionValidated;
public String GetIntiatorEntryID(string domainName)
String result = String.Empty;
//// Bind to EWS
//ExchangeService service = ExchangeConnection.ExchangeService();
//service.ImpersonatedUserId =
//new ImpersonatedUserId(ConnectingIdType.SmtpAddress, "[email protected]");
//// Get LegacyDN Using the function above this one
string sharedByLegacyDN = domainName;
// A conversion function from earlier
string legacyDNinHex = ConvertStringToHex(sharedByLegacyDN);
StringBuilder addBookEntryId = new StringBuilder();
addBookEntryId.Append("00000000"); /* Flags */
addBookEntryId.Append("DCA740C8C042101AB4B908002B2FE182"); /* ProviderUID */
addBookEntryId.Append("01000000"); /* Version */
addBookEntryId.Append("00000000"); /* Type - 00 00 00 00 = Local Mail User */
addBookEntryId.Append(legacyDNinHex); /* Returns the userDN of the impersonated user */
addBookEntryId.Append("00"); /* terminator bit */
result = addBookEntryId.ToString();
//service.ImpersonatedUserId = null;
return result;
public string ConvertStringToHex(string input)
// Take our input and break it into an array
char[] arrInput = input.ToCharArray();
String result = String.Empty;
// For each set of characters
foreach (char element in arrInput)
if (String.IsNullOrEmpty(result))
result = String.Format("{0:X2}", Convert.ToUInt16(element)).ToString();
else
result += String.Format("{0:X2}", Convert.ToUInt16(element)).ToString();
return result.ToString();
public string CreateSharingMessageAttachment(string folderid, string userSharing, string userSharingEntryID, string invitationMailboxID, string userSharedTo, string dataType, string calendarName)
XmlDocument sharedMetadataXML = new XmlDocument();
string sharedMetaDataFilePath = string.Empty;
try
// Create a String that contains our new sharing_metadata.xml file
StringBuilder metadataString = new StringBuilder("<?xml version=\"1.0\"?>");
metadataString.Append("<SharingMessage xmlns=\"http://schemas.microsoft.com/sharing/2008\">");
metadataString.Append("<DataType>" + dataType + "</DataType>");
metadataString.Append("<Initiator>");
metadataString.Append("<Name>" + userSharing + "</Name>");
metadataString.Append("<SmtpAddress>" + "[email protected]" + "</SmtpAddress><EntryId>" + userSharingEntryID.Trim());
metadataString.Append("</EntryId>");
metadataString.Append("</Initiator>");
metadataString.Append("<Invitation>");
metadataString.Append("<Title>" + calendarName + "</Title>");
metadataString.Append("<Providers>");
metadataString.Append("<Provider Type=\"ms-exchange-internal\" TargetRecipients=\"" + userSharedTo + "\">");
metadataString.Append("<FolderId xmlns=\"http://schemas.microsoft.com/exchange/sharing/2008\">");
metadataString.Append(folderid);
metadataString.Append("</FolderId>");
metadataString.Append("<MailboxId xmlns=\"http://schemas.microsoft.com/exchange/sharing/2008\">");
metadataString.Append(invitationMailboxID);
metadataString.Append("</MailboxId>");
metadataString.Append("</Provider>");
metadataString.Append("</Providers>");
metadataString.Append("</Invitation>");
metadataString.Append("</SharingMessage>");
sharedMetadataXML.LoadXml(metadataString.ToString());
string tempPath = System.IO.Path.GetTempPath();
sharedMetaDataFilePath = tempPath + "sharing_metadata.xml";
sharedMetadataXML.Save(sharedMetaDataFilePath);
catch (Exception eg)
throw eg;
return sharedMetaDataFilePath;
public Dictionary<string, string> GetUserSettings(AutodiscoverService autodiscoverService)
GetUserSettingsResponse userresponse = autodiscoverService.GetUserSettings(
"[email protected]",
UserSettingName.UserDisplayName,
UserSettingName.InternalMailboxServerDN,
UserSettingName.UserDN
Dictionary<string, string> myUserSettings = new Dictionary<string, string>();
foreach (KeyValuePair<UserSettingName, Object> usersetting in userresponse.Settings)
if (usersetting.Key.ToString() == "InternalMailboxServerDN")
int lastIndexOfEqual = usersetting.Value.ToString().LastIndexOf("=");
string subString = usersetting.Value.ToString().Substring(lastIndexOfEqual + 1);
string value = subString;
myUserSettings.Add("InternalMailboxServer", value.ToString());
if (usersetting.Key.ToString() == "UserDisplayName")
string[] arrResult = usersetting.Value.ToString().Split('.');
myUserSettings.Add("UserDisplayName", arrResult[0].ToString());
if (usersetting.Key.ToString() == "UserDN")
string[] arrResult = usersetting.Value.ToString().Split('.');
myUserSettings.Add("UserDN", arrResult[0].ToString());
return myUserSettings;
private static byte[] HexStringToByteArray(string input)
byte[] Bytes;
int ByteLength;
string HexValue = "\x0\x1\x2\x3\x4\x5\x6\x7\x8\x9|||||||\xA\xB\xC\xD\xE\xF";
ByteLength = input.Length / 2;
Bytes = new byte[ByteLength];
for (int x = 0, i = 0; i < input.Length; i += 2, x += 1)
Bytes[x] = (byte)(HexValue[Char.ToUpper(input[i + 0]) - '0'] << 4);
Bytes[x] |= (byte)(HexValue[Char.ToUpper(input[i + 1]) - '0']);
return Bytes;
am i missing anything
any help is appreciated
Thanks in advance -
Annoture - Metadata Bridging Solution for Aperture and iView
Aperture and iView users:
I just released Annoture, a metadata bridging solution for Aperture and iView MediaPro! With Annoture, you’re just a click away from sharing metadata between these two popular image management and cataloguing applications. Spend more time working with your decisive moments than worrying about double-entry and incomplete metadata!
Annoture lets you transfer annotations from iView MediaPro catalogs to Aperture projects and albums and back. This two-way transfer of IPTC and metadata information means you are not tied to any one application for your image management and workflow needs. Annoture also features a modular interface that can be extended to support additional applications in the future.
http://www.tow.com/software/annoture/
Users of Aperture and iView can download a fully-functional version of Annoture. The unregistered version will occasionally display a reminder to register, and all images processed in Aperture by Annoture will have a custom “Annotated with Annoture!” tag added. You can remove these items with the full version after purchasing and entering your license code.
Enjoy!
-adamCongratulations on getting this working and available so quickly! I bet many late nights went into this
It's definitely providing some motivation for me to learn more Applescript... -
Registering business event definitions in soa infrastructure
Hi,
What do I need to do to register events into the soa infrastructure so components can publish and subscribe to them?
Everything I found was to create an empty composite, use the wizard to create new business event, add the event and save. But that does not register it in the soa infrastructure... when I go to Enterprise Manager | Business events --> there are not definitions....
What else needs to happen?
Any help greatly appreciated!Events are only shown when there are subscribers to that particular event. What you also may consider is placing the event definition in the MDS. In this case you can reuse the event by just pointing to the shared metadata and event definitions aren't fragemented over several composites.
Regards,
Melvin -
Error while deploying SOA composite via ant
I am getting following error while deploying SOA composite through ant from SOA server (UNIX).It is unable to get mds configuration.
Jdeveloper is not installed in SOA server.
I am trying to copy the SOA project from local machine to SOA server and trying to deploy from SOA server.
Error
Parse of component type files failed, check the adf-config.xml file : "oracle.fabric.common.FabricException: oracle.mds.config.MDSConfigurationException: MDS-01330: unable to load MDS configuration document
MDS-01329: unable to load element "persistence-config"
MDS-01370: MetadataStore configuration for metadata-store-usage "mstore-usage_1" is invalid.
MDS-00503: The metadata path "/u01/orasoa/Oracle/Middleware/Oracle_SOA1/integration" does not contain any valid directories.
I checked /u01/orasoa/Oracle/Middleware/Oracle_SOA1 directory. Integretion directory is not available.
Am I missing anything?
*Please advise.*
build.propeties
============
# build file for HelloWorldComposite
composite.name=AntScriptDeployPOCService
# revision of the composite
composite.revision=1.0
# Set oracle.home to <JDEV_HOME>/jdeveloper, where <JDEV_HOME> is JDEV # installation directory
#oracle.home=C:/Oracle/Middleware/jdeveloper
oracle.home=/u01/orasoa/Oracle/Middleware/Oracle_SOA1
# soa-server side oracle home directory - needed for deployment plan
# and the weblogic sca library deployment
soa.server.oracle.home=/u01/orasoa/Oracle/Middleware/Oracle_SOA1
###### Deployment server connection information
# the admin server connection information
admin.server.host=10.40.237.106
admin.server.port=7001
# the domain where soa infra is installed
server.domain.name=soa_domain
# connection information for the managed server, used for soa-deployment
managed.server.host=10.40.237.106
managed.server.port=8001
# User and credentials for the servers
server.user=weblogic
server.password=<password>
# wls server where soa is targeted.
server.targets=soa_server1
#local.java.home=C:/Oracle/Middleware/jdk160_14_R27.6.5-32
local.java.home=/u01/orasoa/Oracle/Middleware/jdk160_14_R27.6.5-32
Build.xml
<?xml version="1.0" encoding="UTF-8" ?>
<project name="AntScriptDeployPOCService" default="all">
<!-- build.properties -->
<property file="build.properties"/>
<property name="deploy.dir" value="../deploy"/>
<!-- Add targets here -->
<target name="compile-package">
<property name="sca-inf.classes.dir" value="../SCA-INF/classes"/>
<mkdir dir="${sca-inf.classes.dir}"/>
<ant antfile="${oracle.home}/bin/ant-sca-package.xml" target="package" inheritall="false">
<property name="oracle.home" value="${oracle.home}"/>
<property name="compositeDir" value="${basedir}/../"/>
<!-- needed for adf config -->
<property name="scac.application.home" value="${basedir}/../.."/>
<!-- name of the composite -->
<property name="compositeName" value="${composite.name}"/>
<!-- revision of the composite -->
<property name="revision" value="${composite.revision}"/>
<!-- java.passed.home passed to scac, this property will be
overwritten to the env.JAVA_HOME if such env variable is defined in OS level-->
<property name="java.passed.home" value="${local.java.home}"/>
<!--property name="java.passed.home" value="C:/Oracle/Middleware/jdk160_14_R27.6.5-32"-->
</ant>
</target>
<target name="deploy">
<condition property="deploymentplan.name" value="null">
<not>
<isset property="${deploymentplan.name}"/>
</not>
</condition>
<echo>Deploying to http://${managed.server.host}:${managed.server.port}/soa-infra/deployer</echo>
<ant antfile="${oracle.home}/bin/ant-sca-deploy.xml" target="deploy" inheritall="false">
<!-- reformat of prop names -->
<property name="user" value="${server.user}"/>
<property name="password" value="${server.password}"/>
<!-- create the url for deployment -->
<property name="serverURL" value="http://${managed.server.host}:${managed.server.port}/soa-infra/deployer"/>
<!-- location of the sar -->
<property name="sarLocation" value="${deploy.dir}/sca_${composite.name}_rev${composite.revision}.jar"/>
<!-- force overwrite if already there -->
<property name="overwrite" value="true"/>
<!-- configplan-->
<property name="configplan" value="${deploymentplan.name}"/>
</ant>
</target>
<target name="all" depends="compile-package,deploy"/>
</project>Check whether the adf-config.xml file in your app is having proper mds path similar to this:
<adf-mds-config xmlns="http://xmlns.oracle.com/adf/mds/config">
<mds-config xmlns="http://xmlns.oracle.com/mds/config">
<persistence-config>
<metadata-namespaces>
<namespace metadata-store-usage="mstore-usage_1" path="/soa/shared"/>
</metadata-namespaces>
<metadata-store-usages>
<metadata-store-usage id="mstore-usage_1">
<metadata-store class-name="oracle.mds.persistence.stores.file.FileMetadataStore">
<property value="${oracle.home}/integration"
name="metadata-path"/>
<property value="seed" name="partition-name"/>
</metadata-store>
</metadata-store-usage>
</metadata-store-usages>
</persistence-config>
</mds-config>
</adf-mds-config>
" -
ORABPEL-09705 error while deploying SOA project
Hi,
I am trying to use the xsd file which is there in my metadata store, in my SOA project.
DB based Meta data store is working fine.
But when I am using file based metadata store, it is throwing ORABPEL-09705 error as mentioned below
"Caused By: java.lang.RuntimeException: ORABPEL-09705
Could not initialize variable.
An error occurs while initializing BPEL variable Receive_Read_InputVariable_1; the schema processor cannot find the element {http://www.edifecs.com/xdata/200}Transaction-850 in the following schemas: oracle.fabric.common.wsdl.SchemaManager@1dfaa55.
The XSD element on which the variable was based was not properly defined in XSD or the WSDL.
Ensure that the element named in the error message is valid in the XSD or the WSDL."
Please help me in solving this issue.
Thanks,
MonicaCheck whether the adf-config.xml file in your app is having proper mds path similar to this:
<adf-mds-config xmlns="http://xmlns.oracle.com/adf/mds/config">
<mds-config xmlns="http://xmlns.oracle.com/mds/config">
<persistence-config>
<metadata-namespaces>
<namespace metadata-store-usage="mstore-usage_1" path="/soa/shared"/>
</metadata-namespaces>
<metadata-store-usages>
<metadata-store-usage id="mstore-usage_1">
<metadata-store class-name="oracle.mds.persistence.stores.file.FileMetadataStore">
<property value="${oracle.home}/integration"
name="metadata-path"/>
<property value="seed" name="partition-name"/>
</metadata-store>
</metadata-store-usage>
</metadata-store-usages>
</persistence-config>
</mds-config>
</adf-mds-config>
" -
Ant Scripts: Issue while running , getting BPM-71504: Unexpected error pars
Hi
I am running ant scripts through command prompt on the server itself.
And on evry run I am getting the same error I followed this url Steps to deploy an bpel project using ANT scripts.. to start up but couldnt find resolution to my issue
<?xml version = '1.0' encoding = 'UTF-8'?>
<Faults>
<Fault>
<severity>error</severity>
<loc/>
<line/>
<col/>
<file/>
<name/>
<fix/>
<msg>BPM-71504: Unexpected error parsing 'oramds:/soa/shared/workflow/TaskEvidenceService.xsd'. Cause: oracle.mds.exception.MDSException: MDS-00054: The file to be loaded oramds:/soa/shared/workflow/TaskEvidenceService.xsd does not exist.. Action: Verify that file is valid and accessible</msg>
</Fault>
<Fault>
<severity>error</severity>
<loc/>
<line/>
<col/>
<file/>
<name/>
<fix/>
<msg>BPM-71504: Unexpected error parsing 'oramds:/soa/shared/workflow/WorkflowCommon.xsd'. Cause: oracle.mds.exception.MDSException: MDS-00054: The file to be loaded oramds:/soa/shared/workflow/WorkflowCommon.xsd does not exist.. Action: Verify that file is valid and accessible</msg>
</Fault>
<Fault>
<severity>error</severity>
<loc/>
<line/>
<col/>
<file/>
<name/>
<fix/>
<msg>BPM-71504: Unexpected error parsing 'oramds:/soa/shared/workflow/WorkflowTask.xsd'. Cause: oracle.mds.exception.MDSException: MDS-00054: The file to be loaded oramds:/soa/shared/workflow/WorkflowTask.xsd does not exist.. Action: Verify that file is valid and accessible</msg>
</Fault>
</Faults>
Looking forward for a response...
Thanks in advancehi I have configured the adf-config.xml but still getting the same error.
Please let me know what i am doing wrong
<?xml version="1.0" encoding="windows-1252" ?>
<adf-config xmlns="http://xmlns.oracle.com/adf/config"
xmlns:config="http://xmlns.oracle.com/bc4j/configuration"
xmlns:adf="http://xmlns.oracle.com/adf/config/properties"
xmlns:sec="http://xmlns.oracle.com/adf/security/config">
<adf-adfm-config xmlns="http://xmlns.oracle.com/adfm/config">
<defaults useBindVarsForViewCriteriaLiterals="true"/>
<startup>
<amconfig-overrides>
<config:Database jbo.locking.mode="optimistic"/>
</amconfig-overrides>
</startup>
</adf-adfm-config>
<adf:adf-properties-child xmlns="http://xmlns.oracle.com/adf/config/properties">
<adf-property name="adfAppUID" value="AntApplication-7567"/>
</adf:adf-properties-child>
<sec:adf-security-child xmlns="http://xmlns.oracle.com/adf/security/config">
<CredentialStoreContext credentialStoreClass="oracle.adf.share.security.providers.jps.CSFCredentialStore"
credentialStoreLocation="../../src/META-INF/jps-config.xml"/>
</sec:adf-security-child>
<adf-mds-config xmlns="http://xmlns.oracle.com/adf/mds/config">
<mds-config xmlns="http://xmlns.oracle.com/mds/config">
<persistence-config>
<metadata-namespaces>
<namespace path="/soa/shared" metadata-store-usage="mstore-usage_3"/>
</metadata-namespaces>
<metadata-store-usages>
<metadata-store-usage id="mstore-usage_3">
<metadata-store class-name="oracle.mds.persistence.stores.file.FileMetadataStore">
<property name="metadata-path"
value="C:/Oracle/Middleware1/jdev/jdeveloper/integration"/>
<property name="partition-name" value="seed"/>
</metadata-store>
</metadata-store-usage>
</metadata-store-usages>
</persistence-config>
</mds-config>
</adf-mds-config>
</adf-config>
Regards.....
Edited by: bpm11gnewbie on Oct 7, 2012 10:16 PM -
Composite with dependency not working after soa server restart
Hello,
I have composite application that invokes another composite application. After deploying those work fine. But after restarting soa server the one having dependency does not work any more. To soa server log I get following:
<Jul 1, 2010 11:45:29 AM EEST> <Error> <oracle.integration.platform> <SOA-20003> <Unable to register service.
oracle.fabric.common.FabricException: Error in getting XML input stream: http://Yacico:8001/soa-infra/services/default/validationForCC/getStatusByCC?WSDL: Response: '503: Service Unavailable' for url: 'http://Yacico:8001/soa-infra/services/default/validationForCC/getStatusByCC?WSDL'
at oracle.fabric.common.metadata.MetadataManagerImpl.getInputStreamFromAbsoluteURL(MetadataManagerImpl.java:276)
Caused By: java.io.FileNotFoundException: Response: '503: Service Unavailable' for url: 'http://Yacico:8001/soa-infra/services/default/validationForCC/getStatusByCC?WSDL'
<Jul 1, 2010 11:45:30 AM EEST> <Error> <oracle.integration.platform> <SOA-20020> <Deployment of composite "POProcessing" failed: Unable to find a WSDL that has a definition for service {http://oracle.com/sca/soapservice/POProcessing/POProcessing/receivePO}receivePO and port execute_pt. Please make sure that the port attribute for the binding defined in the composite file is correct by checking the namespace, service name, and port name. In addition, check that the WSDL associated with the binding namespace is imported and currently reachable (check the import nodes at the top of the composite file). Finally, validate the HTTP proxy settings for the server..>
So POProcessing does not work any more after server restart. validationForCC works fine also after server restart. Url http://...validationForCC/getStatusByCC?WSDL points to wsdl file and is visible by browser.
I use soa suite 11g patch set 2 (11.1.1.3) running on redhat enterprise linux 5.
Any idea what is the problem?
Is it somehow possible to configure which composites are started first during server startup?
regards, Matti
Edited by: user10197965 on Jul 1, 2010 2:28 AMYes, I did that. I'm not all that happy about this as a solution either, but it's better than making multiple copies.
We have since found out that his is a known bug and that it is fixed in some, but not all, deployments.
-------- see below -------------
Composites With WSDL Dependencies Fail To Deploy Following SOA Server Restart [ID 1272070.1]
Modified:Jul 19, 2012 Type:PROBLEM Status:MODERATED Priority:3
In this Document
Symptoms
Cause
Solution
References
This document is being delivered to you via Oracle Support's Rapid Visibility (RaV) process and therefore has not been subject to an independent technical review.
Applies to:
Oracle SOA Platform - Version 11.1.1.3.0 and later
Information in this document applies to any platform.
Symptoms
A SOA Project has an external reference to a Web Service or a reference to another Composite.
When the SOA Server is started, the Composite is trying to access the WSDL of it's referenced Web Service in order to load data structures. If SOA can not find the WSDL then the Composite fails to load/deploy.
Once this happens the Composite can not be started, or shutdown, from Enterprise Manager Fusion Middleware Control Application.
Related Error Messages:
[ERROR] [SOA-20020] ... Unable to find a WSDL that has a definition for service ... Please make sure that the port attribute for the binding defined in the composite file is correct by checking the namespace, service name, and port name. In addition, check that the WSDL associated with the binding namespace is imported and currently reachable (check the import nodes at the top of the composite file). Finally, validate the HTTP proxy settings for the server.]
javax.wsdl.WSDLException: WSDLException: faultCode=INVALID_WSDL: Error reading import of oramds
Cause
When SOA Server is restarting the Composite can not access the WSDL of it's referenced Web Service (it is not available).
In the first scenario there are two Composites on the same server: CompositeA and CompositeB.
In SOA Suite 11g there is no possibility to specify the load order for the composites. If CompositeA references CompositeB and if CompositeA is firstly loaded then it can not access the WSDL from CompositeB and the issue occurs.
In the second situation there is one Composite on the server (CompositeA) which references an external WebService (ExternalWS). If the ExternalWS is not available when the SOA Server is starting then this issue occurs.
Solution
Solution 1
Redeploy the affected Composite into the SOA Server.
You can do that but it is not advisable in a production environment and in a development environment it will take a lot of time to redeploy the composite manually
Solution 2
Copy the abstract WSDL locally into the project.
This is documented in these articles in our Knowledge base:
• Document:1155033.1 Node Restart Cause Composites To Become Unavailable. Response: '503: Service Unavailable'
• Document:1151973.1 Boot Order Of The Composites Upon Soa Suite Restart
Steps:
o a. Copy and use the WSDL file in the Project
o b. Edit the WebService Adapter
o c. Change the "WSDL URL" to point to the WSDL copied into the project
o d. Redeploy the Project
o e. Make this configuration with all the Projects that have a references with other Web Services
Solution 3
Use shared artifacts in Metadata Service (MDS). A WSDL used by more than one composite is a shared artifact per definition. If the WSDL structure is changed (that is not happening frequently in a production environment), you will normally deploy a composite with a new version because overwriting it will break your production environment. Moreover, in a development environment you will need a proper process in place where different developers access the same artifacts within MDS. In addition, when you use external WSDLs (owned by third parties), you will have a proper process/agreement in place to be notified about modifications affecting your applications.
1. In order to use shared artifacts a MDS connection must be configured in jDeveloper:
http://download.oracle.com/docs/cd/E14571_01/integration.1111/e10224/sca_lifecycle.htm#SOASE85488
2. Deploy the shared artifacts:
o a. Create a JAR profile and include the artifacts to share
o b. Create a SOA bundle that includes the JAR profile
o c. Deploy the SOA bundle to the application server
http://download.oracle.com/docs/cd/E14571_01/integration.1111/e10224/sca_lifecycle.htm#SOASE85472
If the shared artifacts (WSDLs) needed are from other composites this step can be skipped
3. Create a new WebService
o a. When completing the "WSDL URL" click on "Find existing WSDL's"
o b. Select "Resource Palette"
o c. Go to the SOA-MDS
o d. Select a WSDL from a Composite or the one deployed at step 2.
Known Restriction 1
The port and the location for the WSDL reference is not completed automatically by jDeveloper in the composite.xml file. This information must be inserted manually. In Bug:10287325 is raised this issue and it is available for SOA 11gPS2+.
Known Restriction 2
Another issue regarding MDS caching is raised in Bug:10218147 - the MDS cache is not refreshed when an artifact is deployed or deleted.
In order to refresh this cache the server must be restarted. This Bug resolves the issue but in a production environment the server restart will be the preferred option. The reason for that is because in a production environment you never deploy single composites under the same version after artifacts (WSDLs) have been modified.
The fix for the Bug:10218147 can be an acceptable solution in development environment where redeployment would be quicker than restarting the server.
Bug:10218147 is available for SOA 11gPS2+.
To find out more information about how to use Shared Metadata check the following documentation:
Oracle Fusion Middleware Developer's Guide for Oracle SOA Suite 11g
41 Deploying SOA Composite Applications
41.7.3 Deploying and Using Shared Metadata Across SOA Composite Applications in Oracle JDeveloper
URL:
http://download.oracle.com/docs/cd/E14571_01/integration.1111/e10224/sca_lifecycle.htm#CACFEAJJ
Solution 4
The last solution is to use an UDDI (Universal Description Discovery and Integration).
Oracle recommends Oracle Service Registry 11g (OSR). The advantage is that you can use OSR and SOA Suite in a Shared WebLogic Domain.
http://www.oracle.com/technetwork/middleware/registry/overview/index.html
http://blogs.oracle.com/governance/2010/05/oracle_service_registry_11gr1.html
To find out more information about Oracle Service Registry check the following documentation:
Oracle Fusion Middleware Administrator's Guide for Oracle SOA Suite 11g
33 Configuring Service and Reference Binding Components
33.1.3 Changing the Endpoint Reference and Service Key for Oracle Service Registry Integration
http://download.oracle.com/docs/cd/E15523_01/integration.1111/e10226/bc_config.htm#SOAAG37248
Oracle Fusion Middleware Developer's Guide for Oracle SOA Suite 11g
A BPEL Process Activities and Services
A.4 Publishing and Browsing the Oracle Service Registry
http://download.oracle.com/docs/cd/E15523_01/integration.1111/e10224/bp_appx_ref.htm#SOASE85561
Oracle Fusion Middleware Service Registry 11g
http://download.oracle.com/otndocs/tech/soa/OSR11gR1ProductDocumentation.pdf
Solution 5
In case you have BPM Components in the Composites deployed check the following note:
Document 1317803.1 Soa Suite Composite Fails To Deploy Upon Restart Of Managed Server
The issue is caused by the Bug:11822470 SOA SUITE COMPOSITE FAILS TO DEPLOY UPON RESTART OF MANAGED SERVER
References
BUG:10218147 - WSDL CHANGES NEED SOA SUITE SERVER RESTART
BUG:10278478 - WHEN SOA SERVER IS RESTARTED, SOME SOA COMPOSITES COULD NOT LOAD/BE DEPLOYED
BUG:10287325 - ABSTRACT WSDL NOT AVAILABLE WHEN COMPOSITE STARTED
BUG:10311698 - WHEN SOA SERVER IS RESTARTED, SOME SOA COMPOSITES CAN NOT BE STARTUP / SHUTDOWN
BUG:11822470 - SOA SUITE COMPOSITE FAILS TO DEPLOY UPON RESTART OF MANAGED SERVER
@ BUG:9267312 - MDS ARTIFACTS ARE STILL CACHED AFTER DELETING
@ BUG:9708488 - AFTER SOA RESTART, ALL PROCESSES HAVE TO BE REDEPLOYED
@ BUG:9749845 - SCHEMA CACHE STARTS EMPTY AFTER RE-START, BUT NOT AFTER DEPLOYMENT
NOTE:1151973.1 - Boot Order Of The Composites Upon Soa Suite Restart
NOTE:1155033.1 - Node Restart Cause Composites To Become Unavailable. Response: '503: Service Unavailable'
NOTE:1317803.1 - Soa Suite Composite Fails To Deploy Upon Restart Of Managed Server
Bug 11822470 : SOA SUITE COMPOSITE FAILS TO DEPLOY UPON RESTART OF MANAGED SERVER
Bug Attributes
Type B - Defect Fixed in Product Version 11.1.1.6
Severity 2 - Severe Loss of Service Product Version 11.1.1.4
Status 80 - Development to QA/Fix Delivered Internal Platform 912 - Microsoft Windows (32-bit)
Created Mar 1, 2011 Platform Version 2003
Updated Oct 12, 2012 Base Bug N/A
Database Version N/A Affects Platforms Generic
Product Source Oracle
Abstract: SOA SUITE COMPOSITE FAILS TO DEPLOY UPON RESTART OF MANAGED SERVER
*** 03/01/11 08:07 am ***
Customer has a project consists of two services for interaction with the
process and one reference to an external service.
On deployment of the process to an Enterprise Environment, the process works
as expected. However, upon a restart of the managed server, the process will
then fail to deploy.
Workaround used is to redeploy the project again.
Bug 10278478 : WHEN SOA SERVER IS RESTARTED, SOME SOA COMPOSITES COULD NOT LOAD/BE DEPLOYED
Bug Attributes
Type B - Defect Fixed in Product Version
Severity 2 - Severe Loss of Service Product Version 11.1.1.3.0
Status 92 - Closed, Not a Bug Platform 226 - Linux x86-64
Created Nov 10, 2010 Platform Version RED HAT ENTERPRISE LINUX 5
Updated Dec 10, 2010 Base Bug N/A
Database Version N/A Affects Platforms Generic
Product Source Oracle
Abstract: WHEN SOA SERVER IS RESTARTED, SOME SOA COMPOSITES COULD NOT LOAD/BE DEPLOYED
Detailed Problem Description
====================
When a SOA composite get dependencies with other SOA composites located on the same server, if the dependency is still not loaded, the SOA composite will not be loaded, and there is no possibilities for Entreprise Manager console to restart it (EM crash). The only way to make it working is to redeployed the SOA composite from jDeveloper that is not acceptable in a production environment.
The composite that has the issue cannot be start-up or shut-down, although the Enterprise Manager do not show any errors with it. -
Urgent : Fault Policies in 11g
Hi All,
im trying to use fault policies in 11g. as per documentation i can have
1). the fault policies and fault bindings in the same composite. this works fine
2). In a different location that is specified with two properties that you add to the composite.xml file. This option is useful if a fault policy must be used by multiple SOA composite applications. This option overrides any fault policy files that are included in the same directory as the composite.xml file. Example 12-3 provides details about these two properties. In this example, the fault policy files are placed into the SOA Metadata Service (MDS) shared area.
<property
name="oracle.composite.faultPolicyFile">oramds://apps/faultpolicyfiles/
fault-policies.xml
</property>
<property
name="oracle.composite.faultBindingFile">oramds://apps/faultpolicyfiles/
fault-bindings.xml
</property>
Problem Description
i tried to work on both approches
Scenario 1
=====================================================
1). I have 2 Composites with BPEL process
2). First composite will have fault policies and binidings in the same project as composite.xml and invokes the second composite
3). Turn Off the First composite.
remote fault is propagated and waits for recovery.
Scenario 1
=====================================================
1). I have 2 Composites with BPEL process
2). First composite will have fault policies and binidings are deployed to shared metadata and invokes the second composite and reffered as shown below
3). Turn Off the First composite.
remote fault is not getting propagated and process is getting faulted.
please find the attached composite.xml file i have used.
is this the correct way to include the fault policies .. if any body has already worked on fault policies in 11G and accessed them thru share metadata are please suggest me how to resolve this, if not any working example and pointer to setup the properties will be of great help.
<?xml version="1.0" encoding="UTF-8" ?>
<!-- Generated by Oracle SOA Modeler version 1.0 at [12/07/09 12:32]. -->
<composite name="TestHello"
revision="1.0"
label="2009-07-12_12-32-01_093"
mode="active"
state="on"
xmlns="http://xmlns.oracle.com/sca/1.0"
xmlns:xs="http://www.w3.org/2001/XMLSchema"
xmlns:wsp="http://schemas.xmlsoap.org/ws/2004/09/policy"
xmlns:orawsp="http://schemas.oracle.com/ws/2006/01/policy"
xmlns:ui="http://xmlns.oracle.com/soa/designer/">
<import namespace="http://xmlns.oracle.com/SOAMetaData/TestHello/Lakshmi"
location="Lakshmi.wsdl" importType="wsdl"/>
<import namespace="http://xmlns.oracle.com/SOAMetaData/Hello/laks1"
location="http://INT01723:8001/soa-infra/services/default/Hello/laks1.wsdl"
importType="wsdl"/>
<service name="lakshmi_client_ep" ui:wsdlLocation="Lakshmi.wsdl">
<interface.wsdl interface="http://xmlns.oracle.com/SOAMetaData/TestHello/Lakshmi#wsdl.interface(Lakshmi)"
callbackInterface="http://xmlns.oracle.com/SOAMetaData/TestHello/Lakshmi#wsdl.interface(LakshmiCallback)"/>
<binding.ws port="http://xmlns.oracle.com/SOAMetaData/TestHello/Lakshmi#wsdl.endpoint(lakshmi_client_ep/Lakshmi_pt)"/>
<callback>
<binding.ws port="http://xmlns.oracle.com/SOAMetaData/TestHello/Lakshmi#wsdl.endpoint(lakshmi_client_ep/LakshmiCallback_pt)"/>
</callback>
<property name="oracle.composite.faultPolicyFile">oramds://apps/faultpolicyfiles/fault-policies.xml</property>
<property name="oracle.composite.faultBindingFile">oramds://apps/faultpolicyfiles/fault-bindings.xml</property>
</service>
<component name="Lakshmi">
<implementation.bpel src="Lakshmi.bpel"/>
<property name="oracle.composite.faultPolicyFile">oramds://apps/faultpolicyfiles/fault-policies.xml</property>
<property name="oracle.composite.faultBindingFile">oramds://apps/faultpolicyfiles/fault-bindings.xml</property>
</component>
<reference name="Service1"
ui:wsdlLocation="http://INT01723:8001/soa-infra/services/default/Hello/laks1.wsdl">
<interface.wsdl interface="http://xmlns.oracle.com/SOAMetaData/Hello/laks1#wsdl.interface(laks1)"
callbackInterface="http://xmlns.oracle.com/SOAMetaData/Hello/laks1#wsdl.interface(laks1Callback)"/>
<binding.ws port="http://xmlns.oracle.com/SOAMetaData/Hello/laks1#wsdl.endpoint(laks1_client_ep/laks1_pt)"
location="http://INT01723:8001/soa-infra/services/default/Hello/laks1_client_ep?WSDL"/>
<callback>
<binding.ws port="http://xmlns.oracle.com/SOAMetaData/Hello/laks1#wsdl.endpoint(laks1_client_ep/laks1Callback_pt)"/>
</callback>
<property name="oracle.composite.faultPolicyFile">oramds://apps/faultpolicyfiles/fault-policies.xml</property>
<property name="oracle.composite.faultBindingFile">oramds://apps/faultpolicyfiles/fault-bindings.xml</property>
</reference>
<wire>
<source.uri>lakshmi_client_ep</source.uri>
<target.uri>Lakshmi/lakshmi_client</target.uri>
</wire>
<wire>
<source.uri>Lakshmi/Service1</source.uri>
<target.uri>Service1</target.uri>
</wire>
</composite>
Thanks
Nadh
when i try the second scenario it is not picking up the faultA Sample composite.xml for the External fault-policy and fault-binding files.
<?xml version="1.0" encoding="UTF-8" ?>
<!-- Generated by Oracle SOA Modeler version 1.0 at [6/3/09 4:09 PM]. -->
<composite name="Shared_MDS_Fault_Policy_Test"
revision="1.0"
label="2009-06-03_16-09-26_218"
mode="active"
state="on"
xmlns="http://xmlns.oracle.com/sca/1.0"
xmlns:xs="http://www.w3.org/2001/XMLSchema"
xmlns:wsp="http://schemas.xmlsoap.org/ws/2004/09/policy"
xmlns:orawsp="http://schemas.oracle.com/ws/2006/01/policy"
xmlns:ui="http://xmlns.oracle.com/soa/designer/">
<import namespace="http://xmlns.oracle.com/Shared_MDS_Fault_Policy_App/Shared_MDS_Fault_Policy_Test/Med_SharedMDS_Fault_Policy"
location="Med_SharedMDS_Fault_Policy.wsdl" importType="wsdl"/>
<import namespace="http://xmlns.oracle.com/pcbpel/adapter/file/Shared_MDS_Fault_Policy_App/Shared_MDS_Fault_Policy_Test/OutFile%2F"
location="OutFile.wsdl" importType="wsdl"/>
<service name="Med_SharedMDS_Fault_Policy_ep"
ui:wsdlLocation="Med_SharedMDS_Fault_Policy.wsdl">
<interface.wsdl interface="http://xmlns.oracle.com/Shared_MDS_Fault_Policy_App/Shared_MDS_Fault_Policy_Test/Med_SharedMDS_Fault_Policy#wsdl.interface(execute_ptt)"/>
<binding.ws port="http://xmlns.oracle.com/Shared_MDS_Fault_Policy_App/Shared_MDS_Fault_Policy_Test/Med_SharedMDS_Fault_Policy#wsdl.endpoint(Med_SharedMDS_Fault_Policy_ep/execute_pt)"/>
</service>
*<property name="oracle.composite.faultPolicyFile">oramds:/apps/fault-policies.xml*
*</property>*
*<property name="oracle.composite.faultBindingFile">oramds:/apps/fault-bindings.xml*
*</property>*
<component name="Med_SharedMDS_Fault_Policy">
<implementation.mediator src="Med_SharedMDS_Fault_Policy.mplan"/>
</component>
<reference name="OutFile" ui:wsdlLocation="OutFile.wsdl">
<interface.wsdl interface="http://xmlns.oracle.com/pcbpel/adapter/file/Shared_MDS_Fault_Policy_App/Shared_MDS_Fault_Policy_Test/OutFile%2F#wsdl.interface(Write_ptt)"/>
<binding.jca config="OutFile_file.jca"/>
</reference>
<wire>
<source.uri>Med_SharedMDS_Fault_Policy_ep</source.uri>
<target.uri>Med_SharedMDS_Fault_Policy/Med_SharedMDS_Fault_Policy</target.uri>
</wire>
<wire>
<source.uri>Med_SharedMDS_Fault_Policy/OutFile</source.uri>
<target.uri>OutFile</target.uri>
</wire>
</composite>
And also Please make sure that you are refering to correct oramds: location as mentioned by suhariha -
VacationRequest Sample, missing element "mds-config" error upon Deploy
Hi All,
Searched the forum history and couldn't find any hints on this one, wondered if some kind soul could help a SOA beginner.
I took the VacationRequest sample from https://soasamples.samplecode.oracle.com/files/documents/660/794/workflow-100-VacationRequest.zip and am attempting to deploy into a WLS 10.3.2 domain which has the soa_server1 configured correctly. The demo users and app have been already seeded OK from the DemoCommunitySeedApp.
When opening the VacationRequestApp.jws within JDev and receive this error:
Error(12,61): Parse of component type files failed, check the adf-config.xml file : "oracle.fabric.common.FabricException: oracle.mds.config.MDSConfigurationException: MDS-01333: missing element "mds-config": MDS-01333: missing element "mds-config": oracle.mds.config.MDSConfigurationException: MDS-01333: missing element "mds-config": MDS-01333: missing element "mds-config""
adf-config.xml has the following content:
<?xml version="1.0" encoding="windows-1252" ?>
<adf-config xmlns="http://xmlns.oracle.com/adf/config"></adf-config>
Environmental information: JDev 11gR1, Oracle SOA Composite Editor v11.1.2.0.12.16, SOA suite 11gR1, Windows2003R2
Thanks in advance,I added the following right before the end tag, based on a different project:
<adf-mds-config xmlns="http://xmlns.oracle.com/adf/mds/config">
<mds-config xmlns="http://xmlns.oracle.com/mds/config">
<persistence-config>
<metadata-namespaces>
<namespace metadata-store-usage="mstore-usage_1" path="/soa/shared"/>
</metadata-namespaces>
<metadata-store-usages>
<metadata-store-usage id="mstore-usage_1">
<metadata-store class-name="oracle.mds.persistence.stores.file.FileMetadataStore">
<property value="${oracle.home}/integration"
name="metadata-path"/>
<property value="seed" name="partition-name"/>
</metadata-store>
</metadata-store-usage>
</metadata-store-usages>
</persistence-config>
</mds-config>
</adf-mds-config>
It then was able to deploy
Maybe you are looking for
-
Email fonts have changed and scroll bar missing
Not sure how, but when using Firefox and opening my email all my fonts have changed to 8pt size and all regular font (i.e., not bold for unread msgs) and the scroll bar is missing. When I open email using another browser, all email settings are consi
-
Hi, has anyone tried to run an ADF 11g Application on IE8? Is it working? Kind Regards, Friedrich
-
New DV7 laptop keyboard does not work with any PC game.
I have a new dv7-4270 laptop, w/ AMD vision, Premium graphics and 4GB ram. When I try to play ANY PC game (e.g. COD black op, Grand Theft, half-life,ghost recon, black hawk down, etc.) the movement, action, etc keys do not respond. If they do, it's
-
I am enhancing a delivered datasource to include inventory shrinkage. The shrinkage is stored in the R/3 table KONP as a condition record. It could be a percentage or a price per unit. I created an InfoObject in BI for KONWA with the same data type a
-
Can you re-set up id apple on the iphone?
Hi There My wife mixed up her apple ID. The thing is that the apple ID she typed a wrong one in the icloud settings of her new iphone. Problem is that her iphone cannot use icloud and there is no way to change to the right one because she does not k