Skip to content

Aws::Ec2::model::Snapshot: m_startTime double -> Aws::String #142

New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Closed
wants to merge 1 commit into from
Closed

Aws::Ec2::model::Snapshot: m_startTime double -> Aws::String #142

wants to merge 1 commit into from

Conversation

quatmax
Copy link

@quatmax quatmax commented Mar 30, 2016

Hi!

Regarding #135, I patched Snapshot handling startTime as string instead of double.

I think, there is a general bug in handling timestamps within the sdk.

The string conversion to double produces wrong results.

I see three possible solutions for timestamp attributes:

  1. Work with the raw string data instead of doubles (an example is this pull request)
  2. Convert them to a correct double representation.
  3. Convert them to std::time_t or a custom Aws::TimeStamp type

BR, max

@quatmax quatmax changed the title m_startTime double -> Aws::String Aws::ec2::model::Snapshot: m_startTime double -> Aws::String Mar 30, 2016
@quatmax quatmax changed the title Aws::ec2::model::Snapshot: m_startTime double -> Aws::String Aws::Ec2::model::Snapshot: m_startTime double -> Aws::String Mar 30, 2016
@Bu11etmagnet
Copy link

My preference would be for time-related fields to be stored as std::chrono types (duration or time_point, as appropriate) and be converted to strings when communicating with Amazon services.

@cbsmith
Copy link

cbsmith commented Mar 30, 2016

It makes sense to create a custom Amazon Time type with automatic conversions from chrono, string, time_t.

@bizzarri
Copy link

I think this problem exists with the LastModified date/time field in S3 – which returns a double even though it’s a string. All I get is the year when I use this.

Maurice

From: Christopher Smith [mailto:[email protected]]
Sent: Wednesday, March 30, 2016 10:56 AM
To: aws/aws-sdk-cpp [email protected]
Subject: Re: [aws/aws-sdk-cpp] Aws::Ec2::model::Snapshot: m_startTime double -> Aws::String (#142)

It makes sense to create a custom Amazon Time type with automatic conversions from chrono, string, time_t.


You are receiving this because you are subscribed to this thread.
Reply to this email directly or view it on GitHubhttps://github.com//pull/142#issuecomment-203552456

@JonathanHenson
Copy link
Contributor

I'm about to try and knock this out today. I'll keep you posted.

Sent from my iPhone

On Mar 30, 2016, at 11:55 AM, Maurice Bizzarri [email protected] wrote:

I think this problem exists with the LastModified date/time field in S3 – which returns a double even though it’s a string. All I get is the year when I use this.

Maurice

From: Christopher Smith [mailto:[email protected]]
Sent: Wednesday, March 30, 2016 10:56 AM
To: aws/aws-sdk-cpp [email protected]
Subject: Re: [aws/aws-sdk-cpp] Aws::Ec2::model::Snapshot: m_startTime double -> Aws::String (#142)

It makes sense to create a custom Amazon Time type with automatic conversions from chrono, string, time_t.


You are receiving this because you are subscribed to this thread.
Reply to this email directly or view it on GitHubhttps://github.com//pull/142#issuecomment-203552456

You are receiving this because you are subscribed to this thread.
Reply to this email directly or view it on GitHub

@quatmax
Copy link
Author

quatmax commented Mar 30, 2016

Thanks! Looking forward to see your solution.

@JonathanHenson
Copy link
Contributor

Ok, I've reworked the way all date timestamps are handled in the SDK. Have a look and reopen an issue if the issue persists.

@JonathanHenson
Copy link
Contributor

In particular, have a look at aws-cpp-sdk-core/include/aws/core/utils/DateTime.h

@quatmax
Copy link
Author

quatmax commented Apr 5, 2016

Hi! Perfect solution. It seems that there is a bug in ISO 8601 parsing. I will open a new PR.

krzysztof-trzepla added a commit to krzysztof-trzepla/aws-sdk-cpp that referenced this pull request May 21, 2016
aa46c42 VFS-1428 Extend IStorageHelper interface.
811824e VFS-1428 Add option that disables proxy IO helper build.
63defee Merge branch 'develop' of ssh://git.plgrid.pl:7999/vfs/helpers into feature/VFS-1428-support-for-multi-storage-types
2145289 VFS-1428 Add abstract storage helper context layer.
5aaae93 Merge pull request aws#147 in VFS/helpers from feature/VFS-1407-client-get-subscriptions-on-handshake to develop
c8f8915 VFS-1407 Change handshake response message behaviour.
39b5eaf Merge branch 'develop' of ssh://git.plgrid.pl:7999/vfs/helpers into feature/VFS-1407-client-get-subscriptions-on-handshake
8b2e83b VFS-1411 Add Ceph storage helper.
afb68ad Merge pull request aws#144 in VFS/helpers from feature/VFS-1371-clusterproxy-storage-helper to develop
20464d1 VFS-1371 Fix strange merge artifact.
01c6c70 Merge remote-tracking branch 'origin/develop' into feature/VFS-1371-clusterproxy-storage-helper
facd129 VFS-1371 Add SpaceID to proxyio requests.
3500ed7 Merge commit 'e72b0520dddb16f1599ba889ed23da288487c424' into feature/VFS-1371-clusterproxy-storage-helper
e72b052 Squashed 'clproto/' changes from 7e5d95b..8afb7e1
0cb160d Merge pull request aws#146 in VFS/helpers from feature/VFS-1363-add-user-context-to-helpers-operations to develop
da55b41 VFS-1371 Extract inline constant into a named constant.
19d0425 Merge remote-tracking branch 'origin/develop' into feature/VFS-1371-clusterproxy-storage-helper
8865c80 Merge pull request aws#148 in VFS/helpers from feature/VFS-1376-acceptance-tests-for-events to develop
89b2c4f VFS-1376 Fix spinlock in typedStream and client hung after umount in foreground.
1da7ae2 Merge branch 'develop' of ssh://git.plgrid.pl:7999/vfs/helpers into feature/VFS-1407-client-get-subscriptions-on-handshake
3768c24 Merge pull request aws#142 in VFS/helpers from feature/VFS-1289-event-manager-for-one-client-v.3.0 to develop
80692df VFS-1289 Apply recommended changes.
0f52bbb VFS-1407 Apply recommended changes.
5ece72b Merge commit 'cb8ba6fa10e4779dee0ebaf3cf2d5e3c234a56b8' into feature/VFS-1407-client-get-subscriptions-on-handshake
cb8ba6f Squashed 'clproto/' changes from e78734c..8ac886e
a1cf9c4 VFS-1407 Getting subscriptions on handshake response.
14bc168 Merge pull request aws#145 in VFS/helpers from bugfix/VFS-1355-fix-segmentation-fault-when-mounting to develop
9ee6869 Merge pull request aws#143 in VFS/helpers from feature/VFS-1378-global-http-and-websocket-client to feature/VFS-1289-event-manager-for-one-client-v.3.0
bc53f1e Merge commit 'edb0d8533be120fd699b7bb53d7cadcc680f1095' into feature/VFS-1378-global-http-and-websocket-client
edb0d85 Squashed 'appmock/' changes from 8d64333..0e1718a
62118bc Merge commit '872d1320a4cbc5777f49859b4086da83f1815dcd' into feature/VFS-1378-global-http-and-websocket-client
872d132 Squashed 'appmock/' changes from 5490d65..8d64333
909a8c1 Merge commit '7b118d115b3d8f82bdc253d9db3fb53306551284' into feature/VFS-1378-global-http-and-websocket-client
7b118d1 Squashed 'appmock/' changes from 9bad307..5490d65
51baa76 VFS-1355 Fix some race conditions in PersistentConnection.
a0d5ce1 Merge commit '49e0838ae62ab558a72e34487499a1ea6c887994' into feature/VFS-1378-global-http-and-websocket-client
49e0838 Squashed 'appmock/' changes from c3bc2cc..9bad307
5c9b8a9 Merge commit '6769c04efd4ccc2607a6dc839ea97f07bd5ec01b' into feature/VFS-1378-global-http-and-websocket-client
6769c04 Squashed 'appmock/' changes from 740af5e..c3bc2cc
55e0bd1 VFS-1371 Remove SpaceID from ProxyIO arguments.
82af8d0 VFS-1371 Refactor perf Parameter factories.
0c9b9ad VFS-1371 Add 'messages per second' performance test result.
6612e31 VFS-1371 Reply only if message_id is set in integration tests helpers.
79260e0 VFS-1371 Reimplement performance on top of pytest.
b1d5e4f VFS-1371 Fix surprise compilation errors.
614de9e VFS-1371 Enable creating ProxyIO in StorageHelperFactory.
d90b834 VFS-1371 Change messages to conform to the new protocol.
717311c Squashed 'clproto/' content from commit 7e5d95b
218a256 Merge commit '717311c1579eb31c51a3f38a699945cd593e5679' as 'clproto'
dbd8549 VFS-1371 Remove clproto directory.
ecb5058 VFS-1371 Test ProxyIO.
8e01071 VFS-1371 Streamline writing performance tests.
9575562 VFS-1371 Compile protocol for integration tests.
8d934f7 VFS-1371 Add ProxyIO helper.
fb6163a VFS-1371 Add protocol messages for ProxyIO helper.
28fb632 Squashed 'clproto/' changes from f7f9162..e78734c
145b1dd Merge commit '28fb632e74af38fe57cf4af60dec6df1d599412e' into feature/VFS-1289-event-manager-for-one-client-v.3.0
fb42b0a VFS-1371 Provide default implementations for IStorageHelper methods.
d505f6b Merge branch 'develop' of ssh://git.plgrid.pl:7999/vfs/helpers into feature/VFS-1289-event-manager-for-one-client-v.3.0
5e5e879 VFS-1371 Change ClientMessage::serialize to serializeAndDestroy.
0b7ab67 Merge branch 'develop' of ssh://git.plgrid.pl:7999/vfs/helpers into feature/VFS-1289-event-manager-for-one-client-v.3.0
62510fe VFS-1289 Update Sequencer, so that it periodically sends message requests for expected messages. Change TypedStream behaviour.
03ab708 Squashed 'clproto/' changes from 863b0ca..f7f9162
3c76675 Merge commit '03ab708f582896c6cff273a325b29d3c13483f6a' into feature/VFS-1289-event-manager-for-one-client-v.3.0
590f473 Merge commit 'c59c547b7147e8dcf78ea5bd4b40c95071acd20f' into feature/VFS-1289-event-manager-for-one-client-v.3.0
c59c547 Squashed 'clproto/' changes from d606115..863b0ca
d59ec04 VFS-1289 New events multilayer architecture. Unit and integration tests extension.
8be91e5 VFS-1289 Fix compilation errors of NIF libs.
2411b36 Merge commit '1a1105c65d9a2e13d99effa9d9f331beb6ba93b1' into feature/VFS-1289-event-manager-for-one-client-v.3.0
1a1105c Squashed 'clproto/' changes from d69169c..d606115
b20409f Implement sequencer tests.
2ad100e Merge commit '34caa7f1ce287843c8f7db7d8fc31e5efacd8140' into feature/VFS-1289-event-manager-for-one-client-v.3.0
820aad7 VFS-1289 Implement sequencer behaviour.
cec651b Merge branch 'develop' of ssh://git.plgrid.pl:7999/vfs/oneclient into feature/VFS-1289-event-manager-for-one-client-v.3.0
c795f90 VFS-1289 Refactor events framework. Extend unit tests. Fix integration tests.
3856a01 Merge remote-tracking branch 'origin/develop' into feature/VFS-1235-operations-on-files-at-the-client
7ea0f06 VFS-1235 Implement PushListener.
23668b1 VFS-1223 Add a refreshing macaroons capability.

git-subtree-dir: helpers
git-subtree-split: aa46c42b478a7a60a12773f2d137bffbd2717252
cobookman pushed a commit to cobookman/aws-sdk-cpp that referenced this pull request Jan 17, 2022
update submodules
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

5 participants