使用一个post方法多次调用服务器

时间:2017-06-14 09:49:58

标签: java android post

我的应用有问题。这是一个QR扫描应用程序的门票(验证它们)。我的客户抱怨他从一张票中获得了多个帖子,这不应该发生。我住在代码中,从我看到的,一切都好。我附上日志,也许你们中的一些人在这里看到的比我更多?

在以下日志中,我首先输入要检查的事件,然后打开扫描仪,扫描票证,然后重新打开扫描仪活动(自动)。

E/MainActivity: Checking Event
I/pl.itgenerator.kasownikdocel.RestClient: ---> HTTP GET https://tubilety.pl/api/event_info/event003
I/pl.itgenerator.kasownikdocel.RestClient: ---> END HTTP (no body)
W/dalvikvm: VFY: unable to find class referenced in signature (Ljava/nio/file/Path;)
W/dalvikvm: VFY: unable to find class referenced in signature ([Ljava/nio/file/OpenOption;)
I/dalvikvm: Could not find method java.nio.file.Files.newOutputStream, referenced from method okio.Okio.sink
W/dalvikvm: VFY: unable to resolve static method 21096: Ljava/nio/file/Files;.newOutputStream (Ljava/nio/file/Path;[Ljava/nio/file/OpenOption;)Ljava/io/OutputStream;
D/dalvikvm: VFY: replacing opcode 0x71 at 0x000a
W/dalvikvm: VFY: unable to find class referenced in signature (Ljava/nio/file/Path;)
W/dalvikvm: VFY: unable to find class referenced in signature ([Ljava/nio/file/OpenOption;)
I/dalvikvm: Could not find method java.nio.file.Files.newInputStream, referenced from method okio.Okio.source
W/dalvikvm: VFY: unable to resolve static method 21095: Ljava/nio/file/Files;.newInputStream (Ljava/nio/file/Path;[Ljava/nio/file/OpenOption;)Ljava/io/InputStream;
D/dalvikvm: VFY: replacing opcode 0x71 at 0x000a
I/pl.itgenerator.kasownikdocel.RestClient: <--- HTTP 200 https://tubilety.pl/api/event_info/event003 (494ms)
I/pl.itgenerator.kasownikdocel.RestClient: Date: Wed, 14 Jun 2017 09:43:32 GMT
I/pl.itgenerator.kasownikdocel.RestClient: Vary: X-Forwarded-Proto
I/pl.itgenerator.kasownikdocel.RestClient: Cache-Control: no-cache
I/pl.itgenerator.kasownikdocel.RestClient: Content-Length: 46
I/pl.itgenerator.kasownikdocel.RestClient: Content-Type: text/html; charset=UTF-8
I/pl.itgenerator.kasownikdocel.RestClient: Via: 1.1 cache2 (squid)
I/pl.itgenerator.kasownikdocel.RestClient: Connection: keep-alive
I/pl.itgenerator.kasownikdocel.RestClient: OkHttp-Selected-Protocol: http/1.1
I/pl.itgenerator.kasownikdocel.RestClient: OkHttp-Sent-Millis: 1497433410468
I/pl.itgenerator.kasownikdocel.RestClient: OkHttp-Received-Millis: 1497433410751
I/pl.itgenerator.kasownikdocel.RestClient: 3 Impreza testowa 3
                                           2015-09-18 18:00
                                           Ciepła 1
I/pl.itgenerator.kasownikdocel.RestClient: <--- END HTTP (46-byte body)
E/MainActivity: CodeScann success
E/MainActivity: Parsing Event
E/MainActivity: Event exists
W/ApplicationPackageManager: getCSCPackageItemText()
E/DetailActivity: In
E/DetailActivity: inScanQR
W/ApplicationPackageManager: getCSCPackageItemText()
W/dalvikvm: VFY: unable to find class referenced in signature (Landroid/view/SearchEvent;)
I/dalvikvm: Could not find method android.view.Window$Callback.onSearchRequested, referenced from method android.support.v7.view.WindowCallbackWrapper.onSearchRequested
W/dalvikvm: VFY: unable to resolve interface method 15261: Landroid/view/Window$Callback;.onSearchRequested (Landroid/view/SearchEvent;)Z
D/dalvikvm: VFY: replacing opcode 0x72 at 0x0002
I/dalvikvm: Could not find method android.view.Window$Callback.onWindowStartingActionMode, referenced from method android.support.v7.view.WindowCallbackWrapper.onWindowStartingActionMode
W/dalvikvm: VFY: unable to resolve interface method 15265: Landroid/view/Window$Callback;.onWindowStartingActionMode (Landroid/view/ActionMode$Callback;I)Landroid/view/ActionMode;
D/dalvikvm: VFY: replacing opcode 0x72 at 0x0002
E/ZXingScanner: ScannerInitialized
I/Choreographer: Skipped 41 frames!  The application may be doing too much work on its main thread.
D/dalvikvm: GC_FOR_ALLOC freed 767K, 10% free 23846K/26396K, paused 19ms, total 19ms
I/dalvikvm-heap: Grow heap (frag case) to 29.205MB for 3110416-byte allocation
I/dalvikvm: Total arena pages for JIT: 11
I/dalvikvm: Total arena pages for JIT: 12
D/dalvikvm: GC_FOR_ALLOC freed 4025K, 19% free 23953K/29436K, paused 14ms, total 14ms
I/dalvikvm-heap: Grow heap (frag case) to 29.309MB for 3110416-byte allocation
D/dalvikvm: GC_FOR_ALLOC freed <1K, 9% free 26990K/29436K, paused 48ms, total 48ms
D/dalvikvm: GC_FOR_ALLOC freed 10314K, 33% free 23867K/35604K, paused 16ms, total 16ms
I/dalvikvm-heap: Grow heap (frag case) to 29.226MB for 3110416-byte allocation
D/dalvikvm: GC_FOR_ALLOC freed 7102K, 42% free 20830K/35604K, paused 14ms, total 14ms
I/dalvikvm-heap: Grow heap (frag case) to 26.259MB for 3110416-byte allocation
D/dalvikvm: GC_FOR_ALLOC freed <1K, 33% free 23867K/35604K, paused 83ms, total 83ms
I/dalvikvm-heap: Grow heap (frag case) to 29.226MB for 3110416-byte allocation
E/ZXingScanner: The result to handle recieved
I/Choreographer: Skipped 40 frames!  The application may be doing too much work on its main thread.
E/DetailActivity: Result Success
I/pl.itgenerator.kasownikdocel.RestClient: ---> HTTP POST https://tubilety.pl/api/ticket_validation/event003/a3000150
I/pl.itgenerator.kasownikdocel.RestClient: ---> END HTTP (no body)
I/pl.itgenerator.kasownikdocel.RestClient: <--- HTTP 200 https://tubilety.pl/api/ticket_validation/event003/a3000150 (374ms)
I/pl.itgenerator.kasownikdocel.RestClient: Date: Wed, 14 Jun 2017 09:43:42 GMT
I/pl.itgenerator.kasownikdocel.RestClient: Vary: X-Forwarded-Proto
I/pl.itgenerator.kasownikdocel.RestClient: Cache-Control: no-cache
I/pl.itgenerator.kasownikdocel.RestClient: Content-Length: 26
I/pl.itgenerator.kasownikdocel.RestClient: Content-Type: application/json
I/pl.itgenerator.kasownikdocel.RestClient: Via: 1.1 cache2 (squid)
I/pl.itgenerator.kasownikdocel.RestClient: Connection: keep-alive
I/pl.itgenerator.kasownikdocel.RestClient: OkHttp-Selected-Protocol: http/1.1
I/pl.itgenerator.kasownikdocel.RestClient: OkHttp-Sent-Millis: 1497433420642
I/pl.itgenerator.kasownikdocel.RestClient: OkHttp-Received-Millis: 1497433420998
I/pl.itgenerator.kasownikdocel.RestClient: {"name":"A3","quantity":4}
I/pl.itgenerator.kasownikdocel.RestClient: <--- END HTTP (26-byte body)
E/DetailActivity: Ticket Posted
V/MediaPlayer-JNI: native_setup
V/MediaPlayer: constructor
V/MediaPlayer: setListener
V/MediaPlayer-JNI: setDataSourceFD: fd 57
V/MediaPlayer: setDataSource(57, 962608, 254560)
V/MediaPlayer: message received msg=8, ext1=0, ext2=0
V/MediaPlayer: notify(8, 0, 0) callback on disconnected mediaplayer
V/MediaPlayer: setVideoSurfaceTexture
V/MediaPlayer: prepare
V/MediaPlayer: message received msg=200, ext1=973, ext2=0
W/MediaPlayer: info/warning (973, 0)
V/MediaPlayer: callback application
V/MediaPlayer: back from callback
V/MediaPlayer: message received msg=5, ext1=0, ext2=0
V/MediaPlayer: New video size 0 x 0
V/MediaPlayer: callback application
V/MediaPlayer: back from callback
V/MediaPlayer: message received msg=1, ext1=0, ext2=0
V/MediaPlayer: prepared
V/MediaPlayer: signal application thread
V/MediaPlayer: callback application
V/MediaPlayer: prepare complete - status=0
V/MediaPlayer: back from callback
V/MediaPlayer: getDuration_l
V/MediaPlayer-JNI: getDuration: 1441 (msec)
V/MediaPlayer: decode(62, 962608, 254560)
I/MediaPlayer: Don't send intent. msg.arg1 = 0, msg.arg2 = 0
E/MediaPlayer: Should have subtitle controller already set
E/DetailActivity: inScanQR
W/ApplicationPackageManager: getCSCPackageItemText()
E/ZXingScanner: ScannerInitialized
I/Choreographer: Skipped 36 frames!  The application may be doing too much work on its main thread.
V/MediaPlayer-JNI: native_finalize

0 个答案:

没有答案